[ins] fix ins_baro_alt, ned frame, z-down!

This commit is contained in:
Felix Ruess
2013-09-04 19:13:22 +02:00
parent dadd73eb79
commit c459bb0f30
3 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -191,7 +191,7 @@ static void baro_cb(uint8_t __attribute__((unused)) sender_id, const float *pres
ins_ltp_pos.z = POS_BFP_OF_REAL(vff_z);
}
else {
ins_baro_alt = pprz_isa_height_of_pressure(*pressure, ins_qfe);
ins_baro_alt = -pprz_isa_height_of_pressure(*pressure, ins_qfe);
vff_update(ins_baro_alt);
}
INS_NED_TO_STATE();
+1 -1
View File
@@ -50,7 +50,7 @@ extern struct NedCoor_i ins_gps_speed_cm_s_ned;
/* barometer */
#if USE_VFF
extern float ins_baro_alt; ///< altitude calculated from baro in meters
extern float ins_baro_alt; ///< altitude calculated from baro in meters (z-down)
extern float ins_qfe;
extern bool_t ins_baro_initialised;
#endif
@@ -214,7 +214,7 @@ static void baro_cb(uint8_t __attribute__((unused)) sender_id, const float *pres
ins_ltp_pos.z = POS_BFP_OF_REAL(vff_z);
}
else {
ins_baro_alt = pprz_isa_height_of_pressure(*pressure, ins_qfe);
ins_baro_alt = -pprz_isa_height_of_pressure(*pressure, ins_qfe);
vff_update_baro(ins_baro_alt);
}
INS_NED_TO_STATE();