This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Secure DFU: Isn't upgrading firmware with custom files

Hello there,

I am working on secure dfu. I followed all the steps mentioned in this post and successfully created the secure .zip file.

Here's what I did(In this order):

  • Loaded Softdevice 6.1.1
  • Flashed "secure_bootloader_ble_s140_pca10056" into DK
  • Used nRF Connect app on my iOS device to upgrade the application.

Here's what is happening:

  • If I use any file from "secure_dfu_test_images", everything is being upgraded correctly. New appication is working as expected.
  • If I use the .hex file from /project/pca10056/blank/ses/Output/Debug/Exe and create a secure .zip file with nrfutil and try to upgrade the application, the upgrade is complete on nRF Connect App. Then LEDs will be off and nothing happens. On restart, nothing boots up - neither BLE nor new App code.
  • If I manually flash the same .hex file using ses -> Target -> Download File -> Intel Hex(After clearing all memory), the application code is working okay. So, it's not Application problem.


It'd be fantastic if you can help me understand what's going on here and tell me how to fox this.

Thanks

Teja

Parents
  • Hi, 

     

    If I use the .hex file from /project/pca10056/blank/ses/Output/Debug/Exe and create a secure .zip file with nrfutil and try to upgrade the application, the upgrade is complete on nRF Connect App. Then LEDs will be off and nothing happens. On restart, nothing boots up - neither BLE nor new App code.

     You should use ble_app_blinky_pca10056_s140.hex under nRF5_SDK\examples\ble_peripheral\ble_app_blinky\hex to create the .zip file to run the BLE application.

    -Amanda H. 

  • Hi, Amanda,

    Thank you for responding to my question. I have my own project(Without BLE) and I want to understand how to use DFU to update the application.

    As you know already, Everytime I "build" the application using SES, a new .hex file will be created in:

    nRF5_SDK_16.0.0_98a08e2\examples\peripheral\projectName\pca10056\blank\ses\Output\Release\Exe

    Can you please tell me what should I do, apart from creating update package using nrfutil, to update this application using nRFCOnnect app on my phone?

Reply
  • Hi, Amanda,

    Thank you for responding to my question. I have my own project(Without BLE) and I want to understand how to use DFU to update the application.

    As you know already, Everytime I "build" the application using SES, a new .hex file will be created in:

    nRF5_SDK_16.0.0_98a08e2\examples\peripheral\projectName\pca10056\blank\ses\Output\Release\Exe

    Can you please tell me what should I do, apart from creating update package using nrfutil, to update this application using nRFCOnnect app on my phone?

Children
  • Here are the steps I currently follow:

    1. Erase the MCU using SES
    2. Load softdevice by going to Target -> Download File -> Download Intel Hex File -> and selecting the file from \SDK\Components\softdevice\s140\hex
    3. Open secure_bootloader_ble_s140_pca10056 project and loading into DK by clicking on F5
    4. Create the package using nrfutil after matching the softdevice version
    5. Load the package on nRFConnect App on my phone
    6. Connecting to the device, goto Update tab and then click on "Start"
Related