Some minor cleanups and fixes

This commit is contained in:
Oleg Kalachev 2024-12-28 23:57:44 +03:00
parent 1582238abc
commit 8e8c8d05bb
2 changed files with 4 additions and 5 deletions

View File

@ -122,9 +122,9 @@ void calibrateAccelOnce() {
}
void printIMUCal() {
Serial.printf("gyro bias: %f, %f, %f\n", gyroBias.x, gyroBias.y, gyroBias.z);
Serial.printf("accel bias: %f, %f, %f\n", accBias.x, accBias.y, accBias.z);
Serial.printf("accel scale: %f, %f, %f\n", accScale.x, accScale.y, accScale.z);
Serial.printf("gyro bias: %f %f %f\n", gyroBias.x, gyroBias.y, gyroBias.z);
Serial.printf("accel bias: %f %f %f\n", accBias.x, accBias.y, accBias.z);
Serial.printf("accel scale: %f %f %f\n", accScale.x, accScale.y, accScale.z);
}
void printIMUInfo() {

View File

@ -29,8 +29,7 @@ float wrapAngle(float angle) {
template <typename T>
void printArray(T arr[], int size) {
for (uint8_t i = 0; i < size; i++) {
Serial.printf("%g", static_cast<float>(arr[i]));
if (i < size - 1) Serial.print(" ");
Serial.printf("%g ", static_cast<float>(arr[i]));
}
Serial.println();
}