Page 348 - Amphibionics : Build Your Own Biologically Inspired Robot
P. 348
Amphibionics 07 3/24/03 9:13 AM Page 327
Chapter 7 / Turtletron: Build Your Own Robotic Turtle
FIGURE 7.28
H22B1 interrupter
switch package
dimensions and
schematic.
Fabricating the Shaft Encoder
Start by locating the plastic motor mount with six evenly spaced
holes along its outside edge. It is shown in Figure 7.29 and will
function as the encoder disk. Mount it to the end of the robot’s left
motor shaft, opposite to the wheel, using the washer and nut that
were supplied. This small disk only has six holes and six opaque
areas, giving us a rotational accuracy of 30 degrees per state
change, which is sufficient for a small robot like Turtletron. If the
microcontroller is monitoring the interrupter switch and counts 12
state changes, from high to low or vice versa, then the wheel has
made one full rotation. The parts needed to construct the shaft
encoder are listed in Table 7.5.
327