Update imu.c

speed up troll angle
This commit is contained in:
Trey Marc 2014-04-16 17:20:40 +02:00
parent 45b74bf0b6
commit 038a1226ec
1 changed files with 1 additions and 1 deletions

View File

@ -315,7 +315,7 @@ static void getEstimatedAttitude(void)
int angle = lrintf(acosf(cosZ) * throttleAngleScale); int angle = lrintf(acosf(cosZ) * throttleAngleScale);
if (angle > 900) if (angle > 900)
angle = 900; angle = 900;
throttleAngleCorrection = lrintf(cfg.throttle_correction_value * sinf(angle / 900.0f * M_PI / 2.0f)) ; throttleAngleCorrection = lrintf(cfg.throttle_correction_value * sinf(angle / (900.0f * M_PI / 2.0f))) ;
} }
} }