Fix roll correction, closes #1
This commit is contained in:
@@ -35,6 +35,8 @@ void calibrateGyroBias() {
|
||||
biasGZ = (float)(sz/BIAS_SAMPLES);
|
||||
calTempC = readIMUTemp();
|
||||
angleX = angleY = accumX = accumY = 0.0f;
|
||||
// Seed gravity estimate from current accel so projection is correct immediately
|
||||
gravX = imu.readFloatAccelX(); gravY = imu.readFloatAccelY(); gravZ = imu.readFloatAccelZ();
|
||||
|
||||
#ifdef FEATURE_TELEMETRY
|
||||
statRecalCount++;
|
||||
|
||||
Reference in New Issue
Block a user