Skip to content

Commit

Permalink
Yaw boost only in air mode
Browse files Browse the repository at this point in the history
  • Loading branch information
lkaino committed Jun 4, 2017
1 parent f26b886 commit de6074d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/main/flight/mixer_tricopter.c
Original file line number Diff line number Diff line change
Expand Up @@ -235,8 +235,11 @@ int16_t triGetMotorCorrection(uint8_t motorIndex)
const uint16_t servoAngle = triGetCurrentServoAngle();
correction = (throttleRange * getPitchCorrectionAtTailAngle(DEGREES_TO_RADIANS(servoAngle / 10.0f), tailServo.thrustFactor)) - throttleRange;

// Multiply the correction to get more authority
correction *= pitchCorrectionGain;
// Multiply the correction to get more authority (yaw boost)
if (isAirmodeActive())
{
correction *= pitchCorrectionGain;
}
lastMotorCorrection = correction;
}

Expand Down

0 comments on commit de6074d

Please sign in to comment.