We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
ARM MDK 3.4: module / function startadress. I would like to have a flash programming function on a specified address (0xf000) from where the normal program can be updated. This would be a simplified approach for ISP. If something goes wrong, JTAG will solve this problem. I could not find a linker control which would allow this. I already searched forum, with no success.
Functionality: a) first installed program (0x0000..<0xf000) contains ISP function on 0xf000 b) updated program (0x0000..<0xf000) does not contain ISP function, only absolut call to it.
Thanks for any hints Werner
Thank you, I still feel "in the dark". Is there a step by step explanation of the therms used for this scatter script language ie:
LR_IROM1 is this a reserved word? I can guess IROM1 means internal ROM, LR is not clear to me.
using the help system and it's examples just leads me to places, where experts that already know most of it understand it's full meaning, the introductional is too abstact/generic for me. Maybe I'm the only one here, maybe I'm getting old..
> Thank you, I still feel "in the dark". Is there a step by step > explanation of the therms used for this scatter script language ie:
LR_IROM1 0x00000000 0x00020000 { ; load region size_region
A load region describes the memory map before reloction, usually in a non-volatile memory.
The execution regions define both, the contents of the load region, as well as the memory map after relocation.
ER_IROM1 0x00000000 0x00020000 { ; load address = execution address
ER_IROM1 describes what can stay in flash for proper operation.
*.o (RESET, +First)
That would be the startup code including vectors. +FIRST means that this has got to be first in the region. The order in the scatter loading file has no impact on the actual order of elements.
*(InRoot$$Sections)
Some portions of the C-library have to be in flash as well. As a short hand, these are refered to by the name "InRoot$$Sections".
.ANY (+RO)
Any other read-only portions of the image (code, literal pools) go here.
} RW_IRAM1 0x20000000 0x00008000 { ; RW data .ANY (+RW +ZI) }
All variable go into RAM.
}
To get what you want, you'd have to divide your flash into two regions:
LR_IROM1 0x00000000 0x00020000 { ; load region size_region ER_IROM1 0x00000000 0x0000f000 { ; load address = execution address *.o (RESET, +First) *(InRoot$$Sections) .ANY (+RO) } ER_IROM2 +0 (0x00020000-0x0000f000) { *.o (ISP_SECTION, +RO) } RW_IRAM1 0x20000000 0x00008000 { ; RW data .ANY (+RW +ZI) } }
Now all flash space between 0x0000f000 and 0x00020000 can be used for ISP. You will have to adapt this to your requirements.
> LR_IROM1 is this a reserved word? I can guess IROM1 means internal > ROM, LR is not clear to me.
The region names are just identifiers. Only some names have a special meaning (not reserved, though).
> Using the help system and it's examples just leads me to places, > where experts that already know most of it understand it's full > meaning, the introductional is too abstact/generic for me.
infocenter.arm.com/.../Degxrsh.html
And don't forget to tell MDK not to clobber your scatter file! Or give it a different name.
Regards Marcus http://www.doulos.com/arm/
Thanks Marcus, your extensive explanations gave me a good starting point. Checking out doulos.com made me order the C und C++ für Embedded Systems book.
Werner