Step 7: Program the Hand

I have attached the code from my first version. That time, I used two regular Arduinos since I needed 8 Analog In pins. It also isolated the two processes going on: positioning the fingers and measuring the pressures. For my second version (this version) I used an Arduino Mega, so I could fit all of the inputs on one board. As for the code, I pretty much copied and pasted the servo positioning into the pressure reading loop and changed the pin labels around.

For the servo positioning, there still needs to be some work done on limiting the rotation. If they rotate too far, something may break. This is how I broke the finger. 

As I said in the intro, I will always come back to this project to try to improve it bit by bit. Since this is one of my first Arduino programs, there are most likely some inefficiencies in the code. Feel free to post potential modifications. 
<p>hwy,</p><p>can you please help me out with the circuit diagram of the interfacing force sensor and hobby servo with arduino board.???</p><p>i mean the whole connection flow....how it goes</p>
<p>hi how can I get the full description of the project, sounds very interesting and would like to make it. please let me know. thanks</p>
<p>Thanks for your interest, but this is the full description of the project.</p>
How much does it cost to make
The total cost was somewhere in the ballpark of $150-$200. If you have any of the materials already, the cost may be a bit lower, and it also largely depends on where you can find the parts. I was able to find pretty much all of the electronics I needed on sparkfun.
Dude! I remember seeing you in the lab with this! Glad to see it came together really well :)
Super nice, gj! After reading this I am definitely going to try to make fingers like these
Very cool project! How did you do in the science fair?
The award ceremony for state science fair was yesterday, and I was one of the second place winners in the Electrical and Mechanical Engineering category.
Thanks! I was able to place first in Engineering for the school science fair, and my interview for state science fair is on Tuesday.
Good luck! Very cool system! do the pager motors vary in power based on the pressure of touch?
The Arduino takes pressure samples once every minute, and based on those measurements, the motors are on for a portion of each second. At full pressure, the motors should be on all of the time (1 full second during the 1 second measuring interval), and at half pressure, they should be on for 1/2 of the time (1/2 of a second during each 1 second measuring interval).
Had a chance to meet macgyver603 at 2012 AZ SEF in Phoenix, AZ. He is a really bright guy. He let us know about something called HackerSpaces (Mesa, AZ). <br> <br>Great work macgyver603!
Hey do you have a video of this? I'm thinking of making one myself. How much did it cost you, and where did you buy the materials?
I do not have a video of this. I was able to buy most of the electronic at Jameco, and the hand cost about $240 total. Let me know how it goes, and good luck!
Cool! I won't be able to make this project for a while because I'm going to make the segway skateboard first (and it costs around $350).
Wonderful project but I need some help understanding - how do you hook up the vibration motors to your glove? Is that the haptic feedback?<br><br>So the &quot;circuit&quot; as I understand it is - user bends finger in glove, that changes the finger resistor that controls the position of the robot hands' finger angle. when robot fingertip starts applying pressure the variable resistance is used to drive glove Vibrating motors?
Yes, that is how the hand works. The motors are the haptic feedback part of the project, and they are just sewn on. <br>
can you upload a video? is very cool
There are still a couple of fixes I need to take care of, but once those are done, I will see what I can do.
You should have entered this in the Science Olympiad's Robotic Arm Competition! The Olympiad happens in every state, and if your school does well enough, you'll compete against other states too!&nbsp;<a href="http://soinc.org/" rel="nofollow">http://soinc.org/</a>

About This Instructable




Bio: I enjoy working on all sorts of projects. Whether it is creating something with my forge or building the biggest thing I can think of ... More »
More by macgyver603:The Perfect Hard Boiled EggRasp and Pepper Tree KnifePallet Wood Wine Rack and Liquor Shelf
Add instructable to: