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

Cortex M3 - how the startup works

Note: This was originally posted on 15th May 2009 at http://forums.arm.com

Hi all,

I have some problems understanding the startup procedure of the ARM, here Cortex M3.
Address 0x0000.0000 holds the MSP (main Stack Pointer) and it is the 1st register the Cortex will read after a reset/start.

Address 0x0000.0004 holds the Reset Vector and it will be read after reading the MSP before. Then it jumps to the address that is placed in this register. The rest of the program is then called.

Now the question is: when do I write the values to the both registers at address 0x0 and 0x4?

E.g. if I have my bootcode at address at flash address 0x100 I need to write the value into the register 0x4. But when I power on the device it just will read from 0x4 before I can write to there.
0