In "rec/robotino/api2/c/Gyroscope.h" you can find functions for reading Robotino's Gyroscope.
More...
#include "rec/robotino/api2/c/globals.h"
#include "rec/robotino/api2/c/Com.h"
Go to the source code of this file.
In "rec/robotino/api2/c/Gyroscope.h" you can find functions for reading Robotino's Gyroscope.
Use Gyroscope_construct() to create a new Gyroscope object. Associate the Gyroscope object with a com object using Gyroscope_setComId(). Use Gyroscope_value() to read the Gyroscope's state.
#define INVALID_GyroscopeID -1 |
Invalid GyroscopeId is -1
Get the current angle in radians of the Gyroscope.
- Parameters
-
- Returns
- Returns TRUE (1) if the Gyroscope is pressed. Returns FALSE (0) otherwise.
Construct an Gyroscope object
- Returns
- Returns the ID of the newly constructed Gyroscope object.
Destroy the Gyroscope object assigned to id
- Parameters
-
id | The id of the Gyroscope object to be destroyed |
- Returns
- Returns TRUE (1) on success. Returns FALSE (0) if the given GyroscopeId is invalid.
Get the current rate in radians/seconds of the Gyroscope.
- Parameters
-
- Returns
- Returns TRUE (1) if the Gyroscope is pressed. Returns FALSE (0) otherwise.
Associated a Gyroscope object with a communication interface, i.e. binding the Gyroscope to a specific Robotino
- Returns
- Returns TRUE (1) on success. Returns FALSE (0) if the given GyroscopeId or ComId is invalid.