DP / Mbed 2 deprecated RCControlOOPWithThrottle

Dependencies:   mbed

Fork of RCControlOOP by DP

Revision:
1:e694ee3b4a7f
Parent:
0:78e2af20cbf3
Child:
2:e9042e88abf1
--- a/WirelessMousr.cpp	Mon Sep 08 11:32:04 2014 +0000
+++ b/WirelessMousr.cpp	Sun Sep 21 14:43:47 2014 +0000
@@ -16,15 +16,17 @@
     pc.putc(10);
     
     // state machine
-    switch(state) {
+    switch(state)
+    {
     case 's':
       this->stop(); break;
     case 'w':
+      pc.putc('g');
       this->straight(getStraightSpeed()); break;
     case 'a':
-      this->left(getRotateSpeed()); wait(0.25); stop(); break;
+      this->left(getRotateSpeed()); break;
     case 'd':
-      this->right(getRotateSpeed()); wait(0.25); stop(); break;
+      this->right(getRotateSpeed()); break;
     case 'x':
       this->backwards(getStraightSpeed()); break;
     case 'q':
@@ -35,5 +37,9 @@
       this->left(getRotateSlowSpeed()); break;
     case 'c':
       this->right(getRotateSlowSpeed()); break;
+    case '1':
+      this->flipLeft(); break;
+    case '3':
+      this->flipRight(); break;
     }
 }
\ No newline at end of file