Ubuntu Platform API  3.0.0
A library helping with tight integration into the Ubuntu platform
gyroscope.h File Reference
#include <ubuntu/visibility.h>
#include <stdint.h>
+ Include dependency graph for gyroscope.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef void UASGyroscopeEvent
 Opaque type describing a gyroscope reading. More...
 

Functions

UBUNTU_DLL_PUBLIC uint64_t uas_gyroscope_event_get_timestamp (UASGyroscopeEvent *event)
 Query the timestamp of the sensor reading. More...
 
UBUNTU_DLL_PUBLIC UStatus uas_gyroscope_event_get_rate_of_rotation_around_x (UASGyroscopeEvent *event, float *value)
 Query the rate of rotation around the x-axis. More...
 
UBUNTU_DLL_PUBLIC UStatus uas_gyroscope_event_get_rate_of_rotation_around_y (UASGyroscopeEvent *event, float *value)
 Query the rate of rotation around the y-axis. More...
 
UBUNTU_DLL_PUBLIC UStatus uas_gyroscope_event_get_rate_of_rotation_around_z (UASGyroscopeEvent *event, float *value)
 Query the rate of rotation around the z-axis. More...
 

Typedef Documentation

◆ UASGyroscopeEvent

typedef void UASGyroscopeEvent

Opaque type describing a gyroscope reading.

Definition at line 34 of file gyroscope.h.

Function Documentation

◆ uas_gyroscope_event_get_rate_of_rotation_around_x()

UBUNTU_DLL_PUBLIC UStatus uas_gyroscope_event_get_rate_of_rotation_around_x ( UASGyroscopeEvent event,
float *  value 
)

Query the rate of rotation around the x-axis.

Returns
The rate of rotation around the x-axis in radians per second. Positive values indicate counter-clockwise rotation
Parameters
[in]eventThe reading to be queried.

◆ uas_gyroscope_event_get_rate_of_rotation_around_y()

UBUNTU_DLL_PUBLIC UStatus uas_gyroscope_event_get_rate_of_rotation_around_y ( UASGyroscopeEvent event,
float *  value 
)

Query the rate of rotation around the y-axis.

Returns
The rate of rotation around the y-axis in radians per second. Positive values indicate counter-clockwise rotation
Parameters
[in]eventThe reading to be queried.

◆ uas_gyroscope_event_get_rate_of_rotation_around_z()

UBUNTU_DLL_PUBLIC UStatus uas_gyroscope_event_get_rate_of_rotation_around_z ( UASGyroscopeEvent event,
float *  value 
)

Query the rate of rotation around the z-axis.

Returns
The rate of rotation around the z-axis in radians per second. Positive values indicate counter-clockwise rotation
Parameters
[in]eventThe reading to be queried.

◆ uas_gyroscope_event_get_timestamp()

UBUNTU_DLL_PUBLIC uint64_t uas_gyroscope_event_get_timestamp ( UASGyroscopeEvent event)

Query the timestamp of the sensor reading.

Returns
The timestamp of the sensor reading in [µs], timebase: monotonic clock.
Parameters
[in]eventThe reading to be queried.