Final Version from RoboticHackathon 4.-5. April 2015

Dependencies:   Autopilot dillerdasker Rfid mbed

Fork of RoboticHackathon2 by Mathias Lyngklip

Revision:
2:b996c95912b5
Parent:
1:e854d5c12659
Child:
3:9289c1e52ca5
diff -r e854d5c12659 -r b996c95912b5 hack_motor.cpp
--- a/hack_motor.cpp	Sat Apr 05 11:26:42 2014 +0000
+++ b/hack_motor.cpp	Mon Apr 07 06:24:19 2014 +0000
@@ -101,21 +101,45 @@
         HejsA = 0;
         }
         
-void Wheel::venSelv1()
+void Wheel::venSelv1() // Højre
     {
-        M1A.write(0.9); //Set the duty cycle to the wanted percent, from speed variable
+        M1A.write(0.7); //Set the duty cycle to the wanted percent, from speed variable
+        M2A.write(0.0); // -//-
+        M1B = 0;
+        M2B = 0;
+        wait_ms(100);
+        M2A.write(0.7);
+    }
+void Wheel::venSelv2() // Venstre
+    {
+        M1A.write(0.0); //Set the duty cycle to the wanted percent, from speed variable
         M2A.write(0.7); // -//-
         M1B = 0;
         M2B = 0;
-        wait_ms(10);
-        M2A.write(0.9);
+        wait_ms(100);
+        M1A.write(0.7);
     }
-void Wheel::venSelv2()
+void Wheel::venSelv3() // Skarp højre
     {
+        M1A.write(0.8);
+        M2A.write(0.8);
+        wait_ms(25);
         M1A.write(0.7); //Set the duty cycle to the wanted percent, from speed variable
-        M2A.write(0.9); // -//-
+        M2A.write(0.95); // -//-
         M1B = 0;
+        M2B = 1;
+        wait_ms(10);
+        M1A.write(0.0);
+    }
+void Wheel::venSelv4() // Venstre Skarpt
+    {
+        M1A.write(0.8);
+        M2A.write(0.8);
+        wait_ms(25);
+        M1A.write(0.95); //Set the duty cycle to the wanted percent, from speed variable
+        M2A.write(0.7); // -//-
+        M1B = 1;
         M2B = 0;
         wait_ms(10);
-        M1A.write(0.9);
+        M1A.write(0.0);
     }
\ No newline at end of file