users to programming and the Arduino, but the best and
most detailed help is available on the Arduino website
( arduino.cc) and forums. The Arduino IDE (integrated
development environment) even contains a multitude of
sample programs — many of which we pawed through to
dust off our C programming skills. We found a good
sample program that controlled a motor with a button, and
modified it to fit our needs. With a few more lines of code,
we had a program that would have our simple robot move
back and forth when fending off a pug intruder.
With a program in place and the circuit done, we just
needed to house everything in a robot body. An old tissue
box was the perfect size and could be wrapped like a
present when we were done, so our robotic guardian could
lie in wait undetected. For our drive train, we connected a
cardboard wheel to the DC motor using the motorMate and
a popsicle stick as an axle. We held the motor module in
place with zip ties. We taped the lightweight servos to the
side of the box, with the horns peeking to the outside to
operate swinging arms. We then fastened the rest of the
circuit to the back of the box with another zip tie.
Even with all of our manhandling of the circuit while
placing it in the box, we were very impressed with how well
the magnetic connectors stuck together. Two back wheels
on a free spinning axle completed our present-defending
robot. We covered the robot in wrapping paper and bows
so that it would blend in, and we were ready to test it out.
We set the robot up under a tree, nestled among other
presents. We set a present on the pressure plate and let
Paisley loose. Paisley really does have a predilection to mess
with the presents, and in a few seconds he had knocked
the present from the pressure plate. The present defender
sprang to life, lurching toward Paisley while blaring a buzzer
and swinging its gift bow arms. The robot was surprisingly
effective, and the startled pug backed off of the packages.
For this project, we challenged ourselves to build a
robot limited to the electronics we had in the littleBits kit.
Thanks to the Arduino module and some simple code, we
made a real deal robot that successfully fended off a pug
bent on unwrapping presents early.
Don’t think that means you have to be limited to the
magnetic modules and repurposed tissue boxes. Some of
the projects mentioned above like the spinning replicator
and many more impressive creations that populate the
Makerhub on the littleBits website are amalgamations of
the littleBits modules with other kits like LEGO
littleBits has really embraced the combination of their
modules with other kits by offering things like the brick
adapter, which is a plastic plate that connect a littleBits
mounting board to LEGO pieces. Such a cooperative spirit
seems like an appropriate fit with Arduino, and we think it
will be a great fit with tinkerers everywhere that want to
enhance their projects with littleBits. SV
SERVO 12.2014 75
THE FINAL DEFENDER.
PRESENT PUG PROTECTION.
LYING IN WAIT.