I'd like to implement application bootloading using local storage on an EM3587, as described in AN772 and UG103-6. I'm having trouble figuring out how to implement the local storage side - specifically how to write the new image into the top half of local flash. I believe that it's a matter of setting up a halBootloaderAddressTable, then calling the appropriate hal API's in bootloader-interface-app, but the specifics are escaping me...
Any hints, documentation, or example code would be greatly appreciated!
By "top half of local flash" you mean the higher-addressed half, right? With the local storage bootloader, the application is already configured to use the upper half as download space, and you don't need to do anything additional. Just make sure you select the local storage bootloader as the bootloader type when you build the application at the OTA client side, and have these plugins enabled:
OTA Bootloader Cluster Client
OTA Bootloader Cluster Client Policy
OTA Bootloader Cluster Common Code
OTA Bootloader Cluster Storage Common
OTA Cluster Platform Bootloader
OTA Simple Storage EEPROM Driver
- Check SOC Bootloading Support. You can leave other configurations as defaults.
OTA Simple Storage Module
Thanks Yuping! The concept I was missing is that the application (via bootloader-interface) uses the halBootloaderAddressTable (and thus all the storage access functions) directly out of the bootloader, and you don't need to provide it separately. I have it working now with no problems - simple once I understood how it all fits together!
Glad to hear you got it working!