Skip to content

samples: openthread: Switch to new radio_nrf implementation #22915

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions samples/openthread/cli/prj.conf
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

# Enable OpenThread
CONFIG_OPENTHREAD=y

# Network shell
CONFIG_SHELL=y
CONFIG_OPENTHREAD_SHELL=y
Expand All @@ -16,9 +19,4 @@ CONFIG_PM_PARTITION_SIZE_SETTINGS_STORAGE=0x8000
# Enable OpenThread features set
CONFIG_OPENTHREAD_NORDIC_LIBRARY_MASTER=y

CONFIG_NET_L2_OPENTHREAD=y

# Generic networking options
CONFIG_NETWORKING=y

CONFIG_GPIO_SHELL=y
47 changes: 47 additions & 0 deletions samples/openthread/cli/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -169,3 +169,50 @@ tests:
- nrf54l15dk/nrf54l15/cpuapp
- nrf54l15dk/nrf54l10/cpuapp
- nrf54l15dk/nrf54l15/cpuapp/ns
sample.openthread.cli.l2:
sysbuild: true
build_only: true
tags:
- ci_build
- sysbuild
- ci_samples_openthread
platform_allow:
- nrf52840dk/nrf52840
- nrf5340dk/nrf5340/cpuapp
- nrf54l15dk/nrf54l15/cpuapp
- nrf54l15dk/nrf54l10/cpuapp
- nrf54lm20pdk/nrf54lm20a/cpuapp
- nrf54l15dk/nrf54l15/cpuapp/ns
extra_args:
- cli_SNIPPET="ci;l2;ci_l2"
integration_platforms:
- nrf52840dk/nrf52840
- nrf5340dk/nrf5340/cpuapp
- nrf54l15dk/nrf54l15/cpuapp
- nrf54l15dk/nrf54l10/cpuapp
- nrf54lm20pdk/nrf54lm20a/cpuapp
- nrf54l15dk/nrf54l15/cpuapp/ns
sample.openthread.cli.multiprotocol.l2:
sysbuild: true
build_only: true
tags:
- ci_build
- sysbuild
- ci_samples_openthread
platform_allow:
- nrf52840dk/nrf52840
- nrf5340dk/nrf5340/cpuapp
- nrf54l15dk/nrf54l15/cpuapp
- nrf54l15dk/nrf54l10/cpuapp
- nrf54lm20pdk/nrf54lm20a/cpuapp
- nrf54l15dk/nrf54l15/cpuapp/ns
extra_args:
- cli_SNIPPET="ci;logging;multiprotocol;tcp;l2;ci_l2;logging_l2"
- FILE_SUFFIX=ble
integration_platforms:
- nrf52840dk/nrf52840
- nrf5340dk/nrf5340/cpuapp
- nrf54l15dk/nrf54l15/cpuapp
- nrf54l15dk/nrf54l10/cpuapp
- nrf54lm20pdk/nrf54lm20a/cpuapp
- nrf54l15dk/nrf54l15/cpuapp/ns
9 changes: 0 additions & 9 deletions samples/openthread/cli/snippets/ci/ci.conf
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,3 @@ CONFIG_SHELL_DEFAULT_TERMINAL_WIDTH=618
CONFIG_ASSERT=y
CONFIG_ASSERT_NO_COND_INFO=y
CONFIG_RESET_ON_FATAL_ERROR=n

# Enable Zperf
CONFIG_NET_SHELL=y
CONFIG_NET_ZPERF=y
CONFIG_NET_ZPERF_SERVER=y
CONFIG_NET_CONTEXT_RCVTIMEO=y
CONFIG_NET_SOCKETS=y
CONFIG_ZVFS_OPEN_MAX=9
CONFIG_NET_SOCKETS_POLL_MAX=9
14 changes: 14 additions & 0 deletions samples/openthread/cli/snippets/ci_l2/ci_l2.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

# Enable Zperf
CONFIG_NET_SHELL=y
CONFIG_NET_ZPERF=y
CONFIG_NET_ZPERF_SERVER=y
CONFIG_NET_CONTEXT_RCVTIMEO=y
CONFIG_NET_SOCKETS=y
CONFIG_ZVFS_OPEN_MAX=9
CONFIG_NET_SOCKETS_POLL_MAX=9
9 changes: 9 additions & 0 deletions samples/openthread/cli/snippets/ci_l2/snippet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

name: ci_l2
append:
EXTRA_CONF_FILE: ci_l2.conf
12 changes: 12 additions & 0 deletions samples/openthread/cli/snippets/l2/l2.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#


