Skip to content
Snippets Groups Projects
Commit 3b5b2eba authored by rmackay9's avatar rmackay9
Browse files

ArduCopter: set fast gains while auto trim is being executed

parent 67e02a81
No related branches found
No related tags found
No related merge requests found
......@@ -161,6 +161,12 @@ static void auto_trim()
//g.rc_2.dead_zone = 60;
auto_level_counter--;
if( motors.armed() ) {
// set high AHRS gains to force accelerometers to impact attitude estimate
ahrs.set_fast_gains(true);
}
trim_accel();
led_mode = AUTO_TRIM_LEDS;
do_simple = false;
......@@ -174,6 +180,11 @@ static void auto_trim()
reset_control_switch();
// go back to normal AHRS gains
if( motors.armed() ) {
ahrs.set_fast_gains(false);
}
//Serial.println("Done");
auto_level_counter = 0;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment