iio: core: Introduce IIO_CHAN_INFO_CALIBEMISSIVITY
authorVianney le Clément de Saint-Marcq <vianney.leclement@essensium.com>
Mon, 30 Mar 2015 08:34:58 +0000 (10:34 +0200)
committerJonathan Cameron <jic23@kernel.org>
Thu, 9 Apr 2015 14:03:05 +0000 (15:03 +0100)
Contact-less IR temperature sensors measure the temperature of an object
by using its thermal radiation.  Surfaces with different emissivity
ratios emit different amounts of energy at the same temperature.

IIO_CHAN_INFO_CALIBEMISSIVITY allows the user to inform the sensor of the
emissivity of the object in front of it, in order to effectively measure
its temperature.

A device providing such setting is Melexis's MLX90614:
http://melexis.com/Assets/IR-sensor-thermometer-MLX90614-Datasheet-5152.aspx.

Signed-off-by: Vianney le Clément de Saint-Marcq <vianney.leclement@essensium.com>
Cc: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Documentation/ABI/testing/sysfs-bus-iio
drivers/iio/industrialio-core.c
include/linux/iio/iio.h

index 3befcb19f41415393e56a6ef496675ab31c4bc2a..866b4ec4aab698ec0ba4bf4e287985d34403817e 100644 (file)
@@ -1364,3 +1364,14 @@ Description:
                hwfifo_watermak_min but not equal to any of the values in this
                list, the driver will chose an appropriate value for the
                hardware fifo watermark level.
+
+What:          /sys/bus/iio/devices/iio:deviceX/in_temp_calibemissivity
+What:          /sys/bus/iio/devices/iio:deviceX/in_tempX_calibemissivity
+What:          /sys/bus/iio/devices/iio:deviceX/in_temp_object_calibemissivity
+What:          /sys/bus/iio/devices/iio:deviceX/in_tempX_object_calibemissivity
+KernelVersion: 4.1
+Contact:       linux-iio@vger.kernel.org
+Description:
+               The emissivity ratio of the surface in the field of view of the
+               contactless temperature sensor.  Emissivity varies from 0 to 1,
+               with 1 being the emissivity of a black body.
index 4df97f650e448e80053e037fed6d5e208493c687..7c98bc1504e60c107f5783cb6161b69fd1bd9d40 100644 (file)
@@ -128,6 +128,7 @@ static const char * const iio_chan_info_postfix[] = {
        [IIO_CHAN_INFO_CALIBWEIGHT] = "calibweight",
        [IIO_CHAN_INFO_DEBOUNCE_COUNT] = "debounce_count",
        [IIO_CHAN_INFO_DEBOUNCE_TIME] = "debounce_time",
+       [IIO_CHAN_INFO_CALIBEMISSIVITY] = "calibemissivity",
 };
 
 /**
index d86b753e9b30166e0c370845145ac59d2b863a32..b1e46ae89aa7daa91030f8262ecb60a9bbdbb3c1 100644 (file)
@@ -43,6 +43,7 @@ enum iio_chan_info_enum {
        IIO_CHAN_INFO_CALIBWEIGHT,
        IIO_CHAN_INFO_DEBOUNCE_COUNT,
        IIO_CHAN_INFO_DEBOUNCE_TIME,
+       IIO_CHAN_INFO_CALIBEMISSIVITY,
 };
 
 enum iio_shared_by {