This program is for an autonomous robot for the competition at the Hochschule Luzern. http://cruisingcrepe.wordpress.com/ We are one of the 32 teams. http://cruisingcrepe.wordpress.com/ The postition control is based on this Documentation: Control of Wheeled Mobile Robots: An Experimental Overview from Alessandro De Luca, Giuseppe Oriolo, Marilena Vendittelli. For more information see here: http://www.dis.uniroma1.it/~labrob/pub/papers/Ramsete01.pdf

Dependencies:   mbed

Fork of autonomous Robot Android by Christian Burri

Revision:
19:b2f76b0fe4c8
Parent:
18:306d362d692b
Child:
20:01b233b0e606
--- a/main.cpp	Fri May 03 08:35:29 2013 +0000
+++ b/main.cpp	Fri May 03 13:34:34 2013 +0000
@@ -140,8 +140,8 @@
     /**
      * Set the startposition and start the Task for controlling the roboter.
      */
-    //robotControl.setAllToZero(0, 0, PI/2 );
-    robotControl.setAllToZero(START_X_OFFSET, START_Y_OFFSET, PI/2 );
+    robotControl.setAllToZero(0, 0, PI/2 );
+    //robotControl.setAllToZero(START_X_OFFSET, START_Y_OFFSET, PI/2 );
     robotControl.start();
     /*
     pc.baud(460800);
@@ -229,7 +229,39 @@
     /**
      * Close the File PLOTS.txt to read the file after with the computer and draw a diagramm
      */
+     
+     
+    pc.baud(460800);
 
+    pc.printf("********************* MicroBridge 4568 ********************************\n\r");
+    
+    init();
+    
+    // Initialise the ADB subsystem.
+   
+    pc.printf("connection isOpen\n");
+
+    float flt = 0.0f;
+    float flt2 = 0.2f;
+    float flt3 = 1.2f;
+
+    while(1) {
+
+        ADB::poll();
+
+        flt = flt - 0.1f;
+        flt2 = flt2 + 0.2f;
+        flt3 = flt3 - 0.05f;
+        
+        robotControl.setDesiredPositionAndAngle(getDesiredX(), getDesiredY(),  getDesiredTheta());
+        
+        writeActualPosition(robotControl.getxActualPosition(),robotControl.getyActualPosition(), robotControl.getActualTheta());
+
+        //connection->write(sizeof(str),(unsigned char*)&str);
+        wait(1);
+
+    } 
+     
    
      
     state.savePlotFile(s);