Zephyr API Documentation
3.7.0
A Scalable Open Source RTOS
|
Sensor value data structure types based on common data types. More...
#include <sensing_datatypes.h>
Data Fields | |
struct sensing_sensor_value_header | header |
Header of the sensor value data structure. | |
int8_t | shift |
The shift value for the q31_t v[3] reading. | |
struct { | |
uint32_t timestamp_delta | |
Timestamp delta of the reading. More... | |
union { | |
q31_t v [3] | |
3D vector of the reading represented as an array. More... | |
struct { | |
q31_t x | |
X value of the 3D vector. More... | |
q31_t y | |
Y value of the 3D vector. More... | |
q31_t z | |
Z value of the 3D vector. More... | |
} | |
} | |
} | readings [1] |
Array of readings. | |
Sensor value data structure types based on common data types.
Suitable for common sensors, such as IMU, Light sensors and orientation sensors.
Sensor value data structure for 3-axis sensors. struct sensing_sensor_value_3d_q31 can be used by 3D IMU sensors like: SENSING_SENSOR_TYPE_MOTION_ACCELEROMETER_3D, SENSING_SENSOR_TYPE_MOTION_UNCALIB_ACCELEROMETER_3D, SENSING_SENSOR_TYPE_MOTION_GYROMETER_3D, q31 version
struct sensing_sensor_value_header sensing_sensor_value_3d_q31::header |
Header of the sensor value data structure.
struct { ... } sensing_sensor_value_3d_q31::readings[1] |
Array of readings.
int8_t sensing_sensor_value_3d_q31::shift |
The shift value for the q31_t v[3] reading.
uint32_t sensing_sensor_value_3d_q31::timestamp_delta |
Timestamp delta of the reading.
Unit is micro seconds.
q31_t sensing_sensor_value_3d_q31::v[3] |
3D vector of the reading represented as an array.
For SENSING_SENSOR_TYPE_MOTION_ACCELEROMETER_3D and SENSING_SENSOR_TYPE_MOTION_UNCALIB_ACCELEROMETER_3D, the unit is Gs (gravitational force). For SENSING_SENSOR_TYPE_MOTION_GYROMETER_3D, the unit is degrees.
q31_t sensing_sensor_value_3d_q31::x |
X value of the 3D vector.
q31_t sensing_sensor_value_3d_q31::y |
Y value of the 3D vector.
q31_t sensing_sensor_value_3d_q31::z |
Z value of the 3D vector.