From 845d056c18544a5fa9e9e5f7201e6e761f20f9a5 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Mon, 13 Feb 2012 14:11:21 +1100 Subject: [PATCH] fixed PID initialisation --- libraries/PID/PID.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libraries/PID/PID.h b/libraries/PID/PID.h index 09f8b0e8db..384ac0381f 100644 --- a/libraries/PID/PID.h +++ b/libraries/PID/PID.h @@ -17,7 +17,11 @@ public: PID(const float &initial_p = 0.0, const float &initial_i = 0.0, const float &initial_d = 0.0, - const int16_t &initial_imax = 0.0) + const int16_t &initial_imax = 0) : + _kp (initial_p), + _ki (initial_i), + _kd (initial_d), + _imax(initial_imax) { }