From 70178266f0e2b66bb2ccc9620505d14fe7027b2c Mon Sep 17 00:00:00 2001 From: Sander Smeets Date: Mon, 10 Jul 2017 00:28:54 +0200 Subject: [PATCH] VTOL pusher assist: return vehicle to level position --- src/modules/vtol_att_control/standard.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/vtol_att_control/standard.cpp b/src/modules/vtol_att_control/standard.cpp index 028ca85911..ad0ddfbcfc 100644 --- a/src/modules/vtol_att_control/standard.cpp +++ b/src/modules/vtol_att_control/standard.cpp @@ -391,8 +391,8 @@ void Standard::update_mc_state() _pusher_throttle = (sinf(-pitch_forward) - sinf(_params_standard.down_pitch_max)) * _v_att_sp->thrust * _params_standard.forward_thrust_scale; - // limit desired pitch - float pitch_new = -_params_standard.down_pitch_max; + // return the vehicle to level position + float pitch_new = 0; // create corrected desired body z axis in heading frame matrix::Dcmf R_tmp = matrix::Eulerf(roll_new, pitch_new, 0.0f);