|
![]() |
Max NavigationOne of the first skills your mobile robot must master to be useful is Navigation. There are many factors that will determine how a robot will find it's way around in the world. This article will focus on a economical system where the hardware is limited two sonar units, wheel encoders and a simple Dinsmore compass. Exercise (1): The BoxThe first exercise in mobile robot navigation will only use one wheel encoder to determine the distance traveled. The goal is to program the robot to travel in a simple square. Robot Actions: Step 1: Turn 90 degrees Right Step 2: Move Forward 35 encoder counts Step 3: Turn 90 degrees Right Step 4: Move Forward 35 encoder counts Step 5: Turn 90 degrees Right Step 6: Move Forward 35 encoder counts Step 7: Turn 90 degrees Right Step 8:Move Forward 35 encoder counts The Turns are executed using the encoder to count 8 counts as the robot turns. This is very close to a 90 degree turn and a good place to start. The robot does not know exactly which direction it is facing. In this test the robot was always started about 1 foot way and facing a wall. The problem with this method is that the robot does not have way to know if it is in the correct position at anytime. Each time the pattern is executed to robot ends in a slightly different position. Exercise (2) : CheckpointsAs a robot finds it's way around a room, errors will accumulate and the robot may not be exactly where it thinks it is. On a given path, there should be locations the robot can use the check it's position. For the box example above, the robot checks it's position and orientation at each corner that a wall is near by. The robot uses the front sonar units to check the distance to the wall and also that the robot is parallel to the wall. If the robot is not parallel to the wall, it will make a slight turn to correct this. This distance is then corrected by moving toward the wall or away from the wall. Performing these navigation corrections at key locations along a path during a mission greatly improve the robots ability to end it's journey in the correct location. Robot Actions:Step 0: Check distance from wall, orientation to wall. Step 1: Turn 90 degrees Right Step 2: Move Forward 35 encoder counts Step 3: Check distance from wall, orientation to wall. Step 4: Turn 90 degrees Right Step 5: Move Forward 35 encoder counts Step 6: Turn 90 degrees Right Step 7: Move Forward 35 encoder counts Step 8: Check distance from wall, orientation to wall. Step 9: Turn 90 degrees Right Step 10:Move Forward 35 encoder counts (Short video of a Max 99 making an adjustment at a checkpoint) Exercise (3) : Light Following Adding a light sensor is both quick and simple. In this exercise two photo resistors and two 10k ohm resistors are used to create two simple light sensors. These sensors are mounted on the robot and use the HC11 MC bus 5 VDC power supply. Two of the eight A/D channels are used to read the output of the simple light sensors. The photoresistors change resistance in the presence of light. The robot will turn toward the sensors which is reading the most light. (Short video of a MAX following a lamp) Exercise (4) : Compass navigation A Max accurately navigate from point to point with just a single pulse wheel encoder and a compass module. In this example the robot rotates to face a pre-determined direction. The robot will then use a simple PID control loop to remain on this course. Markers have been placed on the floor to represent target locations. Navigation is repeatable within a few inches using just a single encoder and one compasses. For more accurate navigation use the Vector 2X or Devantech I2C compass modules. (Short video a Max 99 using a compass) ....to be continued.... |
![]() |
|