CalibrationMeasurementGenerator

abstract class CalibrationMeasurementGenerator<I>(val context: Context, val accelerometerSensorType: AccelerometerSensorType = AccelerometerSensorType.ACCELEROMETER_UNCALIBRATED, val accelerometerSensorDelay: SensorDelay = SensorDelay.FASTEST, var accuracyChangedListener: SensorCollector.OnAccuracyChangedListener? = null)

Base class to generate calibration measurements. Measurements are generated by taking into account static and dynamic intervals on the device, where the device is kept static (e.g. motionless), or where some force is applied to the device changing its position or orientation. Static and dynamic intervals are always measured using the accelerometer. An additional sensor such as the gyroscope or magnetometer can be used to generate measurements for them. Measurement generator converts device ENU measurements into measurements expressed in local tangent plane NED coordinates.

Parameters

I

type of input data to be processed.

Inheritors

Constructors

Link copied to clipboard
constructor(context: Context, accelerometerSensorType: AccelerometerSensorType = AccelerometerSensorType.ACCELEROMETER_UNCALIBRATED, accelerometerSensorDelay: SensorDelay = SensorDelay.FASTEST, accuracyChangedListener: SensorCollector.OnAccuracyChangedListener? = null)

Properties

Link copied to clipboard

Gets average time interval between accelerometer samples expressed in seconds (s). This is only available once this generator completes initialization.

Link copied to clipboard

Gets average time interval between accelerometer samples. This is only available once this generator completes initialization.

Link copied to clipboard

Gets accelerometer measurement base noise level that has been detected during initialization expressed in meters per squared second (m/s^2). This is only available once detector completes initialization.

Link copied to clipboard
abstract val accelerometerBaseNoiseLevelAsMeasurement: Acceleration?

Gets sensor measurement base noise level that has been detected during initialization. This is only available once detector completes initialization.

Link copied to clipboard

Gets measurement base noise level PSD (Power Spectral Density) expressed in (m^2 * s^-3). This is only available once detector completes initialization.

Link copied to clipboard

Gets measurement base noise level root PSD (Power Spectral Density) expressed in (m * s^-1.5). This is only available once detector completes initialization.

Link copied to clipboard

Gets accelerometer sensor being used to obtain measurements and detect static/dynamic intervals, or null if not available. This can be used to obtain additional information about the sensor.

Link copied to clipboard

Delay of sensor between samples.

Link copied to clipboard

One of the supported accelerometer sensor types.

Gets estimated standard deviation of time interval between accelerometer measurements expressed in seconds (s). This is only available once detector completes initialization.

Gets estimated standard deviation of time interval between accelerometer measurements. This is only available once detector completes initialization.

Link copied to clipboard

Gets estimated variance of time interval between accelerometer measurements expressed in squared seconds (s^2). This is only available once detector completes initialization.

Link copied to clipboard

listener to notify when sensor accuracy changes.

Link copied to clipboard

Gets or sets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes. This threshold is expressed in meters per squared second (m/s^2).

Gets or sets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes.

Link copied to clipboard

Android context.

Link copied to clipboard

Gets or sets number of samples to be processed initially while keeping the sensor static in order to find the base noise level when device is static.

Link copied to clipboard

Gets or sets factor to determine that a sudden movement has occurred during initialization if instantaneous noise level exceeds accumulated noise level by this factor amount. This factor is unit-less.

Link copied to clipboard

Indicates whether last dynamic interval must be skipped.

Link copied to clipboard

Indicates whether last static interval must be skipped.

Link copied to clipboard
abstract var maxDynamicSamples: Int

Gets or sets maximum number of samples allowed in dynamic intervals. Dynamic intervals exceeding this value are discarded.

Link copied to clipboard
abstract var minStaticSamples: Int

Gets or sets minimum number of samples required in a static interval to be taken into account. Smaller static intervals will be discarded.

Number of accelerometer measurements that have been processed.

Link copied to clipboard

Gets number of samples that have been processed in a dynamic period so far.

Link copied to clipboard

Gets number of samples that have been processed in a static period so far.

Link copied to clipboard

Indicates whether this generator is already running.

Link copied to clipboard
abstract val status: Status

Gets status of measurement generator. Initially the generator will be idle. Once it starts, it will start the initialization phase, and once initialization is complete, it will switch between static or dynamic interval until generator is stopped or an error occurs.

Link copied to clipboard
abstract val threshold: Double?

Gets estimated threshold to determine static/dynamic period changes expressed in meters per squared second (m/s^2). This is only available once detector completes initialization.

Link copied to clipboard
abstract val thresholdAsMeasurement: Acceleration?

Gets estimated threshold to determine static/dynamic period changes. This is only available once detector completes initialization.

Link copied to clipboard
abstract var thresholdFactor: Double

Gets or sets factor to be applied to detected base noise level in order to determine threshold for static/dynamic period changes. This factor is unit-less.

Link copied to clipboard
abstract var windowSize: Int

Gets or sets length of number of samples to keep within the window being processed to determine instantaneous sensor noise level. Window size must always be larger than allowed minimum value, which is 2 and must have an odd value.

Functions

Gets average time interval between accelerometer measurements. This is only available once detector completes initialization.

abstract fun getAccelerometerBaseNoiseLevelAsMeasurement(result: Acceleration): Boolean

Gets sensor measurement base noise level that has been detected during initialization. This is only available once detector completes initialization.

Gets estimated standard deviation of time interval between accelerometer measurements. This is only available once detector completes initialization.

abstract fun getBaseNoiseLevelAbsoluteThresholdAsMeasurement(result: Acceleration)

Gets overall absolute threshold to determine whether there has been excessive motion during the whole initialization phase. Failure will be detected if estimated base noise level exceeds this threshold when initialization completes.

Link copied to clipboard
abstract fun getThresholdAsMeasurement(result: Acceleration): Boolean

Gets estimated threshold to determine static/dynamic period changes. This is only available once detector completes initialization.

Link copied to clipboard
abstract fun start()

Starts collection of sensor measurements.

Link copied to clipboard
abstract fun stop()

Stops collection of sensor measurements.