mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 05:23:33 +08:00
mc_pos_control: simplify weathervane logic
This commit is contained in:
@@ -633,8 +633,8 @@ MulticopterPositionControl::run()
|
||||
if (_wv_controller != nullptr) {
|
||||
|
||||
// in manual mode we just want to use weathervane if position is controlled as well
|
||||
if (_wv_controller->weathervane_enabled() && !(_control_mode.flag_control_manual_enabled
|
||||
&& !_control_mode.flag_control_position_enabled)) {
|
||||
if (_wv_controller->weathervane_enabled() && (!_control_mode.flag_control_manual_enabled
|
||||
|| _control_mode.flag_control_position_enabled)) {
|
||||
_wv_controller->activate();
|
||||
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user