Forum Discussion
Altera_Forum
Honored Contributor
16 years agoWriting SDRAM HELP !!!!!!!!
Hi, I wrote a function in C to W SDRAM memory : void write_sdram() { int *buffer = (int *) 0x00800000; // SDRAM addr base buffer[0]=0xaaaa; buffer...
Altera_Forum
Honored Contributor
16 years agoCould it be because int is 32 bits data type variable? Try alt_u16 for buffer and I think this will work.
--- Quote Start --- Hi, I wrote a function in C to W SDRAM memory : void write_sdram() { int *buffer = (int *) 0x00800000; // SDRAM addr base buffer[0]=0xaaaa; buffer[1]=0xcccc; } When I read the SDRAM with altera DE1 control panel data is : addr 0 = aaaa addr 1 = 0000 addr 2 = cccc addr 3 = 0000 Why ??? If the SDRAM data width is 16 bits , I'm waiting for addr 0 = aaaa addr 1 = cccc Help me please !!!!! --- Quote End ---