summaryrefslogtreecommitdiff
path: root/drivers/iio/chemical/Kconfig
diff options
context:
space:
mode:
authorNarcisa Ana Maria Vasile <narcisaanamaria12@gmail.com>2017-07-17 22:28:03 +0300
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2017-07-22 21:16:37 +0100
commita94c24a712acb26f3712ec7bf56e9b13e40a2a74 (patch)
tree48839df2f92b42866d4094e593bba4a2ce379646 /drivers/iio/chemical/Kconfig
parent7c6d5c7ee883a3600e6d4f2cbac585172d9a00c2 (diff)
iio: chemical: ccs811: Add support for AMS CCS811 VOC sensor
Add support for CCS811 VOC sensor. This patch adds support for reading current and voltage across the sensor and TVOC and equivalent CO2 values. Scale and offset values have been computed according to datasheet: - For current: raw value is in microamps => 0.001 scale to convert to milliamps - For voltage: 1.65V = 1023, therefore 1650mV = 1023 => 1650.0/1023 = 1.612903 scale to convert to millivolts - For eCO2: raw value range is from 400ppm to 8192ppm. => (val - 400) * (100 - 0) / (8192 - 400) + 0 = (val - 400) * 0.01283367 => offset: -400, scale = 0.012834 to get a percentage value -For TVOC: raw value range is from 0ppb to 1187ppb. => (val - 0) * 100 / (1187 - 0) + 0 = val * 0.0842459 => scale = 0.084246 for getting a percentage value Cc: Daniel Baluta <daniel.baluta@gmail.com> Cc: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Narcisa Ana Maria Vasile <narcisaanamaria12@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/chemical/Kconfig')
-rw-r--r--drivers/iio/chemical/Kconfig7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/iio/chemical/Kconfig b/drivers/iio/chemical/Kconfig
index cea7f9857a1f..4d799b5cceac 100644
--- a/drivers/iio/chemical/Kconfig
+++ b/drivers/iio/chemical/Kconfig
@@ -21,6 +21,13 @@ config ATLAS_PH_SENSOR
To compile this driver as module, choose M here: the
module will be called atlas-ph-sensor.
+config CCS811
+ tristate "AMS CCS811 VOC sensor"
+ depends on I2C
+ help
+ Say Y here to build I2C interface support for the AMS
+ CCS811 VOC (Volatile Organic Compounds) sensor
+
config IAQCORE
tristate "AMS iAQ-Core VOC sensors"
depends on I2C