corrected error assignation of motors in methods right and left. now it work fun. Added function to read calibrated sensors data.

Fork of m3pi by Chris Styles

Files at this revision

API Documentation at this revision

Comitter:
chris
Date:
Mon Nov 01 16:18:55 2010 +0000
Parent:
1:816a80dcc1a3
Child:
3:c38d2f980494
Commit message:
Corrected code line_position function

Changed in this revision

m3pi.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/m3pi.cpp	Fri Oct 29 13:30:11 2010 +0000
+++ b/m3pi.cpp	Mon Nov 01 16:18:55 2010 +0000
@@ -101,7 +101,7 @@
     pos = _ser.getc();
     pos += _ser.getc() << 8;
     
-    float fpos = (pos - 2048)/2048;
+    float fpos = ((float)pos - 2048.0)/2048.0;
     return(fpos);
 }