qgroundcontrol icon indicating copy to clipboard operation
qgroundcontrol copied to clipboard

Follow Target message's GPS altitude is not AMSL, but Ellipsoidal Altitude

Open junwoo091400 opened this issue 3 years ago • 1 comments

Expected Behavior

The QGC code encodes the FOLLOW_TARGET MAVLink message to send target's position. And the altitude should be in AMSL (Above Mean Sea Level), however the real testing on Android device has shown that it's rather reporting in Ellipsoidal Altitude.

https://github.com/mavlink/qgroundcontrol/blob/6db3447fa7c1531a28bf394f393dfdb59fc9145d/src/FollowMe/FollowMe.cc#L78-L111

Current Behavior

FollowMe_GPS_Alt

The follow_target's altitude is tracking along with drone's alt_ellipsoid, which is the ellipsoidal altitude. But it should be sent in reference to the AMSL altitude.

Detailed Description

The Qt interface that QGC is using, should be giving the AMSL altitude, but it't not. So it is likely a Qt Bug as well. But I haven't found resources online to discuss fix on Qt's side.

https://doc.qt.io/qt-5/qgeocoordinate.html#altitude-prop

This arises from a fact that MASL (Geoid as a reference) and Ellipsoidal Altitude (Ellipsoid as reference) differs!

Some related information for curious readers :

  • https://en.wikipedia.org/wiki/Geoid
  • https://gisgeography.com/geoid-mean-sea-level/
  • https://stackoverflow.com/questions/11168306/is-androids-gps-altitude-incorrect-due-to-not-including-geoid-height

junwoo091400 avatar Mar 29 '22 16:03 junwoo091400

image

Here's a diagram I drew to show the difference between AMSL vs Ellipsoidal height.

junwoo091400 avatar Aug 29 '22 13:08 junwoo091400