More sensible LED status, delays
This commit is contained in:
@@ -27,7 +27,7 @@ void calibrateGyroBias() {
|
||||
double sx=0, sy=0, sz=0;
|
||||
for (int i=0; i<BIAS_SAMPLES; i++) {
|
||||
sx += imu.readFloatGyroX(); sy += imu.readFloatGyroY(); sz += imu.readFloatGyroZ();
|
||||
digitalWrite(LED_BLUE, (i%20 < 10)); delay(5);
|
||||
digitalWrite(LED_GREEN, (i%20 < 10)); delay(5); // green flutter during calibration
|
||||
}
|
||||
biasGX = (float)(sx/BIAS_SAMPLES);
|
||||
biasGY = (float)(sy/BIAS_SAMPLES);
|
||||
@@ -41,7 +41,7 @@ void calibrateGyroBias() {
|
||||
statBiasRms = sqrtf((bxr*bxr + byr*byr + bzr*bzr) / 3.0f);
|
||||
#endif
|
||||
|
||||
digitalWrite(LED_BLUE, HIGH);
|
||||
digitalWrite(LED_GREEN, HIGH); // off after calibration
|
||||
Serial.print("[CAL] T="); Serial.print(calTempC,1);
|
||||
Serial.print("C bias="); Serial.print(biasGX,4);
|
||||
Serial.print(","); Serial.print(biasGY,4);
|
||||
|
||||
Reference in New Issue
Block a user