Support for the nRF52840-Dongle. More...
Support for the nRF52840-Dongle.
$ make BOARD=nrf52840dongle -C examples/saul flash term
> saul write 2 10 40 10
The nRF52840-Dongle is a bare USB-stick shaped device that houses barely anything than the nRF52840 itself, which offers BLE and 802.15.4 and USB connectivity.
Unlike similar sticks (like the nRF52840-MDK), it features no dedicated programmer hardware but relies on direct USB communication with a built-in bootloader.
The board features two LEDs (LD1: green, LD2: RGB), a user (SW1) and a reset button as well as 15 configurable external pins.
The board is flashed using its on-board boot loader; the proprietary nrfutil program needs to be installed, and nrfutil install nrf5sdk-tools
needs to be executed. Note that nrfutil, even when not running the "install" command, will install itself into ~/.nrfutil
. The older Python based version of nrfutil is no longer maintained by Nordic, and has become dysfunctional on Python 3.11.
The nrfutil can turn the binary into a suitable zip file and send it to the bootloader. The process is automated in the usual make flash
target.
If RIOT is already running on the board, it will automatically reset the CPU and enter the bootloader. If some other firmware is running or RIOT crashed, you need to enter the bootloader manually by pressing the board's reset button.
Readiness of the bootloader is indicated by LD2 pulsing in red.
The usual way to obtain a console on this board is using an emulated USB serial port (CDC-ACM). This is available automatically using the stdio_cdc_acm
module, unless any other stdio module is enabled.
On Linux systems with ModemManager < 1.10 installed, make term
will, in some setups, fail for a few seconds after the device has come up. This is fixed in its 1.12.4 version, but should not be more than a short annoyance in earlier versions.
To ease debugging, pins 0.13 and 0.15 are configured as RX and TX, respectively. They provide stdio if no CDC-ACM is disabled, and can be used as a custom UART otherwise.
Files | |
file | board.h |
Board specific configuration for the nRF52840-Dongle. | |
file | gpio_params.h |
Configuration of SAUL mapped GPIO pins. | |
file | periph_conf.h |
Peripheral configuration for the nRF52840-Dongle. | |
file | pwm_params.h |
Configuration of SAUL mapped PWM channels. | |