Final Project files for mBed development.

Dependencies:   m3pi mbed

Revision:
12:1aa6b8a74136
Parent:
11:a30f30d3066e
Child:
14:41fa8b95a9ab
--- a/control.c	Sun Nov 16 05:26:24 2014 +0000
+++ b/control.c	Sun Nov 16 09:11:34 2014 +0000
@@ -23,6 +23,7 @@
     fseek(fp, 0L, SEEK_SET);
     contents = (char*)malloc(size);
     fread(contents, size, 1, fp);
+    memcpy(moves, contents, size);
     fclose(fp);
 }
 
@@ -48,20 +49,14 @@
     wait(.5);
 
     while(1) {
-        if(start_button) {
+        if(!start_button) {
             pi.stop();
             goto start;
         }
-        
+        forward(10);
+        right(90);    
         //
         // Right now the robot controller is clearly a very basic
-        // 'hello world' loop that must be changed.
-        forward(10);
-        right(90);
-        forward(10);
-        right(90);
-        forward(10);
-        wait(2);
-        left(180);
+        // 'hello world' loop that must be changed.      
     }
 }
\ No newline at end of file