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

Is it possible to program an application on nRF52832 using SES if I have Buttonless DFU implemented?

Hello!

I am working on a project where we want over the air updates for the finished product. To make that possible I implemented the buttonless DFU and it is working great!

My current issue is that now that a bootloader has been added to the device if I change the application at all it no longer matches what is expected. If I program the application using SES it will immediately go into the bootloader and display as DFUTarg instead of booting into the newly flashed application.

Is there a way to program the device using SES while the bootloader is present? For example a setting that I could set up while creating the bootloader settings file that tells it to ignore changes made in the application?

I am using the following:

Secure Bootloader for s132, Softdevice 7.2.0 S132, and my custom application. 

SDK 17.0.2

NRF52832

  • Thank you for your response, The CRC check was what I was looking for and it fixed my issue.

    For added information, I looked at the articles you linked and verified that my project already had those implemented. The first link talked about NRF_BL_APP_CRC_CHECK_SKIPPED_ON_GPREGRET2 and NRF_BL_APP_CRC_CHECK_SKIPPED_ON_SYSTEMOFF_RESET being set in the sdk_config.h file of the bootloader project. Both were already set to 1, so that wasn't the issue. 

    The second link mentioned a function nrf_dfu_app_is_valid() which doesn't show in either my bootloader project or the application project I'm basing my work off of. I am assuming that this function has been replaced somewhere, but because the link is from 3 years ago I'm not sure what it would have been changed to. 

    My solution to the problem ended up being a setting when creating the bootloader settings file. In addition to the command I posted originally I added the command --app-boot-validation NO_VALIDATION 

    This seems to indicate to the bootloader that it doesn't need to perform the CRC check and that it can boot into the application. I have tested the new settings and everything is working smoothly now.

    Thank you for your time. It would be helpful to have a tutorial or an updated explanation of the "nrfutil settings generate" command somewhere, the documentation is lacking and the --help message gives possible options, but I wasn't able to find a good resource to explain those options. 

    My final command was in the following form:

    nrfutil settings generate --app-boot-validation NO_VALIDATION --softdevice s132_nrf52_7.2.0_softdevice.hex --key-file PRIVATE KEY LOCATION --family NRF52 --application APPLICATION HEX --application-version-string "VERSION NUMBER" --bl-settings-version 2 --bootloader-version 0 OUTPUT HEX FILE 

Related