mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-16 06:53:33 +08:00
fixed optimal recovery condition
This commit is contained in:
@@ -2022,7 +2022,7 @@ MulticopterPositionControl::task_main()
|
||||
/* control roll and pitch directly if no aiding velocity controller is active
|
||||
* and only if optimal recovery is not used */
|
||||
if (!_control_mode.flag_control_velocity_enabled
|
||||
&& !_params.opt_recover > 0) {
|
||||
&& _params.opt_recover <= 0) {
|
||||
math::Matrix<3, 3> R_sp;
|
||||
_att_sp.roll_body = _manual.y * _params.man_roll_max;
|
||||
_att_sp.pitch_body = -_manual.x * _params.man_pitch_max;
|
||||
|
||||
Reference in New Issue
Block a user