Lines Matching defs:sensor

23  * Class representing a sensor. Use {@link SensorManager#getSensorList} to get
34 * A constant describing an accelerometer sensor type.
41 * A constant string describing an accelerometer sensor type.
45 public static final String STRING_TYPE_ACCELEROMETER = "android.sensor.accelerometer";
48 * A constant describing a magnetic field sensor type.
55 * A constant string describing a magnetic field sensor type.
59 public static final String STRING_TYPE_MAGNETIC_FIELD = "android.sensor.magnetic_field";
62 * A constant describing an orientation sensor type.
73 * A constant string describing an orientation sensor type.
80 public static final String STRING_TYPE_ORIENTATION = "android.sensor.orientation";
83 * A constant describing a gyroscope sensor type.
89 * A constant string describing a gyroscope sensor type.
93 public static final String STRING_TYPE_GYROSCOPE = "android.sensor.gyroscope";
96 * A constant describing a light sensor type.
103 * A constant string describing a light sensor type.
107 public static final String STRING_TYPE_LIGHT = "android.sensor.light";
110 * A constant describing a pressure sensor type.
117 * A constant string describing a pressure sensor type.
121 public static final String STRING_TYPE_PRESSURE = "android.sensor.pressure";
124 * A constant describing a temperature sensor type
134 * A constant string describing a temperature sensor type
142 public static final String STRING_TYPE_TEMPERATURE = "android.sensor.temperature";
145 * A constant describing a proximity sensor type. This is a wake up sensor.
153 * A constant string describing a proximity sensor type.
157 public static final String STRING_TYPE_PROXIMITY = "android.sensor.proximity";
160 * A constant describing a gravity sensor type.
167 * A constant string describing a gravity sensor type.
171 public static final String STRING_TYPE_GRAVITY = "android.sensor.gravity";
174 * A constant describing a linear acceleration sensor type.
181 * A constant string describing a linear acceleration sensor type.
186 "android.sensor.linear_acceleration";
189 * A constant describing a rotation vector sensor type.
196 * A constant string describing a rotation vector sensor type.
200 public static final String STRING_TYPE_ROTATION_VECTOR = "android.sensor.rotation_vector";
203 * A constant describing a relative humidity sensor type.
210 * A constant string describing a relative humidity sensor type
214 public static final String STRING_TYPE_RELATIVE_HUMIDITY = "android.sensor.relative_humidity";
217 * A constant describing an ambient temperature sensor type.
224 * A constant string describing an ambient temperature sensor type.
229 "android.sensor.ambient_temperature";
232 * A constant describing an uncalibrated magnetic field sensor type.
236 * device) is not considered in the given sensor values. However, such hard iron bias values
240 * (i.e. there are no discontinuities in the data stream while using this sensor) and
249 * A constant string describing an uncalibrated magnetic field sensor type.
254 "android.sensor.magnetic_field_uncalibrated";
257 * A constant describing an uncalibrated rotation vector sensor type.
275 * A constant string describing an uncalibrated rotation vector sensor type.
280 "android.sensor.game_rotation_vector";
283 * A constant describing an uncalibrated gyroscope sensor type.
285 * to adjust the given sensor values. However, such gyro-drift bias values
297 * A constant string describing an uncalibrated gyroscope sensor type.
302 "android.sensor.gyroscope_uncalibrated";
305 * A constant describing a significant motion trigger sensor.
308 * itself. The sensor continues to operate while the device is asleep
311 * locks for this sensor to trigger. This is a wake up sensor.
319 * A constant string describing a significant motion trigger sensor.
324 "android.sensor.significant_motion";
327 * A constant describing a step detector sensor.
329 * A sensor of this type triggers an event each time a step is taken by the user. The only
332 * when the foot hit the ground, generating a high variation in acceleration. This sensor is
336 * {@link Sensor#REPORTING_MODE_SPECIAL_TRIGGER} sensor.
343 * A constant string describing a step detector sensor.
347 public static final String STRING_TYPE_STEP_DETECTOR = "android.sensor.step_detector";
350 * A constant describing a step counter sensor.
352 * A sensor of this type returns the number of steps taken by the user since the last reboot
355 * the last step for that event was taken. This sensor is implemented in hardware and is
357 * period of time, do NOT unregister for this sensor, so that it keeps counting steps in the
359 * is awake. Application needs to stay registered for this sensor because step counter does not
360 * count steps if it is not activated. This sensor is ideal for fitness tracking applications.
361 * It is defined as an {@link Sensor#REPORTING_MODE_ON_CHANGE} sensor.
368 * A constant string describing a step counter sensor.
372 public static final String STRING_TYPE_STEP_COUNTER = "android.sensor.step_counter";
378 * gyroscope. This sensor uses lower power than the other rotation vectors, because it doesn't
391 "android.sensor.geomagnetic_rotation_vector";
404 * This sensor requires permission {@code android.permission.BODY_SENSORS}.
415 public static final String STRING_TYPE_HEART_RATE = "android.sensor.heart_rate";
418 * A sensor of this type generates an event each time a tilt event is detected. A tilt event
420 * least 35 degrees since the activation of the sensor. It is a wake up sensor.
428 * A constant string describing a wake up tilt detector sensor type.
434 "android.sensor.tilt_detector";
437 * A constant describing a wake gesture sensor.
441 * When this sensor triggers, the device behaves as if the power button was pressed, turning the
442 * screen on. This behavior (turning on the screen when this sensor triggers) might be
444 * behavior of the sensor: only whether the framework turns the screen on when it triggers.
447 * the device. This sensor must be low power, as it is likely to be activated 24/7.
451 * @hide This sensor is expected to only be used by the system ui
456 * A constant string describing a wake gesture sensor.
458 * @hide This sensor is expected to only be used by the system ui
461 public static final String STRING_TYPE_WAKE_GESTURE = "android.sensor.wake_gesture";
464 * A constant describing a wake gesture sensor.
466 * A sensor enabling briefly turning the screen on to enable the user to
470 * When this sensor triggers, the device turns the screen on momentarily
473 * (briefly turning on the screen when this sensor triggers) might be deactivated
475 * behavior of the sensor: only whether the framework briefly turns the screen on
479 * the device. This sensor must be low power, as it is likely to be activated 24/7.
483 * @hide This sensor is expected to only be used by the system ui
488 * A constant string describing a wake gesture sensor.
490 * @hide This sensor is expected to only be used by the system ui
493 public static final String STRING_TYPE_GLANCE_GESTURE = "android.sensor.glance_gesture";
496 * A constant describing a pick up sensor.
498 * A sensor of this type triggers when the device is picked up regardless of wherever it was
499 * before (desk, pocket, bag). The only allowed return value is 1.0. This sensor deactivates
507 * A constant string describing a pick up sensor.
509 * @hide This sensor is expected to be used internally for always on display.
512 public static final String STRING_TYPE_PICK_UP_GESTURE = "android.sensor.pick_up_gesture";
515 * A constant describing all sensor types.
519 // If this flag is set, the sensor defined as a wake up sensor. This field and REPORTING_MODE_*
526 * applications are requesting a higher rate, the sensor data might be delivered at faster rates
535 * applications are requesting a higher rate, the sensor data might be delivered at faster rates
541 * Events are reported in one-shot mode. Upon detection of an event, the sensor deactivates
548 * Events are reported as described in the description of the sensor. The rate passed to
549 * registerListener might not have an impact on the rate of event delivery. See the sensor
563 // Note: This needs to be updated, whenever a new sensor is added.
568 0, // padding because sensor types start at 1
597 * Each sensor has exactly one reporting mode associated with it. This method returns the
598 * reporting mode constant for this sensor type.
600 * @return Reporting mode for the input sensor, one of REPORTING_MODE_* constants.
610 static int getMaxLengthValuesArray(Sensor sensor, int sdkLevel) {
613 if (sensor.mType == Sensor.TYPE_ROTATION_VECTOR &&
617 int offset = sensor.mType;
619 // we don't know about this sensor, so this is probably a
620 // vendor-defined sensor, in that case, we don't know how many value
623 // FIXME: sensor HAL should advertise how much data is returned per
624 // sensor
653 * @return name string of the sensor.
660 * @return vendor string of this sensor.
667 * @return generic type of this sensor.
674 * @return version of the sensor's module.
681 * @return maximum range of the sensor in the sensor's unit.
688 * @return resolution of the sensor in the sensor's unit.
695 * @return the power in mA used by this sensor while in use
703 * or zero if this sensor only returns a value when the data it's measuring
711 * @return Number of events reserved for this sensor in the batch mode FIFO. This gives a
719 * @return Maximum number of events of this sensor that could be batched. If this value is zero
720 * it indicates that batch mode is not supported for this sensor. If other applications
729 * @return The type of this sensor as a string.
737 * @return The permission required to access this sensor. If empty, no permission is required.
750 * sensor events corresponding to the lowest frequency that this sensor supports. When lower
755 * @return The max delay for this sensor in microseconds.
762 * Returns true if the sensor is a wake-up sensor.
791 * events. That is, the AP will wake up and the sensor will deliver the events before the
796 * @return <code>true</code> if this is a wake-up sensor, <code>false</code> otherwise.