SPI Programming Sequence for iCE40HX8K-EVB

Started by cdan, April 03, 2026, 01:04:38 PM

Previous topic - Next topic

cdan

I am using an external programmer (pico-serprog) to program the iCE40HX8K via SPI. Programming only works if C_RESET is pulled LOW before powering on the board. If C_RESET is pulled LOW after power is already applied, SPI communication fails.

Can you confirm: When C_RESET is pulled LOW while the board is already powered on, do the SDI, SDO, and SCK pins on the FPGA chip enter high-impedance (Hi-Z) state? Is there a specific reset/power-on sequence required for the iCE40 to enter SPI programming mode?

LubOlimex

Yes, this is expected way to reliably be able to program via SPI. This is mentioned in our guides, for example when using OLIMEXINO-32U4 to re-program the board via Arduino IDE:

https://github.com/OLIMEX/iCE40HX1K-EVB/tree/master/programmer/olimexino-32u4%20firmware

Notice this part in the README.md:

"BUT+RST to start USB to Serial Hold BUT down until last restart, i.e. for a rather long time. Think of BUT as a shift-button to RST, but that must be held down a long time after RST has been released.

This is useful when developing FPGA-projects that use serial communication with the computer that you used to program it with. You don't have to buy an extra USB to serial converter or use an extra USB cable or port."
Technical support and documentation manager at Olimex