From ca9cb2214f2a5d290e0c5a0ace1c6ce4264fa16f Mon Sep 17 00:00:00 2001 From: RomanBapst Date: Thu, 2 May 2024 14:44:35 +0200 Subject: [PATCH] quadchute: fixed sign for handling altitude resets Signed-off-by: RomanBapst --- src/modules/vtol_att_control/vtol_type.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/vtol_att_control/vtol_type.cpp b/src/modules/vtol_att_control/vtol_type.cpp index 808c9c03c2a..1d6f5b667a5 100644 --- a/src/modules/vtol_att_control/vtol_type.cpp +++ b/src/modules/vtol_att_control/vtol_type.cpp @@ -324,7 +324,7 @@ void VtolType::handleEkfResets() _altitude_reset_counter = _local_pos->z_reset_counter; if (PX4_ISFINITE(_quadchute_ref_alt)) { - _quadchute_ref_alt += _local_pos->delta_z; + _quadchute_ref_alt -= _local_pos->delta_z; } }