The Thread NCP/RCP example demonstrates an OpenThread application that can serve as a low-power wireless Network Co-Processor (NCP) or Radio Co-Processor (RCP) to communicate with Userspace WPAN Network Daemon (wpantund) on Unix-like operating systems. This example has similar functionality as the NCP/RCP example available in the official OpenThread repository, but has been adapted to use with the nRF5 SDK. For additional information on wpantund, refer to wpantund on GitHub.
See the following table for the overview of the available NCP/RCP example configurations.
Configuration | Description | Stack variant used | Available for |
---|---|---|---|
FTD UART | Uses the UART communication and SEGGER J-Link as a UART-USB converter. | Thread FTD | PCA10056, PCA10100 |
FTD USB | Uses the USB peripheral that is available in the nRF52 devices and communicates as a native USB CDC device. | Thread FTD | PCA10056, PCA10059 (with bootloader, see nRF52840 Dongle), PCA10100 |
FTD SPI | Uses the SPI Slave peripheral and requires additional wpantund configuration. | Thread FTD | PCA10056, PCA10100 |
Radio UART | Uses the UART communication and SEGGER J-Link as a UART-USB converter. It is used for RCP topology and requires additional wpantund configuration as well as POSIX OpenThread application. | Thread Radio | PCA10056, PCA10068, PCA10100 |
Radio SPI | Uses the SPI Slave peripheral. It is used for RCP topology and requires additional wpantund configuration as well as POSIX OpenThread application. | Thread Radio | PCA10056, PCA10068, PCA10100 |
If native USB CDC connectivity is used on hosts running on Windows XP or Windows 7, you must manually install the nordic_cdc_acm.inf
driver that is located at <InstallFolder>/examples/usb_drivers
.
Hosts running on Windows 8 (and later) will automatically pick the correct driver (usbser.sys
).
This example can be used along with Nordic’s Border Router solution to provide Internet connectivity to the Thread network. For more information about NCP/RCP and Border Router cooperation, refer to Thread Border Router.
The NCP/RCP application starts in the disconnected state, and remains so until it is appropriately configured by the Border Router. After NCP/RCP is connected to the Border Router and the Border Router is rebooted, NCP/RCP will try to connect to the existing network or form a new one.
Network state is indicated by LED1. When the device is not connected to a network, the LED blinks at a 200-ms period. Once the device connects to a network, either as a Child or as a Leader, the LED stops blinking and remains turned on.
You can find the source code and the makefiles for NCP/RCP in the following folder: <InstallFolder>/examples/thread/ncp
.
The example uses LED assignments as described in Thread BSP LED and button reference for the following LEDs:
To test the example: