Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
20687 Discussions

nios2 fail to boot from onchip memory

Altera_Forum
Honored Contributor II
1,053 Views

*quartus 11.0 

hi all, 

 

we have a problem to put the software on the sof file, 

and i cant figure out the problem. 

 

the issue is: 

 

1. I have a SOPC system that has a nios processor with onchip memory. 

 

2. I have a working hardware and software (the software make one led blink). 

 

3. i compiled and downloaded the SOF file to the FPGA, 

then i used the "software build tool for eclipse" to run the program. 

result: program works, the led is blinking. 

 

4. reset vector points to the "on chip memory". 

on-chip memory is pointing to initialize from a specific hex file "onchip_memory_2.hex". 

 

5. then i did the following:  

 

on the "software build tool for eclipse": 

make + run( to test to see if the led blinks) 

make generate-> make install (to generate the hex file) 

verified that the date on the hex file has changed. 

recompile the project on quartus 

see that the sof file has changed. 

download the sof file. 

 

i had expected to see a blinking led due to the software now been downloaded to the FPGA by the HEX file,  

 

but that was not the case! the led was a solid on, no blinking. 

 

 

can any one help me with this thing? 

 

what do i do wrong? 

 

 

yoav
0 Kudos
3 Replies
Altera_Forum
Honored Contributor II
336 Views

well, i solved the issue: 

 

i am posting the solution so it can help others. 

 

when booting from the flash or RAM, you need to point all prints to null. 

 

you do this by editinf the stdout (and others) to "none" in the BSP editor. 

 

if not, the code will freeze on any printf command in the code. 

 

 

hope this helps!
0 Kudos
Altera_Forum
Honored Contributor II
336 Views

hi, 

I am also having the same issue as posted in link. 

I am getting the error as "No rule to make targer 'mem_init_install'. 

can you please tell me why this error is coming. 

I am using quartus 11.0 and nios software build tools for eclipse.
0 Kudos
Altera_Forum
Honored Contributor II
336 Views

Hello yoav, 

 

I have the same problem. I am using printf in my code but has un-commented them. 

My program is not running when embedding the hex-file into the sof-file. 

Loading the program into memory with eclipse everything works fine. 

Any suggestions what could be wrong ? 

 

Best regard, 

 

Wamor
0 Kudos
Reply