Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Very interesting question!!!!</p> <p>I'm developing somethig similar to your application. What i found about TYPE_LINEAR_ACCELERATION isn't happy for me.</p> <p>1) TYPE_LINEAR_ACCELERATION, TYPE_GRAVITY, ecc are implemented only for Android 2.3 (and up) So i have Android 2.2 and i can't test them.</p> <p>2) TYPE_LINEAR_ACCELERATION isn't so accurate as it would be, because there are some simple problem when substract the gravity. In fact is a "sensor fusion" that uses accelerometer and orientation to know where is directed the gravity and then subs. it.</p> <p>Here i found a very usefull answer that explain it:</p> <p><a href="https://groups.google.com/forum/#!topic/android-developers/GOm9yhTFZaM" rel="noreferrer">https://groups.google.com/forum/#!topic/android-developers/GOm9yhTFZaM</a></p> <blockquote> <p><strong>TYPE_ACCELEROMETER</strong> uses the accelerometer and only the accelerometer. It returns raw accelerometer events, with minimal or no processing at all. </p> <p><strong>TYPE_GYROSCOPE</strong> (if present) uses the gyroscope and only the gyroscope. Like above, it returns raw events (angular speed un rad/s) with no processing at all (no offset / scale compensation). </p> <p><strong>TYPE_ORIENTATION</strong> is deprecated. It returns the orientation as yaw/ pitch/roll in degres. It's not very well defined and can only be relied upon when the device has no "roll". This sensor uses a combination of the accelerometer and the magnetometer. Marginally better results can be obtained using SensorManager's helpers. This sensor is heavily "processed". </p> <p><strong>TYPE_LINEAR_ACCELERATION, TYPE_GRAVITY, TYPE_ROTATION_VECTOR</strong> are "fused" sensors which return respectively the linear acceleration, gravity and rotation vector (a quaternion). It is not defined how these are implemented. On some devices they are implemented in h/w, on some devices they use the accelerometer + the magnetometer, on some other devices they use the gyro. </p> <p>On Nexus S and Xoom, the gyroscope is currently NOT used. They behave as if there was no gyro available, like on Nexus One or Droid. We are planing to improve this situation in a future release. </p> <p>Currently, the only way to take advantage of the gyro is to use TYPE_GYROSCOPE and integrate the output by hand. </p> <p>I hope this helps, </p> <p>Mathias</p> </blockquote> <p>Anyway, in various place on the web i found no best word about phone sensor and their potential, due to the fact that aren't accurate...</p> <p>Some more precision can be reached using Kalman filter, but i have no idea how...</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload