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

updated dynThrottle curve

This commit is contained in:
Nicola De Pasquale 2020-08-07 15:28:36 +02:00
parent b1af9befe5
commit 988024ee4e

View file

@ -625,7 +625,7 @@ float dynThrottle(float throttle) {
void dynLpfGyroUpdate(float throttle)
{
if (gyro.dynLpfFilter != DYN_LPF_NONE) {
const unsigned int cutoffFreq = fmax(dynThrottle(throttle) * gyro.dynLpfMax, gyro.dynLpfMin);
const unsigned int cutoffFreq = (gyro.dynLpfMax - gyro.dynLpfMin) * dynThrottle(throttle) + gyro.dynLpfMin;
if (gyro.dynLpfFilter == DYN_LPF_PT1) {
DEBUG_SET(DEBUG_DYN_LPF, 2, cutoffFreq);