diff --git a/soc/arm/nordic_nrf/Kconfig.peripherals b/soc/arm/nordic_nrf/Kconfig.peripherals index a4b1b8d35ae..3e358e16de8 100644 --- a/soc/arm/nordic_nrf/Kconfig.peripherals +++ b/soc/arm/nordic_nrf/Kconfig.peripherals @@ -124,6 +124,9 @@ config HAS_HW_NRF_RADIO_BLE_CODED config HAS_HW_NRF_RADIO_IEEE802154 bool +config HAS_HW_NRF_RADIO_BLE_DF + bool + config HAS_HW_NRF_RNG bool diff --git a/soc/arm/nordic_nrf/nrf52/Kconfig.soc b/soc/arm/nordic_nrf/nrf52/Kconfig.soc index 9b7f75b6603..3efe1e61f25 100644 --- a/soc/arm/nordic_nrf/nrf52/Kconfig.soc +++ b/soc/arm/nordic_nrf/nrf52/Kconfig.soc @@ -295,6 +295,7 @@ config SOC_NRF52833 select HAS_HW_NRF_RADIO_TX_PWR_HIGH select HAS_HW_NRF_RADIO_BLE_CODED select HAS_HW_NRF_RADIO_IEEE802154 + select HAS_HW_NRF_RADIO_BLE_DF select HAS_HW_NRF_RNG select HAS_HW_NRF_RTC0 select HAS_HW_NRF_RTC1 diff --git a/subsys/bluetooth/controller/Kconfig b/subsys/bluetooth/controller/Kconfig index d9ca722bd05..9a0c46e0d26 100644 --- a/subsys/bluetooth/controller/Kconfig +++ b/subsys/bluetooth/controller/Kconfig @@ -550,6 +550,7 @@ config BT_CTLR_SMI_TX_SETTING help Enable support for Bluetooth 5.0 SMI TX through a system setting. +source "subsys/bluetooth/controller/Kconfig.df" source "subsys/bluetooth/controller/Kconfig.ll_sw_split" config BT_CTLR_ASSERT_HANDLER @@ -561,11 +562,6 @@ config BT_CTLR_ASSERT_HANDLER and will be invoked whenever the controller code encounters an unrecoverable error. -config BT_CTLR_DF - bool "LE Direction Finding Support [EXPERIMENTAL]" if BT_LL_SW_SPLIT - help - Enable support for Bluetooth 5.1 Direction Finding - endif # BT_CTLR config BT_CTLR_DEBUG_PINS_CPUAPP diff --git a/subsys/bluetooth/controller/Kconfig.df b/subsys/bluetooth/controller/Kconfig.df new file mode 100644 index 00000000000..ae3ff657e61 --- /dev/null +++ b/subsys/bluetooth/controller/Kconfig.df @@ -0,0 +1,64 @@ +# Zephyr Bluetooth Controller configuration options + +# Copyright (c) 2020 Nordic Semiconductor ASA +# SPDX-License-Identifier: Apache-2.0 + +config BT_CTLR_DF_SUPPORT + bool + +config BT_CTLR_DF_CTE_TX_SUPPORT + bool + +config BT_CTLR_DF_ANT_SWITCH_2US_SUPPORT + bool + +config BT_CTLR_DF_ANT_SWITCH_1US_SUPPORT + bool + +menuconfig BT_CTLR_DF + bool "LE Direction Finding [Experimental]" + depends on BT_CTLR_DF_SUPPORT + help + Enable support for Bluetooth 5.1 Direction Finding + +if BT_CTLR_DF + +# Basic controller functionalities required for implementation of +# Bluetooth v5.1 Direction Finding + +config BT_CTLR_DF_CTE_TX + bool "Enable transmission of Constant Tone Extension" + depends on BT_CTLR_DF_CTE_TX_SUPPORT + default y + help + Enable support for transmission of Constant Tone Extension in + controller. + +config BT_CTLR_DF_ANT_SWITCHING_1US + bool "Enable support for 1us antenna switching slots" + depends on BT_CTLR_DF_ANT_SWITCH_1US_SUPPORT + default y + help + Enable support for 1us antenna switching slots. This antenna switching + mode is optional for Direction Finding according to Bluetooth v5.1. + +# Features related with Direction Finding +# BT Core spec 5.1, Vol 6, Part B, sec. 4.6 Feature Support + +config BT_CTLR_DF_ANT_SWITCH_TX + bool "Enable antenna switching during CTE transmission (AoD) feature" + depends on BT_CTLR_DF_CTE_TX && BT_CTLR_DF_ANT_SWITCH_2US_SUPPORT + default y + help + Enable support for antenna switching during CTE transmission. + Also known as Angle of Departure mode. + +config BT_CTLR_DF_CONN_CTE_RSP + bool "Enable Connection CTE Response feature" + depends on BT_CTLR_DF_CTE_TX && BT_CONN + default y + help + Enable support for Bluetooth v5.1 Connection CTE Response feature + in controller. + +endif # BT_CTRL_DIRECTION_FINDING diff --git a/subsys/bluetooth/controller/Kconfig.ll_sw_split b/subsys/bluetooth/controller/Kconfig.ll_sw_split index cd634022d1c..153388318f9 100644 --- a/subsys/bluetooth/controller/Kconfig.ll_sw_split +++ b/subsys/bluetooth/controller/Kconfig.ll_sw_split @@ -37,6 +37,13 @@ config BT_LLL_VENDOR_NORDIC select BT_CTLR_XTAL_ADVANCED_SUPPORT select BT_CTLR_SCHED_ADVANCED_SUPPORT select BT_CTLR_TIFS_HW_SUPPORT + # Direction Finding + select BT_CTLR_DF_SUPPORT if HAS_HW_NRF_RADIO_BLE_DF + select BT_CTLR_DF_CTE_TX_SUPPORT if HAS_HW_NRF_RADIO_BLE_DF + select BT_CTLR_DF_ANT_SWITCH_2US_SUPPORT if HAS_HW_NRF_RADIO_BLE_DF + # optional ant switching slot mode + select BT_CTLR_DF_ANT_SWITCH_1US_SUPPORT if HAS_HW_NRF_RADIO_BLE_DF + default y help Use Nordic Lower Link Layer implementation.