Merge pull request #15708 from leandrolanzieri/pr/kconfig/drivers_opqr

drivers/{o, p, q, r}*: add modules to Kconfig
This commit is contained in:
Francisco 2021-01-18 10:06:09 +01:00 committed by GitHub
commit 8e40f6a653
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
24 changed files with 263 additions and 1 deletions

View File

@ -16,7 +16,8 @@ tests/driver_b* tests/driver_ccs811 tests/driver_ccs811_full tests/driver_dcf77
tests/driver_dfplayer tests/driver_dht tests/driver_ds18 tests/driver_ds75lx tests/driver_dfplayer tests/driver_dht tests/driver_ds18 tests/driver_ds75lx
tests/driver_ds1307 tests/driver_ds3231 tests/driver_ds3234 tests/driver_dsp0401 tests/driver_ds1307 tests/driver_ds3231 tests/driver_ds3234 tests/driver_dsp0401
tests/driver_dynamixel tests/driver_edbg_eui tests/driver_f* tests/driver_g* tests/driver_dynamixel tests/driver_edbg_eui tests/driver_f* tests/driver_g*
tests/driver_h* tests/driver_i* tests/driver_j* tests/driver_my9221"} tests/driver_h* tests/driver_i* tests/driver_j* tests/driver_my9221
tests/driver_o* tests/driver_p* tests/driver_q* tests/driver_r*"}
: ${TEST_KCONFIG_native:="examples/hello-world tests/periph_*"} : ${TEST_KCONFIG_native:="examples/hello-world tests/periph_*"}
export RIOT_CI_BUILD=1 export RIOT_CI_BUILD=1

View File

@ -17,6 +17,7 @@ rsource "feetech/Kconfig"
rsource "grove_ledbar/Kconfig" rsource "grove_ledbar/Kconfig"
rsource "motor_driver/Kconfig" rsource "motor_driver/Kconfig"
rsource "my9221/Kconfig" rsource "my9221/Kconfig"
rsource "rgbled/Kconfig"
endmenu # Actuator Device Drivers endmenu # Actuator Device Drivers
menu "Display Device Drivers" menu "Display Device Drivers"
@ -41,6 +42,7 @@ rsource "Kconfig.net"
menu "Peripherals drivers" menu "Peripherals drivers"
rsource "periph_common/Kconfig" rsource "periph_common/Kconfig"
rsource "rtt_rtc/Kconfig"
endmenu # Peripherals drivers endmenu # Peripherals drivers
menu "Sensor Device Drivers" menu "Sensor Device Drivers"
@ -80,6 +82,13 @@ rsource "lpsxxx/Kconfig"
rsource "mag3110/Kconfig" rsource "mag3110/Kconfig"
rsource "mma8x5x/Kconfig" rsource "mma8x5x/Kconfig"
rsource "opt3001/Kconfig" rsource "opt3001/Kconfig"
rsource "pca9633/Kconfig"
rsource "pca9685/Kconfig"
rsource "pcd8544/Kconfig"
rsource "ph_oem/Kconfig"
rsource "pir/Kconfig"
rsource "pulse_counter/Kconfig"
rsource "qmc5883l/Kconfig"
rsource "sps30/Kconfig" rsource "sps30/Kconfig"
rsource "tcs37727/Kconfig" rsource "tcs37727/Kconfig"
rsource "tmp00x/Kconfig" rsource "tmp00x/Kconfig"

View File

@ -1,9 +1,18 @@
# Copyright (c) 2020 Freie Universitaet Berlin # Copyright (c) 2020 Freie Universitaet Berlin
# 2020 HAW Hamburg
# #
# This file is subject to the terms and conditions of the GNU Lesser # 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 # General Public License v2.1. See the file LICENSE in the top level
# directory for more details. # directory for more details.
# #
config MODULE_OPT3001
bool "OPT3001 Ambient Light Sensor"
depends on HAS_PERIPH_I2C
depends on TEST_KCONFIG
select MODULE_PERIPH_I2C
select MODULE_XTIMER
menuconfig KCONFIG_USEMODULE_OPT3001 menuconfig KCONFIG_USEMODULE_OPT3001
bool "Configure OPT3001 driver" bool "Configure OPT3001 driver"
depends on USEMODULE_OPT3001 depends on USEMODULE_OPT3001

12
drivers/pca9633/Kconfig Normal file
View File

@ -0,0 +1,12 @@
# 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.
#
config MODULE_PCA9633
bool "PCA9633 I2C PWM controller"
depends on HAS_PERIPH_I2C
depends on TEST_KCONFIG
select MODULE_PERIPH_I2C

16
drivers/pca9685/Kconfig Normal file
View File

@ -0,0 +1,16 @@
# 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.
#
config MODULE_PCA9685
bool "PCA9685 I2C PWM controller"
depends on !HAS_CPU_EFM32 # efm32 CPU doesn't support PWM_RIGHT
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_I2C
depends on TEST_KCONFIG
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_I2C
select MODULE_XTIMER

15
drivers/pcd8544/Kconfig Normal file
View File

@ -0,0 +1,15 @@
# 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.
#
config MODULE_PCD8544
bool "PCD8544 LCD driver"
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_SPI
depends on TEST_KCONFIG
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_SPI
select MODULE_XTIMER

17
drivers/ph_oem/Kconfig Normal file
View File

@ -0,0 +1,17 @@
# 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.
#
config MODULE_PH_OEM
bool "Atlas Scientific pH OEM sensor"
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_GPIO_IRQ
depends on HAS_PERIPH_I2C
depends on TEST_KCONFIG
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_GPIO_IRQ
select MODULE_PERIPH_I2C
select MODULE_XTIMER

15
drivers/pir/Kconfig Normal file
View File

