Other Parts Discussed in Thread: MSP430F5438A
Hello
I am trying to help my customer develop a Firmware update mechanism based "loosely"on the bootloader but one where the current code can keep running while receiving the new code (firmware). We are using the F5438 experimentors board for this work and would like to be running from Flash Bank 2 while receiving code into Flash Bank 3, then switch the Vector table over when all the code is received.
My problem is getting the Linker command file to place all the code and relevant tables into FLASH2 or FLASH3 as I can't get the .cinit section to go anywhere apart from section FLASH (starting at 0x5C00). If I change
.cinit : {} > FLASH to .cinit : {} > FLASH2
I get the Error below, any ideas how I can get around this ?
C:\ti\ccsv4\ccsv4\utils\gmake\gmake -k all
'Building target: Firmware_Upgrade.out'
'Invoking: Linker'
"C:/ti/ccsv4/ccsv4/tools/compiler/msp430/bin/cl430" -vmspx -g -O0 --define=__MSP430F5438A__ --diag_warning=225 --code_model=large --silicon_errata=CPU22 --silicon_errata=CPU21 --silicon_errata=CPU23 --silicon_errata=CPU40 --printf_support=minimal -z -m"Firmware_Upgrade.map" --stack_size=160 --heap_size=160 --use_hw_mpy=F5 --warn_sections -i"C:/ti/ccsv4/ccsv4/msp430/include" -i"C:/ti/ccsv4/ccsv4/tools/compiler/msp430/lib" -i"C:/ti/ccsv4/ccsv4/tools/compiler/msp430/include" --reread_libs --rom_model -o "Firmware_Upgrade.out" "./main.obj" "./BSL.obj" -l"libc.a" "../lnk_msp430f5438a.cmd"
<Linking>
"./autoinit.c", line 30 (approximate): warning: relocation from function
"_auto_init" to symbol "__cinit__" overflowed; the 17-bit relocated address
0x1028a is too large to encode in the 16-bit field (type = 'R_MSP_REL16'
(161), file =
"C:\ti\ccsv4\ccsv4\tools\compiler\msp430\lib\rts430x.lib<autoinit.obj>",
offset = 0x00000004, section = ".text:_auto_init")
"./autoinit.c", line 30 (approximate): warning: relocation from function
"_auto_init" to symbol "__cinit__" overflowed; the 17-bit relocated address
0x1028a is too large to encode in the 16-bit field (type = 'R_MSP_REL16'
(161), file =
"C:\ti\ccsv4\ccsv4\tools\compiler\msp430\lib\rts430x.lib<autoinit.obj>",
offset = 0x0000000e, section = ".text:_auto_init")
warning: output file "Firmware_Upgrade.out" cannot be loaded and run on a
target system
'Finished building target: Firmware_Upgrade.out'
' '
Build complete for project Firmware_Upgrade