Adafruit Library
Public Attributes | List of all members
sensors_event_t Struct Reference

#include <Adafruit_CPlay_Sensor.h>

Public Attributes

int32_t version
 must be sizeof(struct sensors_event_t) */
 
int32_t sensor_id
 unique sensor identifier */
 
int32_t type
 sensor type */
 
int32_t reserved0
 reserved */
 
int32_t timestamp
 time is in milliseconds */
 
union {
   float   data [4]
 array for floating point general data
 
   sensors_vec_t   acceleration
 acceleration values are in meter per second per second (m/s^2) */
 
   sensors_vec_t   magnetic
 magnetic vector values are in micro-Tesla (uT) */
 
   sensors_vec_t   orientation
 orientation values are in degrees */
 
   sensors_vec_t   gyro
 gyroscope values are in rad/s */
 
   float   temperature
 temperature is in degrees centigrade (Celsius) */
 
   float   distance
 distance in centimeters */
 
   float   light
 light in SI lux units */
 
   float   pressure
 pressure in hectopascal (hPa) */
 
   float   relative_humidity
 relative humidity in percent */
 
   float   current
 current in milliamps (mA) */
 
   float   voltage
 voltage in volts (V) */
 
   sensors_color_t   color
 color in RGB component values */
 
}; 
 union of sensor event data
 

Detailed Description

struct sensor_event_s is used to provide a single sensor event in a common format.


The documentation for this struct was generated from the following file: