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

DFU get started switch to DFU MODE

Im working with nrf52832 alone without dk ,  and sdk15.0.0 and SES
 i followd the tutorial of DFU mode : https://devzone.nordicsemi.com/nordic/nordic-blog/b/blog/posts/getting-started-with-nordics-secure-dfu-bootloader#h21sjziaqedvq7246h1tdi5lxp57zry
but in the step  Update new application firmware. i dont know how to switch dfu mode.
first i run the project secure_bootloadre_ble_s132_pca10040 , and Debug (go) it works i update to prkect via dfu , and restart to my application, but to go back to dfu another time, i dont know how to do it I should add a dfu service to my project ?? how ?? or there is some reset button or what please help me 

  • By default, if you hold down button 4 when you reset the device (or power cycle), then that will trigger DFU mode. If you have a custom PCB, look in nrf_bootloader.c in your bootloader project:

    static void dfu_enter_button_init(void)
    {
        nrf_gpio_cfg_sense_input(NRF_BL_DFU_ENTER_METHOD_BUTTON_PIN,
                                 BUTTON_PULL,
                                 NRF_GPIO_PIN_SENSE_LOW);
    }

    So check what your NRF_BL_DFU_ENTER_METHOD_BUTTON_PIN is defined to.

    Alternatively, you can use something called a buttonless_dfu service.This is a BLE service that is used to put the nRF back into DFU mode. If you try to update the application over dfu to the ble_app_buttonless_dfu example found in SDK15.0.0\examples\ble_peripheral

    If you look at how this service is implemented and handled, you can either copy that service into your application, or copy your other services into this example.

    Best regards,

    Edvin

  • Thanks a lot Mr Edvin,
    it works for me as you said I modified my bootloader project. and it works , now I'll see how to add a restart button to my application our w poweroff poweron, cause for the moment I shoud unplug and plug the alimentation .

    otherwise I want to try your suggestion the buttonless_dfu example, but it doesnt work , i pick up the example of SDK15.0.0 cause Im working on it, with the nrf52832 is it because or ram or what , here is the picture of the segger results:

    here is how it begin it seems everythin okey , this the image before the execution:

    here is the image of the error:

    here is the error above :

    and the source of the error:

    if its possible to help with the button ,and the butonless , it will be great , otherwise nor probleme , the main thing it works

  • Hello, I am new and I cannot seem to open a new topic. So excuse me for using this one.

    My question is rather simple:

    I have bought plain MDBT42Q module and connected power. On my iPhone I have nRF Connect running that I want to use to install firmware.

    But the devices don't have DFU mode activated. How do I force them to go into DFU mode? Please help!

  • Hello , You should first upload a bootloader , that support DFU , and from that you can start doing DFU.
    I hope you will find a bootloader that will work for MDBt42Q.
    in conclusion , the solution is the bootloader

Related