own bootloader and IAP problem
2004-10-27 by burner_itfi
hello friends i hope you can help me. I programmed a bootloader (sector 0) who can check the flashed application (sectors 1-13) if the application is correct and can flash a new application or configuration over can0, can1 or serial. After the start, the bootlaoder starts with a function pointer (when the check sum calculation is correct) to the startup code of the application the application. (the bootloader and the application are two projects, not one hex file). When the application get the message that it whould be flashed, it must call the programming function in the bootloader. I tried to jump from the application directly to the program function of the bootloader but the startup code of the application overwrite all variable of the bootloader so that the program function not correctly work. My Problem is, how i can tell the bootloader that it is not a normal start when the application jump with a function pointer back to the startup code from the bootloader, but it is call from the application and it go into program mode. best regards Tobi ps.: Sorry my english is not the best. ;-)