Page 70 ·
Robotics with the Boe-Bot
√
If the servo does not turn, skip to the Your Turn section on page 70 so that you
can test and center the other servo that’s connected to P13.
What's a Potentiometer?
A potentiometer is kind of like an adjustable resistor. The
resistance of a potentiometer is adjusted with a moving part. On some potentiometers, this
moving part is a knob or a sliding bar, others have sockets that can be adjusted with
screwdrivers. The resistance of the potentiometer inside the Parallax Continuous Rotation
servo is adjusted with a #1 point Phillips screwdriver tip. You can learn more about
potentiometers in
What's a Microcontroller?
and
Basic Analog and Digital
student guides.
Your Turn – Centering the Servo Connected to P13
√
Repeat the process for the servo connected to P13 using this program:
Example Program: CenterServoP13.bs2
' Robotics with the Boe-Bot - CenterServoP13.bs2
' This program sends 1.5 ms pulses to the servo connected to
' P13 for manual centering.
' {$STAMP BS2}
' {$PBASIC 2.5}
DEBUG "Program Running!"
DO
PULSOUT 13, 750
PAUSE 20
LOOP
Remember to completely disconnect power when you are done.
If you have a Board of Education Rev C.
√
Move the 3-position switch to position-0.
If you have a BASIC Stamp HomeWork Board:
√
Unplug the 9 V battery from the battery clip to disconnect power to the HomeWork
Board.
√
Remove one battery from the battery pack.