How to configure the Kéfir I board using iCEcube2 + Diammond programmer (step by step)

  1. Start iCEcube2, for example running /opt/iCEcube2.2016.02/iCEcube2, then choose New project:

  2. Use Kefir_Capsense as project name and choose the icecube2_pap folder included in this package. Choose the iCE40 family and the HX4K device, make sure the selected package is TQ144. The rest of the default values are good:

  3. Select the Next button and you'll get the dialog used to select the source files for our project. Choose the kefir_capsense.v file from the verilog folder and add it to the list (>>):

  4. Now synthetize the project running Synplify Pro (doble-click):

  5. Once finished select the Constraint Files in the Add P&R Files section:

  6. Here we add the kefir_i.pcf file from the constraints folder:

  7. Doble-click on Run P&R to perform the place and route for our project:

  8. The final result will look like this:

  9. To configure the FPGA we use another tool: Diammond Programmer. First connect the Kefir board to a USB port (well, Milk is the one connected), then start Diammond Programmer, for example running /usr/local/programmer/3.4/bin/lin/programmer.

    Select the Create a new blank project option:

    Note: the application will stop responding for some periods, will see the Milk's power LED blinking (not in versions 3.7 and newer)

  10. If the initialization process succeeds the tool will select the HW-USBN-2B (FTDI) cable, if not you can try using the Detect Cable button. Once you got the cable detected select FTUSB-1 as Port.

    Now select the Device Family:

  11. In the new dialog select the SPI Flash Programming mode.
    Choose the generated bitstream as Programming file. iCEcube2 generates this file as: Kefir_Capsense_Implmnt/sbt/outputs/bitmap/Kefir_Capsense_bitmap.bin (inside the working folder).
    Then select the flash memory used in the board: Vendor WinBond Device W25X40.
    Finally push OK:

    Here is an example of where is the .bin file:

  12. Press the Program button (the one with the green arrow):

  13. If all went ok you'll get something like it: