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?

  • I did use nRF51DK(s130) before and now using nRF52DK(s132+bootloader). With nRF51DK I only use nRFgo Studio. With nRF52DK I also start using nfrjprog and nrfutil.

  • Yes, but do you have one nRF device that is connected to you computer running the connectivity firmware supplied with the pc-ble-driver in addition to the nRF52 DK that is flashed with the bootloader and the s132 SoftDevice?

  • Sorry Im not sure what you mean. Im new on this. I think "NO" on that question.

    "connectivity firmware supplied with the pc-ble-driver" ?

    Is that a step I missed before I flash: ...\nRF5_SDK_12.1.0_0d23e2a\examples\dfu\ble_dfu_send_hex\test_images_update_nrf52\dfu_test_softdevice_bootloader_s132.hex that I program with: "nrfjprog -f NRF52 –-chiperase --program dfu_test_softdevice_bootloader_s132.hex --verify"

    And then trying to flash: ...\nRF5_SDK_12.1.0_0d23e2a\examples\dfu\ble_dfu_send_hex\test_images_update_nrf52\dfu_test_app_hrm_s132.hex that I program with: "nrfutil dfu ble -ic NRF52 -n "DfuTest" -p COM5 -pkg dfu_test_app_hrm_s132.zip"

    I was thinking everything are prepared after installing i.e nRF5x-Command-Line-Tools Installer.

    When I was running nRFgo Studio I remember something is uppdated to the connected nRF52 DK device first time.

  • Hi Kent, nrfutil uses the pc-ble-driver,a serialization API for our SoftDevices that needs Nordic Hardware( either a nRF51 Dongle or nRF51/52 DK) flashed with the connectivity firmware connected to your computer in order to use it to perform DFU over BLE on another nRF5x device. Thus when you use the following command

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

    nrfutil will look for a nRF5x device connected to COM5, that is flashed with the connectivity firmware, and then use it to send the DFU packets to a second nRF5x device that is advertising as "DfuTarg" (by default) since you have not specified which device it should update. You can upload the connectivity firmware by adding the -f option to the command above, i.e.

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

    As you said, pc-nrfutil-1.5.0 have the correct pc-ble-drive for dfu example using SDK v12.1.0 ? So my problem is I cant install it correctly and therefore I cant even run "nrfutil --help" or anything. Should I avoid SDK v12.1.0 and use nrfutil2.0.0?

    The reason I left out the -f option was otherwise the softdevice and bootloader already in place will be erased and then in next step nrfutil2.0.0 will timeout probably due to there is no bootloader anymore.

    For the moment I dont have any success so I will try to use pc-nrfutil-1.5.0 in linux environment...

Related