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

SDK 15 and Mesh 2.0 Generate a DFU file with nrfutil - ValueError

We used nRF5_SDK_15.0.0_a53641a and nrf5_SDK_for_Mesh_v2.0.0_src.

We are following DFU quick start guide http://infocenter.nordicsemi.com/index.jsp?topic=%2Fcom.nordic.infocenter.meshsdk.v0.10.0%2Findex.html

For nRF52:

mesh-sdk$ nrfutil dfu genpkg --application bin/blinky/blinky_nrf52832_xxAA_s132_5.0.0.hex \
--company-id 0x00000089 \
--application-id 1 \
--application-version 2 \
--key-file private_key.txt \
--sd-req 0x009D \
--mesh dfu_test.zip
We used "--company-id 0x00000089 \" to match Step 2 public key:
{
"bootloader_config": {
"bootloader_id": 1,
"bootloader_version": 1,
"company_id": 89,
"application_id": 1,
"application_version": 1,
"public_key": "ed09a58df6db5cd15b8637304f31d31f4042492ed7c7e4839fbe903f260a2ba1a855e92b72885825481ad56282bcf549ad7455ec46f000f0f62d97eeec883ba6"
}
}
The hex we used is C:\Nordic\nRF5_SDK_15.0.0_a53641a\mesh_sdk\bin\blinky\blinky_nrf52832_xxAA_s132_5.0.0.hexblinky_nrf52832_xxAA_s132_5.0.0.hex
We got ValueError, please see attached screen shot. 
Please advise.  Thanks
  • I have two tips: add some prints (i.e. sys.stdout.write("...")) in the bootloader_verify.py script to see where the error is occurring and/or try the whole dfu getting started process again. Most likely there is some small mistake you are making somewhere that is leading to this issue (e.g. running mesh_bootloader_gccarmemb instead of mesh_bootloader_serial_gccarmemb). I have tested this example again with three nrf52832 dev kits & the blinky dfu worked.

    I have had one issue with the COM port, so it might also be worthwhile to try a different usb port or try running the python bootloader_verify.py script on another one of your devices.

  • Hello,

    Thank you for the help here.

    I tried all the steps mentioned in the post, including the change to flash_placement.xml before flashing to the target board, I still see the issue (Failed to establish connection, after sending the DFU start packet).

    I’m following the quick start guide for this, using following setup: one target board – nrf52840 dev kit, softdevice – s140_6.0.0 (I verified in the nRF Go studio that this corresponds to ID 0x00A9), bootloader: mesh_bootloader_serial_gccarmemb_nrf52840_xxAA.hex. I built my dfu application using ninja/cmake, having set the device and softdevice to nrf52840/s140 respectively.

    Do I need to flash the host board as well, with the same first application? I assumed that since it is just a carrier, as long as it is recognized as a JLINK device, I should be able to run nrfutil on the serial port connected to the host board.

    Please advise,

    Thanks and regards,

    Shubhangi

  • It worked in my other computer now.

    I tried both

    C:\Nordic_SES\nrf5_SDK_for_Mesh_v2.0.1_src\bin\bootloader\gccarmemb\ mesh_bootloader_serial_gccarmemb_nrf52832_xxAA.hex

    And

    C:\Nordic_SES\nrf5_SDK_for_Mesh_v2.0.1_src\bin\bootloader\armcc\ mesh_bootloader_serial_armcc_nrf52832_xxAA.hex

    What is the difference between gccarmemb and armcc?

    Now it works using serial port, but my goal is updating firmware on mesh devices without using any cable connection as stated in the DFU quick start guide.

    I tried to use -s <serial number> on another module, but nothing happened.  Please specify which steps I should add -s <serial number>.  

    Please advise.  Thanks.

  • Did you  apply 

    "nrfjprog --reset" on step 9?
  • Hi Shubhangi, could you please open a new devzone case regarding this issue? Kind Regards, Bjorn

Related