Animatronic Eyes and Wii Nunchuck Part 2 using Arduino
After I built the animatronic eyes in PART 1, I wanted to complete the face with a voice and possibly moving eyebrows. If you look back at my PART 1, you’ll see that for the base I used a model from Thingiverse. Once you have the model 3D printed, you will need to add in the 9 gram servos.
A quick check of Ebay gives you Tower Pro MG 90 S MG90s Full Metal Gear 9 gram Servo. They are very inexpensive at about $5.00 each.
Once you get your servos, you’ll also need hardware between the servo and the eye and eyelids. You will need Dubro EZ connectors ($9/dozen), threaded rods ( $3/six), and ball links ( $18/dozen for the heavy duty ones). If you live in a larger city ( larger than mine) it would be best to go to a hobby store and purchase the parts so you can see the size and how the connections work. Otherwise, there are many online stores with remote control parts.
After you get it all connected, it’s time to figure out how to adjust the servos. If you send a command to move the servo too far, you will burn the motor out (I destroyed two). Then I wrote an Arduino program that allows you to use a potentiometer to move the servo back and forth. Looking at the computer serial monitor you can read the values as you adjust the servo motion back and forth.
To make that work, use the code attached. Make sure that your Pololu servo controller is connected to your Arduino. The code has some links to let you know how to connect the potentiometer. Record the settings for each servo and use them in the later code to control the eyes.
You will also want to test out your Neopixel eyes if you decide to use them. The Adafruit site has a great tutorial on wiring up the Neopixels and some code to test them. You’ll want to set the number of Neopixel units to 2, otherwise the second eye won’t light up.
WOW – That’s a lot, but now you’re set up to make this robot head even more complex!
ou will notice that the eyes go through the Adafruit “rainbow” sequence between sound files.
Step 1: Materials:
Well, there are lots of materials…I will only list a few here:
- *I used and Arduino Uno for the brain
- *You will need a VS1053 sound module or some other sound module compatible with the Arduino
- *Also a servo controller. There are a bunch out there to choose from. I am using a Pololu 8 servo controller.
- *a pop-rivet gun and pop-rivets or alternately 1/2″ bolts and nuts to hold the head together
- *file folders for the prototype
- *aluminum flashing for the skin
- *a couple of ICs and some components if you choose to build a sound detector yourself instead of using the Sparkfun one.
- *a moderately heavy set of scissors
- *some flat brass or other metal, or possibly rigid plastic for the jaw
- *some foam core for the electronics platform
- *a dremel tool for various drilling
- *a steel ruller and ballpoint pen and fine sharpie
Step 2: How to make a jaw react to sound.
How to make the jaw of an animatronic robot coordinate with a recorded voice?
I found this fun Instructable that seemed to hold the solution:
Randolfo figured out a circuit that takes the audio input and sends an analog output to the Arduino. That way you can look at the level of sound and have the mouth open more with a louder sound, and less with a softer sound, and close with no sound.
However, if you don’t want to build your own sound sensor, I found this possible replacement from Sparkfun. If you look down the comments, you’ll find someone who wants to de-solder the mic and hook it to an audio output. Apparently, if you do that and remove one resistor, you can use all of its sensor data. That means an analog readout as well as a gate. You could use the gate for two positions: open or closed. Or you could use the analog readout to set the servo position: louder=mouth more open.
http://www.thingiverse.com/thing:32189 by Kongorilla.
For more detail: Animatronic Eyes and Wii Nunchuck Part 2 using Arduino
EasyEDA: Ideas for Circuit Design, Innovation for Electronics Access
Free Circuit Design: Schematic – Simulation – PCB Layout – Gerber Viewer
Cheapest PCB Prototype: Only $2 for 10pcs 10×10cm PCBs, 24 hours Quick Turn, DHL Delivery in 3 Days
This Post / Project can also be found using search terms:
- arduino wii controller