Parallax Boe-Bot Student Manual page 120

Hide thumbs Also See for Boe-Bot:
Table of Contents

Advertisement

Page 106 · Robotics with the Boe-Bot
When the supply voltage comes back above 5.2 V, the BASIC Stamp starts running
again, but not at the same place in the program. Instead, it starts from the beginning of
the program. This is actually the same thing that happens when you unplug power and
plug it back in, and it's also the same thing that happens if you press and release the Reset
button on your board.
When the Boe-Bot's batteries are running low, brownouts can cause the program to
restart when you're not expecting it to. This can lead to some really mystifying Boe-Bot
behavior. In some cases, the Boe-Bot will be running whatever course it's programmed
to navigate, and all of the sudden, it might seem to get lost and go in an unexpected
direction. If low batteries are the cause, it could be the fact that the Boe-Bot's program
went back to the beginning and started over again. In other cases, the Boe-Bot can end
up doing a confused dance because every time the servos start turning, it overtaxes the
already low batteries. The program attempts to make the servos turn for a split second,
then restarts, over and over again.
These situations make a program start/reset indicator an extremely useful diagnostic
device as well as a useful robot tool. One way to indicate resets is to include an
unmistakable signal at the beginning of all the Boe-Bot's programs. The signal occurs
every time the power gets plugged in, but it also occurs every time a reset due to
brownout conditions occurs. One effective signal for resets is a speaker that emits a tone
each time the BASIC Stamp program runs from the beginning or resets.
BASIC Stamp HomeWork Board Special Instructions
Although the reset indicator will tell you when the 9 V battery supplying the BASIC Stamp is
running low, it will not tell you when the servo supply (the battery pack) is running low.
You can always tell when your battery pack is running low because the servos will gradually
move slower and slower during normal operation. When you observe this symptom, replace
the dead batteries with new 1.5 V alkaline batteries.
This exercise will introduce a device called a piezoelectric speaker (piezospeaker) that
you can use to generate tones. This speaker can make different tones depending on the
frequency of high/low signals it receives from the BASIC Stamp. The schematic symbol
and part drawing for the piezoelectric speaker are shown in Figure 3-16. This speaker
will be used for emitting the tones when the BASIC Stamp is reset in this activity as well
as in the rest of the activities in this text.

Advertisement

Table of Contents
loading

Table of Contents