Change-Id: Ie034418055ed9b10608e06fd6e35d64bddb73598
This commit is contained in:
Jean-Baptiste Queru
2011-05-18 16:40:03 -07:00

View File

@@ -61,6 +61,7 @@ __BEGIN_DECLS
#define SENSOR_TYPE_GRAVITY 9 #define SENSOR_TYPE_GRAVITY 9
#define SENSOR_TYPE_LINEAR_ACCELERATION 10 #define SENSOR_TYPE_LINEAR_ACCELERATION 10
#define SENSOR_TYPE_ROTATION_VECTOR 11 #define SENSOR_TYPE_ROTATION_VECTOR 11
#define SENSOR_TYPE_RELATIVE_HUMIDITY 12
#define SENSOR_TYPE_AMBIENT_TEMPERATURE 13 #define SENSOR_TYPE_AMBIENT_TEMPERATURE 13
/** /**
@@ -287,6 +288,17 @@ __BEGIN_DECLS
* sensors_event_t.data[2] = z*sin(theta/2) * sensors_event_t.data[2] = z*sin(theta/2)
* sensors_event_t.data[3] = cos(theta/2) * sensors_event_t.data[3] = cos(theta/2)
* *
*
* Relative Humidity
* -----------------
*
* A relative humidity sensor measures relative ambient air humidity and
* returns a value in percent.
*
* Relative humidity sensors report a value only when it changes and each
* time the sensor is enabled. setDelay() is ignored.
*
*
* Ambient Temperature * Ambient Temperature
* ------------------- * -------------------
* *
@@ -361,6 +373,9 @@ typedef struct sensors_event_t {
/* pressure in hectopascal (hPa) */ /* pressure in hectopascal (hPa) */
float pressure; float pressure;
/* relative humidity in percent */
float relative_humidity;
}; };
uint32_t reserved1[4]; uint32_t reserved1[4];
} sensors_event_t; } sensors_event_t;