Final Project files for mBed development.

Dependencies:   m3pi mbed

Revision:
23:e4616259a7f0
Parent:
22:46b9d9b2e35c
Child:
24:b797563776fc
--- a/main.c	Sun Dec 07 04:39:33 2014 +0000
+++ b/main.c	Sun Dec 07 05:55:38 2014 +0000
@@ -379,6 +379,10 @@
         theta = atan(((double) delta_x)/((double) delta_y));
         theta *= 57.29;
         delta_a = theta-angle;
+        if (delta_x < 0 && delta_y < 0) {
+            delta_a += 180;
+        }
+        angle += theta;
         pi.cls();
         pi.locate(0,0);
         pi.printf("a:%f", delta_a);