Matthias Praja / Mbed 2 deprecated All-15Final

Dependencies:   mbed

Fork of All-15 by Ladner-Praja

Revision:
14:7560cbb335f1
Parent:
13:2100fbde6d34
Child:
15:dbb2ef352057
diff -r 2100fbde6d34 -r 7560cbb335f1 main.cpp
--- a/main.cpp	Tue Jul 07 22:31:37 2015 +0000
+++ b/main.cpp	Tue Jul 07 22:34:07 2015 +0000
@@ -79,7 +79,7 @@
             else
             {
                 output = 0xff;
-                if((myline&0x01)>0)
+                if((myline&0x08)>0)
                 {
                     MotorR_FORWARD = 0;  
                     MotorR_EN=0;
@@ -88,16 +88,16 @@
                 else
                 {
                     MotorR_FORWARD = 1;  
-                    if((myline&0x02)>0)
+                    if((myline&0x04)>0)
                     {
-                        MotorR_EN=0.10;
+                        MotorR_EN=0.25;
                         output=output&(~0x40);
                     }
                     else
-                        MotorR_EN=0.25;
+                        MotorR_EN=0.5;
                 }
                 
-                if((myline&0x08)>0)
+                if((myline&0x01)>0)
                 {
                     MotorL_EN=0;
                     MotorL_FORWARD = 0;  
@@ -106,13 +106,13 @@
                 else
                 {
                     MotorL_FORWARD = 1;  
-                    if((myline&0x04)>0)
+                    if((myline&0x02)>0)
                     {
-                        MotorL_EN=0.10;
+                        MotorL_EN=0.25;
                         output=output&(~0x20);
                     }
                     else
-                        MotorL_EN=0.25;
+                        MotorL_EN=0.5;
                 }
                 myled=myline;
                 i2c.start();