First team commit

Dependents:   ASEE-2014

Fork of LineFollower by Christopher Bradford

Files at this revision

API Documentation at this revision

Comitter:
blu12758
Date:
Mon Mar 24 00:49:23 2014 +0000
Parent:
10:a9233fa6240d
Commit message:
yeah

Changed in this revision

LineFollower.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/LineFollower.cpp	Mon Mar 24 00:44:31 2014 +0000
+++ b/LineFollower.cpp	Mon Mar 24 00:49:23 2014 +0000
@@ -35,7 +35,7 @@
                 sum += (i+1);
                 count++;
             }
-        if(count == 0) return 0;
+        if(count == 0 || count == 8) return -1;
         float center = sum/count;
         //Change the sp_adj_mult to change how drastic your adjustments are. 0-1
         float speed_adjust = sp_adj_mult*(center-4.5)/(3.5)*maxspeed;