2012-11-20 05:04 AM
My application requires a BOOT loader that loads an application into a FLASH device. I have created two different applications:
A BOOT loader application. start 0x08000000 A FLASH application. start 0x08008000Both has vector tables.
The FLASH application must call some of the functions in the BOOT loader. Is there a clever way to do this? I use coocox IDE and stm 103ZE dev board .... Havent you some examples for better understanding? thanks for reply >:-) #bootloader-application-function2012-11-20 07:01 AM
You could add function entries into the vector table, or extension thereof.
In RealView you could provide a DEF (definition) file to the linker that pointed to functions at given addresses in a BOOT ROM and the linker would bind to them, the same could probably be achieved with linker script files, or casting. This is probably something I'd avoid in a flash device.2012-11-20 04:53 PM
As a matter of fact, I just did this today. I simply created function pointers to those functions that I want to access from the main application. I created these as const so that they would be stored in flash. Simply locate these pointers at a location in flash that will not change (like right after the bootloader vectors).