Forum Discussion
Altera_Forum
Honored Contributor
13 years agoif you use sdram in your project, mybe your vhdl code has some problems.
i used "tut_DE2_sdram_vhdl" to create project and test sdram pay attention to inputs and outputs, some pins like DRAM_DQ is inout pin; and this code in "tut_DE2_sdram_vhdl" is incorrect BA <= (DRAM_BA_1 & DRAM_BA_0); DQM <= (DRAM_UDQM & DRAM_LDQM); and must be replaced by this codes. DRAM_BA_1 <= BA(1); DRAM_BA_0 <= BA(0); DRAM_UDQM <= DQM(1); DRAM_LDQM <= DQM(0); pay attention. DRAM_BA_1, DRAM_BA_0, DRAM_UDQM, DRAM_LDQM are output pins, so the code about sdram that is given in "tut_DE2_sdram_vhdl" dose not asign any signal to this pins, so when you running a program by nios II eclipse or altera monitor program or altera debug client you mybe see this errors: 1- Downloading ELF Process failed! 2- Using cable "USB-Blaster [USB-0]", device 1, instance 0x00 Resetting and pausing target processor: OK Initializing CPU cache (if present) OK Downloading 00800000 ( 0%) Downloading 00803804 (87%) Downloading 01001000 (99%) Downloaded 15KB in 0.2s (75.0KB/s) Verifying 00800000 ( 0%) Verify failed between address 0x800000 and 0x803107 Leaving target processor paused by changing the tow line of code, that described above, the problem will be solved. pll settings and configuration must be done accordance to "tut_DE2_sdram_vhdl" document; DRAM_CLK assignment by pll is so important. for example this done in "tut_DE2_sdram_vhdl" document, by neg_3ns: sdram_pll PORT MAP (CLOCK_50, DRAM_CLK); if you create a project in Quartus, after changing and compiling the project you must regenerate the bsp in nois II Eclipse if you use this program to write c code for nios II processor. the problem solved: Using cable "USB-Blaster [USB-0]", device 1, instance 0x00 Resetting and pausing target processor: OK Initializing CPU cache (if present) OK Downloading 00800000 ( 0%) Downloading 00803B60 (88%) Downloading 01001000 (99%) Downloaded 15KB in 0.2s (75.0KB/s) Verifying 00800000 ( 0%) Verifying 00803B60 (88%) Verifying 01001000 (99%) Verified OK Starting processor at address 0x00800194 i'm not good in English, so ...