• Keine Ergebnisse gefunden

ActivMedia robots trapezoidal velocity profile

• Befehl: Fahre 95 cm

• Trapez-Kurve = Sollwerte

• Regelung: 50ms Zyklus, PID-Regler, Eingabe = Sollwerte, Ausgabe = PWM

• Regelung: 50ms Zyklus, PID-Regler, Eingabe = Sollwerte, Ausgabe = PWM der Motoren

Parameterfiles

Woher kennt das Clientprogramm die Anzahl der Sonarsensoren?

Client nimmt Verbindung zum Roboter auf Client nimmt Verbindung zum Roboter auf

Roboter meldet sich mit Class (bei uns Pioneer) und Subclass P3 melden sich als Subclass p3dx-sh oder p2d8+

P2 meldet sich als Subclass p2ce

Client lädt zur Subclass xxx die passende Parameterdatei params/xxx.p

• also p2ce.p oder p3dx-sh.p oder p2d8+.p

Parameterfile in ARIA – z.B. p3dx.p

Section General settings ;SectionFlags for General settings:

Class Pioneer ; general type of robot Subclass p3dx ; specific type of robot Subclass p3dx ; specific type of robot RobotRadius 250 ; radius in mm

RobotDiagonal 120 ; half-height to diagonal of octagon

RobotWidth 425 ; width in mm

RobotLength 511 ; length in mm of the whole robot

