Step 5: Wiring the circuit
You can see my wiring. It's a little messy, but it works. After the wiring is done, I like to use the multimeter to test for continuity to make sure everything is connected correctly.
I used right angle (0.1") headers for any connections to the circuit. This keeps the vertical size down and puts it onto the foot print of where the circuit will sit on the headband. I like to put the servo connections on the sides with the battery and power connections poking out of the back.
I like to cut out a small piece of perf board and connect the pushbutton to it. I attached long wires to it to make sure I would be able to comfortably be able to push the button even though it's connected to the circuit that will ultimately sit on my head.
In order to connect the female leads on the battery, the regulator and the circuit board, I had to make a few makeshift male to male connectors from pieces of perf board and resized headers.
You can also check the circuit diagram here at upverter: http://upverter.com/abetusk/2ff4634ff64db304/Kears/
Remove these ads by
Signing Up











































Visit Our Store »
Go Pro Today »




http://www.pololu.com/catalog/product/1350
It's a tiny servo controller that lets you run scripts. It can run up to six servos, so two of headers on it can be converted to inputs for hooking up switches. :)
You get your little maestro board. It has six servo slots, which is perfect for this project. Use the first four slots for the ears (0 and 1 for the left ear and 2 and 3 for the right ear). Next you will designate the remaining two slot for the control switches. Buy the "partial kit" and just populate the first four servo header positions and the two pin power header. Reference the manul http://www.pololu.com/docs/0J40 for the locations and specs on these. You designate servos and inputs like switches in the sofware http://www.pololu.com/docs/0J40/3.a . Once you connect the board to your PC via the USB you will see how to configure it pretty easily. I say to leave the last two headers of so you can solder the switch wires right to the board. Te me that would be easier. All you need to set up the switches is two 1-100k resistors for pull-ups in order to keep from getting false signals. Check here for info on hooking up the switches. Now, all you have to do is plug in all your servos and the battery. Just make sure that you don't plug in a battery that is of a voltage that is too high for your servos, they won't last you very long if you do. I suggest that you write down what channels you use for what as in 0-left ear up/down, 1-left ear left/right and so forth. Now you can center all your servos and save those settings. You are now ready to start scripting your cat gestures. It's all loop based, so what you want to do is write subs for each gesture and have the button events jump you into the appropriate sub. Let me know how it works out for you. Tweaking the scripting is my favorite part, so I won't spoil that for you. :)
Thanks!
I would suggest getting a simple setup running on some breadboard, i.e. connecting the power to the regulator, the regulator to the circuit, wiring at least one servo out of the micro, connecting the button and testing before proceeding further. Once that's done, you'll have a good understanding of how to connect components together. You can use either protoboard or perfboard for connections, I just prefer protoboard as I find it easier to work with.
Send me a private message if you get stuck and I'll do what I can to help.
Each of the servos needs to be connected to the power line and grounded, along with the button, pullup resistor and microcontroller. The power should be from the regulator that provides a steady 5V from a lithium ion battery. The analogy is a wall wart: You plug in the wall wart into the wall socket then plug in your device from the wall wart to provide the power you need for your device. The 2 cell lithium ion battery is like wall socket power and the regulator is like the wall wart.
The 2 cell lithium ion battery is needed to provide the amperage necessary for the servos and the regulator is needed to provide a steady 5v and service the amperage draw needed by the microcontroller and servos (mostly the servos). Using a 9v or AAs might work (through the regulator, of course) but I've run into problems, I think because the amperage requirements of the servos is too heavy.
To figure out what color wire from the servo corresponds to power, signal and ground, I found the following web site useful: http://www.societyofrobots.com/actuators_servos.shtml .
I take it you're a beginner to electronics and so this stuff might be a little confusing. I hope the above addressed the confusion you had, but if it didn't, feel free to send me a private message to discuss this further.
Good luck and make sure to show pictures after you're done!