A LineFollower library for ASEE-2014

Dependents:   ASEE-2014

Revision:
1:c319e24af8df
Parent:
0:2623af9e8ef3
--- a/LineFollower.h	Tue Feb 18 04:14:48 2014 +0000
+++ b/LineFollower.h	Fri Feb 21 04:40:34 2014 +0000
@@ -27,12 +27,21 @@
     * @return The value of the Sensor
     */                    
     uint8_t read();
+    
+    /** Follow a line
+    * 
+    * @param    l left drive motor
+    * @param    r  right drive motor
+    */                    
+    void followLine(Motor l, Motor r);
         
     protected:
-    
+    /* Constants */
     #define ROTATE_SPEED    100
-    #define MAXSPEED        200
-    int array[8] {0,0,0,0,0,0,0,0};
+    #define MAXSPEED        1
+    
+    /* Attributes */
+    DigitalIn array[8];
     DigitalIn _ir1;
     DigitalIn _ir2;
     DigitalIn _ir3;