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

Buttonless DFU setting in Bootloader for nRF52832

Hello,

We have a custom board of nRF52832 with two buttons and right now Buttonless DFU is also working perfectly. But, we have scenario where if combination of two buttons pressed at once, than board gets into DFU mode and need to rid of it. Hence, I started working on the bootloader since at application level i,e when board is on entering DFU mode has  been removed. But, when device is off, by pressing button1 and than button2, the device still goes into DFU mode.

I comipled secure bootloader from SDK 14.2 and removed DFU enter via button press in in nrf_dfu_enter_check() inside nrf_dfu.c, by overridding with another function has shown in this link  by creating a custom_functions.c and adding it to makefile. And, now I can flash the bootloader and as well as the application and I get the icon to flash the DFU as it displayed below

       

but later than, I cannot do buttonless DFU update anymore. As soon I try to flash my application device turns off.

Also, I have set s_dfu_settings.enter_buttonless_dfu = 1; in nrf_dfu_init() function of nrf_dfu.c and than called overriding function nrf_dfu_enter_check() from custom_functions.c. Is this correct ?

Could anyone please look into it and let me know if I am doing something wrong ?

Thanks and Regards,

Nagarjun

  • Hi,

    It's a bit hard to get what exact issue you are having. 
    Could you record the phone's screen when you do DFU ? 
    When the device stuck, do you know if it stuck in the bootloader or it stuck in the application ? The bootloader is not a black box, you can add breakpoint and step in if you want. 

    For the bootloader to enter DFU mode you need to add the check for GPREGRET  back in nrf_dfu_enter_check(). 

    Please also verify that you can do DFU if you only flash the softdevice + bootloader.

Related