Hi @ all,
I'm trying to implement a Bootloader on my MC9S08DZ60.
I have several questions but I didn't find any answers in the forums that match to my problem. So I am looking foreward to your replies.
1. is it possible to flash the bootloader in the protected section of ROM?
I want to make a application in C for the bootloader code which can flash a application program via CAN bus.
2. How is it possible to flash the user application to another ROM-Adress (unprotected)?
3. How can I jump from user application to bootloader and from bootloader to user application?
4. Can I flash two different programms with P&E micro USB Multilink interface? This is for testing the jumps between user application and bootloader. How should I do this? What files have to be adjusted?
5. Do you know other issues I have to take care about (Interrupt vector table relocation, .prm-file modifications)?
PE micro USB multilink interface
For the background informaton: The bootloader which I have to develop will be programmed to each ECU. The user application will be done seperately and should be flashed onto the controller via CAN-Bus. If an Reset occours the bootloader should start and chack, if there is a user application programmed. If so the bootloader should start the user application.
When the user application receives a special CAN-Message the bootloader should start agaín to erase the chip and flash a new user application.
When no user application is programmed on the chip the bootloader should run and wait for the user application to be flashed.
My idea is to programm a bootloader and locate it into a protected area of the Flash ROM with PE micro. When a user application is developed it should be possible to flash it into the unprotected area of Flash ROM also using PE micro but without overwriting the bootloader.
I read AN 2295 but I don't have experience with assembler code. The application will be programmed in C.
Thank you very much for your help.