nRF5 SDK for Thread contains the pre-built OpenThread stack in the form of binary libraries. If you want to build your own project, you must include all of the mandatory libraries and can add some of the optional libraries.
The binaries can be found in the following folder: <InstallFolder>\external\openthread\lib
. Currently, libraries for GCC, IAR, and Keil 5 are provided.
Refer to the release notes for the ID of the OpenThread commit that has been used to generate pre-built Thread stack libraries and for testing and verification.
Refer to API for detailed API reference for the libraries.
Mandatory libraries:
libopenthread-ftd.a
or libopenthread-mtd.a
- OpenThread’s Thread Stack implementation of the Full Thread Device (FTD) or Minimal Thread Device (MTD) librarylibmbedcrypto-cc310.a
or libmbedcrypto.a
- MbedTLS SSL library with CryptoCell support for operations used by OpenThread: ECC, SHA-256 and AES ECB or with no hardware accelerationlibopenthread-nrf52840-sdk.a
or libopenthread-nrf52840-sdk-usb.a
- nRF52840 OpenThread’s platform implementation library (with optional USB CDC support)libopenthread-nrf52840-softdevice-sdk.a
or libopenthread-nrf52840-sdk-softdevice-usb.a-
nRF52840 OpenThread’s platform implementation library that uses SoftDevice API (with optional USB CDC support)libopenthread-platform-utils.a
- OpenThread’s platform util which contains the flash manager libraryOptional libraries:
libopenthread-cli-ftd.a
or libopenthread-cli-mtd.a
- Command Line Interface (CLI) librarylibopenthread-ncp-ftd.a
or libopenthread-ncp-mtd.a
- Network Co-Processor (NCP) librarylibopenthread-diag.a
– OpenThread’s diagnostic module libraryLimitations:
The pre-built OpenThread libraries located in <InstallFolder>\external\openthread\lib
do not support DHCPv6 Client/Server.
The OpenThread stack has been officially certified on nRF52840 as a Thread Group Certified Component. For certification, the following Thread Harness version has been used:
The following OpenThread commit has been used to generate the stack libraries, with this commit reverted.
The above commit has been reverted because of a known issue (TESTPLAN-380) in Thread Harness and Thread Test Bed.
While performing Thread Certification tests for Nordic Semiconductor's nRF52840 multiprotocol SoC, the chip was constantly connected as a Bluetooth low energy 5 peripheral device to a Bluetooth low energy central node, in addition to performing the Device Under Test (DUT) role for Thread Test Bed. The Bluetooth low energy bit rate was 1 Mbit/s, and the connection interval was 200 ms. Each node transmitted 18-19 ATT payload bytes to the peer in average 1 s interval.
For the current release of nRF5 SDK for Thread, a newer version of OpenThread libraries was generated in order to support new features, such as USB. The included stack passes 142 out of 150 tests that were run with Thread V1.2 Test Harness Release 1.2.0 and the complete Thread Test Bed.
OpenThread, as the only stack, implements propagation of the Thread Network Data according to the specification. This issue will be fixed in the next versions of the Thread Harness.
Internal testing has been done on the CLI application and OpenThread libraries compiled with GCC. The libraries can be found in the following folder: <InstallFolder>\external\openthread\lib\gcc\certification
.
How to run certification tests on nRF52840 dev-kits:
In order to certify a Thread product, all certification test cases must be run on the Thread Test Harness software.
A detailed description on how to assemble and configure Thread Test Bed and run Thread Test Harness can be found here: Thread Group's Confluence wiki page.
The first step is to use a proper OpenThread THCI file that works with the Thread stack, which is included in nRF5 SDK for Thread 0.11.0. The proper file (OpenThread.py
) is located in the directory <InstallFolder>\external\openthread\THCI
and it must be copied to C:\GRL\Thread1.1\Thread_Harness\THCI
(the original file must be overwritten).
The procedure of running the Thread Test Harness software on Nordic Semiconductor's nRF52840 SoC (on the PCA10056 Development Kit) must be adjusted in the following way. Thread Test Harness does not correctly identify the PCA10056 Development Kit out-of-the-box. Due to a collision of USB PID:VID with another vendor (this is valid only for Nordic Semiconductor development kits with J-Link virtual COM port), Nordic devices are not automatically added to the devices list. To add an nRF52840 device, drag the OpenThread: TI CC2538DK device and drop it on the configuration page. After that, the devices are configured and proper baud rate (115200) and COM port is set.
Useful links: OpenThread THCI
The following tables present flash memory and RAM requirements for the stack and for the applications compiled with the chosen options using the GCC compiler with size optimization. Note that RAM memory requirements may be adjusted, for example to support different number of children, buffers, or registered addresses. The default configuration for nRF52840 platform is defined in two files:
Stack memory requirements:
Additional options: None
Type | Crypto | Protocol | Flash KB | RAM KB |
---|---|---|---|---|
FTD | CC310 | SINGLE | 197 | 29 |
FTD | CC310 | MULTI | 198 | 28 |
FTD | SW | SINGLE | 152 | 29 |
FTD | SW | MULTI | 152 | 28 |
MTD | CC310 | SINGLE | 158 | 24 |
MTD | CC310 | MULTI | 158 | 23 |
MTD | SW | SINGLE | 112 | 24 |
MTD | SW | MULTI | 112 | 23 |
Additional options: "COMMISSIONER=1 JOINER=1 DHCP6_SERVER=1 DHCP6_CLIENT=1 CERT_LOG=1 DEFAULT_LOGGING=1 COAP=1 DNS_CLIENT=1 TMF_PROXY=1 BORDER_ROUTER=1 MAC_FILTER=1 MTD_NETDIAG=1"
Type | Crypto | Protocol | Flash KB | RAM KB |
---|---|---|---|---|
FTD | CC310 | SINGLE | 219 | 46 |
FTD | CC310 | MULTI | 219 | 45 |
FTD | SW | SINGLE | 229 | 46 |
FTD | SW | MULTI | 230 | 45 |
MTD | CC310 | SINGLE | 173 | 41 |
MTD | CC310 | MULTI | 174 | 40 |
MTD | SW | SINGLE | 184 | 41 |
MTD | SW | MULTI | 184 | 40 |
Additional options: "COMMISSIONER=1 JOINER=1 COAP=1 DNS_CLIENT=1 MTD_NETDIAG=1 BORDER_ROUTER=1 DHCP6_SERVER=1 DHCP6_CLIENT=1 CERT_LOG=1"
Type | Crypto | Protocol | Flash KB | RAM KB |
---|---|---|---|---|
FTD | CC310 | SINGLE | 218 | 45 |
FTD | CC310 | MULTI | 218 | 45 |
FTD | SW | SINGLE | 228 | 45 |
FTD | SW | MULTI | 229 | 45 |
MTD | CC310 | SINGLE | 173 | 40 |
MTD | CC310 | MULTI | 173 | 40 |
MTD | SW | SINGLE | 183 | 40 |
MTD | SW | MULTI | 184 | 40 |
Additional options: "JOINER=1 DHCP_CLIENT=1 DNS_CLIENT=1 COAP=1"
Type | Crypto | Protocol | Flash KB | RAM KB |
---|---|---|---|---|
FTD | CC310 | SINGLE | 205 | 45 |
FTD | CC310 | MULTI | 206 | 44 |
FTD | SW | SINGLE | 215 | 45 |
FTD | SW | MULTI | 216 | 44 |
MTD | CC310 | SINGLE | 165 | 40 |
MTD | CC310 | MULTI | 166 | 39 |
MTD | SW | SINGLE | 175 | 40 |
MTD | SW | MULTI | 176 | 39 |
Additional options: "JOINER=1 DHCP_SERVER=1 DHCP_CLIENT=1 COAP=1 DNS_CLIENT=1 BORDER_ROUTER=1 MTD_NETDIAG=1"
Type | Crypto | Protocol | Flash KB | RAM KB |
---|---|---|---|---|
FTD | CC310 | SINGLE | 206 | 45 |
FTD | CC310 | MULTI | 207 | 44 |
FTD | SW | SINGLE | 216 | 45 |
FTD | SW | MULTI | 217 | 44 |
MTD | CC310 | SINGLE | 168 | 40 |
MTD | CC310 | MULTI | 169 | 39 |
MTD | SW | SINGLE | 178 | 40 |
MTD | SW | MULTI | 179 | 39 |
CLI application memory requirements
Additional options: None
Application type | Flash KB | RAM KB |
---|---|---|
multiprotocol/cli_cc310_ftd | 187 | 36 |
multiprotocol/cli_cc310_mtd | 138 | 31 |
multiprotocol/cli_swcrypto_ftd | 194 | 36 |
multiprotocol/cli_swcrypto_mtd | 144 | 31 |
singleprotocol/cli_cc310_ftd | 163 | 35 |
singleprotocol/cli_cc310_mtd | 113 | 30 |
singleprotocol/cli_swcrypto_ftd | 169 | 35 |
singleprotocol/cli_swcrypto_mtd | 119 | 30 |
Additional options: "COMMISSIONER=1 JOINER=1 DHCP6_SERVER=1 DHCP6_CLIENT=1 CERT_LOG=1 DEFAULT_LOGGING=1 COAP=1 DNS_CLIENT=1 TMF_PROXY=1 BORDER_ROUTER=1 MAC_FILTER=1 MTD_NETDIAG=1"
Application type | Flash KB | RAM KB |
---|---|---|
multiprotocol/cli_cc310_ftd | 286 | 59 |
multiprotocol/cli_cc310_mtd | 232 | 54 |
multiprotocol/cli_swcrypto_ftd | 272 | 53 |
multiprotocol/cli_swcrypto_mtd | 218 | 48 |
singleprotocol/cli_cc310_ftd | 261 | 57 |
singleprotocol/cli_cc310_mtd | 207 | 52 |
singleprotocol/cli_swcrypto_ftd | 247 | 51 |
singleprotocol/cli_swcrypto_mtd | 193 | 46 |
Additional options: "COMMISSIONER=1 JOINER=1 COAP=1 DNS_CLIENT=1 MTD_NETDIAG=1 BORDER_ROUTER=1 DHCP6_SERVER=1 DHCP6_CLIENT=1 CERT_LOG=1"
Application type | Flash KB | RAM KB |
---|---|---|
multiprotocol/cli_cc310_ftd | 284 | 59 |
multiprotocol/cli_cc310_mtd | 229 | 54 |
multiprotocol/cli_swcrypto_ftd | 270 | 52 |
multiprotocol/cli_swcrypto_mtd | 216 | 48 |
singleprotocol/cli_cc310_ftd | 259 | 57 |
singleprotocol/cli_cc310_mtd | 204 | 52 |
singleprotocol/cli_swcrypto_ftd | 245 | 51 |
singleprotocol/cli_swcrypto_mtd | 190 | 46 |
Additional options: "JOINER=1 DHCP_CLIENT=1 DNS_CLIENT=1 COAP=1"
Application type | Flash KB | RAM KB |
---|---|---|
multiprotocol/cli_cc310_ftd | 268 | 58 |
multiprotocol/cli_cc310_mtd | 218 | 53 |
multiprotocol/cli_swcrypto_ftd | 254 | 52 |
multiprotocol/cli_swcrypto_mtd | 205 | 47 |
singleprotocol/cli_cc310_ftd | 243 | 57 |
singleprotocol/cli_cc310_mtd | 194 | 52 |
singleprotocol/cli_swcrypto_ftd | 229 | 51 |
singleprotocol/cli_swcrypto_mtd | 180 | 46 |
Additional options: "JOINER=1 DHCP_SERVER=1 DHCP_CLIENT=1 COAP=1 DNS_CLIENT=1 BORDER_ROUTER=1 MTD_NETDIAG=1"
Application type | Flash KB | RAM KB |
---|---|---|
multiprotocol/cli_cc310_ftd | 271 | 58 |
multiprotocol/cli_cc310_mtd | 224 | 53 |
multiprotocol/cli_swcrypto_ftd | 257 | 52 |
multiprotocol/cli_swcrypto_mtd | 210 | 47 |
singleprotocol/cli_cc310_ftd | 246 | 57 |
singleprotocol/cli_cc310_mtd | 200 | 52 |
singleprotocol/cli_swcrypto_ftd | 232 | 51 |
singleprotocol/cli_swcrypto_mtd | 186 | 46 |