AnsweredAssumed Answered

EXTERNAL RAM WITH STM32F429DISCO

Question asked by gerson74 on May 14, 2014
Latest reply on Aug 7, 2014 by Clive One
Hi!
I would like to use the external RAM IS42S16400 present into the demo board STM32F429DISCO to store program variables.

To do that i modify the linker script 
MEMORY
{
  FLASH (rx)      : ORIGIN = 0x08000000, LENGTH = 2048K
  RAM (xrw)       : ORIGIN = 0x20000000, LENGTH = 192K 
  MEMORY_B1 (rx)  : ORIGIN = 0x60000000, LENGTH = 0K
  CCMRAM (rw)     : ORIGIN = 0x10000000, LENGTH = 64K
  SDRAM(xrw)      : ORIGIN = 0xD0000000, LENGTH = 4096K
}
.....
.....
.....

  .sdram :
  {
    *(.sdram)
    *(.sdram*)
    *(.sdram_rodata)
    *(.sdram_rodata*)
  } >SDRAM

In the main program 

    SDRAM_Init();
    /* FMC SDRAM GPIOs Configuration */
    SDRAM_GPIOConfig();
    /* Disable write protection */
    FMC_SDRAMWriteProtectionConfig(FMC_Bank2_SDRAM,DISABLE);

Up to here it seems to work correctly.


Can i define a variable in this way??

uint8_t my_data[1000]  __attribute__ ((section (".sdram")));

If i put this instruction, the compiler generates a .bin too large and the system does not work.

Thanks!!!

Outcomes