# Enable Zephyr's OpenThread L2 layer
CONFIG_NET_L2_OPENTHREAD=y

# Enable networking required by L2 layer
CONFIG_NETWORKING=y
9 changes: 9 additions & 0 deletions samples/openthread/cli/snippets/l2/snippet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

name: l2
append:
EXTRA_CONF_FILE: l2.conf
14 changes: 0 additions & 14 deletions samples/openthread/cli/snippets/logging/logging.conf
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@
# Enable Zephyr logging
CONFIG_LOG=y

# Increase the default RX stack size
CONFIG_IEEE802154_NRF5_RX_STACK_SIZE=832

# Use separate thread for logging
CONFIG_LOG_MODE_DEFERRED=y

Expand All @@ -17,17 +14,6 @@ CONFIG_LOG_MAX_LEVEL=3
# Option for configuring log level in this sample
CONFIG_OT_COMMAND_LINE_INTERFACE_LOG_LEVEL_INF=y

# Enable net module logging
# CONFIG_NET_LOG=y
# Option for configuring log level in net config library
# CONFIG_NET_CONFIG_LOG_LEVEL_INF=y

# Option for configuring log level in Zephyr L2 logging
# CONFIG_OPENTHREAD_L2_DEBUG=y
# CONFIG_OPENTHREAD_L2_LOG_LEVEL_DBG=y
# CONFIG_OPENTHREAD_L2_DEBUG_DUMP_15_4=y
# CONFIG_OPENTHREAD_L2_DEBUG_DUMP_IPV6=y

# Enable Mbed TLS logging
# CONFIG_OPENTHREAD_MBEDTLS_DEBUG=y
# CONFIG_MBEDTLS_DEBUG_LEVEL=3
Expand Down
24 changes: 24 additions & 0 deletions samples/openthread/cli/snippets/logging_l2/logging_l2.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
# Enable Zephyr logging
CONFIG_LOG=y

# Increase the default RX stack size
CONFIG_IEEE802154_NRF5_RX_STACK_SIZE=832

# Use separate thread for logging
CONFIG_LOG_MODE_DEFERRED=y

# Enable net module logging
CONFIG_NET_LOG=y

# Option for configuring log level in net config library
CONFIG_NET_CONFIG_LOG_LEVEL_INF=y

# Option for configuring log level in Zephyr L2 logging
CONFIG_OPENTHREAD_L2_DEBUG=y
CONFIG_OPENTHREAD_L2_LOG_LEVEL_DBG=y
CONFIG_OPENTHREAD_L2_DEBUG_DUMP_15_4=y
CONFIG_OPENTHREAD_L2_DEBUG_DUMP_IPV6=y
9 changes: 9 additions & 0 deletions samples/openthread/cli/snippets/logging_l2/snippet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

name: logging_l2
append:
EXTRA_CONF_FILE: logging_l2.conf
13 changes: 3 additions & 10 deletions samples/openthread/coap_server/prj.conf
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

# Enable OpenThread
CONFIG_OPENTHREAD=y

# nRF board library
CONFIG_DK_LIBRARY=y

Expand All @@ -19,19 +22,9 @@ CONFIG_SHELL_CMD_BUFF_SIZE=416
# Increase Settings storage size
CONFIG_PM_PARTITION_SIZE_SETTINGS_STORAGE=0x8000

# Network sockets
CONFIG_NET_SOCKETS=y
CONFIG_NET_SOCKETS_POLL_MAX=4

# Same network Master Key for client and server
CONFIG_OPENTHREAD_NETWORKKEY="00:11:22:33:44:55:66:77:88:99:aa:bb:cc:dd:ee:ff"

# L2 OpenThread enabling
CONFIG_NET_L2_OPENTHREAD=y

# Generic networking options
CONFIG_NETWORKING=y

CONFIG_MBEDTLS_SHA1_C=n
CONFIG_FPU=y

Expand Down
21 changes: 21 additions & 0 deletions samples/openthread/coap_server/snippets/l2/l2.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#


# Enable Zephyr's OpenThread L2 layer
CONFIG_NET_L2_OPENTHREAD=y

# Enable networking required by L2 layer
CONFIG_NETWORKING=y

# Enable Zperf
CONFIG_NET_SHELL=y
CONFIG_NET_ZPERF=y
CONFIG_NET_ZPERF_SERVER=y
CONFIG_NET_CONTEXT_RCVTIMEO=y
CONFIG_NET_SOCKETS=y
CONFIG_ZVFS_OPEN_MAX=9
CONFIG_NET_SOCKETS_POLL_MAX=9
9 changes: 9 additions & 0 deletions samples/openthread/coap_server/snippets/l2/snippet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

