mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
drivers/mhz19: Update kconfig model
This commit is contained in:
parent
0ec4525733
commit
551d25a296
@ -5,30 +5,41 @@
|
||||
# directory for more details.
|
||||
#
|
||||
|
||||
if TEST_KCONFIG
|
||||
|
||||
menu "MH-Z19 CO2 sensor"
|
||||
depends on HAS_PERIPH_GPIO || HAS_PERIPH_UART
|
||||
|
||||
config MODULE_MHZ19_UART
|
||||
bool "MH-Z19 over UART"
|
||||
depends on HAS_PERIPH_UART
|
||||
select MODULE_PERIPH_UART
|
||||
select MODULE_MHZ19
|
||||
menuconfig MODULE_MHZ19
|
||||
bool
|
||||
prompt "MH-Z19 CO2 sensor" if !(MODULE_SAUL_DEFAULT && HAVE_MHZ19)
|
||||
default (MODULE_SAUL_DEFAULT && HAVE_MHZ19)
|
||||
depends on TEST_KCONFIG
|
||||
select MODULE_ZTIMER
|
||||
select MODULE_ZTIMER_MSEC
|
||||
|
||||
if MODULE_MHZ19
|
||||
|
||||
config MODULE_MHZ19_PWM
|
||||
bool "MH-Z19 over PWM"
|
||||
default HAVE_MHZ19_PWM
|
||||
depends on HAS_PERIPH_GPIO
|
||||
select MODULE_PERIPH_GPIO
|
||||
select MODULE_MHZ19
|
||||
select MODULE_ZTIMER
|
||||
select MODULE_ZTIMER_MSEC
|
||||
|
||||
config MODULE_MHZ19
|
||||
config MODULE_MHZ19_UART
|
||||
bool "MH-Z19 over UART"
|
||||
default HAVE_MHZ19_UART
|
||||
depends on HAS_PERIPH_UART
|
||||
select MODULE_PERIPH_UART
|
||||
|
||||
endif # MODULE_MHZ19
|
||||
|
||||
config HAVE_MHZ19
|
||||
bool
|
||||
help
|
||||
Indicates that a MH-Z19 CO2 sensor is present.
|
||||
|
||||
endmenu # MH-Z19 CO2 sensor
|
||||
config HAVE_MHZ19_PWM
|
||||
bool
|
||||
help
|
||||
Indicates that a MH-Z19 CO2 sensor is present on the pwm.
|
||||
|
||||
endif # TEST_KCONFIG
|
||||
config HAVE_MHZ19_UART
|
||||
bool
|
||||
help
|
||||
Indicates that a MH-Z19 CO2 sensor is present on the uart.
|
||||
|
@ -3,6 +3,7 @@
|
||||
CONFIG_MODULE_ZTIMER=y
|
||||
CONFIG_MODULE_ZTIMER_MSEC=y
|
||||
|
||||
CONFIG_MODULE_MHZ19=y
|
||||
# Use UART mode by default
|
||||
CONFIG_MODULE_MHZ19_UART=y
|
||||
#CONFIG_MODULE_MHZ19_PWM=y
|
||||
|
Loading…
Reference in New Issue
Block a user