Hi,
I'm using mcv5223X board. I want to program a bootloader (BL) for update the main code. I saw the bare minimum boot loader, but this code accepts programs up to 128 kb, but i need upload bigger programs. The idea is to program a BL that runs after the reset and check a TCP/IP comand. If the comand is the correct, the program will recive the code (in parts) and then flash it to de asignated space (in parts too). When the upload finishes, the BL will check the program is ok and then jump to it.
If the BL doesn´t recive the comand, it will check the program and then will jump to the program.
I saw in the bare minimun bootloader (uTaskerBootV1.4_CW7) that in file mcf5223X_boot.s after calling uTaskerBoot apears that:
move.l #0x00000800,a0
move.l (a0),sp
move.l #0x00000804,a0
move.l (a0),a0 /* use for standard boot loader from internal FLASH */
jmp (a0) /* jump to the main program */
I suppose that the main program start in the address 0x804. Here I have a question, when I program the main application how can I define the address where de main sub is flashed?
The second question is how to initilizate the Exception Vector Table in the main application: The default lcf file defines vectorrom (RX) : ORIGIN = 0x00000000, LENGTH = 0x00000400. And in the position 0x004 calls the _starup. So i can't erase modify this page to avoid problems.
thanks for all
Gonzalo
PD: sorry about my bad english