summaryrefslogtreecommitdiffstats
path: root/drivers/iio/industrialio-event.c
diff options
context:
space:
mode:
authorIrina Tirdea2015-01-11 20:10:11 +0100
committerJonathan Cameron2015-01-27 19:49:55 +0100
commit27be84236d75c13a83c45d850390f40b58401d97 (patch)
treead80b4543ccd8e386dcc23662375330a55192990 /drivers/iio/industrialio-event.c
parentiio: core: Introduce IIO_CHAN_INFO_CALIBWEIGHT (diff)
downloadkernel-qcow2-linux-27be84236d75c13a83c45d850390f40b58401d97.tar.gz
kernel-qcow2-linux-27be84236d75c13a83c45d850390f40b58401d97.tar.xz
kernel-qcow2-linux-27be84236d75c13a83c45d850390f40b58401d97.zip
iio: core: Introduce CHANGE event type
A step detector will generate an interrupt each time N step are detected. A device that has such pedometer functionality is Freescale's MMA9553L: http://www.freescale.com/files/sensors/doc/ref_manual/MMA9553LSWRM.pdf. Introduce IIO_EV_TYPE_CHANGE event type for events that are generated when the channel passes a threshold on the absolute change in value. Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/industrialio-event.c')
-rw-r--r--drivers/iio/industrialio-event.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/iio/industrialio-event.c b/drivers/iio/industrialio-event.c
index 78cf115dc0d4..b33ce55eb695 100644
--- a/drivers/iio/industrialio-event.c
+++ b/drivers/iio/industrialio-event.c
@@ -198,6 +198,7 @@ static const char * const iio_ev_type_text[] = {
[IIO_EV_TYPE_THRESH_ADAPTIVE] = "thresh_adaptive",
[IIO_EV_TYPE_MAG_ADAPTIVE] = "mag_adaptive",
[IIO_EV_TYPE_INSTANCE] = "instance",
+ [IIO_EV_TYPE_CHANGE] = "change",
};
static const char * const iio_ev_dir_text[] = {