From a25764b19c6c556d024db4a272b1ccc7a2890975 Mon Sep 17 00:00:00 2001 From: Piotr Pryga Date: Tue, 15 Jun 2021 11:16:46 +0200 Subject: [PATCH] samples: Bluetooth: df_tx: Add config for support the nRF52820 Add required configuration and DTS overlay for support the nRF52820 SOC. Signed-off-by: Piotr Pryga --- .../README.rst | 1 + .../boards/nrf52833dk_nrf52820.conf | 10 +++++++ .../boards/nrf52833dk_nrf52820.overlay | 26 +++++++++++++++++++ .../boards/nrf52833dk_nrf52833.overlay | 2 +- .../prj.conf | 6 ----- 5 files changed, 38 insertions(+), 7 deletions(-) create mode 100644 samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.conf create mode 100644 samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.overlay diff --git a/samples/bluetooth/direction_finding_connectionless_tx/README.rst b/samples/bluetooth/direction_finding_connectionless_tx/README.rst index 71be5ffeb33..3ae85ee8b41 100644 --- a/samples/bluetooth/direction_finding_connectionless_tx/README.rst +++ b/samples/bluetooth/direction_finding_connectionless_tx/README.rst @@ -14,6 +14,7 @@ Requirements ************ * nRF52833DK board with nRF52833 SOC +* nRF52833DK board with nRF52820 SOC * antenna matrix for AoD (optional) Building and Running diff --git a/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.conf b/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.conf new file mode 100644 index 00000000000..8e43e75c274 --- /dev/null +++ b/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.conf @@ -0,0 +1,10 @@ +CONFIG_BT_CTLR=y +CONFIG_BT_LL_SW_SPLIT=y + +CONFIG_BT_CTLR_ADV_EXT=y +CONFIG_BT_CTLR_ADV_PERIODIC=y + +# Enable Direction Finding TX Feature including AoA and AoD +CONFIG_BT_CTLR_DF=y +CONFIG_BT_CTLR_DF_ANT_SWITCH_RX=n +CONFIG_BT_CTLR_DF_SCAN_CTE_RX=n diff --git a/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.overlay b/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.overlay new file mode 100644 index 00000000000..cbc346ce25f --- /dev/null +++ b/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52820.overlay @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2021 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: Apache-2.0 + */ + +&radio { + status = "okay"; + /* This is an example number of antennas that may be available + * on antenna matrix board. + */ + dfe-antenna-num = <10>; + /* This is an example switch pattern that will be used to set an + * antenna for Tx PDU (period before start of Tx CTE). + */ + dfe-pdu-antenna = <0x1>; + + /* These are example GPIO pin numbers that are provided to + * Radio peripheral. The pins will be acquired by Radio to + * drive antenna switching when AoD is enabled. + */ + dfegpio0-gpios = <&gpio0 1 0>; + dfegpio1-gpios = <&gpio0 2 0>; + dfegpio2-gpios = <&gpio0 3 0>; + dfegpio3-gpios = <&gpio0 4 0>; +}; diff --git a/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52833.overlay b/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52833.overlay index 68f89379d99..cbc346ce25f 100644 --- a/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52833.overlay +++ b/samples/bluetooth/direction_finding_connectionless_tx/boards/nrf52833dk_nrf52833.overlay @@ -9,7 +9,7 @@ /* This is an example number of antennas that may be available * on antenna matrix board. */ - dfe-antenna-num = < 10 >; + dfe-antenna-num = <10>; /* This is an example switch pattern that will be used to set an * antenna for Tx PDU (period before start of Tx CTE). */ diff --git a/samples/bluetooth/direction_finding_connectionless_tx/prj.conf b/samples/bluetooth/direction_finding_connectionless_tx/prj.conf index b8019fb683b..82563cc149d 100644 --- a/samples/bluetooth/direction_finding_connectionless_tx/prj.conf +++ b/samples/bluetooth/direction_finding_connectionless_tx/prj.conf @@ -1,14 +1,8 @@ CONFIG_BT=y -CONFIG_BT_CTLR=y -CONFIG_BT_LL_SW_SPLIT=y CONFIG_BT_DEVICE_NAME="DF Connectionless Beacon App" CONFIG_BT_EXT_ADV=y CONFIG_BT_PER_ADV=y -CONFIG_BT_CTLR_ADV_EXT=y -CONFIG_BT_CTLR_ADV_PERIODIC=y # Enable Direction Finding Feature including AoA and AoD CONFIG_BT_DF=y -CONFIG_BT_CTLR_DF=y -CONFIG_BT_CTLR_DF_ADV_CTE_TX=y