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

DFU Update: "Upload Failed: Unknown Command" & Signature-less Bootloader

I am trying to package a firmware update and flash it over BLE DFU and I keep getting the following error on the nRF Toolbox app:

"Upload Failed: Unknown Command"

I cannot figure out why this is happening and I can't find anyone else having this error on here.  Here are the commands I used to create the initial bootloader and settings (flashed over J-Link).

Generating the Settings hex:

nrfutil settings generate --family NRF52 --application ../AKDP/BUILD/AKDP_RevE.hex --application-version 20 --bootloader-version 1 --bl-settings-version 1 akdp_bl_settings.hex

Generated Bootloader DFU settings .hex file and stored it in: akdp_bl_settings.hex

Bootloader DFU Settings:
* File:                 akdp_bl_settings.hex
* Family:               nRF52
* Start Address:        0x0007F000
* CRC:                  0x9F32BF67
* Settings Version:     0x00000001 (1)
* App Version:          0x00000014 (20)
* Bootloader Version:   0x00000001 (1)
* Bank Layout:          0x00000000
* Current Bank:         0x00000000
* Application Size:     0x0003EEB8 (257720 bytes)
* Application CRC:      0xD62A0BD6
* Bank0 Bank Code:      0x00000001

Merging the settings hex with the bootloader hex:

mergehex -m akdp_bl_settings.hex ./bootloader_secure_ble/pca10040_debug/armgcc/_build/nrf52832_xxaa_s132.hex -o akdp_bl_with_settings.hex

Parsing input hex files.
Merging files.
Storing merged file.

After flashing the softdevice and the bootloader, here is what I used to generate the package file:

nrfutil pkg generate --application ../AKDP/BUILD/AKDP_RevE.hex --application-version 21 --hw-version 52 --sd-req 0x9D,0xA5 AKDP_RevE_with_BL_pkg.zip

Other information:

  • Device: nRF52832
  • SDK: 14.2.0
  • Board: Custom

I cannot understand why this isn't working.  It all looks fine to me.  The bootloader build completed without any problems.  Any help would be greatly appreciated.

Parents
  • Hi,

    Can you upload a log of the DFU upgrade process to give a bit more understanding of what is going on? You can also try upgrading using the nRF Connect app for mobile or desktop. It might also be useful to see the log from the nRF side, which you can get by using the debug version of the bootloader (with RTT logging).

  • I just flashed the same bootloader but unsecured and in debug mode.  I tried using DFU to send one of the example .zip packages and it worked fine.  So it doesn't seem like the problem is in the bootloader, but in my application package.  I'm not sure what it is though.  If I flash the firmware and bootloader directly, everything works fine.  Then if I package the exact same application and try to flash over DFU, that's when I get this Unknown Command error.  Do you see something wrong with the settings I am using with nrfutil to package my application?

Reply
  • I just flashed the same bootloader but unsecured and in debug mode.  I tried using DFU to send one of the example .zip packages and it worked fine.  So it doesn't seem like the problem is in the bootloader, but in my application package.  I'm not sure what it is though.  If I flash the firmware and bootloader directly, everything works fine.  Then if I package the exact same application and try to flash over DFU, that's when I get this Unknown Command error.  Do you see something wrong with the settings I am using with nrfutil to package my application?

Children
No Data
Related