2018-01-21 07:39 PM
I want to realize a OTA function that IAP jump to APP1 or APP2. But I have a doubt whether need I to generate two APPs for OTA, because the APP1 and APP2's vecotor is different(If my customer has done lots of OTA, diffenrent devices maybe in different APPs )? Is there any intelligent way to solve this problem?
#stm32f0-iap-multi-app2018-01-21 08:30 PM
People have used relocatable object files to solve such issues.
2018-01-21 11:31 PM
Can you give me more details? I'm a green hand for it. How to modify the relocatable object files and how to use it?
2018-01-22 09:19 AM
You'd want to use/create an object file format that provides relocation information that you fixup and commit when you write to a specific FLASH address you are using for APP1 or APP2
https://en.wikipedia.org/wiki/Object_file
This would be covered by 'Linkers and Loaders' type texts and course work. Coding a demonstration of this goes beyond the scope of things I'm going to provide on the forum.
2018-01-22 03:40 PM
Is there any related examples or articles?
2018-01-22 05:55 PM
Perhaps you can take an example firmware and link it at the two possible addresses, and then 'diff' the binary images to see how many things are different between the two to gauge the scope of the differences, and how you might efficiently encode that information. Selection 'position independent' compiler options where available.