mirror of https://github.com/ArduPilot/ardupilot
reset Rate_I for takeoff
This commit is contained in:
parent
efce991bfb
commit
b1d52da431
|
@ -903,12 +903,6 @@ static void fast_loop()
|
||||||
// IMU DCM Algorithm
|
// IMU DCM Algorithm
|
||||||
read_AHRS();
|
read_AHRS();
|
||||||
|
|
||||||
if(takeoff_complete == false){
|
|
||||||
// reset these I terms to prevent awkward tipping on takeoff
|
|
||||||
//reset_rate_I();
|
|
||||||
//reset_stability_I();
|
|
||||||
}
|
|
||||||
|
|
||||||
// custom code/exceptions for flight modes
|
// custom code/exceptions for flight modes
|
||||||
// ---------------------------------------
|
// ---------------------------------------
|
||||||
update_yaw_mode();
|
update_yaw_mode();
|
||||||
|
@ -1452,6 +1446,17 @@ void update_roll_pitch_mode(void)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(g.rc_3.control_in == 0 && roll_pitch_mode <= ROLL_PITCH_ACRO){
|
||||||
|
reset_rate_I();
|
||||||
|
reset_stability_I();
|
||||||
|
}
|
||||||
|
|
||||||
|
if(takeoff_complete == false){
|
||||||
|
// reset these I terms to prevent awkward tipping on takeoff
|
||||||
|
//reset_rate_I();
|
||||||
|
//reset_stability_I();
|
||||||
|
}
|
||||||
|
|
||||||
// clear new radio frame info
|
// clear new radio frame info
|
||||||
new_radio_frame = false;
|
new_radio_frame = false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue