Parallax Boe-Bot Assembly page 29

Mini-sumo robotics assembly documentation and programming
Hide thumbs Also See for Boe-Bot:
Table of Contents

Advertisement

The core of the program, at the label Main , is broken down into several sections:
Move forward slowly
Pivot turn 90 degrees on left wheel
Move forward quickly
Pivot turn 180 degrees on right wheel
Move forward quickly
Spin turn (rotates SumoBot around its own center) 360 degrees
Hold position
Note: If the SumoBot starts by backing up, the motor connections are reversed. Move
the power switch to position 0 (off), change the connections, and then move the power
switch back to position 2 to retest. You could change the firmware as well, but then
you'll need to change all the SumoBot programs included in this kit.
Each movement section is constructed using a FOR-NEXT control loop to give the
motors enough time to perform the actual movements. You may notice that the SumoBot
does not move precisely as the code dictates that it should. Do not be alarmed. Small
variations in motors may cause the SumoBot to veer slightly to one side or the other
when it should be moving straight.
This condition can be corrected (more precisely, tuned) by modifying the speed constants
for the motors. If, for example, the SumoBot veers to the left when it should be moving
straight, you may want to reduce the right motor speed a bit to correct the path of travel.
The same holds true for the turns. In this case, the motor speed is not the culprit. To
adjust turns, modify the FOR-NEXT loop end-point value and retest. If the SumoBot
turns too much, reduce the loop end-point. If it doesn't turn quite enough, increase the
loop end-point value.
Chapter 2: SumoBot Locomotion · Page 19

Advertisement

Table of Contents
loading

This manual is also suitable for:

QuadcrawlerToddlerSumobotHexcrawler

Table of Contents