drivers/lpsxxx: fix variant selection
This commit is contained in:
parent
cfdd941f9b
commit
2dab9eeb32
@ -6,38 +6,42 @@
|
|||||||
# directory for more details.
|
# directory for more details.
|
||||||
#
|
#
|
||||||
|
|
||||||
choice
|
menuconfig MODULE_LPSXXX
|
||||||
bool "LPSXXX Pressure Sensors"
|
bool
|
||||||
optional
|
prompt "LPSXXX Pressure Sensors" if !(MODULE_SAUL_DEFAULT && HAVE_LPSXXX)
|
||||||
depends on HAS_PERIPH_I2C
|
depends on HAS_PERIPH_I2C
|
||||||
depends on TEST_KCONFIG
|
depends on TEST_KCONFIG
|
||||||
|
select MODULE_PERIPH_I2C
|
||||||
|
help
|
||||||
|
Device driver for the LPSXXX pressure sensor family
|
||||||
|
(LPS331AP/LPS25HB/LPS22HB/LPS22HH). Select a model.
|
||||||
|
|
||||||
|
if MODULE_LPSXXX
|
||||||
|
|
||||||
|
choice LPSXXX_VARIANT
|
||||||
|
bool "Model"
|
||||||
|
default MODULE_LPS331AP if HAVE_LPS331AP
|
||||||
|
default MODULE_LPS22HB if HAVE_LPS22HB
|
||||||
|
default MODULE_LPS22HH if HAVE_LPS22HH
|
||||||
|
default MODULE_LPS25HB if HAVE_LPS25HB
|
||||||
help
|
help
|
||||||
Device driver for the LPSXXX pressure sensor family
|
Device driver for the LPSXXX pressure sensor family
|
||||||
(LPS331AP/LPS25HB/LPS22HB/LPS22HH). Select a model.
|
(LPS331AP/LPS25HB/LPS22HB/LPS22HH). Select a model.
|
||||||
|
|
||||||
config MODULE_LPS331AP
|
config MODULE_LPS331AP
|
||||||
bool "LPS331AP"
|
bool "LPS331AP"
|
||||||
select MODULE_LPSXXX
|
|
||||||
|
|
||||||
config MODULE_LPS22HB
|
config MODULE_LPS22HB
|
||||||
bool "LPS22HB"
|
bool "LPS22HB"
|
||||||
select MODULE_LPSXXX
|
|
||||||
|
|
||||||
config MODULE_LPS22HH
|
config MODULE_LPS22HH
|
||||||
bool "LPS22HH"
|
bool "LPS22HH"
|
||||||
select MODULE_LPSXXX
|
|
||||||
|
|
||||||
config MODULE_LPS25HB
|
config MODULE_LPS25HB
|
||||||
bool "LPS25HB"
|
bool "LPS25HB"
|
||||||
select MODULE_LPSXXX
|
|
||||||
|
|
||||||
endchoice
|
endchoice
|
||||||
|
|
||||||
config MODULE_LPSXXX
|
endif # MODULE_LPSXXX
|
||||||
bool
|
|
||||||
depends on HAS_PERIPH_I2C
|
|
||||||
depends on TEST_KCONFIG
|
|
||||||
select MODULE_PERIPH_I2C
|
|
||||||
|
|
||||||
menuconfig KCONFIG_USEMODULE_LPSXXX
|
menuconfig KCONFIG_USEMODULE_LPSXXX
|
||||||
bool "Configure LPSXXX driver"
|
bool "Configure LPSXXX driver"
|
||||||
@ -58,3 +62,31 @@ config LPSXXX_DEFAULT_ADDRESS
|
|||||||
datasheet.
|
datasheet.
|
||||||
|
|
||||||
endif # KCONFIG_USEMODULE_LPSXXX
|
endif # KCONFIG_USEMODULE_LPSXXX
|
||||||
|
|
||||||
|
config HAVE_LPSXXX
|
||||||
|
bool
|
||||||
|
select MODULE_LPSXXX if MODULE_SAUL_DEFAULT
|
||||||
|
|
||||||
|
config HAVE_LPS331AP
|
||||||
|
bool
|
||||||
|
select HAVE_LPSXXX
|
||||||
|
help
|
||||||
|
Indicates that a LPS331AP sensor is present.
|
||||||
|
|
||||||
|
config HAVE_LPS22HB
|
||||||
|
bool
|
||||||
|
select HAVE_LPSXXX
|
||||||
|
help
|
||||||
|
Indicates that a LPS22HB sensor is present.
|
||||||
|
|
||||||
|
config HAVE_LPS22HH
|
||||||
|
bool
|
||||||
|
select HAVE_LPSXXX
|
||||||
|
help
|
||||||
|
Indicates that a LPS22HH sensor is present.
|
||||||
|
|
||||||
|
config HAVE_LPS25HB
|
||||||
|
bool
|
||||||
|
select HAVE_LPSXXX
|
||||||
|
help
|
||||||
|
Indicates that a LPS25HB sensor is present.
|
||||||
|
|||||||
@ -1,4 +1,5 @@
|
|||||||
# this file enables modules defined in Kconfig. Do not use this file for
|
# this file enables modules defined in Kconfig. Do not use this file for
|
||||||
# application configuration. This is only needed during migration.
|
# application configuration. This is only needed during migration.
|
||||||
CONFIG_MODULE_LPS331AP=y
|
CONFIG_MODULE_LPS331AP=y
|
||||||
|
CONFIG_MODULE_LPSXXX=y
|
||||||
CONFIG_MODULE_XTIMER=y
|
CONFIG_MODULE_XTIMER=y
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user