From 45e3ef9221d905d8a3da0fc7e19899352d646fee Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Sat, 9 May 2009 01:42:11 +0200 Subject: * digital/asserv, host/simu/robot/aquajim: - use real robot dimension. --- host/simu/robots/aquajim/model/bag.py | 10 +++++----- host/simu/robots/aquajim/view/robot.py | 7 +++---- 2 files changed, 8 insertions(+), 9 deletions(-) (limited to 'host/simu/robots') diff --git a/host/simu/robots/aquajim/model/bag.py b/host/simu/robots/aquajim/model/bag.py index 6cbc52ef..ace646b6 100644 --- a/host/simu/robots/aquajim/model/bag.py +++ b/host/simu/robots/aquajim/model/bag.py @@ -42,15 +42,15 @@ class Bag: self.elevator_door) self.distance_sensor = [ DistanceSensorSharps (link_bag.io.adc[0], scheduler, table, - (150, 150), 0, (self.position, )), + (50, 130), 0, (self.position, )), DistanceSensorSharps (link_bag.io.adc[1], scheduler, table, - (150, 0), 0, (self.position, )), + (50, -130), 0, (self.position, )), DistanceSensorSharps (link_bag.io.adc[2], scheduler, table, - (150, -150), 0, (self.position, )), + (50, 0), 0, (self.position, )), DistanceSensorSharps (link_bag.io.adc[3], scheduler, table, - (-150, 100), pi, (self.position, )), + (0, 130), pi, (self.position, )), DistanceSensorSharps (link_bag.io.adc[4], scheduler, table, - (-150, -100), pi, (self.position, )), + (0, -130), pi, (self.position, )), ] self.path = link_bag.io.path diff --git a/host/simu/robots/aquajim/view/robot.py b/host/simu/robots/aquajim/view/robot.py index 8974b179..713a30c4 100644 --- a/host/simu/robots/aquajim/view/robot.py +++ b/host/simu/robots/aquajim/view/robot.py @@ -46,15 +46,14 @@ class Robot (simu.inter.drawable.Drawable): self.trans_rotate (self.angle) self.trans_translate (self.pos) # Draw robot body. - # TODO - self.draw_polygon ((150, 150), (150, -150), (-150, -150), - (-150, 150), (150, 150)) + self.draw_polygon ((150, 155), (-90, 155), (-150, 70), + (-150, -70), (-90, -155), (150, -155)) # Draw Robot axis. axes_fill = '#404040' self.draw_line ((-150, 0), (150, 0), fill = axes_fill, arrow = 'last') # Draw Robot wheels. - f = 150 # Wheel spacing + f = 142 + 2 * 31.5 - 13.5 # Wheel spacing wr = 63 / 2 # Wheel diameter self.draw_line ((0, +f / 2), (0, -f / 2), fill = axes_fill) self.draw_line ((-wr, f / 2), (+wr, f / 2), fill = axes_fill) -- cgit v1.2.3