-
Notifications
You must be signed in to change notification settings - Fork 4
Home
- Youtube Videos
- Introduction
- Installation in Icestudio
- Using the collection
- Examples
- Translations
- Organization of the collection
- Creating new constants
- Contributing to the Collection
All the documentation is in English, except these videos which are in Spanish
Click on the images to see the videos in Youtube
In this collection you will find constant values of different sizes, including Bits, for using in your digital circuits for opensource FPGAs created with icestudio
These are examples of such constants:
The collections are a groups of folders containing blocks, examples, translation and images compressed into a .ZIP file. You can learn more about this organization on this wiki section: Organization of the collections
To install the iceK collection you can download the ZIP file from the latest release (click on Sorce code (zip)). Or if you want to have the latest changes, get the ZIP directly from the repository (main branch): icek-main.zip. You can also clone the repo and use the collection from there, or fork the repo and clone it if you want to contribute
In the standard installation the collection is placed in the .icestudio/collections/
folder inside your HOME folder. For installing it from icestudio follow these steps:
- Download the collection .ZIP file. For example iceK-main.zip (latest) or iceK-0.1.0.zip (stable)
- From icestudio click on the Tools/Collection/Add Menu:
- Select the .ZIP file with the collection and click on Open
- Write the name you want for the collection (or leave the default) and click on OK
- The collection is installed! You can select it from the Select/Collection Menu
- Access to its content at the top right menu
You can also access to the collections using the Colection manager
If you enter into the .icestudio/collections
folder you will see the installed collection (iceK-0.1.0):
You can install the collections in another folders. These are called external collections. They allow us to use collections cloned directly from a github a repo, so that you can use them, add new blocks and contribute
The first step for using external collection is configuring the folder in which they will be placed. You can do this from the Edit/Preferences/External Collections Menu
Write down the absolute path for storing the Collections and click on OK
Now you can place in that folder all the external collections you want. Either uncompresing the ZIP files, or cloning the collections from a repo. For example, you can clone the latest iceK version from the repo:
obijuan@Hoth:~/Develop/Collections$ git clone https://github.com/FPGAwars/iceK
Every time icestudio starts, I will read the external collections from that folder. If icestudio is already started, you can update the external collection just by clicking on the Tools/Collections/Reload
In the Select/Collection Menu you will see all the installed collections, either internal or external:
And also in the collection manager:
In this collection there are two types of blocks: The generic constants and the normal constants
The generic constants are represented by the k
symbol. They have one parameter for giving them a value. For example, this is the 1-bit generic constant. You can write 0 or 1 as a parameter
And this is the 8-bits generic constant, with a value of 255. The value can be set in binary, hexadecimal or decimal:
The normal constants are blocks with a given value (that cannot be changed). For example, this is the 2-bits contant value 3
All the normal constants are created from a generic constant, giving its value to the parameters. If you go inside the 2-bits constant value 3 this is what you will see:
You can find some examples tested for different boards in the icestudio File/Examples menu, once this collection has been selected (Select/Collection/iceK). Just open the example and upload directly to your board
You can see more details on how to test the examples for diferent boards on this section: Testing the examples
All the examples are also located in the folder examples in this repo
The 1-bit constant '1' is used for turning on a LED
The 2-bit constant '3' (11 in binary) is used for turning on two LEDs
A 1-bit generic constant is used for turning on or off one LED
A 4-bit generic constant is used for turning on or off four LEDs
The collection can be translated to any language. Any translation is very welcome!! 😀️ If you want to translate it to your native languaje please follow these instructions: Translating the collection into your language
In the collection repo you will find the following folders:
- blocks: This is were the icestudio blocks are located, with all the elements of the collection, organized by subfolders
-
examples: Circuit examples ready to use in Icestudio. Inside this examples there are some special elements:
- 00-Index.ice: Collection index. Here you will see some of the more important blocks that the collection contains:
When you open it you will see something like this:
-
TESTs: This is used by the collection developer for testing the different blocks. Everytime a block is added, it should be tested somehow. That tests are in that folder. This is not likely for the standar user, so you can skip it
-
icons: Here you will find the SVG files for the icons used in the collection blocks. You can edit them or create new icons from them
- block+icon: Some of the blocks in SVG, for using them in your documentations. These are some examples:
- locale: Folder with the English texts and their translation into other languages
- wiki: Images used in this wiki
You can easily create new constants from the current blocks. Just follow these steps:
- Place a constant similar to the one you would like to create. Image you want to add the 5-bits constant 31: Select for example the 5-bits 0 constant from Bus/Bus-05/value-0 and place it on a circuit
-
Select the block and click on Edit/Copy (or press Ctrl-C)
-
Click on Edit/Clone. It will create an indepent copy of the block
- Doble click on the new block for going inside it
- Click on the top-right lock for editing the block
- *Write the new value for the constant. In this example we will use the value 31
- Change the block description, version, name and icon. Click on Edit/Project information and change the data. For updating the icon you should first have the icon in SVG and then open it from the Project information window
- Finished. Click on OK and then on the lock. Your new block is ready!
- The NEW BLOCK IS NOT in the collection YET!
NOTE that this new block has not been saved into the iceK collection. It is available for you to use in your circuits, or copy and paste to other circutis. If you want to save it into some folder, or into another collection, enter into the block again and click on File/Save as. Select the folder were you want to save it and click on OK. If it was saved in the block folder of another collection, it will be available the next time you run icestudio and open that collection. Or you can click on Tools/Collection/Reload and it will be available in that collection
Contributions are welcome! 😀️
You can contribute in different manners:
- Adding new constants. Maybe you would like to add the constants you need for your circuits and share them with the community
- Translating the collection to your language
- Migrating the examples to more boards
These are the steps to follow for contributing:
- Fork the icek repo into your github account
- Clone it to your computer
- Install the collection as an external collection, so that you can access it from icestudio (See: Other uses: External collection)
- Create your own constant (See Creating new constants)
- Save it click on Tools/Collection/Reload for using it and testing it
- Commit and push to your repo
- Emit a pull request
-
The main language is English: Create all your blocks and examples in English (the English text should be inside de .ice files). Then translate it to your local language (if you like), following the instructions mentioned here: Translating the collection into your language
-
The iceK collection is ONLY FOR CONSTANTs. If you want to contribute with other type of blocks, do it in its corresponding collection (iceGate, iceMux, iceRegs....)