mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-02-18 08:54:15 +01:00
Flip the sign of throttle in the guidance altitude control
This commit is contained in:
parent
7f226867c6
commit
62117430cf
@ -364,6 +364,8 @@ static void updateVtolDesiredAttitude()
|
||||
|
||||
// Compute desired down command
|
||||
downError = velocityDesired.Down - velocityActual.Down;
|
||||
// Must flip this sign
|
||||
downError = -downError;
|
||||
downVelIntegral = bound(downVelIntegral + downError * dT * guidanceSettings.VerticalVelPID[GUIDANCESETTINGS_VERTICALVELPID_KI],
|
||||
-guidanceSettings.VerticalVelPID[GUIDANCESETTINGS_VERTICALVELPID_ILIMIT],
|
||||
guidanceSettings.VerticalVelPID[GUIDANCESETTINGS_VERTICALVELPID_ILIMIT]);
|
||||
|
Loading…
x
Reference in New Issue
Block a user