I have an Android 7 phone and I have written an Android application for recording the following sensor values:

Accelerometer (Sensor.TYPE_ACCELEROMETER)
Linear acceleration (Sensor.TYPE_LINEAR_ACCELERATION)
Gravity (Sensor.TYPE_GRAVITY)
Gyroscope (Sensor.TYPE_GYROSCOPE)
Magnetic Field (Sensor.TYPE_MAGNETIC_FIELD)
Rotation Vector (Sensor.TYPE_ROTATION_VECTOR)
Game Rotation Vector (Sensor.TYPE_GAME_ROTATION_VECTOR)

I think the linear acceleration is the accelerometer minus gravity.

Can somebody explain what the difference between accelerometer, gyroscope, rotation vector and game rotation vector is? I've read the description in the Android documentation but it is not clear to me.

Moreover, can I use the magnetic field recordings to calculate some motion or position measurements which I'm not getting from the other listed sensor measurements?

  • A gyroscope is a proper gyroscope, it finds the ground... Accelerometer reads gforces and finds the acceleration.... Gravity sensor must measure weight changes from say, jumping.. Magnetic Field messures the grounds magnetic energy ( for GPS Coordinates & Compass ) .... Rotation vector is a metal ball that falls to the side for landscape or to the bottom for portrait orientation recognition... Game Rotation Vector may be the gyroscope... Many older sensors are only available because a gyroscope wasn't available... Now heaps of devices have gyroscopes, you don't need a rotation sensor.. – Gadget Guru Apr 4 at 21:34
  • @Zillinium Thank you for the explanations. So what I understand is that I just need gyroscope and accelerometer, right? But what about linear acceleration (accelerometer minus gravity)? And is the magnetic field measures of any use for motion and position? – machinery Apr 6 at 14:24
  • Each Land Mass or Area on earth has a different magnetic frequency, This is like a signature... So yes the magnetic readings are uses for position with the GPS ... If you use high accuracy GPS, The magnetic readings, i think it is call magnetic frequency, is used for calculating the real time position... – Gadget Guru Apr 6 at 17:24
  • @Zillinium Alright, but just for orientation and motion of phone on same place the magnetic field readings are not of any use? – machinery Apr 6 at 23:02
  • I can't think of many uses for it to do with orientation, however it could help with rotation ( Compass ) . – Gadget Guru Apr 7 at 2:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.