Forum Discussion
NiosII booting from on-chip memory SPI issue
- 2 years ago
Hi all,
Just an update to this issue.
The problem has been resolved by disabling the alt_printf statement in my C code. My .pof works now, and it can send the spi commands after power cycling the board.
My guess is that as there is no communication between the board and the nios2 terminal, the alt_printf pointer got lost when executing the function. Hence when loading .pof, all alt_printf must be disabled.
Regards,
Reuben Goh
Hi,
Thank you for the feedback.
The Tx and Rx led on our board is continuosly blinking.
Would like to ask you to check on few things.
- If running .pof file, does it always stop at 53rd line?
- Does NiosII output prints using .pof continuos or stopped after 53 lines as well?
- If above is true, can you try to perform test with the simple normal hello world prints and see if that can continue.
Below is changes we made -
for max 10 ocram using xip design, you need to use the on-chip flash ram IP and the on-chip memory(RAM or ROM) IP,
enable the mem init in the on-chip memory, and disable mem init in on chip flash, and use single uncompressed
then generate and compile in quartus.
for .hex generation, we need to use the mem_ini_gen in eclipse:
https://www.intel.com/content/www/us/en/docs/programmable/683689/current/application-12184.html
- Build mem_init_generate on eclipse follow the link above. (successful built will created mem_init folder under project folder)
- Go to platform designer and on the ram editor parameter , check box for "initialize memory content" and "enable non-default initialization file".
- Generate hdl and close platform designer.
- Go to Quartus and recompile.