zephyr/drivers/sensor/ti/ina23x/Kconfig
Tomáš Juřena b4dcdaaeab drivers: sensor: ti: ina230: Fix dts warning if INA230_TRIGGER enabled
Updates the Kconfig condition to support trigger functionality for INA236.
This will get rid of `warning: INA230_TRIGGER (defined at
drivers/sensor/ti/ina23x/Kconfig:43) was assigned the value 'y' but got
the value 'n'.` if INA230_TRIGGER is enabled.

Signed-off-by: Tomáš Juřena <jurenatomas@gmail.com>
2024-11-27 08:18:57 +01:00

53 lines
1.4 KiB
Plaintext

# Copyright 2021 The Chromium OS Authors
#
# SPDX-License-Identifier: Apache-2.0
config INA23X
bool "INA23X Current and Power Monitor"
default y
depends on DT_HAS_TI_INA230_ENABLED || DT_HAS_TI_INA236_ENABLED || DT_HAS_TI_INA237_ENABLED
select I2C
help
Enable driver for INA23X Current and Power Monitor.
if INA23X
config INA230
bool "INA230"
default y
depends on DT_HAS_TI_INA230_ENABLED || DT_HAS_TI_INA236_ENABLED
help
Enable driver for INA230/INA231/INA236.
config INA237
bool "INA237"
default y
depends on DT_HAS_TI_INA237_ENABLED
help
Enable driver for INA237.
config INA237_VSHUNT
bool "INA237 VShunt Measurement Enable"
depends on DT_HAS_TI_INA237_ENABLED
help
Enable shunt voltage measurement for INA237.
This is the actual shunt voltage measured which is scaled within the
INA237 based upon the SHUNT_CAL register. This value is useful for
looking at measurement noise or debugging the SHUNT_CAL value.
Note that enabling this option requires an extra I2C read when
SENSOR_CHAN_ALL is selected, so only enable if the shunt voltage
measurement is required.
config INA230_TRIGGER
bool "INA230 trigger mode"
depends on INA230
depends on GPIO
depends on $(dt_compat_any_has_prop,$(DT_COMPAT_TI_INA230),alert-gpios) || $(dt_compat_any_has_prop,$(DT_COMPAT_TI_INA236),alert-gpios)
help
Set to enable trigger mode using gpio interrupt, where
interrupts are configured to line ALERT PIN.
endif # INA23X