nRF5 SDK is not maintained anymore
More Info: Consider nRF Connect SDK for new designs

Unable to program nrf52840dongle

I have just received nRF52840 dongle and I cannot get it programed. I have tried both west flash and nrfProgrammer from nrfConnect.

I have been developing using nrf52840dk so far, and I have no issue programming the dk.


In nrfProgrammer device comes as Unknown ( shown on attached nrf52840.png) I am attaching the log in a separate file  nrfProgrammer.log



Syslog output from Ubuntu 20.04:
May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.303051] usb 1-2: new full-speed USB device number 15 using xhci_hcd
May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.453934] usb 1-2: New USB device found, idVendor=1915, idProduct=521f, bcdDevice= 1.00
May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.453946] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.453951] usb 1-2: Product: Open DFU Bootloader
May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.453955] usb 1-2: Manufacturer: Nordic Semiconductor
May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.453959] usb 1-2: SerialNumber: F3E11021BA23
May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.461463] cdc_acm 1-2:1.0: ttyACM0: USB ACM device
May 23 09:32:33 jyu-ThinkPad-T470p mtp-probe: checking bus 1, device 15: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2"
May 23 09:32:33 jyu-ThinkPad-T470p mtp-probe: bus: 1, device: 15 was not an MTP device
May 23 09:32:33 jyu-ThinkPad-T470p snapd[1029]: hotplug.go:199: hotplug device add event ignored, enable experimental.hotplug
May 23 09:32:33 jyu-ThinkPad-T470p mtp-probe: checking bus 1, device 15: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2"
May 23 09:32:33 jyu-ThinkPad-T470p mtp-probe: bus: 1, device: 15 was not an MTP device

west flash output:


-- west flash: using runner nrfjprog
FATAL ERROR: "nrfjprog --ids" did not find a board; is the board connected?






Do you have any suggestion on how can I program the dongle? 
Please let me know if you need any other information.

Parents
  • Hi,

    The nRF52840 Dongle does not have an onboard debugger, so you cannot program it using west unless you are using an external debug probe. Instead, you can put it in bootloader mode and use the Programmer app or nrfutil to upload the new firmware to it. To make the dongle enter bootloader mode you need to press the RESET button:

    If the dongle is already plugged in when you press the RESET button it might not go into bootloader mode, so please try to unplug the dongle from your computer, and then hold in the RESET button while you plug it in. It should show up in the Programmer app as a bootloader device.

    Best regards,

    Marte

  • Thanks for the reply.
    I was pressing the RESET button and the LED2 was flashing red indicating bootloader mode. Syslog on ubuntu was also indicating bootloader mode:
    May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.453946] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
    May 23 09:32:33 jyu-ThinkPad-T470p kernel: [ 4146.453951] usb 1-2: Product: Open DFU Bootloader

    In the and I have managed to program it for the "nRF Sniffer for Bluetooth LE"  from Windows on the same PC(using exactly the same steps) in the end. Apparently there was an issue with the Ubuntu 20.04 environment for the nrf52840dongle ( although it works fine with the nrf528400dk)

    Now when booting without pressing RESET device is recognized as "nRF Sniffer for Bluetooth LE" . When booting with RESET pressed LED blinks red and device is recognized as "Product: Open DFU Bootloader" but still the nrfProgrammer is unable to program the device:

    2022-05-20T10:38:48.210Z ERROR Error when fetching device versions: readFwInfo error
    2022-05-20T10:40:42.521Z DEBUG Sending usage data...
    2022-05-20T10:40:42.522Z DEBUG Category: pc-nrfconnect-programmer
    2022-05-20T10:40:42.522Z DEBUG Action: Close device


    We need to be able to program the device from the Linux system. Any hints on resolving the programming issues on Ubuntu 20.04?

  • Hi,

    It is good to hear that you are able to program it from Windows at least. I will check internally if there are any known issues with Ubuntu.

    Please gather a log of this issue in Ubuntu with verbose logging enabled:

    1. Make sure the dongle is plugged into the computer and in bootloader mode.
    2. Go to the 'about' tab in the Programmer app.
    3. Enable verbose logging and select 'restart with verbose logging'.
    4. After the Programmer restarts try to select the dongle from the device list.
    5. Select 'open log file' at the bottom of the terminal in the Programmer.
    6. Upload the log here.

    I will forward the log to the developers.

    Best regards,

    Marte

  • Thanks again for the fast reply. I am attaching the log file.

    I have my user added to the dialout group (owner of /dev/ttyACM0). I have also tried changing the permissions of the /dev/ttyACM0 to 0666 ( same as the developmentKit when it  comes up) and I still experience the same error.


    When the dongle is started in a normal mode ( as a sniffer), the dongle is opened, and used by Wireshark without any issues.
    Let me know if you need any other info.

Reply
  • Thanks again for the fast reply. I am attaching the log file.

    I have my user added to the dialout group (owner of /dev/ttyACM0). I have also tried changing the permissions of the /dev/ttyACM0 to 0666 ( same as the developmentKit when it  comes up) and I still experience the same error.


    When the dongle is started in a normal mode ( as a sniffer), the dongle is opened, and used by Wireshark without any issues.
    Let me know if you need any other info.

Children
Related