Forum Discussion
Altera_Forum
Honored Contributor
21 years agoWhere is your read/write data stored?
nios2-download will set up the initial values of the text, rodata and rwdata sections before starting the processor. If you reconfigure the FPGA (as happens at powerup) then the initial values of the text, rodata and rwdata sections will be loaded from the configuration device (they're part of the SOF file). But if you just reset the processor then this just sets the program counter to the reset address. The text and rodata sections should not have been changed so they'll be OK, but the rwdata section will have been modified by your program from the expected initial values. This is probably what's causing the problem.