AP_PID: compiler warnings: reordered constructor
This commit is contained in:
parent
0b29848277
commit
54f4d4b07c
@ -56,7 +56,7 @@ float AC_HELI_PID::get_ff(float requested_rate) const
|
||||
|
||||
float AC_HELI_PID::get_leaky_i(float leak_rate)
|
||||
{
|
||||
if((_ki != 0) && (_dt != 0)){
|
||||
if(!AP_Math::is_zero(_ki) && !AP_Math::is_zero(_dt)){
|
||||
_integrator -= (float)_integrator * leak_rate;
|
||||
_integrator += ((float)_input * _ki) * _dt;
|
||||
if (_integrator < -_imax) {
|
||||
|
Loading…
Reference in New Issue
Block a user