Carbon Fibre / Classic_PID
Revision:
2:f78e083a20c4
Parent:
1:f85ca5649d55
Child:
3:715c8245e671
--- a/Classic_PID.cpp	Mon Nov 17 10:40:27 2014 +0000
+++ b/Classic_PID.cpp	Mon Jan 19 14:20:30 2015 +0000
@@ -101,7 +101,7 @@
     float Intergral = _Ki * _sumError;                                 // Calculate the Intergral part
     
     // Calculate the output
-    _output = (_setPoint * _kvelff) + Proportional + Intergral; 
+    _output = ((1 / _setPoint) * _kvelff) + Proportional + Intergral; 
         
     // Check for wind-up
     if(_output > _maxLimit)