summaryrefslogtreecommitdiffstats
path: root/include/android
diff options
context:
space:
mode:
authorEtienne Le Grand <etn@google.com>2014-05-27 18:14:51 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-05-27 18:14:51 +0000
commit03b1a9db9d8edc2ee15062204b19c0fc340e5b69 (patch)
tree445b29f2d477a17619b438abe471cc4bd05ad92a /include/android
parent72c524dd8cd91b4899e5e180764ffcf410e094da (diff)
parentb3a65bb0c2d2f6e660510efe0d93b3d26b0b2bf9 (diff)
downloadframeworks_native-03b1a9db9d8edc2ee15062204b19c0fc340e5b69.zip
frameworks_native-03b1a9db9d8edc2ee15062204b19c0fc340e5b69.tar.gz
frameworks_native-03b1a9db9d8edc2ee15062204b19c0fc340e5b69.tar.bz2
am b3a65bb0: am 9dcd38ad: Merge "Add heart rate to ASensorEvent" into klp-modular-dev
* commit 'b3a65bb0c2d2f6e660510efe0d93b3d26b0b2bf9': Add heart rate to ASensorEvent
Diffstat (limited to 'include/android')
-rw-r--r--include/android/sensor.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/android/sensor.h b/include/android/sensor.h
index 64bc9b5..878f8ff 100644
--- a/include/android/sensor.h
+++ b/include/android/sensor.h
@@ -66,6 +66,7 @@ enum {
* Sensor accuracy measure
*/
enum {
+ ASENSOR_STATUS_NO_CONTACT = -1,
ASENSOR_STATUS_UNRELIABLE = 0,
ASENSOR_STATUS_ACCURACY_LOW = 1,
ASENSOR_STATUS_ACCURACY_MEDIUM = 2,
@@ -130,6 +131,11 @@ typedef struct AUncalibratedEvent {
};
} AUncalibratedEvent;
+typedef struct AHeartRateEvent {
+ float bpm;
+ int8_t status;
+} AHeartRateEvent;
+
/* NOTE: Must match hardware/sensors.h */
typedef struct ASensorEvent {
int32_t version; /* sizeof(struct ASensorEvent) */
@@ -151,6 +157,7 @@ typedef struct ASensorEvent {
AUncalibratedEvent uncalibrated_gyro;
AUncalibratedEvent uncalibrated_magnetic;
AMetaDataEvent meta_data;
+ AHeartRateEvent heart_rate;
};
union {
uint64_t data[8];