mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-18 22:05:17 +03:00
add const, remove float cast
This commit is contained in:
parent
f545637669
commit
942d1bb384
1 changed files with 1 additions and 1 deletions
|
@ -444,7 +444,7 @@ void pidInitConfig(const pidProfile_t *pidProfile)
|
||||||
maxVelocity[FD_ROLL] = maxVelocity[FD_PITCH] = pidProfile->rateAccelLimit * 100 * dT;
|
maxVelocity[FD_ROLL] = maxVelocity[FD_PITCH] = pidProfile->rateAccelLimit * 100 * dT;
|
||||||
maxVelocity[FD_YAW] = pidProfile->yawRateAccelLimit * 100 * dT;
|
maxVelocity[FD_YAW] = pidProfile->yawRateAccelLimit * 100 * dT;
|
||||||
if (pidProfile->itermWindupPointPercent < 100) {
|
if (pidProfile->itermWindupPointPercent < 100) {
|
||||||
float ITermWindupPoint = (float)pidProfile->itermWindupPointPercent / 100.0f;
|
const float ITermWindupPoint = pidProfile->itermWindupPointPercent / 100.0f;
|
||||||
ITermWindupPointInv = 1.0f / (1.0f - ITermWindupPoint);
|
ITermWindupPointInv = 1.0f / (1.0f - ITermWindupPoint);
|
||||||
}
|
}
|
||||||
itermAcceleratorGain = pidProfile->itermAcceleratorGain;
|
itermAcceleratorGain = pidProfile->itermAcceleratorGain;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue