No message
authorJordi <jordiguerrero@gmail.com>
Sat, 13 Feb 2016 15:09:06 +0000 (15:09 +0000)
committerJordi <jordiguerrero@gmail.com>
Sat, 13 Feb 2016 15:09:06 +0000 (15:09 +0000)
PID_test.py

index 6e99cf0..a167e92 100644 (file)
@@ -24,9 +24,11 @@ fTicksLeft = "/sys/devices/ocp.3/48302000.epwmss/48302180.eqep/position"
 fTicksRight = "/sys/devices/ocp.3/48304000.epwmss/48304180.eqep/position"
 
 TicksxRevolution = 1200
-WheelRadius = 16
+#WheelRadius = 16
+WheelRadius = 31.8/2
 #WheelDistance = 85.5
-WheelDistance = 89
+#WheelDistance = 89
+WheelDistance = 88.9
 
 global distance
 
@@ -214,9 +216,10 @@ time.sleep(0.02)
 
 measureDistance();
 
-#it = iter([400,0,400,400,0,400,200,200,0,0,400,0,400,400,0,400,200,200,0,0])
+it = iter([400,0,400,400,0,400,200,200,0,0,400,0,400,400,0,400,200,200,0,0])
+#it = iter([400,0,400,400,0,400,200,200,0,0])
 #it = iter([200,0,200,200,0,200,0,0])
-it = iter([200,50])
+#it = iter([200,50])
 for xT, yT in zip(it, it):
     xTarget = xT
     yTarget = yT