diff --git a/libraries/PID/PID.h b/libraries/PID/PID.h index f125e889b9..7a859cf896 100644 --- a/libraries/PID/PID.h +++ b/libraries/PID/PID.h @@ -16,9 +16,9 @@ class PID { public: - PID(const float & initial_p = 0.0, - const float & initial_i = 0.0, - const float & initial_d = 0.0, + PID(const float & initial_p = 0.0f, + const float & initial_i = 0.0f, + const float & initial_d = 0.0f, const int16_t & initial_imax = 0) { AP_Param::setup_object_defaults(this, var_info); diff --git a/libraries/PID/examples/pid/pid.pde b/libraries/PID/examples/pid/pid.pde index 4f34056864..944f5ef64a 100644 --- a/libraries/PID/examples/pid/pid.pde +++ b/libraries/PID/examples/pid/pid.pde @@ -32,7 +32,7 @@ void setup() pid.kP(1); pid.kI(0); - pid.kD(0.5); + pid.kD(0.5f); pid.imax(50); pid.save_gains(); pid.kP(0);