That is the code i use in my project, consist in hand what is controlled by a glove with sensors flex. I will explain all the factors and the tips i use in my code.

Dependencies:   flex_sensor mbed Servo

Here we have the code of the both sides of the project, the part will control the arm and the part will move our arm.

Revision:
2:0f0535b697ce
Parent:
1:8347f6c06e1c
--- a/gloveSensorSend.lib	Wed Jul 01 08:52:31 2015 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-http://developer.mbed.org/users/Ronjea/code/gloveSensorSend/#17ebf84f093c