1# Copyright (c) 2016-2021 Nordic Semiconductor ASA 2# SPDX-License-Identifier: Apache-2.0 3 4config ZEPHYR_HAL_NORDIC_MODULE 5 bool 6 7config HAS_NORDIC_DRIVERS 8 bool 9 10menu "Nordic drivers" 11 depends on HAS_NORDIC_DRIVERS 12 13choice NRF_802154_SOURCE 14 prompt "Source of the IEEE 802.15.4 radio driver" 15 16config NRF_802154_SOURCE_HAL_NORDIC 17 bool "Open source" 18 19endchoice 20 21menuconfig NRF_802154_RADIO_DRIVER 22 bool "NRF IEEE 802.15.4 radio driver" 23 depends on HAS_HW_NRF_RADIO_IEEE802154 24 select DYNAMIC_INTERRUPTS 25 select ENTROPY_GENERATOR 26 depends on !$(dt_nodelabel_enabled,timer1) 27 help 28 This option enables nRF IEEE 802.15.4 radio driver in Zephyr. Note, 29 that beside the radio peripheral itself, this drivers occupies several 30 other peripherals. A complete list can be found in the hal_nordic 31 repository, within drivers/nrf_radio_802154/nrf_802154_peripherals.h 32 file. As the nRF IEEE 802.15.4 radio driver defines IRQ configuration 33 abstraction layer API and its Zephyr-specific implementation uses dynamic 34 interrupts, the DYNAMIC_INTERRUPTS switch is selected unconditionally. 35 36if NRF_802154_RADIO_DRIVER 37 38config NRF_802154_MULTIPROTOCOL_SUPPORT 39 bool 40 help 41 In dynamic multiprotocol applications, access to the radio peripheral 42 must be distributed by an arbiter. To support this arbitration 43 in the driver, this option must be enabled. Otherwise, the driver 44 assumes that access to the radio peripheral is granted indefinitely. 45 46choice NRF_802154_SL_TYPE 47 prompt "nRF IEEE 802.15.4 Service Layer Type" 48 49config NRF_802154_SL_OPENSOURCE 50 bool "Open source" 51 select SENSOR if NRF_802154_TEMPERATURE_UPDATE 52 select TEMP_NRF5 if NRF_802154_TEMPERATURE_UPDATE 53 54endchoice 55 56config NRF_802154_TEMPERATURE_UPDATE 57 bool "nRF 802.15.4 temperature update" 58 default y if !SOC_NRF54H20 59 help 60 Enable temperature update for nRF 802.15.4 driver 61 62config NRF_802154_TEMPERATURE_UPDATE_INIT_PRIO 63 int "nRF52 IEEE 802.15.4 temperature update initialization priority" 64 depends on NRF_802154_TEMPERATURE_UPDATE 65 default 91 66 help 67 Set the initialization priority of a temperature update for nRF 802.15.4 driver. 68 69config NRF_802154_TEMPERATURE_UPDATE_PERIOD 70 int "nRF 802.15.4 temperature update period in milliseconds" 71 depends on NRF_802154_TEMPERATURE_UPDATE 72 default 60000 73 help 74 Period of a temperature update for nRF 802.15.4 driver in milliseconds 75 76endif # NRF_802154_RADIO_DRIVER 77 78config NRF_802154_SERIALIZATION 79 bool 80 select IPC_SERVICE 81 select MBOX 82 help 83 This helper symbol indicates that the nRF 802.15.4 serialization is available. 84 85config NRF_802154_SER_HOST 86 bool "nRF IEEE 802.15.4 Driver serialization host" 87 depends on !NRF_802154_RADIO_DRIVER 88 depends on !HAS_HW_NRF_RADIO_IEEE802154 89 select IEEE802154_NRF5_EXT_IRQ_MGMT if IEEE802154_NRF5 90 select NRF_802154_SERIALIZATION 91 help 92 Enable serialization of nRF IEEE 802.15.4 Driver. This option is to be 93 used if radio is not available in the core, but radio services are 94 provided by a serialization backend. 95 96menuconfig NRF_802154_SER_RADIO 97 bool "nRF IEEE 802.15.4 Driver serialization radio" 98 depends on HAS_HW_NRF_RADIO_IEEE802154 99 depends on !IEEE802154_NRF5 100 select NRF_802154_RADIO_DRIVER 101 select NRF_802154_SERIALIZATION 102 help 103 Enable serialization of nRF IEEE 802.15.4 Driver. This option is to be 104 used if radio is available in the core to provide radio services over 105 a serialization backend. 106 107if NRF_802154_SER_RADIO 108 109config NRF_802154_SER_RADIO_INIT_PRIO 110 int "nRF52 IEEE 802.15.4 serialization initialization priority" 111 default 51 112 help 113 Set the initialization priority number. Do not mess with it unless 114 you know what you are doing. 115 116endif 117 118menu "nRF 802.15.4 serialization" 119 depends on NRF_802154_SER_HOST || NRF_802154_SER_RADIO 120 121config NRF_802154_SER_LOG 122 bool "802.15.4 serialization logs" 123 default n 124 help 125 This option enable debug logs of 802.15.4 serialization module. 126 127config NRF_802154_SER_DEFAULT_RESPONSE_TIMEOUT 128 int "Default Spinel serialization response timeout in milliseconds" 129 default 500 130 help 131 This option specifies default timeout of spinel status response 132 in milliseconds. 133 134endmenu # NRF_802154_SER_HOST || NRF_802154_SER_RADIO 135 136if NRF_802154_RADIO_DRIVER || NRF_802154_SERIALIZATION 137 138choice NRF_802154_CCA_MODE 139 prompt "nRF IEEE 802.15.4 CCA mode" 140 default NRF_802154_CCA_MODE_ED 141 help 142 CCA mode 143 144config NRF_802154_CCA_MODE_ED 145 bool "Energy Above Threshold" 146 147config NRF_802154_CCA_MODE_CARRIER 148 bool "Carrier Seen" 149 150config NRF_802154_CCA_MODE_CARRIER_AND_ED 151 bool "Energy Above Threshold AND Carrier Seen" 152 153config NRF_802154_CCA_MODE_CARRIER_OR_ED 154 bool "Energy Above Threshold OR Carrier Seen" 155 156endchoice 157 158config NRF_802154_CCA_ED_THRESHOLD 159 int "nRF IEEE 802.15.4 CCA Energy Detection threshold" 160 default 45 161 help 162 If energy detected in a given channel is above the value then the 163 channel is deemed busy. The unit is defined as per 802.15.4-2006 spec. 164 165config NRF_802154_CCA_CORR_THRESHOLD 166 int "nRF IEEE 802.15.4 CCA Correlator threshold" 167 default 45 168 169config NRF_802154_CCA_CORR_LIMIT 170 int "nRF IEEE 802.15.4 CCA Correlator limit" 171 default 2 172 help 173 Limit for occurrences above correlator threshold. When not equal to 174 zero the correlator based signal detect is enabled. 175 176config NRF_802154_RX_BUFFERS 177 int "nRF 802.15.4 receive buffers" 178 default 16 179 help 180 Number of buffers in nRF 802.15.4 driver serialization host's receive queue. 181 If this value is modified, its remote counterpart must be set to the exact same value. 182 183config NRF_802154_PENDING_SHORT_ADDRESSES 184 int "nRF 802.15.4 pending short addresses" 185 default 16 186 help 187 Number of slots containing short addresses of nodes for which pending data is stored 188 189config NRF_802154_PENDING_EXTENDED_ADDRESSES 190 int "nRF 802.15.4 pending extended addresses" 191 default 16 192 help 193 Number of slots containing extended addresses of nodes for which pending data is stored 194 195config NRF_802154_ENCRYPTION 196 bool "nRF 802.15.4 AES-CCM* authentication & encryption" 197 depends on !CRYPTO_NRF_ECB 198 199config NRF_802154_SECURITY_KEY_STORAGE_SIZE 200 int "nRF 802.15.4 security key storage size" 201 default 3 202 help 203 Number of encryption keys that the nRF 802.15.4 Radio Driver can store simultaneously. 204 205config NRF_802154_CARRIER_FUNCTIONS 206 bool "nRF 802.15.4 carrier functions" 207 default y if (OPENTHREAD_DIAG || IEEE802154_CARRIER_FUNCTIONS) 208 help 209 This option enables functions such as modulated carrier and continuous carrier. 210 If this option is modified on a multicore SoC, its remote counterpart must be set to the exact same value. 211 212choice NRF_802154_ASSERT_CHOICE 213 prompt "nRF 802.15.4 assert implementation" 214 default NRF_802154_ASSERT_ZEPHYR_MINIMAL 215 216config NRF_802154_ASSERT_ZEPHYR_MINIMAL 217 bool "nRF 802.15.4 minimal assertions" 218 help 219 This option provides minimal run-time checking of the nRF 802.15.4 Radio Driver's operation, 220 even if kernel-wide CONFIG_ASSERT is disabled. In case of an abnormal condition the function 221 `nrf_802154_assert_handler()` is called. File and line debug information are not provided 222 to save memory of the image file. Default implementation of the `nrf_802154_assert_handler` 223 involves a call to `k_panic`/`k_oops` and allows further tweaking of the behavior. 224 You can also provide your own implementation of `nrf_802154_assert_handler`. 225 226config NRF_802154_ASSERT_ZEPHYR 227 bool "nRF 802.15.4 Radio Driver assertions as Zephyr's standard __ASERT_NO_MSG" 228 help 229 The run-time checking of the nRF 802.15.4 Radio Driver depends fully on the configuration 230 of the `__ASSERT_NO_MSG` macro, including the ability to completely turn off the run-time 231 checking. 232 233endchoice # NRF_802154_ASSERT_CHOICE 234 235endif # NRF_802154_RADIO_DRIVER || NRF_802154_SERIALIZATION 236 237endmenu # HAS_NORDIC_DRIVERS 238 239rsource "nrfs/Kconfig" 240rsource "nrfx/Kconfig" 241rsource "Kconfig.nrf_regtool" 242