mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-06-01 02:55:07 +08:00
added field for pressure altitude to global position
This commit is contained in:
@@ -18,3 +18,4 @@ float32 epv # Standard deviation of position vertically
|
|||||||
float32 terrain_alt # Terrain altitude in m, WGS84
|
float32 terrain_alt # Terrain altitude in m, WGS84
|
||||||
bool terrain_alt_valid # Terrain altitude estimate is valid
|
bool terrain_alt_valid # Terrain altitude estimate is valid
|
||||||
bool dead_reckoning # True if this position is estimated through dead-reckoning
|
bool dead_reckoning # True if this position is estimated through dead-reckoning
|
||||||
|
float32 pressure_alt # Pressure altitude
|
||||||
|
|||||||
@@ -2602,7 +2602,7 @@ protected:
|
|||||||
if (updated) {
|
if (updated) {
|
||||||
mavlink_altitude_t msg;
|
mavlink_altitude_t msg;
|
||||||
|
|
||||||
msg.altitude_monotonic = global_pos.alt;
|
msg.altitude_monotonic = global_pos.pressure_alt;
|
||||||
msg.altitude_amsl = global_pos.alt;
|
msg.altitude_amsl = global_pos.alt;
|
||||||
msg.altitude_local = -local_pos.z;
|
msg.altitude_local = -local_pos.z;
|
||||||
msg.altitude_relative = home.alt;
|
msg.altitude_relative = home.alt;
|
||||||
|
|||||||
Reference in New Issue
Block a user