Skip to content
This repository has been archived by the owner on Oct 29, 2024. It is now read-only.

Commit

Permalink
ds
Browse files Browse the repository at this point in the history
  • Loading branch information
LeProblemeEDMN committed Jun 1, 2024
1 parent b592833 commit 78e010f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions raspberrypi/daughter_cards/wheeledbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,7 @@ def goto_stop(self, x, y,sensors, theta=None, direction=None, finalangle=None, l
rPos=self.get_position()
radiusRobot=370
ang=rPos[2]%(2*math.pi)
print(ang,theta)
#fait en sorte que |ang-theta|<pi pr trouver le sens du robot
if(theta-ang>math.pi):
theta-=2*math.pi
Expand Down
4 changes: 2 additions & 2 deletions raspberrypi/tests/wbTest.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@
print("Sensors:",sensors)

wheeledbase.start_match()
wheeledbase.goto_stop(0,0, sensors,finalangle=-math.pi/2)
wheeledbase.goto_stop(0,0, sensors,theta=-math.pi/2)
time.sleep(1)
wheeledbase.goto_stop(0,0, sensors,finalangle=0)
wheeledbase.goto_stop(0,0, sensors,theta=0)
while 1:
print(wheeledbase.get_position(),sensors.get_all_sensors())

0 comments on commit 78e010f

Please sign in to comment.