Hi, I am using KL03Z32 for our project. In Figure 11-2 in the Reference Manual (KL03 Sub-Family Reference Manual, Rev. 4, August, 2014), there is a judgement that "Is user application valid?". I would like to understand how the ROM boot loader know the user application is valid or not. It would be appreciated if someone can share the answer or give me a hint.
Solved! Go to Solution.
Hello Felix Tsai:
Please check the response in the next thread:
If you have any doubt just let me know.
Regards!,
Jorge Gonzalez
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hello Felix Tsai:
Please check the response in the next thread:
If you have any doubt just let me know.
Regards!,
Jorge Gonzalez
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Jorge,
Thanks for your reply. The thread you hinted is not the answer to my question. I have to implement the failsafe mechanism when the firmware update fails due to unstable power, such as the power is unintentionally unplugged when firmware update is in progress. From the reference manual, I understood how to make KL03Z32 boot from ROM bootloader when power on resets. But no information about how the ROM boot loader know the user application is valid or not, so that I cannot understand if Timeout detection is enabled or not. If I know how bootloader code check the user application is valid or not, I can control bootloader code to disable Timeout detection and stay in ROM bootloader, i.e. not jump to the corrupted user application in the flash memory.
Felix.
You should reserve an area of memory that the boot loader clears on start, and fills with a specific pattern on successful completion. I can't think of a good way to actually ensure the validity of the firmware otherwise.