Program for the water play project for the course Software Testing Practical 2016 given at the VU University

Dependencies:   mbed DRV88255 TextLCD Ping mbed-rtos

Revision:
71:38bb6bf09933
Parent:
70:642153418c6e
Child:
78:a44ad011dd41
--- a/PIDController.cpp	Mon Jun 20 13:31:09 2016 +0000
+++ b/PIDController.cpp	Tue Jun 21 12:09:12 2016 +0000
@@ -37,8 +37,9 @@
         ml_int = std::max(1, ml_int);
     
         cout << "PIDCONTROLLER: need to pump " << ml_int << " (" << ml << ")" << " ml of salty water\r\n";
+        printf("need to pump %d ml of salty water\r\n",ml_int);
         
-        //this->pump_salt_water(ml_int);
+        this->pumpSaltWater(ml_int);
     
     } else if(s >= SALT_MAX_UNDESIRED) {
 
@@ -47,8 +48,9 @@
         ml_int = std::max(1, ml_int);
         
         cout << "PIDCONTROLLER: need to pump " << ml_int << " (" << ml << ")" << " ml of fresh water\r\n";
+        printf("need to pump %d ml of fresh water\r\n",ml_int);
         
-        //this->pump_fresh_water(ml_int);     
+        this->pumpFreshWater(ml_int);     
         
     }
 }
@@ -163,7 +165,9 @@
 }
 
 void PIDController::doTestingStuff(int ml) {
-    while(1)
+    while(1) {
         this->pumpSaltWater(ml);
+        //this->pumpFreshWater(ml);
+    }
 }