next up previous contents
Next: 7.35 rwi Up: 7. Device Drivers Previous: 7.33 reb   Contents

Subsections


7.34 rflex

Authors

Matt Brewer mbrewer(at)andrew.cmu.edu, Toby Collett t.collett(at)auckland.ac.nz

Synopsis

The rflex_* family of drivers are used to control RWI robots by directly communicating with RFLEX onboard the robot (i.e., Mobility is bypassed). To date, these drivers have been tested on an ATRV-Jr, but they should work with other RFLEX-controlled robots: you will have to determine some parameters to set in the config file, however.

As of March 2003 these drivers have been modified to support the b21r robot, Currently additional support has been added for the power interface and bumper interface. For the pan tilt unit on the b21r please refer to the ptu46 driver. - Toby Collett

Interfaces / Configuration requests

Although all the RFLEX interaction is actually done in a single thread, the different devices are accessed through different Player drivers: Some generic devices (e.g. aio and dio) may be available, but are untested.

Configuration file options

For example configuration files, see umass_ATRVJr.cfg, umass_ATRVMini.cfg and b21r_rflex_lms200.cfg.

IMPORTANT: Due to a number of initilisation issues relating to the multipart nature of the rflex driver the configuration option rflex_done must be set to 1 in the last rflex driver in the config file. This will cause the server to wait until all the rflex driver options have been parsed before launching its main thread. The driver will hang if you do not speify this value

rflex_position

Name Type Default Meaning
rflex_serial_port string none Serial port connected to RFlex device. See note 5.
mm_length string none Length of the robot in millimeters
mm_width string none Width of the robot in millimeters
odo_distance_conversion string none Odometry conversion. See Note 1.
odo_angle_conversion string none Odometry conversion. See Note 2.
default_trans_acceleration string none Set translational acceleration, in mm.
default_rot_acceleration string none Set rotational acceleration, in radians.

rflex_sonar

Name Type Default Meaning
rflex_serial_port string none Serial port connected to RFlex device. See note 5.
range_distance_conversion string none Sonar range conversion factor. See Note 7.
sonar_age string none Prefiltering parameter. See Note 3.
max_num_sonars string none See Note 4.
num_sonars string none See Note 4.
num_sonar_banks string none See Note 4.
num_sonars_possible_per_bank string none See Note 4.
num_sonars_in_bank string none See Note 4.
mmrad_sonar_poses string none Sonar positions and directions. See Note 6.

rflex_bumper

Name Type Default Meaning
rflex_serial_port string none Serial port connected to RFlex device. See note 5.
bumper_count int none Number of bumper panels
bumper_def float tuple none Tuple of geometry for each bumper
rflex_bumper_address int 64 The base address of first bumper in the DIO address range

rflex_ir

Name Type Default Meaning
rflex_serial_port string none Serial port connected to RFlex device. See note 5.
rflex_base_bank int 0 Base IR Bank
rflex_bank_count int 0 Number of banks in use
rflex_banks int tuple [0] Number of IR sensors in each bank
pose_count int 0 Total Number of IR sensors
ir_min_range int 0 Min range of ir sensors (mm) (Any range below this is returned as 0)
ir_max_range int 0 Max range of ir sensors (mm) (Any range above this is returned as max)
rflex_ir_calib float tuple [1 1] IR Calibration data (see Note 8)
poses float tuple [0] x,y,theta of sensors (mm, mm, deg)

rflex_power

Name Type Default Meaning
rflex_serial_port string none Serial port connected to RFlex device. See note 5.
rflex_power_offset int 0 The calibration constant for the power calculation in decivolts

Notes

  1. Since the units used by the Rflex for odometry appear to be completely arbitrary, this coefficient is needed to convert to millimeters: mm = (rflex units) / (odo_distance_conversion). These arbitrary units also seem to be different on each robot model. I'm afraid you'll have to determine your robot's conversion factor by driving a known distance and observing the output of the RFlex.
  2. Conversion coefficient for rotation odometry: see odo_distance_conversion. Note that heading is re-calculated by the Player driver since the RFlex is not very accurate in this respect. See also Note 1.
  3. Used for prefiltering: the standard Polaroid sensors never return values that are closer than the closest obstacle, thus we can buffer locally looking for the closest reading in the last "sonar_age" readings. Since the servo tick here is quite small, you can still get pretty recent data in the client.
  4. These values are all used for remapping the sonars from Rflex indexing to player indexing. Individual sonars are enumerated 0-15 on each board, but at least on my robots each only has between 5 and 8 sonar actually attached. Thus we need to remap all of these indexes to get a contiguous array of N sonars for Player.

  5. The first RFlex device (position, sonar or power) in the config file must include this option, and only the first device's value will be used.
  6. This is about the ugliest way possible of telling Player where each sonar is mounted. Include in the string groups of three values:"x1 y1 th1 x2 y2 th2 x3 y3 th3 ...". x and y are mm and theta is radians, in Player's robot coordinate system.
  7. Used to convert between arbitrary sonar units to millimeters: mm = sonar units / range_distance_conversion.
  8. Calibration is in the form Range = (Voltage/a)b and stored in the tuple as [a1 b1 a2 b2 ...] etc for each ir sensor.


next up previous contents
Next: 7.35 rwi Up: 7. Device Drivers Previous: 7.33 reb   Contents
2004-06-02