nRF91x1: DECT NR+ PHY hello

The DECT NR+ physical layer (PHY) hello sample demonstrates how to set up a simple DECT NR+ application with the DECT PHY firmware.

Important

The sample only showcases the use of the DECT NR+ physical layer interface of the Modem library and is not a complete standalone application.

Requirements

The sample supports the following development kits, and requires at least two kits:

Hardware platforms

PCA

Board name

Board target

nRF9161 DK

PCA10153

nrf9161dk

nrf9161dk/nrf9161/ns

nRF9151 DK

PCA10171

nrf9151dk

nrf9151dk/nrf9151/ns

Note

The nRF91x1: DECT NR+ PHY hello sample requires the DECT NR+ PHY firmware to run on the nRF91x1 modem core. For more information, contact the Nordic Semiconductor sales department.

When built for a board target with the */ns variant, the sample is configured to compile and run as a non-secure application with Cortex-M Security Extensions enabled. Therefore, it automatically includes Trusted Firmware-M that prepares the required peripherals and secure services to be available for the application.

Overview

The sample shows a simple broadcast and reception of DECT NR+ messages between devices on a hard-coded channel.

After initialization, the devices run into a loop, transmitting a counter value before listening for incoming receptions. The time to listen is set by the CONFIG_RX_PERIOD_S Kconfig option. The loop is exited after a number of transmissions set by the CONFIG_TX_TRANSMISSIONS Kconfig option, or it continues forever if the CONFIG_TX_TRANSMISSIONS Kconfig option is set to 0.

Each device can be reset to run the sample again.

Configuration

See Configuring and building an application for information about how to permanently or temporarily change the configuration.

Configuration options

Check and configure the following Kconfig options:

CONFIG_CARRIER

The sample configuration defines the carrier to use. The availability of the channels and the exact regulations for using them vary in different countries. See section 5.4.2 of ETSI TS 103 636-2 for the calculation.

CONFIG_NETWORK_ID

The configuration option specifies the network ID. It ranges from 1 to 4294967295 with the default value set to 91.

CONFIG_MCS

The configuration option specifies the Modulation Coding Scheme (MCS). The MCS impacts how much data can fit into each subslot. The default value is set to 1.

CONFIG_TX_POWER

The configuration option sets the transmission power. See the table 6.2.1-3 of ETSI TS 103 636-4 for more details. It ranges from 0 to 11 with the default value set to 11.

CONFIG_TX_TRANSMISSIONS

The configuration option sets the number of transmissions before the sample exits. It ranges from 0 to 4294967295 with the default value set to 30.

CONFIG_RX_PERIOD_S

The sample configuration sets the receive window period. The time is set in seconds. The default value is set to 5 seconds.

Building and running

This sample can be found under samples/dect/dect_phy/hello_dect in the nRF Connect SDK folder structure.

When built as firmware image for a board target with the */ns variant, the sample has Cortex-M Security Extensions (CMSE) enabled and separates the firmware between Non-Secure Processing Environment (NSPE) and Secure Processing Environment (SPE). Because of this, it automatically includes the Trusted Firmware-M (TF-M). To read more about CMSE, see Processing environments.

To build the sample, follow the instructions in Configuring and building an application for your preferred building environment. See also Programming an application for programming steps and Testing and optimization for general information about testing and debugging in the nRF Connect SDK.

Note

When building repository applications in the SDK repositories, building with sysbuild is enabled by default. If you work with out-of-tree freestanding applications, you need to manually pass the --sysbuild parameter to every build command or configure west to always use it.

Important