name: l2
append:
EXTRA_CONF_FILE: l2.conf
11 changes: 0 additions & 11 deletions samples/openthread/coap_server/snippets/logging/logging.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,6 @@
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause

# Enable net module logging
# CONFIG_NET_LOG=y
# Option for configuring log level in net config library
# CONFIG_NET_CONFIG_LOG_LEVEL_INF=y

# Option for configuring log level in Zephyr L2 logging
# CONFIG_OPENTHREAD_L2_DEBUG=y
# CONFIG_OPENTHREAD_L2_LOG_LEVEL_DBG=y
# CONFIG_OPENTHREAD_L2_DEBUG_DUMP_15_4=y
# CONFIG_OPENTHREAD_L2_DEBUG_DUMP_IPV6=y

# Configure sample logging setting
CONFIG_LOG=y
CONFIG_COAP_SERVER_LOG_LEVEL_DBG=y
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
# Enable Zephyr logging
CONFIG_LOG=y

# Increase the default RX stack size
CONFIG_IEEE802154_NRF5_RX_STACK_SIZE=832

# Use separate thread for logging
CONFIG_LOG_MODE_DEFERRED=y

# Enable net module logging
CONFIG_NET_LOG=y

# Option for configuring log level in net config library
CONFIG_NET_CONFIG_LOG_LEVEL_INF=y

# Option for configuring log level in Zephyr L2 logging
CONFIG_OPENTHREAD_L2_DEBUG=y
CONFIG_OPENTHREAD_L2_LOG_LEVEL_DBG=y
CONFIG_OPENTHREAD_L2_DEBUG_DUMP_15_4=y
CONFIG_OPENTHREAD_L2_DEBUG_DUMP_IPV6=y
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

name: logging_l2
append:
EXTRA_CONF_FILE: logging_l2.conf
8 changes: 3 additions & 5 deletions samples/openthread/coprocessor/prj.conf
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,16 @@
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

# Enable OpenThread
CONFIG_OPENTHREAD=y

# Set OpenThread NCP architecture
CONFIG_OPENTHREAD_COPROCESSOR=y
CONFIG_OPENTHREAD_COPROCESSOR_RCP=y

# Nordic feature set
CONFIG_OPENTHREAD_NORDIC_LIBRARY_RCP=y

CONFIG_NET_L2_OPENTHREAD=y

# Generic networking options
CONFIG_NETWORKING=y

# Increase Settings storage size
CONFIG_PM_PARTITION_SIZE_SETTINGS_STORAGE=0x8000

Expand Down
21 changes: 21 additions & 0 deletions samples/openthread/coprocessor/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -88,3 +88,24 @@ tests:
- nrf21540dk/nrf52840
integration_platforms:
- nrf52840dk/nrf52840
sample.openthread.coprocessor.l2:
sysbuild: true
build_only: true
tags:
- ci_build
- sysbuild
- ci_samples_openthread
platform_allow:
- nrf52840dk/nrf52840
- nrf54l15dk/nrf54l15/cpuapp
- nrf54l15dk/nrf54l10/cpuapp
- nrf54lm20pdk/nrf54lm20a/cpuapp
- nrf54l15dk/nrf54l15/cpuapp/ns
extra_args:
- cli_SNIPPET="ci;l2"
integration_platforms:
- nrf52840dk/nrf52840
- nrf54l15dk/nrf54l15/cpuapp
- nrf54l15dk/nrf54l10/cpuapp
- nrf54lm20pdk/nrf54lm20a/cpuapp
- nrf54l15dk/nrf54l15/cpuapp/ns
21 changes: 21 additions & 0 deletions samples/openthread/coprocessor/snippets/l2/l2.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#


# Enable Zephyr's OpenThread L2 layer
CONFIG_NET_L2_OPENTHREAD=y

# Enable networking required by L2 layer
CONFIG_NETWORKING=y

# Enable Zperf
CONFIG_NET_SHELL=y
CONFIG_NET_ZPERF=y
CONFIG_NET_ZPERF_SERVER=y
CONFIG_NET_CONTEXT_RCVTIMEO=y
CONFIG_NET_SOCKETS=y
CONFIG_ZVFS_OPEN_MAX=9
CONFIG_NET_SOCKETS_POLL_MAX=9
9 changes: 9 additions & 0 deletions samples/openthread/coprocessor/snippets/l2/snippet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#
# Copyright (c) 2025 Nordic Semiconductor
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

name: l2
append:
EXTRA_CONF_FILE: l2.conf
Loading