Kallisto Linux API
Library for interacting with Kallisto devices
|
#include <sensor_event_listener.hpp>
Public Member Functions | |
SensorEvent (std::chrono::nanoseconds _timestamp, std::vector< float > _values) | |
~SensorEvent () | |
Data Fields | |
std::chrono::nanoseconds | timestamp |
std::vector< float > | values |
Class that encapsulates a sensor event.
SensorEvent | ( | std::chrono::nanoseconds | _timestamp, |
std::vector< float > | _values | ||
) |
SensorEvent constructor.
~SensorEvent | ( | ) |
SensorEvent destructor.
std::chrono::nanoseconds timestamp |
The time at which the event happened in nanoseconds.
This time is generated by the Kallisto device and synchronized with the wall clock.
Since the transport layer is the Bluetooth Low Energy, there will be delays to the event delivery. A event generated will be delayed by the BLE connection (refer to the Bluetooth specification for details) and by queuing in the device side. Expect delays, in average, of about 100 ms.
std::vector<float> values |
The length and contents of the values vector depends on which KallistoSensor type is being monitored.
Each sensor has different type of values reported:
All values are in SI units (m/s^2)
All values are in micro-Tesla (uT) and measure the ambient magnetic field in the X, Y and Z axis.
All values are in rad/s in the X, Y and Z axis.
Reports a single value between 0 and 100 that represents the state-of-charge. Only changes are reported.
Reports a single value (0 or 1) that represents if the battery is charging. Only changes are reported.
Reports a single value in dBm.