FPGA, SoC, And CPLD Boards And Kits
FPGA Evaluation and Development Kits
6034 Discussions

Use Nios API codes to program flash

Liang_X_Intel
Employee
568 Views

Hi,

 

The standard way to burn .sof and .elf into flash is using flash programmer, it is easy and reliable. But I need to use my own NIOS code to write these two files into flash, and I see the .flash files in the /flash folder (generated by flash programmer during the programming). I extracted data portion from .flash files and write them into the flash without offset between two files. From flash read and manual comparison, I am pretty sure my own flash writing content matches what flash programmer does, the only problem is that when I power cycle the board, the FPGA didn't boot from flash automatically, my FPGA is cyclone IV, is there any extra step I missed here?

 

Thanks

LX

0 Kudos
2 Replies
Fawaz_Al-Jubori
Employee
385 Views

Hello.

This should be fine from Nios II point of view. We have used Nios II in board update portal applications before, check this link:

https://fpgacloud.intel.com/devstore/platform/16.1.0/Standard/board-update-portal-utilizing-epcq-flash-memory-reference-design/

 

You can find the software used to write the flash file to flash memory. However, this design was made for Cyclone V boards using EPCQ. In your case, no big difference between them since both are using EPCS/Q flash families.

 

I am checking with our configuration team regarding this case, once I get a feedback from them, I will let you know.

 

Thanks

0 Kudos
Fawaz_Al-Jubori
Employee
385 Views

Hello,

You might refer to the example above. Try to use the rbf file instead of flash file.

 

Thanks

0 Kudos
Reply