nrfutil tool fails to read the .zip DFU package

Hello . I saw this issue raised previously but with no resolution so here it is again

I built the smp-svr sample in VSCode with Zephyr SDK 2.6.1 which produced  a DFU package dfu_application.zip

I can successfully  update my device over BLE  with the Device Manager mobile app but nrfutil fails with the following error

./nrfutil.exe dfu ble -pkg /c/vd/samples/smp_svr/build-nrfdk/zephyr/dfu_application-.zip -ic NRF52 -p COM6 -a "EA:55:B0:DF:A9:6A"
Traceback (most recent call last):
File "nordicsemi\__main__.py", line 1555, in <module>
File "click\core.py", line 1137, in __call__
File "click\core.py", line 1062, in main
File "click\core.py", line 1668, in invoke
File "click\core.py", line 1668, in invoke
File "click\core.py", line 1404, in invoke
File "click\core.py", line 763, in invoke
File "nordicsemi\__main__.py", line 1209, in ble
File "nordicsemi\dfu\dfu.py", line 69, in __init__
File "nordicsemi\dfu\package.py", line 671, in unpack_package
File "nordicsemi\dfu\manifest.py", line 200, in from_json
KeyError: 'manifest'
[37460] Failed to execute script '__main__' due to unhandled exception!

I tried 

./nrfutil-6_12.exe pkg display /c/vd/samples/smp_svr/build-nrfdk/zephyr/dfu_application.zip with the same error

So appears that nrfutil fails to read the package

Looking through the forums I found one post that suggested to use the previous version of nrfutil. Tried 6.12 without success

Any ideas?

Thank you

Parents
  • Hello,

    Could you please let me know which version of nrfUtil you were using initially (before downgrading)? I recommend using version 7.0.

    I am not entirely sure, but are you trying to perform BLE DFU with the generated dfu_package.zip inside the build/zephyr folder? If so, the error might be due to the manifest file within the dfu_application.zip file.

    I recommend generating the zip file using the command nrfutil pkg generate. Please follow the instructions on this page for generating the zip file and then proceed with the steps outlined in the "Performing a DFU" section.

    Kind regards,

    Abhijith

  • Yes, initially I was using the latest nrfutil tool from your website. It has version 7.13.0

    Yes, I am trying to perform BLE DFU with the dfu_application.zip file that was generated as part of the smp_svr sample build. This package is recognized by the Device Manager mobile app and I was able to run BLE DFU successfully  with it.  Are you saying nrfutil does not support the  manifest format generated by the Zephyr build?

    Here is the manifest from dfu_application.zip

    {
        "format-version": 0,
        "time": 1720621221,
        "files": [
            {
                "load_address": 49664,
                "version_MCUBOOT": "1.2.3+0",
                "type": "application",
                "board": "nrf52840_custom_3_1_2",
                "soc": "nRF52840_QIAA",
                "size": 390926,
                "file": "app_update.bin",
                "modtime": 1720621221
            }
        ],
        "name": "smp_svr",
        "firmware": {
            "zephyr": {
                "revision": null
            },
            "nrf": {
                "revision": "eef645c4a31201df353fdff5447262d7675fa1c1"
            }
        }
    }
Reply
  • Yes, initially I was using the latest nrfutil tool from your website. It has version 7.13.0

    Yes, I am trying to perform BLE DFU with the dfu_application.zip file that was generated as part of the smp_svr sample build. This package is recognized by the Device Manager mobile app and I was able to run BLE DFU successfully  with it.  Are you saying nrfutil does not support the  manifest format generated by the Zephyr build?

    Here is the manifest from dfu_application.zip

    {
        "format-version": 0,
        "time": 1720621221,
        "files": [
            {
                "load_address": 49664,
                "version_MCUBOOT": "1.2.3+0",
                "type": "application",
                "board": "nrf52840_custom_3_1_2",
                "soc": "nRF52840_QIAA",
                "size": 390926,
                "file": "app_update.bin",
                "modtime": 1720621221
            }
        ],
        "name": "smp_svr",
        "firmware": {
            "zephyr": {
                "revision": null
            },
            "nrf": {
                "revision": "eef645c4a31201df353fdff5447262d7675fa1c1"
            }
        }
    }
Children
No Data
Related