Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
12600 Discussions

BeMicro MAX10 does not keep program after power down?

Honored Contributor II




I've been following several tutorials on how to make my first Nios using an FPGA and finally I got it to work. I use Qsys to create a basic Nios/s and connect to the LEDs and one switch for reset. I program the sof file after I save the Qsys file and I'm back to quartus. Then I lunch the eclipse tool from within quartus 15.0.2. I have a small C program to toggle some bits and turn on some of the LEDs. It works fine. I can change the C program and reprogram (from within eclipse) and see the changes in the LEDs. 



The BeMicro MAX10 has an LED counter program running when I plug it into the usb port. Then I program the sof file with my Nios system. The LED counter program stops and all LEDs are off (that's their init state). When I program/run the eclips C program the LED reflects what I program in C. If I exit eclipse, quartus and disconnect the BeMicro from the usb port, then reconnect the BeMicro the counter LED program runs. Where did my Nios program go? 



I read the docs for MAX10. It looks like it has some ICB (internal config bits) that set what happens at power up. But I can't find them in the quartus software. Can someone shed some light into this please? 



0 Kudos
1 Reply
Honored Contributor II

MAX10 won't store it's configuration image if you're only programming it with the .sof file. You need to program it's FLASH memory, from which it boots at power up. You can do this as follows: 


1) In Quartus, select 'File' -> 'Convert Programming Files...'. 

2) Change the 'Programming file type' to 'Programmer Object File (.opf)' 

3) Ignore the 'Configuration device' but set the 'Mode:' to 'Internal Configuration'. 

4) In the 'Input files to convert' window, select 'SOF Data' and 'Add File...'. Select your '.sof' image. 

5) Click 'Generate'. 


In the programmer, load up your new '.pof' and check the 'Program/Configure' box next to 'CFM0'. Then Start. This will put your image into FLASH (rather slowly) from which your MAX10 will boot when you power the board up. 


I've not had cause to boot a Nios from a MAX10 device yet. However, an730 - nios ii processor booting methods in max 10 fpga devices ( discusses it at length. I'm sure it'll help. 



0 Kudos