Setup OpenThread Border Router with nRF52840 Dongle - canonical/openthread-border-router-snap GitHub Wiki

This is a reference document for setting up and configuring OTBR (OpenThread Border Router) with Nordic nRF52840 Dongle.

Build and flash RCP firmware on nRF52480 dongle

In order for Nordic Semiconductor nRF52840 Dongle to act as the Radio Co-Processor (RCP), it needs to run the OT (OpenThread) RCP firmware. Following the instructions here.

Refer to FAQ for tips on a few common issues.

Configure and run OTBR snap

Now that the RCP firmware has successfully flashed, connect the dongle, then refer to this guide to install the OTBR snap, configure, and run it.

FAQ

Find the device name

For flashing the firmware and using the RCP, you need to find the device name assigned to the dongle.

The simplest way to do so is to run dmesg with the -w/--follow flag before connecting the device. Here is an example, showing device name ttyACM0 which means that the device path on the system would be /dev/ttyACM0:

$ sudo dmesg -W
[23930.322598] usb 1-8: USB disconnect, device number 24
[23930.971312] usb 1-8: new full-speed USB device number 25 using xhci_hcd
[23931.130085] usb 1-8: New USB device found, idVendor=1915, idProduct=cafe, bcdDevice= 1.00
[23931.130099] usb 1-8: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[23931.130104] usb 1-8: Product: nRF528xx OpenThread Device
[23931.130108] usb 1-8: Manufacturer: Nordic Semiconductor
[23931.130111] usb 1-8: SerialNumber: F54FE6398B9E
[23931.133681] cdc_acm 1-8:1.0: ttyACM0: USB ACM device
PIP version error

If you encounter an error related to pip version during the installation of nRF Util, such as:

  Could not find a version that satisfies the requirement pc_ble_driver_py>=0.14.0 (from nrfutil) (from versions: 0.1.0, 0.2.0, 0.3.0, 0.4.0, 0.5.0, 0.6.0, 0.6.1, 0.6.2, 0.8.0, 0.8.1, 0.9.0, 0.9.1, 0.10.0, 0.11.0, 0.11.1, 0.11.2, 0.11.3, 0.11.4)
No matching distribution found for pc_ble_driver_py>=0.14.0 (from nrfutil)

Update pip with the following commands:

python3 -m pip install -U pip
python3 -m pip install -U nrfutil
AttributeError

If you encounter an error related to AttributeError during the installation of nRF Util, such as:

AttributeError: 'dict' object has no attribute 'iteritems'

Install missing packages with the following commands:

 sudo apt-get -y install libusb-1.0-0-dev sed
 pip3 install click crcmod ecdsa intelhex libusb1 piccata protobuf pyserial pyyaml tqdm pc_ble_driver_py
 pip3 install -U --no-dependencies nrfutil

Note that there are additional incompatibility issues with Python 3.11. Refer here

Unexpected Executed OP_CODE error

If you encounter an error during flashing, such as:

pc_ble_driver_py.exceptions.NordicSemiException: Unexpected Executed OP_CODE.
Expected: 0x02 Received: 0x7E

Verify the environment as described here, or unplug the dongle from current USB port and plug it into another new USB port as documented here.

References: