From: Dan Murphy <dmurphy@ti.com>
To: <linux-iio@vger.kernel.org>
Cc: <jic23@kernel.org>, Dan Murphy <dmurphy@ti.com>
Subject: [PATCH 1/3] iio: heart_monitors: Add support for heart rate monitors
Date: Wed, 22 Apr 2015 11:32:09 -0500 [thread overview]
Message-ID: <1429720331-1900-2-git-send-email-dmurphy@ti.com> (raw)
In-Reply-To: <1429720331-1900-1-git-send-email-dmurphy@ti.com>
Add a type for heart rate monitors
Add the modifier name in beats per minute.
Signed-off-by: Dan Murphy <dmurphy@ti.com>
---
drivers/iio/industrialio-core.c | 1 +
include/uapi/linux/iio/types.h | 1 +
tools/iio/iio_event_monitor.c | 2 ++
3 files changed, 4 insertions(+)
diff --git a/drivers/iio/industrialio-core.c b/drivers/iio/industrialio-core.c
index 4df97f6..b7b3817 100644
--- a/drivers/iio/industrialio-core.c
+++ b/drivers/iio/industrialio-core.c
@@ -75,6 +75,7 @@ static const char * const iio_chan_type_name_spec[] = {
[IIO_ENERGY] = "energy",
[IIO_DISTANCE] = "distance",
[IIO_VELOCITY] = "velocity",
+ [IIO_HEARTRATE] = "heartrate",
};
static const char * const iio_modifier_names[] = {
diff --git a/include/uapi/linux/iio/types.h b/include/uapi/linux/iio/types.h
index 5c46019..b5e8c2f 100644
--- a/include/uapi/linux/iio/types.h
+++ b/include/uapi/linux/iio/types.h
@@ -35,6 +35,7 @@ enum iio_chan_type {
IIO_ENERGY,
IIO_DISTANCE,
IIO_VELOCITY,
+ IIO_HEARTRATE,
};
enum iio_modifier {
diff --git a/tools/iio/iio_event_monitor.c b/tools/iio/iio_event_monitor.c
index 427c271..b2cc544 100644
--- a/tools/iio/iio_event_monitor.c
+++ b/tools/iio/iio_event_monitor.c
@@ -51,6 +51,7 @@ static const char * const iio_chan_type_name_spec[] = {
[IIO_HUMIDITYRELATIVE] = "humidityrelative",
[IIO_ACTIVITY] = "activity",
[IIO_STEPS] = "steps",
+ [IIO_HEARTRATE] = "heartrate",
};
static const char * const iio_ev_type_text[] = {
@@ -130,6 +131,7 @@ static bool event_is_known(struct iio_event_data *event)
case IIO_HUMIDITYRELATIVE:
case IIO_ACTIVITY:
case IIO_STEPS:
+ case IIO_HEARTRATE:
break;
default:
return false;
--
1.9.1
next prev parent reply other threads:[~2015-04-22 16:32 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-22 16:32 Adding Heart Monitors to IIO take 2 Dan Murphy
2015-04-22 16:32 ` Dan Murphy [this message]
2015-04-26 17:29 ` [PATCH 1/3] iio: heart_monitors: Add support for heart rate monitors Jonathan Cameron
2015-04-27 14:35 ` Dan Murphy
2015-04-22 16:32 ` [PATCH 2/3] iio: bindings: Add TI afe4403 heart monitor documentation Dan Murphy
2015-04-26 17:30 ` Jonathan Cameron
2015-04-27 14:49 ` Dan Murphy
2015-04-22 16:32 ` [PATCH 3/3] iio: heart_monitor: Add TI afe4403 heart monitor Dan Murphy
2015-04-26 18:38 ` Jonathan Cameron
2015-04-29 12:27 ` Dan Murphy
2015-05-07 22:51 ` Jonathan Cameron
2015-05-08 19:56 ` Dan Murphy
2015-04-29 13:52 ` Dan Murphy
2015-05-07 22:52 ` Jonathan Cameron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1429720331-1900-2-git-send-email-dmurphy@ti.com \
--to=dmurphy@ti.com \
--cc=jic23@kernel.org \
--cc=linux-iio@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox