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:
38:930469a33001
Parent:
36:8aeb014bd651
Child:
40:1668630544c7
Child:
45:bb33913d4fd2
--- a/PIDController.cpp	Tue Jun 14 15:56:14 2016 +0000
+++ b/PIDController.cpp	Tue Jun 14 17:49:08 2016 +0000
@@ -10,6 +10,13 @@
 // This is called in the main loop on every iteration
 void PIDController::update() {
     
+    #ifndef RUN_TESTS
+    if(this->num_iters < STARTUP_ITERATIONS) {
+        printf("PIDController: not running, startup phase");
+        return;
+    }
+    #endif
+    
     // Control the heater
     // This could be done in the pumping function as well, if needed
     this->set_heating(this->temp->getValue() < 32.0f);