Sonar sensor and mounting

The sonar sensor of the robot allows it to find the goal.  This is performed once it has the ball.  It performs a 360 degree scan in 60 segments.  If it is unsuccessful at finding the goal, it will identify the middle of the room, head to it, and scan again.

The actual physical mounting of the sensor was difficult, due to its large size.  Our mounting solution is shown below.

The entire search and movement behaviour is controlled from one function.  The code for this is here.

The servo which turns the sensor was geared up so that the range of servo movement allowed for a 360 degree turn.  This is easily done by attaching a gear to the servo head with the supplied screws.

There were some problems associated with the sonar sensor:

  1. It can scan in one of two modes.  One for close up and one for distance work, however as we needed to use large distances (over 6 foot) the close up results were erratic.  This lead to problems 'seeing' close up walls.
  2. To use the sensor a permanent modification to the Handy Board is needed.
  3. Even readings taken statically can vary a lot, so a large sample is suggested.
  4. Different materials reflect different amounts of sonar e.g. a sheet of card will reflect better than a sheet of glass.  This has implications when designing the environment for the robot.