Forum: ARM programming with GCC/GNU tools bootlader design

Author: Roman Mashak (romez777)
Posted on:

Rate this post
0 useful
not useful
Hello dear friends,

last 2 weeks I've spent studying ARM C-startup concepts, remapping and
the similar. I need this to implement a simple bootloader.

It looks to me I more or less understand these things and this are some
ideas I came up with:

- Bootloader I'm designing is not universal, but rather for upgrading
the firmware of specific structure and purpose, this means boot code
will be aware of some peculiarities of the F/W
- the application (i.e. firmware) will use vectors and exceptions (fiq &

Therefore, this is how I view the design:
1) the main application (which is supposed to be upgraded by bootloader)
copies vectors table in to RAM
2) then sets REMAP bit, this maps RAM region to 0x200000 AND 0x0
3) the vector table of application should be linked on 0x0 address,
while the rest part of it on the other address (for example, 0x101000,
providing that bootcode resides in the first 0x1000 bytes)
4) on bootloader side - remapping is not necessary (all boot does is
load application's image and burn on flash). We MAY need remapping for
flash operations, in order to avoid compiler-specific features, for
example IAR's '__ramfunc' or similar...

This is my vision and understanding of the whole thing. Your comments on
it are welcome!


Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]

Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.