Skip to content

Commit

Permalink
Update bbn_atomS3R_mahony.ino
Browse files Browse the repository at this point in the history
  • Loading branch information
mgrouch authored Feb 11, 2025
1 parent ae9ad00 commit d0677fc
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions bbn_atomS3R_mahony/bbn_atomS3R_mahony.ino
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,6 @@ void repeatMe() {
}
}

unsigned long last_calib_save = 0UL;

void printCalib() {
size_t index = 0;
Serial.println("Calibration data:");
Expand Down Expand Up @@ -126,7 +124,7 @@ void setup() {
Serial.println(imu_name);
last_update = micros();

float twoKp = (2.0f * 50.0f);
float twoKp = (2.0f * 2.0f);
float twoKi = (2.0f * 0.0001f);
mahony_AHRS_init(&mahony, twoKp, twoKi);

Expand All @@ -136,18 +134,10 @@ void setup() {
else {
printCalib();
}
//M5.Imu.setCalibration(0, 0, 32);
}

void loop() {
AtomS3.update();
repeatMe();
delayMicroseconds(4000);
unsigned long now_ms = millis();
if (now_ms - last_calib_save > 60000) {
if (last_calib_save > 0) {
//M5.Imu.saveOffsetToNVS();
}
last_calib_save = now_ms;
}
}

0 comments on commit d0677fc

Please sign in to comment.