Plane: Support seperate roll and pitch limits

This commit is contained in:
Leonard Hall 2019-07-27 15:08:02 +09:30 committed by Randy Mackay
parent 7f5d6662b3
commit 124d18228b
1 changed files with 2 additions and 1 deletions

View File

@ -140,7 +140,8 @@ void QuadPlane::tailsitter_output(void)
tilt_right = extra_elevator + tilt_right * tailsitter.vectored_hover_gain;
if (fabsf(tilt_left) >= SERVO_MAX || fabsf(tilt_right) >= SERVO_MAX) {
// prevent integrator windup
motors->limit.roll_pitch = 1;
motors->limit.roll = 1;
motors->limit.pitch = 1;
motors->limit.yaw = 1;
}
SRV_Channels::set_output_scaled(SRV_Channel::k_tiltMotorLeft, tilt_left);