This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

RAM Mapping

Hello,

I'm having a little problem to map the RAM memory in my project.
I'm using LPC2478 and I have 3 memory banks at
0x80000000 with size 0x200000
0x81000000 with size 0x200000
0x82000000 with size 0x200000

The memory map should be :
stack at internal ram 0x40000000
module bank.c using all the tree banks for database

How do I write the scatter file to alloc this memmory map?

Parents Reply Children
  • Thanks for your help.

    But I think is not exactly that.
    Look a simple example, a have this three areas

    long Bank0[0x80000];
    long Bank1[0x80000];
    long Bank2[0x80000];

    But when I compile the folowing messages is shwon:

    "No space in execution regions with .ANY selector matching Section .bss(banck.c)"

    "Sections of aggregate size 0x600000 bytes could not fit into .ANY selector(s)."

    But in the memory window all parameter are configured with the write address and size. I have area enough to alocate those banks. How do I write the all scatter file?
    What should I do? I'm getting crazy!

  • I assume you don't have enough RAM (at need 1536 KB for these arrays only!).
    don't go mad. that will disturb you reading the manual :-)

  • Hello,

    I have RAM enough, that I'm sure.

    A long use 4 bytes, so an array with 0x80000 longs will use

    0x80000 x 4 bytes = 2097152 2Mb each array

    So if I have 3 external memorys with 2097152bytes and I want to alocate 3 arrays with 2097152bytes I dont understand how is not memory enough.

    Excuse me if I was not clear enough.

    Thank you

  • the best things to do are:
    * place every buffer in a separate C module, and treat it like in the previous post - namely, place the generate .o file in a particular section in memory as demonstrated above.
    * read the document to which I refer above. it will answer all of your questions.

  • or you can use the __at directive, like this:

    const unsigned long long sys_software_programming_success_high __attribute__( (at(FIRMWARE_ID_ADDR+0xFF8) ) ) = 0xFFFFFFFFFFFFFFFF ;