Skip to content
Snippets Groups Projects
Commit d2be825e authored by Charles Javerliat's avatar Charles Javerliat Committed by Charles JAVERLIAT
Browse files

wip

parent 6893d3f6
No related branches found
No related tags found
No related merge requests found
...@@ -147,6 +147,8 @@ class CoordinatorNode(): ...@@ -147,6 +147,8 @@ class CoordinatorNode():
while theta_accum < abs(theta): while theta_accum < abs(theta):
dTheta = 0
if theta > 0: if theta > 0:
if self.theta < last_theta: if self.theta < last_theta:
dTheta = abs(2 * pi + self.theta - last_theta) dTheta = abs(2 * pi + self.theta - last_theta)
...@@ -159,6 +161,7 @@ class CoordinatorNode(): ...@@ -159,6 +161,7 @@ class CoordinatorNode():
dTheta = abs(self.theta - last_theta) dTheta = abs(self.theta - last_theta)
theta_accum = theta_accum + dTheta theta_accum = theta_accum + dTheta
if abs(theta_accum - abs(theta)) <= radians(3): if abs(theta_accum - abs(theta)) <= radians(3):
self.set_speed(0, 0.25 if theta > 0 else -0.25) self.set_speed(0, 0.25 if theta > 0 else -0.25)
else: else:
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment