only orientation and geomagnetic field sensors support the "status" field
enforce this in the HAL API. Change-Id: I54d2fde84a852482a96140f8f1945cc6044e628a
This commit is contained in:
parent
1144bea332
commit
fbe985ca9c
1 changed files with 18 additions and 2 deletions
|
@ -650,6 +650,22 @@ enum {
|
|||
/**
|
||||
* sensor event data
|
||||
*/
|
||||
typedef struct {
|
||||
union {
|
||||
float v[3];
|
||||
struct {
|
||||
float x;
|
||||
float y;
|
||||
float z;
|
||||
};
|
||||
struct {
|
||||
float azimuth;
|
||||
float pitch;
|
||||
float roll;
|
||||
};
|
||||
};
|
||||
} sensors_data_t;
|
||||
|
||||
typedef struct {
|
||||
union {
|
||||
float v[3];
|
||||
|
@ -692,7 +708,7 @@ typedef struct sensors_event_t {
|
|||
float data[16];
|
||||
|
||||
/* acceleration values are in meter per second per second (m/s^2) */
|
||||
sensors_vec_t acceleration;
|
||||
sensors_data_t acceleration;
|
||||
|
||||
/* magnetic vector values are in micro-Tesla (uT) */
|
||||
sensors_vec_t magnetic;
|
||||
|
@ -701,7 +717,7 @@ typedef struct sensors_event_t {
|
|||
sensors_vec_t orientation;
|
||||
|
||||
/* gyroscope values are in rad/s */
|
||||
sensors_vec_t gyro;
|
||||
sensors_data_t gyro;
|
||||
|
||||
/* temperature is in degrees centigrade (Celsius) */
|
||||
float temperature;
|
||||
|
|
Loading…
Reference in a new issue