1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-17 21:35:44 +03:00

More commented

This commit is contained in:
borisbstyle 2015-05-09 02:08:52 +02:00
parent d6cb6a34e7
commit 5dee66fee9

View file

@ -184,7 +184,7 @@ static void pidLuxFloat(pidProfile_t *pidProfile, controlRateConfig_t *controlRa
// -----calculate P component
PTerm = RateError * pidProfile->P_f[axis] * PIDscaler[axis] / 100;
// -----calculate I component
// -----calculate I component. Note that PIDscaler is divided by 1000, because it is simplified formule from the previous multiply by 10
errorGyroIf[axis] = constrainf(errorGyroIf[axis] + RateError * dT * pidProfile->I_f[axis] * PIDscaler[axis] / 1000, -250.0f, 250.0f);
// limit maximum integrator value to prevent WindUp - accumulating extreme values when system is saturated.