mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-18 16:03:34 +08:00
Navigator: VTOL: disable weather vane during yaw aligning before front transition
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
This commit is contained in:
committed by
Roman Bapst
parent
af0d63250c
commit
ab28f1e4f7
@@ -259,6 +259,12 @@ bool FlightTaskAuto::_evaluateTriplets()
|
||||
}
|
||||
}
|
||||
|
||||
if (_ext_yaw_handler != nullptr) {
|
||||
// activation/deactivation of weather vane is based on parameter WV_EN and setting of navigator (allow_weather_vane)
|
||||
(_param_wv_en.get() && _sub_triplet_setpoint->get().current.allow_weather_vane) ? _ext_yaw_handler->activate() :
|
||||
_ext_yaw_handler->deactivate();
|
||||
}
|
||||
|
||||
// set heading
|
||||
if (_ext_yaw_handler != nullptr && _ext_yaw_handler->is_active()) {
|
||||
_yaw_setpoint = _yaw;
|
||||
|
||||
@@ -120,7 +120,8 @@ protected:
|
||||
(ParamInt<px4::params::MPC_YAW_MODE>) _param_mpc_yaw_mode, // defines how heading is executed,
|
||||
(ParamInt<px4::params::COM_OBS_AVOID>) _param_com_obs_avoid, // obstacle avoidance active
|
||||
(ParamFloat<px4::params::MPC_YAWRAUTO_MAX>) _param_mpc_yawrauto_max,
|
||||
(ParamFloat<px4::params::MIS_YAW_ERR>) _param_mis_yaw_err // yaw-error threshold
|
||||
(ParamFloat<px4::params::MIS_YAW_ERR>) _param_mis_yaw_err, // yaw-error threshold
|
||||
(ParamBool<px4::params::WV_EN>) _param_wv_en // enable/disable weather vane (VTOL)
|
||||
);
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user