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

Not able to upload Bluetooth hci_usb hex file to nRF52840-Dongle

Hi,

My goal: Flash hci_usb  in my nRF52840 Dongle, so that i can use Bluez stack in my Linux host and nRF dongle as BT controller.

Build status: Success

Flash : Failed

Board connection: OK, I am able to see hciconfig

Build command: make flash

Output:

Generating files from zephyr.elf for board: nrf52840_pca10059
[100%] Built target zephyr_final
[100%] Flashing nrf52840_pca10059
-- west flash: using runner nrfjprog
FATAL ERROR: "nrfjprog --ids" did not find a board; is the board connected?
zephyr/cmake/flash/CMakeFiles/flash.dir/build.make:57: recipe for target 'zephyr/cmake/flash/CMakeFiles/flash' failed
make[3]: *** [zephyr/cmake/flash/CMakeFiles/flash] Error 1
CMakeFiles/Makefile2:3568: recipe for target 'zephyr/cmake/flash/CMakeFiles/flash.dir/all' failed
make[2]: *** [zephyr/cmake/flash/CMakeFiles/flash.dir/all] Error 2
CMakeFiles/Makefile2:3575: recipe for target 'zephyr/cmake/flash/CMakeFiles/flash.dir/rule' failed
make[1]: *** [zephyr/cmake/flash/CMakeFiles/flash.dir/rule] Error 2
Makefile:651: recipe for target 'flash' failed
make: *** [flash] Error 2

Please help. 

Parents
  • Hi,

    As already suggested, you need to use nRF Connect Programmer unless you connect a debugger, since the nRF52840 dongle does not have an onboard debugger. Please make sure to place your application so that it starts from 0x1000 instead of 0, and also does not overlap with the bootloader at the end of the flash. You can see more information in the nRF52840 Dongle Programming Tutorial. The tutorial is nRF5 SDK specific, but the key here is to 1) build the application to be correctly placed in flash, and 2) update via USB DFU.

  • Hello Einar,

     Due to some other issues, I could not look into this any further. But, now I got chance to resume this task. I tried using nrfutil dfu. Following is the command and its error output. (note: /dev/ttyACM1 is my nRF52840 Dongle)

    $ nrfutil dfu usb-serial -pkg ./package.zip -p /dev/ttyACM1

    Traceback (most recent call last):
      File "/home/sri/.local/lib/python3.6/site-packages/serial/serialposix.py", line 265, in open
        self.fd = os.open(self.portstr, os.O_RDWR | os.O_NOCTTY | os.O_NONBLOCK)
    PermissionError: [Errno 13] Permission denied: '/dev/ttyACM1'

    I tried using nrfutil dfu serial option also. But result is same. Please suggest how to proceed. Thank you

Reply
  • Hello Einar,

     Due to some other issues, I could not look into this any further. But, now I got chance to resume this task. I tried using nrfutil dfu. Following is the command and its error output. (note: /dev/ttyACM1 is my nRF52840 Dongle)

    $ nrfutil dfu usb-serial -pkg ./package.zip -p /dev/ttyACM1

    Traceback (most recent call last):
      File "/home/sri/.local/lib/python3.6/site-packages/serial/serialposix.py", line 265, in open
        self.fd = os.open(self.portstr, os.O_RDWR | os.O_NOCTTY | os.O_NONBLOCK)
    PermissionError: [Errno 13] Permission denied: '/dev/ttyACM1'

    I tried using nrfutil dfu serial option also. But result is same. Please suggest how to proceed. Thank you

Children
Related