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

DFU again and again over BLE

Hi Guys,

I have managed to get the BLE DFU demo service working fine (dual bank) on nRF51822 EK. I use a Linux Python program (bitbucket.org/.../nrf51_dfu_linux) (with small modifications to the pexpect string) to connect to the tag “DfuTarg” and control the download of a new image. I can download the new binary image (over 632 20-btyle blocks) of the demo HRM profile. After download, as expected the tag comes up with name “Nordic_HRM”.

However, you seem to only be able to do this operation once… the DFU service disappears when the new tag code is running.

I need to embed the device in silicone and cannot physically connect to the device – hence why DFU is desperately important to our research project to be deployed to 100 homes to monitor residential healthcare.

I have tried to download the image file of the DFU over DFU but this cannot be done because the DFU tag code and the bootloader reside in different parts of memory so that the binary file to download the DFU is 256Mbytes.

Can anyone please point me in the right direction to use the BLE DFU so that I can repeatedly download new images over BLE on top of each other without plugging the USB debug cable in. I am happy to add the DFU profile to my existing BLE tag code. Perhaps the solution is to leave the bootloader alone and only download and update only the program part, but I don’t know how to do that.

Many thanks, Simon

  • If I understand your question properly it sounds like you want the DFU service exposed at the same time your application services are exposed. The DFU doesn't work that way, it is a stand alone project built separately from your application. See this question for more details:

    DFU explanation

    You also need to define a mechanism for entering DFU mode. The Nordic example uses a button held down at powerup. Here is another mechanism you could use:

    DFU entry

Related