GyroscopeSensor

Last Updated On 2021-07-16

Version 1MinSDK 7Tutorial Video

Non-visible component that can measure angular velocity in three dimensions in units of degrees per second.

In order to function, the component must have its Enabled property set to True, and the device must have a gyroscope sensor.


Properties

You can set the below properties in the UI part of the builder.

  • Enabled - it's a boolean value which is set to true by default.

Block Properties

You can set the below blocks properties in the blocks section of the builder.

Available

Indicates whether a gyroscope sensor is available.


Enabled

Enabled property getter method.


XAngularVelocity

The angular velocity around the X axis, in degrees per second.


YAngularVelocity

The angular velocity around the Y axis, in degrees per second.


ZAngularVelocity

The angular velocity around the Z axis, in degrees per second.



Events

You can set the below event blocks in the blocks section of the builder.

GyroscopeChanged

Indicates that the gyroscope sensor data has changed. The timestamp parameter is the time in nanoseconds at which the event occurred.