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

Not able to perform DFU (FOTA) using nRF Connect Application or nRF ToolBox

Hi, I am trying to initiate Firmware Upgrade using the nRF Connect Mobile Application (also tried using nRF ToolBox).

As described in the below link - github.com/.../init packet handling

I created the ZIP File following the steps in the PDF file - How to create INIT File for nRF as mentioned in the link above. I have initiated upload using following steps -

  1. ZIP File created using nRF UTILITY
  2. .BIN and .DAT file

The error which I am getting is - After successfully starting Bootloader, the device is getting disconnected.

Please find the attached log of nRF LoggernRFLogger_Error.txt and .DAT Filefirmware.dat In the Log, you can see that after below byte is written to initiate DFU on characteristic, the connection is terminated. "D 14:38:28.776 [DFU] gatt.writeCharacteristic(00001531-1212-efde-1523-785feabcd123) A 14:38:32.142 [DFU] Jump to bootloader sent (Op Code = 1, Upload Mode = 4)"

Note: I am able to successfully perform DFU using Master Control Panel version 3.10 Device Information - Chip nRF52832, Softdevice support - S130 and S132. Mobile Used - Samsung A7 -2015, Android 6.0

  • Hi Monika,

    Have you used nrf.exe (nrfutil.exe) to generate the .zip file ? Or you simply generate the .dat and .bin file manually ?

    I would suggest to use the .zip file.

    Which SDK version did you use ?

    Could you check if the device manage to switch to DFU bootloader mode (advertising as DFUTarg) after you write to 0x0104 to the characteristic (00001531-1212-efde-1523-785feabcd123) ? From the log it seems the phone couldn't connect to the DFU target .

    D	14:38:35.098	[DFU] gatt = device.connectGatt(autoConnect = false)
    I	14:38:39.958	[DFU] Disconnected
    
  • Hi Hung, Thank You for your response.

    Yes, I have generated the ZIP file from nrfutil.exe using below command - nrfutil dfu genpkg --application [application].hex --application-version [version] --softdevice [softdevice].hex --bootloader [bootloader].hex --dev-type [type] --dev-revision [revision] --sd-req [list of supported Soft Device ids] [name of the distribution packet].zip

    SDK version which we are using is - SDK - 11

    Connections fails as soon as it calls DFUTarg.

    Let me know how can I resolve this issue at my end.

  • Could you explain this: "Connections fails as soon as it calls DFUTarg" ?

    Are you updating only the application or the application and softdevice and bootloader ? If you only update application you should not include the softdevice and bootloader.

    You may want to capture a sniffer trace, it would reveal what happened over the air. If you don't have the hardware for sniffer, you can try to debug the bootloader and check if the app managed to connect the bootloader.

Related