@ -0,0 +1,15 @@
# 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.
#
config MODULE_PIR
bool "PIR Motion Sensor"
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_GPIO_IRQ
depends on TEST_KCONFIG
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_GPIO_IRQ
select MODULE_XTIMER

View File

@ -1,9 +1,36 @@
# Copyright (c) 2020 Freie Universitaet Berlin # Copyright (c) 2020 Freie Universitaet Berlin
# 2021 HAW Hamburg
# #
# This file is subject to the terms and conditions of the GNU Lesser # 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 # General Public License v2.1. See the file LICENSE in the top level
# directory for more details. # directory for more details.
# #
if TEST_KCONFIG && HAS_PERIPH_GPIO && HAS_PERIPH_GPIO_IRQ
menu "PN532 NFC reader"
config MODULE_PN532_I2C
bool "PN532 with I2C support"
depends on HAS_PERIPH_I2C
select MODULE_PERIPH_I2C
select MODULE_PN532
config MODULE_PN532_SPI
bool "PN532 with SPI support"
depends on HAS_PERIPH_SPI
select MODULE_PERIPH_SPI
select MODULE_PN532
config MODULE_PN532
bool
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_GPIO_IRQ
endmenu # PN532 NFC reader
endif # TEST_KCONFIG && HAS_PERIPH_GPIO && HAS_PERIPH_GPIO_IRQ
menuconfig KCONFIG_USEMODULE_PN532 menuconfig KCONFIG_USEMODULE_PN532
bool "Configure PN532 driver" bool "Configure PN532 driver"
depends on USEMODULE_PN532 depends on USEMODULE_PN532

View File

@ -0,0 +1,15 @@
# 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.
#
config MODULE_PULSE_COUNTER
bool "Pulse counter"
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_GPIO_IRQ
depends on TEST_KCONFIG
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_GPIO_IRQ
select MODULE_XTIMER

20
drivers/qmc5883l/Kconfig Normal file
View File

@ -0,0 +1,20 @@
# 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_QMC5883L
bool "QMC5883L 3-Axis Digital Magnetic sensor"
depends on HAS_PERIPH_I2C
depends on TEST_KCONFIG
select MODULE_PERIPH_I2C
config MODULE_QMC5883L_INT
bool "Interrupt support"
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_GPIO_IRQ
depends on MODULE_QMC5883L
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_GPIO_IRQ

11
drivers/rgbled/Kconfig Normal file
View File

@ -0,0 +1,11 @@
# 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.
#
config MODULE_RGBLED
bool "RGB-LED driver"
depends on TEST_KCONFIG
select MODULE_COLOR

View File

@ -4,6 +4,36 @@
# General Public License v2.1. See the file LICENSE in the top level # General Public License v2.1. See the file LICENSE in the top level
# directory for more details. # directory for more details.
# #
if TEST_KCONFIG
choice
bool "RN2XX3 LoRa module"
optional
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_UART
config MODULE_RN2483
bool "RN2483"
select MODULE_RN2XX3
config MODULE_RN2903
bool "RN2903"
select MODULE_RN2XX3
endchoice
config MODULE_RN2XX3
bool
depends on HAS_PERIPH_GPIO
depends on HAS_PERIPH_UART
select MODULE_PERIPH_GPIO
select MODULE_PERIPH_UART
select MODULE_FMT
select MODULE_XTIMER
endif # TEST_KCONFIG
menuconfig KCONFIG_USEMODULE_RN2XX3 menuconfig KCONFIG_USEMODULE_RN2XX3
bool "Configure RN2XX3 driver" bool "Configure RN2XX3 driver"
depends on USEMODULE_RN2XX3 depends on USEMODULE_RN2XX3

15
drivers/rtt_rtc/Kconfig Normal file
View File

@ -0,0 +1,15 @@
# 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.
#
config MODULE_RTT_RTC
bool "RTC-based RTT"
depends on HAS_PERIPH_RTT
depends on TEST_KCONFIG
select MODULE_PERIPH_RTT
select HAS_PERIPH_RTC # provides RTC
help
Basic RTC implementation based on a RTT.

View File

@ -0,0 +1,4 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_OPT3001=y
CONFIG_MODULE_XTIMER=y

View File

@ -0,0 +1,5 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_PCA9633=y
CONFIG_MODULE_XTIMER=y
CONFIG_MODULE_SHELL=y

View File

@ -0,0 +1,4 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_PCA9685=y
CONFIG_MODULE_SHELL=y

View File

@ -0,0 +1,4 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_PCD8544=y
CONFIG_MODULE_SHELL=y

View File

@ -0,0 +1,5 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_PH_OEM=y
CONFIG_MODULE_EVENT=y
CONFIG_MODULE_EVENT_CALLBACK=y

View File

@ -0,0 +1,3 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_PIR=y

View File

@ -0,0 +1,8 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
# select if you want to build the SPI or the I2C version of the driver
CONFIG_MODULE_PN532_I2C=y
# CONFIG_MODULE_PN532_SPI=y
CONFIG_MODULE_XTIMER=y

View File

@ -0,0 +1,3 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_PULSE_COUNTER=y

View File

@ -0,0 +1,9 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_QMC5883L=y
# enable gpio interrupt support
CONFIG_MODULE_QMC5883L_INT=y
CONFIG_MODULE_CORE_THREAD_FLAGS=y
CONFIG_MODULE_XTIMER=y

View File

@ -0,0 +1,5 @@
# this file enables modules defined in Kconfig. Do not use this file for
# application configuration. This is only needed during migration.
CONFIG_MODULE_RN2483=y
CONFIG_MODULE_SHELL=y
CONFIG_MODULE_SHELL_COMMANDS=y