1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-14 11:59:58 +03:00

Merge pull request #9486 from IllusionFpv/updated-dlpf-curve

Updated DLPF curve
This commit is contained in:
Michael Keller 2020-02-17 23:57:49 +13:00 committed by GitHub
commit 17e620f997
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1636,7 +1636,7 @@ void dynLpfDTermUpdate(float throttle)
float dynDtermLpfCutoffFreq(float throttle, uint16_t dynLpfMin, uint16_t dynLpfMax, uint8_t expo) {
const float expof = expo / 10.0f;
static float curve;
curve = 2 * throttle * (1 - throttle) * expof + powerf(throttle, 2);
curve = throttle * (1 - throttle) * expof + throttle;
return (dynLpfMax - dynLpfMin) * curve + dynLpfMin;
}