RobotLengthFront 210 ; length in mm to the front of the robot (if this is 0 RobotLengthRear 301 ; length in mm to the rear of the robot (if this is 0 Holonomic true ; turns in own radius

MaxRVelocity 500 ; absolute maximum degrees / sec MaxRVelocity 500 ; absolute maximum degrees / sec MaxVelocity 2200 ; absolute maximum mm / sec

MaxLatVelocity 0 ; absolute lateral maximum mm / sec HasMoveCommand false ; has built in move command

RequestIOPackets false ; automatically request IO packets

RequestEncoderPackets false ; automatically request encoder packets

Parameterfile in ARIA – z.B. p3dx.p

Section Conversion factors

;SectionFlags for Conversion factors:

AngleConvFactor 0.001534 ; radians per angular unit (2PI/4096) DistConvFactor 1 ; multiplier to mm from robot units DistConvFactor 1 ; multiplier to mm from robot units VelConvFactor 1 ; multiplier to mm/sec from robot units

RangeConvFactor 1 ; multiplier to mm from sonar units DiffConvFactor 0.0056 ; ratio of angular velocity to wheel Vel2Divisor 20 ; divisor for VEL2 commands

GyroScaler 1.626 ; Scaling factor for gyro readings

Section Accessories the robot has

;SectionFlags for Accessories the robot has:

;SectionFlags for Accessories the robot has:

TableSensingIR false ; if robot has upwards facing table sensing IR NewTableSensingIR false ; if table sensing IR are sent in IO packet

FrontBumpers false ; if robot has a front bump ring

NumFrontBumpers 5 ; number of front bumpers on the robot RearBumpers false ; if the robot has a rear bump ring

NumRearBumpers 5 ; number of rear bumpers on the robot

Parameterfile in ARIA – z.B. p3dx.p

Section Sonar parameters

SonarNum 8 ; number of sonar on the robot

; SonarUnit <sonarNumber> <x position, mm> <y position, mm> <heading of disc, degrees>

SonarUnit 0 69 136 90 SonarUnit 0 69 136 90 SonarUnit 1 114 119 50 SonarUnit 2 148 78 30 SonarUnit 3 166 27 10 SonarUnit 4 166 -27 -10 SonarUnit 5 148 -78 -30 SonarUnit 6 114 -119 -50 SonarUnit 7 69 -136 -90

Section IR parameters

IRNum 0 ; number of IRs on the robot

; IRUnit <IR Number> <IR Type> <Persistance, cycles> <x position, mm> <y position, mm>

Parameterfile in ARIA – z.B. p3dx.p

Section Movement control parameters ; if these are 0 the parameters from robot flash will be used, otherwise these values will be used

;SectionFlags for Movement control parameters:

;SectionFlags for Movement control parameters:

SettableVelMaxes true ; if TransVelMax and RotVelMax can be set

TransVelMax 0 ; maximum desired translational velocity for the robot RotVelMax 0 ; maximum desired rotational velocity for the robot SettableAccsDecs true ; if the accel and decel parameters can be set

TransAccel 0 ; translational acceleration TransDecel 0 ; translational deceleration RotAccel 0 ; rotational acceleration RotAccel 0 ; rotational acceleration RotDecel 0 ; rotational deceleration

HasLatVel false ; if the robot has lateral velocity

LatVelMax 0 ; maximum desired lateral velocity for the robot LatAccel 0 ; lateral acceleration

LatDecel 0 ; lateral deceleration

Parameterfile in ARIA – z.B. p3dx.p

Section GPS parameters

GPSPX 0 ; x location of gps receiver antenna on robot, mm GPSPY 0 ; y location of gps receiver antenna on robot, mm GPSPY 0 ; y location of gps receiver antenna on robot, mm GPSType standard ; type of gps receiver (trimble, novatel, standard)

GPSPort COM2 ; port the gps is on

GPSBaud 9600 ; gps baud rate (9600, 19200, 38400, etc.)

Section Compass parameters

CompassType robot ; type of compass: robot (typical configuration), or

; serialTCM (computer serial port)

CompassPort ; serial port name, if CompassType is serialTCM CompassPort ; serial port name, if CompassType is serialTCM

Parameterfile in ARIA – z.B. p3dx.p

Section Laser parameters

LaserType lms2xx ; type of laser

LaserPortType serial ; type of port the laser is on LaserPortType serial ; type of port the laser is on LaserPort COM4 ; port the laser is on

LaserAutoConnect true ; if the laser connector should autoconnect this laser or not LaserFlipped false ; if the laser is upside-down or not

LaserPowerControlled false ; if the power to the laser is controlled by serial LaserMaxRange 0 ; Max range to use for the laser, 0 to use default

LaserCumulativeBufferSize 0 ; Cumulative buffer size to use for the laser, 0 to use default LaserX 21 ; x location of laser, mm

LaserY 0 ; y location of laser, mm LaserY 0 ; y location of laser, mm LaserTh 0 ; rotation of laser, deg

LaserZ 0 ; height of the laser off the ground, mm (0 means unknown) LaserStartingBaudChoice 38400 ; StartingBaud for the sensor (leave blank for default, use this to

have a larger StartingBaud)

LaserAutoBaudChoice ; AutoBaud for the sensor (leave blank for default, use this to have a larger units)

PioneerRobotModels.world.inc

Der Simulator kann verschiedene Robotermodelle, Laserscanner, Sonarsensoren usw. simulieren

Die Definition der SIMULIERTEN Roboter und Sensoren befindet sich im File Die Definition der SIMULIERTEN Roboter und Sensoren befindet sich im File

MobileSim\PioneerRobotModels.world.inc Beispiel:

Definition eines P3DX für den Simulator im File PioneerRobotModels.world.inc

Definition eines P3DX für den Simulator in PioneerRobotModels.world.inc

# Model for a p3dx differential-drive robot base with sonar.

define p3dx pioneer (

pioneer_robot_subtype "p3dx„

# Speed profile:

# Speed profile:

max_speed [1.0 0 1.74]

accel [0.3 0 1.74]

decel [0.3 0 1.74]

# Body shape:

origin [-0.04465 0.0 0.0]

size [0.511 0.4]

polygons 1

polygon[0].points 8

polygon[0].point[0] [-0.12 0.2555] polygon[0].point[1] [0.12 0.2555]

polygon[0].point[0] [-0.12 0.2555] polygon[0].point[1] [0.12 0.2555]

polygon[0].point[2] [0.2 0.12] polygon[0].point[3] [0.2 -0.12]

polygon[0].point[4] [0.12 -0.2555] polygon[0].point[5] [-0.12 -0.2555]

polygon[0].point[6] [-0.2 -0.12] polygon[0].point[7] [-0.2 0.12]

polygon[0].filled 1 ……

)

Definition eines P3DX für den Simulator in PioneerRobotModels.world.inc

define p3dx pioneer ( …..

# client protocol conversion factors

pioneer_distconv 0.485 pioneer_diffconv 0.0056 pioneer_velconv 1.0

pioneer_velconv 1.0

# Sonar:

pioneerSonar ( scount 8

spose[0] [0.069 0.136 90] spose[1] [0.114 0.119 50]

spose[2] [0.148 0.078 30] spose[3] [0.166 0.027 10]

spose[4] [0.166 -0.027 -10] spose[5] [0.148 -0.078 -30]

spose[6] [0.114 -0.119 -50] spose[7] [0.069 -0.136 -90]

)

sicklms200( pose [0 0 0] ) sicklms200( pose [0 0 0] ) )

define p3dx-noerr p3dx ( odom_error [0 0 0]

)

Definition eines Sonars für den Simulator in PioneerRobotModels.world.inc

# Sonar array

define pioneerSonar ranger (

sview [0.1 5.0 30] # min (m), max (m), field of view (deg)

noise 0.0005 # sonar is pretty stable, actually

# If we use projection_type "closest" then you can get slightly

# more complex sonar behavior, which can be tuned with these parameters:

# more complex sonar behavior, which can be tuned with these parameters:

#projection_type "closest"

#projection_res 6 # Test a sensor's field of view at a resolution of 6 degrees

#enable_throwaway 1

#throwaway_thresh 0.4 # Test range delta to consider throwing reading away

#throwaway_prob 0.8 # Probability of throwing a sensor reading away

Definition eines Lasersscanners für den Simulator in PioneerRobotModels.world.inc

# SICK LMS-200 laser rangefinder configured for 32m range define sicklms200 laser (

range_min 0.0 range_max 32.767 range_min 0.0 range_max 32.767 samples 181 fov 180.0

color "LightBlue„ size [0.155 0.15]

#height 0.195 # Uncomment to enable

laser_beam_height 0.08 # approx, it actually can vary a few cm in real life laser_return 1 ranger_return 1

blobfinder_return 0 fiducial_return 0

noise 0.0075 # Adds uniform random number in [-0.0075, 0.0075] meters noise 0.0075 # Adds uniform random number in [-0.0075, 0.0075] meters reading_angle_error 0.0007 # Adds uniform random number in

[-0.0007,0.0007] radians laser_return_rules 3

….

)

Definition eines Lasersscanners für den Simulator in PioneerRobotModels.world.inc

# SICK LMS-200 laser rangefinder configured for 32m range define sicklms200 laser (

…..

# Turn reflector values >1 to 1 if more than 30m away

# Turn reflector values >1 to 1 if more than 30m away laser_return_rule[0].model_gt 1

laser_return_rule[0].condition "outside_range"

laser_return_rule[0].range 30 laser_return_rule[0].detect 1

# Turn reflector values >1 to 1 if more than 90deg away laser_return_rule[1].model_gt 1

laser_return_rule[1].condition "outside_angle"

laser_return_rule[1].angle 90 laser_return_rule[1].detect 1 laser_return_rule[1].detect 1

# Turn reflector value 2 into 33 (the actual value the SICK returns to ARIA) laser_return_rule[2].model_eq 2

laser_return_rule[2].detect 33 )