Antonia Baumgartner / Mbed 2 deprecated YB_copy

Dependencies:   mbed

Fork of Versuch21 by Antonia Baumgartner

Revision:
5:93d3efe46493
Parent:
0:b886f13e4ac6
--- a/Classes/Controller.h	Tue May 01 11:42:38 2018 +0000
+++ b/Classes/Controller.h	Wed May 09 13:33:59 2018 +0000
@@ -16,16 +16,23 @@
     virtual ~Controller();
     void setDesiredSpeedLeft(float desiredSpeedLeft);
     void setDesiredSpeedRight(float desiredSpeedRight);
-    static const float COUNTS_PER_TURN;
     void resetCounter();
+    float getSpeedLeft();
+    float getSpeedRight();
+    float getIntegralLeft();
+    float getIntegralRight();
+    float getProportionalLeft();
+    float getProportionalRight();
 
 private:
 
     static const float PERIOD;
-    
+    static const float COUNTS_PER_TURN;
     static const float LOWPASS_FILTER_FREQUENCY;
     static const float KN;
     static const float KP;
+    static const float KI;
+    static const float I_MAX;    
     static const float MAX_VOLTAGE;
     static const float MIN_DUTY_CYCLE;
     static const float MAX_DUTY_CYCLE;
@@ -42,6 +49,8 @@
     float              desiredSpeedRight;
     float              actualSpeedLeft;
     float              actualSpeedRight;
+    float              iSumLeft;
+    float              iSumRight;
     Ticker             ticker;
     
     void               run();
@@ -54,5 +63,3 @@
 
 
 
-
-