Datasheet
Page 146· Applied Robotics with the SumoBot
With some experimentation, you can also control the speed of the servos too. Note from
Figure 4-3 that the relationship between pulse width and rotational velocity is not simply
linear. For example, a
Duration of 700 is still pretty close to full speed clockwise, but
as you increase to 710, 720, 730, and so on, there should be a noticeable reduction in
speed. The closer
Duration is to 750, the slower the servo will turn. Likewise, 800 is
still pretty close to full speed counterclockwise, but as
Duration gets closer to 750, the
servo will rotate counterclockwise more slowly.
Figure 4-3 PULSOUT Duration vs. Rotational Velocity for Parallax Continuous Rotation Servo
ServoControlExample.bs2 demonstrates how to use
PULSOUT Duration and FOR...NEXT
loop
EndValue arguments to determine the SumoBot's maneuver and the time the
SumoBot spends executing that maneuver.
Example Program: ServoControlExample.bs2
√ Enter, save, and run the ServoControlExample.bs2.
√ Verify that the SumoBot executes each of the maneuvers mentioned in the
comments.
Speed Reduces
Pulse Width, µs 1300 1350 1400 1450 1500 1550 1600 1650 1700
PULSOUT Duration 650 675 700 725 750 775 800 825 850
Full Speed
Clockwise
Full Speed
Counterclockwise
Full
Stop
Speed Reduces
60
40
20
0
-20
-40
-60
Rotational Velocity, RPM