Browse Source

Plane: adjust throttle mix for auto landing

use mix-max during landing approach and initial descent, use min in
land final. As discussed with Leonard
apm_2208
Andrew Tridgell 3 years ago
parent
commit
8b16b5ca94
  1. 12
      ArduPlane/quadplane.cpp

12
ArduPlane/quadplane.cpp

@ -3608,7 +3608,17 @@ void QuadPlane::update_throttle_mix(void) @@ -3608,7 +3608,17 @@ void QuadPlane::update_throttle_mix(void)
// check for requested descent
bool descent_not_demanded = pos_control->get_vel_desired_cms().z >= 0.0f;
if (large_angle_request || large_angle_error || accel_moving || descent_not_demanded) {
bool use_mix_max = large_angle_request || large_angle_error || accel_moving || descent_not_demanded;
/*
special case for auto landing, we want a high degree of
attitude control until LAND_FINAL
*/
if (in_vtol_land_sequence()) {
use_mix_max = !in_vtol_land_final();
}
if (use_mix_max) {
attitude_control->set_throttle_mix_max(1.0);
} else {
attitude_control->set_throttle_mix_min();

Loading…
Cancel
Save