I am trying to achieve the following scheme on the MCF5282.
- Internal Flsah: Sector 0 (16KB): Boot Loader
- Internal Flsah: Sector 1 (16KB): Inventory and Sytem Data
- Internal Flsah: Sector 2 to 16 inclusively: Image A (240 Kbytes)
- Internal Flsah: Sector 17 to 32 inclusively: Image B (240 Kbytes)
When the system boots up, the BootLoader checks a byte in Sector 1 at a specific address and, based on the value read at a specific address (say 1 or 0), decides to jump to Image A or Image B.
Thus, I will burn:
- Image A starting address 0x0000 8000
- Image B starting address 0x0004 4000
The Data of both Image A and B will be in SRAM at specific address.
- Is this scheme possible?
- There is very little explanation in “CodeWarrior Build Tools Reference ColdFire Architectures Edition” manual on the Position-Independent Code. Very vague and unclear. Is there more explanation on this Position-Independent Code and data?
- How do I set up my linker file for Image A and Image B to be address independent? In other words, I don’t want to have a specific linker file for Image A and a specific linker file for Image B but rather a “generic” linker file for both. Is it possible?
- This “generic” linker file should therefore specify the Data that will be at fix address in SRAM. Nevertheless, the address of a) Vector table, b) Constants and c) code, should be relative to the stating address of the image in Flash.
Is this feasible?
Message Edited by SVC1 on 2008-04-11 03:58 PM