1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-23 00:05:33 +03:00

Yaw Expo Feature

This commit is contained in:
borisbstyle 2015-05-05 16:43:27 +02:00 committed by Dominic Clifton
parent 5bf687a150
commit da8bb6f6fc
8 changed files with 23 additions and 3 deletions

View file

@ -209,7 +209,8 @@ void annexCode(void)
tmp = 0;
}
}
rcCommand[axis] = tmp * -masterConfig.yaw_control_direction;
tmp2 = tmp / 100;
rcCommand[axis] = (lookupYawRC[tmp2] + (tmp - tmp2 * 100) * (lookupYawRC[tmp2 + 1] - lookupYawRC[tmp2]) / 100) * -masterConfig.yaw_control_direction;
prop1 = 100 - (uint16_t)currentControlRateProfile->rates[axis] * ABS(tmp) / 500;
}
// FIXME axis indexes into pids. use something like lookupPidIndex(rc_alias_e alias) to reduce coupling.