
Joan Horvath/Rich Cameron
PROJECT 2: THE FAMILIAR
Let’s move on to design a familiar — an
interactive companion creature that will react to
programmed inputs. For example, a dog might
wag its tail in response to being moved in one of
the ways that the micro:bit recognizes, or a turtle
might pull its head in and out in response to the
micro:bit being touched on its logo.
A servomotor (Figure
H
) is used to move
an attached “horn” to a specified angle. The
micro:bit’s power and ground connections can
support either lighting an LED strip or moving
a servo, but not both at once. (In principle, you
could attach both if there was separate power
available ...