I am working with KW24D512 and I am trying to add ota functionality to my application.
I have added ota client to my own application.
The new image is stored into internal flash (gEepromDevice_InternalFlash_c & gUseInternalStorageLink_d)
I'm able to get the new image from the ota server + test_tool_V12 (OTA updates / OTAP thread). The image is loaded in flash and the function OTA_SetNewImageFlag() returns FTFx_OK.
The client resets, but it never start!!
It looks like a bootloader problem because the ota client image built with bootloader binary don't start without iar debugger.
There is no problem with the same ota client build without bootloader.
I have tried :
OtapBootloader.bin from framework \bootloader\bin
BootloaderOTAP_KW24D512.bin from framework \bootloader\bootloader_OTAP_serial\bootloader_OTAP_KW24D512\exe
And I got the same failure!!
Which bootloader binary file do I need to use to support ota client feature on KW24D512 based application?
The bootloader project used for OTA client is at the following location:
As a first test, please do the following:
1. Write the bootloader binary to board; (you can do this from IAR or using the TestTool -> Firmware Loader -> Kinetis Firmware loader);
2. Write the Thread node binary. From your comment, seems that you put the right options, but to double check consider the following:
- If you are using end_device_ota_client you should just update the gEepromType_d from config.h file to match to internal flash and to put gUseInternalStorageLink_d=1 at project linker option.
- If you are not using the demo example, please consider the following:
3. Reset the board to see if the firmware pass over the bootloader and starts with Thread node firmware (at this step the debugger should not be attached to board).
If step 3 is not working, please consider to remove the gEraseNVMLink_d=1 from the project linker options (thread node firmware) and repeat the steps 1, 2, 3.
It will depend on the iDE you are using, but by any chance did you set the Bootloader configuration in the project? This configuration it's mentioned in the Kinetis Thread Stack Over-the-Air (OTA) Firmware Update User’s Guide.
The gUseBootloaderLink_d should be set to 1 to tell the application the where it should be located.