Gyroscope

@CarProtocol
@RequiresCarApi(value = 3)
public final class Gyroscope


Information about car specific gyroscopes available from the car hardware.

Summary

Public constructors

Creates an Gyroscope with the given raw data.

Public methods

boolean
@NonNull CarValue<List<Float>>

Returns the raw gyroscope data from the car sensor.

int
@NonNull String

Public constructors

Gyroscope

Added in 1.1.0
public Gyroscope(@NonNull CarValue<List<Float>> rotations)

Creates an Gyroscope with the given raw data.

Throws
java.lang.NullPointerException

if rotations is null

Public methods

equals

Added in 1.4.0-rc02
public boolean equals(@Nullable Object other)

getRotations

Added in 1.1.0
public @NonNull CarValue<List<Float>> getRotations()

Returns the raw gyroscope data from the car sensor.

Individual values can be Float.Nan if not reported. The array values consist of:

  • [0]: X component of rotation, in rad/s
  • [1]: Y component of rotation, in rad/s
  • [2]: Z component of rotation, in rad/s

hashCode

Added in 1.4.0-rc02
public int hashCode()

toString

Added in 1.4.0-rc02
public @NonNull String toString()