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

DFU is Working Just For the First Time

Hi,

I am trying to setup DFU on a PCA10001 board with the following specifications:

  • softdevice v8.0
  • bootloader: From SDK v8 examples (bootloader\pca10028\dual_bank_ble_s110\arm5_no_packs) and modified from here to make it compatible with 16KB RAM
  • application: From SDK v8 examples (ble_app_hrs\pca10028\s110_with_dfu\arm5_no_packs)

I do the following steps:

  • clearing the flash and downloading the softdevice and the bootloader.
  • In this step I can see "DfuTarg" device is advertising and I can send my application to the device using Master Control Panel.
  • Then my device starts advertising as "Nordic_HRM" with dfu service.
  • Trying to update the application firmware with a new one, the device switches from application to bootloader and I receive the "BLE_GATTS_EVT_TIMEOUT" event repeatedly with "BLE_GATT_TIMEOUT_SRC_PROTOCOL" source and I cannot see my device advertising anymore and obviously I receive a timeout in Master Control Panel.

Is there any other setting missing in my experiments?

Thank you

Parents
  • I was finally able to fix the problem. Because I was using a device with 16KB RAM, I assigned my application firmware the area of RAM from 0x20002000 to (0x20002000+0x2000) while my bootloader was using two different pieces of RAM which the first one was starting at 0x20002000 and the second was 0x80 bytes ending at (0x20002000+0x4000). The second piece of the assigned RAM is used for sharing some data between the bootloader and application. I had to modify my application RAM to cover from 0x20002000 to (0x20002000+0x4000). In this way both of the bootloader and application will have access to that 0x80 byte shared data.

    Thank You.

Reply
  • I was finally able to fix the problem. Because I was using a device with 16KB RAM, I assigned my application firmware the area of RAM from 0x20002000 to (0x20002000+0x2000) while my bootloader was using two different pieces of RAM which the first one was starting at 0x20002000 and the second was 0x80 bytes ending at (0x20002000+0x4000). The second piece of the assigned RAM is used for sharing some data between the bootloader and application. I had to modify my application RAM to cover from 0x20002000 to (0x20002000+0x4000). In this way both of the bootloader and application will have access to that 0x80 byte shared data.

    Thank You.

Children
Related