Page 42 · Robotics with the Boe-Bot
Standard Servos vs. Continuous Rotation Servos: Standard servos are designed to
receive electronic signals that tell them what position to hold. These servos control the
positions of radio controlled airplane flaps, boat rudders, and car steering. Continuous
rotation servos receive the same electronic signals, but instead of holding certain positions,
they turn at certain speeds and directions.
controlling wheels and pulleys.
ACTIVITY #1: HOW TO TRACK TIME AND REPEAT ACTIONS
Controlling a servo motor's speed and direction involves a program that makes the
BASIC Stamp send the same message, over and over again. The message has to repeat
itself around 50 times per second for the servo to maintain its speed and direction. This
activity has a few PBASIC example programs that demonstrate how to repeat the same
message over and over again and control the timing of the message.
Displaying Messages at Human Speeds
You can use the
PAUSE
executing the next command.
PAUSE Duration
The number that you put to the right of the
argument, and it's the value that tells the BASIC Stamp how long it should wait before
moving on to the next command. The units for the
of a second (ms). So, if you want to wait for one second, use a value of 1000. Here's
how the command should look:
PAUSE 1000
If you want to wait for twice as long, try:
PAUSE 2000
A second is abbreviated "s". In this text, when you see 1 s, it means one second.
A millisecond is one thousandth of a second, and it is abbreviated "ms". The command
PAUSE 1000 delays the program for 1000 ms, which is 1000/1000 of a second, which is one
second, or 1 s. Got it?
command to tell the BASIC Stamp to wait for a while before
PAUSE
Continuous rotation servos are ideal for
command is called the
argument are thousandths
Duration
Duration
Need help?
Do you have a question about the Boe-Bot and is the answer not in the manual?
Questions and answers