diff --git a/cpu/cc2538/Kconfig b/cpu/cc2538/Kconfig index 104746b8d7..50d27267c9 100644 --- a/cpu/cc2538/Kconfig +++ b/cpu/cc2538/Kconfig @@ -21,6 +21,7 @@ config CPU_FAM_CC2538 select HAS_PERIPH_UART_NONBLOCKING select HAS_PERIPH_RTT_OVERFLOW select HAS_PERIPH_WDT + select HAVE_CC2538_RF ## CPU Models config CPU_MODEL_CC2538NF53 @@ -48,4 +49,9 @@ config CPU_MODEL config CPU default "cc2538" if CPU_FAM_CC2538 +config MODULE_PERIPH_UART_NONBLOCKING + bool + depends on HAS_PERIPH_UART_NONBLOCKING + select MODULE_TSRB + source "$(RIOTCPU)/cortexm_common/Kconfig" diff --git a/cpu/cc2538/Makefile.features b/cpu/cc2538/Makefile.features index 0fd7200a4f..27bd934a5f 100644 --- a/cpu/cc2538/Makefile.features +++ b/cpu/cc2538/Makefile.features @@ -15,3 +15,9 @@ FEATURES_PROVIDED += periph_wdt FEATURES_PROVIDED += cortexm_mpu include $(RIOTCPU)/cortexm_common/Makefile.features + +# This configuration enables modules that are only available when using Kconfig +# module modelling +ifeq (1, $(TEST_KCONFIG)) + KCONFIG_ADD_CONFIG += $(RIOTCPU)/cc2538/cc2538.config +endif diff --git a/cpu/cc2538/cc2538.config b/cpu/cc2538/cc2538.config new file mode 100644 index 0000000000..811b1f3712 --- /dev/null +++ b/cpu/cc2538/cc2538.config @@ -0,0 +1 @@ +CONFIG_MODULE_PM_LAYERED=y diff --git a/cpu/cc2538/radio/Kconfig b/cpu/cc2538/radio/Kconfig new file mode 100644 index 0000000000..f3fd036b6e --- /dev/null +++ b/cpu/cc2538/radio/Kconfig @@ -0,0 +1,30 @@ +# Copyright (c) 2021 HAW Hamburg +# +# This file is subject to the terms and conditions of the GNU Lesser +# General Public License v2.1. See the file LICENSE in the top level +# directory for more details. +# + +menuconfig MODULE_CC2538_RF + bool "CC2538 IEEE 802.15.4 radio" + depends on TEST_KCONFIG + depends on CPU_FAM_CC2538 + +if MODULE_CC2538_RF + +config MODULE_CC2538_RF_OBS_SIG + bool "Output observation signals" + help + Say y to output different observation signals from the RF Core + to GPIO pins. These signals can be useful for debugging of + low-level protocols or control of external PA, LNA, or switches. + + For more information check section 9.2.4 of the CC2538 User's Manual. + +endif # MODULE_CC2538_RF + +config HAVE_CC2538_RF + bool + select MODULE_CC2538_RF if MODULE_NETDEV_DEFAULT + help + Indicates that a cc2538 radio is present. diff --git a/drivers/Kconfig.net b/drivers/Kconfig.net index afe39e97c5..c2e470d35e 100644 --- a/drivers/Kconfig.net +++ b/drivers/Kconfig.net @@ -9,6 +9,7 @@ rsource "at86rf215/Kconfig" rsource "ata8520e/Kconfig" rsource "can_trx/Kconfig" rsource "cc110x/Kconfig" +source "$(RIOTCPU)/cc2538/radio/Kconfig" rsource "dose/Kconfig" rsource "mcp2515/Kconfig" rsource "mrf24j40/Kconfig"