DECT NR+ operates on free but regulated radio channels. The regulations and availability of the channels vary by country and region. It is your responsibility to operate the devices according to local regulations, both at the development site and in the device operating regions. If you are in the EU or US with permission to operate on the DECT band and can ensure that access rules are met, you can use the overlay-eu.conf and overlay-us.conf Kconfig overlays, respectively. If other configuration is required, set the carrier using the CONFIG_CARRIER Kconfig option, and the transmission power using the CONFIG_TX_POWER Kconfig option. If you, as a user, are not permitted to operate on the DECT band or cannot ensure that access rules are met, you must ensure there are no radio emissions from the devices running the sample. This can be done with the use of an RF chamber.

  • To build with one of the provided overlays, run the following command:

    west build -p -b build_target -- -DEXTRA_CONF_FILE="<your_overlay>"
  • To build with other carrier and transmission power configuration, run the following command:

    west build -p -b build_target -- -DCONFIG_CARRIER=<your_carrier> -DCONFIG_TX_POWER=<your_tx_power>

You can also add your own overlay or the Kconfig options to the project configuration to build with other carrier and transmission power configurations.

Testing

After programming the sample to your development kit, complete the following steps to test it:

  1. Connect the kit to the computer using a USB cable. The kit is assigned a COM port (Windows) or ttyACM device (Linux), which is visible in the Device Manager.

  2. Connect to the kit with a terminal emulator (for example, nRF Connect Serial Terminal). See Testing and optimization for the required settings and steps.

  3. Observe that the devices transmit a counter value that is received by the other devices.

  4. After a given number of transmissions, observe that the devices shut down and exit the sample.

Sample output

The sample shows an output similar to the following:

Device 1:

*** Booting nRF Connect SDK v3.5.99-ncs1 ***
[00:00:00.378,784] <inf> app: Dect NR+ PHY Hello sample started
[00:00:00.691,375] <inf> app: Dect NR+ PHY initialized, device ID: 12345
[00:00:00.691,406] <inf> app: Transmitting 0
[00:00:05.697,784] <inf> app: Transmitting 1
[00:00:10.704,193] <inf> app: Transmitting 2
[00:00:14.186,553] <inf> app: Received header from device ID 67890
[00:00:14.186,889] <inf> app: Received data (RSSI: -54.5): Hello DECT! 0
[00:00:15.710,571] <inf> app: Transmitting 3
[00:00:19.192,932] <inf> app: Received header from device ID 67890
[00:00:19.193,267] <inf> app: Received data (RSSI: -54.5): Hello DECT! 1
[00:00:20.716,949] <inf> app: Transmitting 4
...
[00:02:24.352,661] <inf> app: Received header from device ID 67890
[00:02:24.352,996] <inf> app: Received data (RSSI: -54.5): Hello DECT! 26
[00:02:25.876,739] <inf> app: Transmitting 29
[00:02:25.876,831] <inf> app: Reached maximum number of transmissions (30)
[00:02:25.876,831] <inf> app: Shutting down
[00:02:25.893,554] <inf> app: Bye!

Device 2:

*** Booting nRF Connect SDK v3.5.99-ncs1 ***
[00:00:00.407,287] <inf> app: Dect NR+ PHY Hello sample started
[00:00:00.719,238] <inf> app: Dect NR+ PHY initialized, device ID: 67890
[00:00:00.719,268] <inf> app: Transmitting 0
[00:00:02.254,211] <inf> app: Received header from device ID 12345
[00:00:02.254,547] <inf> app: Received data (RSSI: -54.5): Hello DECT! 3
[00:00:05.725,646] <inf> app: Transmitting 1
[00:00:07.260,620] <inf> app: Received header from device ID 12345
[00:00:07.260,955] <inf> app: Received data (RSSI: -54.5): Hello DECT! 4
...
[00:02:10.885,284] <inf> app: Transmitting 26
[00:02:12.420,318] <inf> app: Received header from device ID 12345
[00:02:12.420,654] <inf> app: Received data (RSSI: -54.5): Hello DECT! 29
[00:02:15.891,693] <inf> app: Transmitting 27
[00:02:20.898,071] <inf> app: Transmitting 28
[00:02:25.904,449] <inf> app: Transmitting 29
[00:02:25.904,541] <inf> app: Reached maximum number of transmissions (30)
[00:02:25.904,571] <inf> app: Shutting down
[00:02:25.921,325] <inf> app: Bye!

Dependencies

It uses the following sdk-nrfxlib library:

It uses the following Zephyr library:

In addition, it uses the following secure firmware component: