Each maneuver involves two wheel speeds and an amount of time.
To decrease the distance of a forward or backward maneuver, you have a choice of decreasing either the speed or the time. Likewise, distance will increase with either a longer time traveled or a higher speed. Increasing the speed to increase distance only works if the servos are not already going at top speed though.
Turns can also be greater or smaller angles, and speed and time are the two variables that can be adjusted. If speed remains the same, but time is reduced, the angle turned will be less. Alternatively, the maneuver time can be left unchanged and the wheel speeds can be increased or decreased for smaller or larger angle turns.
When the SumoBot can “see” its opponent, top speed maneuvers to either start pushing or get out of the way are common. If the SumoBot is searching for its opponent, it is sometimes better to move slower while scanning left and right with sensors.
Try This
Let’s take a closer look at how changing the maneuver times changes the distances traveled and angles turned.
- Modify your maneuver program so that instead of taking 3 seconds for each maneuver, it takes 2 seconds for the forward and backward maneuvers and 0.75 seconds for each turn.
- Test the program, and verify that it travels about ⅔ of the previous forward/backward distances and much shorter turns.
- Tune the 750 times so that the SumoBot executes a 90⁰ left turn followed by a 90⁰ right turn.