Reference   Language | Libraries | Comparison | Changes

CurieIMU

readGyro()

Description

Reads the raw value of the gyro.

Syntax

CurieIMU.readGyro(int gx, int gy, int gz)

Parameters

gx: a variable in which the gyro's value along x will be stored.
gy: a variable in which the gyro's value along y will be stored.
gz: a variablle in which the gyro's value along z will be stored.

To convert any of the raw values in angular velocity (°/s) use the following formula:
float av = ( avRaw/32768.9)*getGyroRange()
where avRaw is either gx, gy or gz.

See also

Reference Home

Corrections, suggestions, and new documentation should be posted to the Forum.

The text of the Arduino reference is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.

Share