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

Buttonless DFU custom entry

Hi,

I am using nRF52832 with NUS and buttonless DFU running well next to each other (SDK13). Instead of the standard way to jump to the bootloader (writing a 0x01 to the DFU characteristic) I would like to use a custom command via NUS. I imagine that this would be more secure, because the bootloader can then only be entered if the command is known.

To do that, I need to remove the Bluetooth part of the buttonless DFU, but still keep the part which makes the application jump to the bootloader.

Whats the best way to implement that, does anyone have an idea?

Many thanks, Josef

Parents
  • Hi Josef,

    To enter bootloader, you simply need to write to bootloader setting a flag

    .enter_buttonless_dfu = true;
    

    This is done in enter_bootloader() function. After that you can wait for the flash completed event to disconnect the connection and then when the connection is disconnected (BLE_GAP_EVT_DISCONNECTED) you trigger a soft reset NVIC_SystemReset(); .

    UPDATE: This is only applied for SDK v12 and SDK v13 alpha.

  • Hi Hung, do you by any chance know if the procedure you explained one month ago is still the same with the new SDK13? I just updated and it seems some changes have been made to the experimental buttonless bootloader and it works differently now. I am still looking into it, if you could give me a kickstart it would be highly appreciated. Thanks, J

Reply Children
No Data
Related