title: Flutter/android How to calculate acceleration relative to ground?
body: <p>Since acceleration is calculated relative to the phone, how can I convert this relative to the earth?</p>
  <p>I believe I need to know what angle the phone is at (pitch) and then use trig to normalise the acceleration directions.</p>
  <p>Gyroscopic data isn't helpful since it actually provides a rate of change, rather than the actual pitch.</p>
  <p>I have tried using the aeyrium package as that should provide pitch and roll, but I believe the calculations to be wrong - having the phone vertically up or vertically down gives the same pitch but a different roll value, which is totally wrong.</p>
  <p>Should I be using the magnetometer to get the pitch - would it even do that?</p>