Altera_Forum
Honored Contributor
15 years agoMEMORY TEST program usage
Hi guys,
I need to test DDR on my board. I've created SOPC builder project with Nios and 2 memories - on-chip and DDR controller. Both reset and exceptions point to on_chip. Altera provides memtest.c which allows to test your external memory. It is stated there thatThe RAM test is destructive to the contents of the RAM. For this
* reason, you MUST assure that none of the software sections are located in
* the RAM being tested. This requires that code, data, and exception
* locations must all be in a memory seperate from the one being tested.
So in the BSP settings all sectors go to the on_chip RAM. But I don't know exactly how this memtest program knows which specific memory to test??? Basically, first you write in the Nios console which specific range of memory you would like to test by writing address in 0xXXXXXXXX format to the memory_base and memory_end variables. Then the program tests this specific locations say, MemTestAddressBus(memory_base, memory_size); But it doesn't have sense for me. Because 0xXXXXXXXX can be in the on-chip memory??? How to make sure that I'm testing the external DDR? Please help. P.S. Some additional information. If I put .text section to on_chip I see strange symbols, like hieroglyph, instead of welcome text, etc. If I put .text section to DDR, my program stops execution after some seconds. I don't see any solutions, what i do wrong?