Leveling Estimator2
Estimates leveling of device (roll and pitch angle) by estimating gravity vector using accelerometer measurements only. This estimator does not estimate attitude yaw angle, as either a magnetometer or gyroscope would be needed. When device is placed vertically (pitch values close to 90 degrees), this estimator might become unreliable. If device is expected to be in this orientation, avoid using this estimator and use AccurateLevelingEstimator2 instead.
Constructors
Types
Interface to notify when sensor accuracy changes.
Interface to notify when a new leveling measurement is available.
Properties
an averaging filter for accelerometer samples to obtain sensed gravity component of specific force. (Only used if useAccelerometer is true).
One of the supported accelerometer sensor types. (Only used if useAccelerometer is true).
listener to notify changes in accuracy.
Indicates whether gravity norm must be adjusted to either Earth standard norm, or norm at provided location. If no location is provided, this should only be enabled when device is close to sea level.
true to estimate coordinate transformation, false otherwise. If not needed, it can be disabled to improve performance and decrease cpu load.
true to estimate euler angles, false otherwise. If not needed, it can be disabled to improve performance and decrease cpu load.
listener to notify when a new leveling measurement is available.
Delay of accelerometer or gravity sensor between samples.
Initial offset expressed in nano seconds between first received measurement timestamp and start time expressed in the monotonically increasing system clock obtained by SystemClock.elapsedRealtimeNanos.
indicates whether startOffset will be computed when first measurement is received or not. True indicates that offset is computed, false assumes that offset is null.
true to use accelerometer sensor, false to use system gravity sensor.