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

nrfutil dfu ble failed to open Win 10

I try to load my nRF52 with app via ble from windows 10 laptop.

nRF52 dev kit is loaded with the Softdevice and Bootloader from nRF5_SDK_12.1.0\examples\dfu\ble_dfu_send_hex\test_images_update_nrf52.

I have no problems to load nRF52 dfu_test_app_hrm_s132.zip from Mobile nRF Toolbox.

I try to do as admin:

"nrfutil dfu ble -ic NRF52 -n "DfuTest" -p COM5 -pkg dfu_test_app_hrm_s132.zip"

from windows 10 python2.7.12(nrfutil2.0.0/pc_ble_driver_py0.8.0) only version installed.

but get open failed exception (access denied):

"C:\Python27\lib\site-packages\pc_ble_driver_py\ble_driver.py", line 126, in wrapper raise NordicSemiException('Failed to {}. Error code: {}'.format(wrapped.name, err_code)) pc_ble_driver_py.exceptions.NordicSemiException: Failed to open. Error code: 13

I can see nRF52 device "DfuTest" in win bluetooth device list.

Any ideas?

  • You're running cmd.exe as administrator right? However, you have to use nrfutil v1.5.0 if you're using the Secure Bootloader from SDK v12.1.0, please see our Github page, here is the link.

  • Thanks! yes Im running cmd.exe as administrator.

    I installed nrfutil v1.5.0 by the following as admin:

    1. install Python 2.7.12

    2. python -m pip install --upgrade pip

    3. python -m pip install -U setuptools

    4. python -m pip install pyinstaller

    5. unzip pc-nrfutil-1.5.0 and cd to it

    6. python setup.py install

    7. pyinstaller nrfutil.spec

    running as admin "nrfutil --help" but gets:

    File "C:\Python27\lib\site-packages\pc_ble_driver_py-0.8.0-py2.7.egg\pc_ble_driver_py\config.py", line 48, in sd_api_ver_get raise RuntimeError('Connectivity IC identifier conn_ic_id is not set') RuntimeError: Connectivity IC identifier conn_ic_id is not set

    I have already run:

    nrfjprog -f NRF52 –-chiperase --program dfu_test_softdevice_bootloader_s132.hex --verify

  • You have to uninstall nrfutil v0.8.0 as it will casue a conflict with the newer version. Also check that your path variable is pointing to the correct version.

  • Seems pc_ble_driver_py-0.8.0 still be installed even if I force it away :(

    I now did the following:

    1. delete entry in %USERPROFILE%\AppData\Local\pip\cache

    2. delete existing pc-nrfutil-1.5.0 folder

    3. unzip pc-nrfutil-1.5.0 and cd to it

    4. uninstall existing Python and delete the folder

    5. install Python 2.7.12

    6. open cmd.exe as administrator

    7. python -m pip install --no-cache-dir -r requirements.txt

    8. python nordicsemi/main.py

    but still get the:

    Traceback (most recent call last): File "nordicsemi/main.py", line 50, in from nordicsemi.dfu.dfu_transport_ble import DfuTransportBle File "C:\Users\4light\Downloads\pc-nrfutil-1.5.0\pc-nrfutil-1.5.0\nordicsemi\dfu\dfu_transport_ble.py", line 48, in from pc_ble_driver_py.ble_driver import BLEDriver, BLEDriverObserver, BLEUUIDBase, BLEUUID, BLEAdvData, BLEGapConnParams, NordicSemiException File "C:\Python27\lib\site-packages\pc_ble_driver_py\ble_driver.py", line 63, in nrf_sd_ble_api_ver = config.sd_api_ver_get() File "C:\Python27\lib\site-packages\pc_ble_driver_py\config.py", line 48, in sd_api_ver_get raise RuntimeError('Connectivity IC identifier conn_ic_id is not set') RuntimeError: Connectivity IC identifier conn_ic_id is not set


    The log from the "python -m pip install --no-cache-dir -r requirements.txt"

    Collecting six>=1.9 (from -r requirements.txt (line 1)) Downloading six-1.10.0-py2.py3-none-any.whl

    Collecting pyserial>=2.7 (from -r requirements.txt (line 2)) Downloading pyserial-3.2.1-py2.py3-none-any.whl (189kB) 100% |################################| 194kB 4.9MB/s

    Collecting enum34>=1.0.4 (from -r requirements.txt (line 3)) Downloading enum34-1.1.6-py2-none-any.whl

    Collecting click>=6.0 (from -r requirements.txt (line 4)) Downloading click-6.6-py2.py3-none-any.whl (71kB) 100% |################################| 71kB 663kB/s

    Collecting ecdsa>=0.13 (from -r requirements.txt (line 5)) Downloading ecdsa-0.13-py2.py3-none-any.whl (86kB) 100% |################################| 92kB 980kB/s

    Collecting behave (from -r requirements.txt (line 6)) Downloading behave-1.2.5-py2.py3-none-any.whl (109kB) 100% |################################| 112kB 5.7MB/s

    Collecting protobuf (from -r requirements.txt (line 7)) Downloading protobuf-3.1.0.post1-py2.py3-none-any.whl (347kB) 100% |################################| 348kB 5.4MB/s

    Collecting pc-ble-driver-py>=0.6.1 (from -r requirements.txt (line 8)) Downloading pc_ble_driver_py-0.8.0.tar.gz (13.1MB) 100% |################################| 13.1MB 5.7MB/s

    Collecting parse>=1.6.3 (from behave->-r requirements.txt (line 6)) Downloading parse-1.6.6-py2-none-any.whl

    Collecting parse-type>=0.3.4 (from behave->-r requirements.txt (line 6)) Downloading parse_type-0.3.4.tar.gz (62kB) 100% |################################| 71kB 6.0MB/s

    Requirement already satisfied (use --upgrade to upgrade): setuptools in c:\python27\lib\site-packages (from protobuf->-r requirements.txt (line 7))

    Collecting wrapt (from pc-ble-driver-py>=0.6.1->-r requirements.txt (line 8)) Downloading wrapt-1.10.8.tar.gz

    Collecting future (from pc-ble-driver-py>=0.6.1->-r requirements.txt (line 8)) Downloading future-0.16.0.tar.gz (824kB) 100% |################################| 829kB 6.0MB/s

    Installing collected packages: six, pyserial, enum34, click, ecdsa, parse, parse-type, behave, protobuf, wrapt, future, pc-ble-driver-py

    Running setup.py install for parse-type ... done Running setup.py install for wrapt ... done Running setup.py install for future ... done Running setup.py install for pc-ble-driver-py ... done

    Successfully installed behave-1.2.5 click-6.6 ecdsa-0.13 enum34-1.1.6 future-0.16.0 parse-1.6.6 parse-type-0.3.4 pc-ble-driver-py-0.8.0 protobuf-3.1.0.post1 pyserial-3.2.1 six-1.10.0 wrapt-1.10.8

  • Hi Kent, do you have a nRF51 Dongle or another nRF52 DK that runs the connectivity firmware in addition to the nRF52 DK with the S132 and the bootloader right?

Related