We follow the OTA guide: Add DFU support to your application
Add below code in main.c:
Our prj.conf:
We follow the OTA guide: Add DFU support to your application
Add below code in main.c:
Our prj.conf:
This is my partitions.yml file in build folder:
app: address: 0xc200 end_address: 0x45000 region: flash_primary size: 0x38e00 mcuboot: address: 0x0 end_address: 0xc000 placement: before: - mcuboot_primary region: flash_primary size: 0xc000 mcuboot_pad: address: 0xc000 end_address: 0xc200 placement: before: - mcuboot_primary_app region: flash_primary size: 0x200 mcuboot_primary: address: 0xc000 end_address: 0x45000 orig_span: &id001 - mcuboot_pad - app region: flash_primary sharers: 0x1 size: 0x39000 span: *id001 mcuboot_primary_app: address: 0xc200 end_address: 0x45000 orig_span: &id002 - app region: flash_primary size: 0x38e00 span: *id002 mcuboot_secondary: address: 0x45000 end_address: 0x7e000 placement: after: - mcuboot_primary align: start: 0x1000 region: flash_primary share_size: - mcuboot_primary size: 0x39000 settings_storage: address: 0x7e000 end_address: 0x80000 placement: align: start: 0x1000 before: - end region: flash_primary size: 0x2000 sram_primary: address: 0x20000000 end_address: 0x20020000 region: sram_primary size: 0x20000
Hi Jimmy,
I noticed that in the log MCUBoot was responding with "NOT SUPPORTED" it seems that there were an issue with confirming the image.
Have you tested without changing the signing key ? Have you managed to do DFU update with MCUBoot before ?
As far as I know CONFIG_MCUBOOT_SIGNATURE_KEY_FILE is obsoleted and you should use CONFIG_BOOT_SIGNATURE_KEY_FILE in the mcuboot configuration only (either by the mcuboot prj.conf of by the overlay in child_image\mcuboot.conf).
But I think it's the best to not changing the key and use the default key for testing first.
Please try to follow the guide here. Please use option "Confirm only" when you test.
I delete the below config:
app prj.conf:
I use the new version of Device manage app, it show "Image not confirmed".
So, why my image cannot confirmed ?
Hi Jimmy,
I was just following the guide again and it worked just fine.
Could you try to test the following project. It's made with NCS v2.2.0 but it should work with earlier SDK as well.
I also attached here the two bin files that you can use to test. By using app_update3, the device should advertise as "Zephyr Heartrate 3" instead of "Zephyr Heartrate 2" and you can use the other file to update back to "Zephyr Heartrate 2".
The hex and bin file was built for nRF52832 but it would work with nRF52833 as well.