The inspiration for this project was to create something that was both mechanically, electrically and programmatically complex enough to provide a sufficient learning experience.
We also sought an interactive project that would be able to have an audience capturing effect. By combining all of these desires, we leaned towards the more robotic side of mechatronics, and thus began the search into bionic hands. We decided that the goal of our project was to create a mechanical hand that mimics the motion of a human hand. The main goal was to be able to learn and practice skill sets, and be able to convey them in the project. This project also had an agreed upon budget that we wished to stay within, so we acquired the parts that were needed to present the project goal.
The project consists of two main components, a mechanical hand, and a glove equipped with sensors. The glove sensors are meant to capture the motion of the hand in real time, and then convey it to the mechanical hand’s motors to actuate the motion. Both the glove and the mechanical hand are equipped with a microcontroller, and they communicate with the GUI on our labview software via Wifi TCP/IP receive block. The multitasking part of our project is that the sensors and the actuators must ideally function together at the same time.
The glove has 5 flex sensors attached to where the fingers are. The range of the flex sensor goes from 0 to 90 degrees, and it has resistance of ~10k Ω when it is not bent at 0 degrees and ~20 k Ω when it is bent at 90 degrees. The range of motion of the sensor is limited; however it satisfies the requirement of showing the needed skill set.
The following is a wiring diagram of one sensor connected to the microcontroller.
The main idea of the wiring is that there is a voltage divider where the 10k ohm is the first resistor and the flex sensor acts as the other, and the Vout is received by the microcontroller on a GPIO pin used as an ADC (12 bit).
Five pins were used to collect sensor values from the five fingers, and then code was written so that the analog values were converted to angle values, and those were concatenated in a string and sent to labview.
Calibration was needed to be done to do proper mapping of values. Fingers were stretched to obtain the analog value at 0 degrees for each finger, and then closed to make sure the analog value maxes at 4095. Those analog values were then clamped and mapped to get angles from 0 to 90.
The mechanical hand has five 6V DC motors and each is equipped with an encoder to track current position and receive needed pwm signals to actuate. Each motor shaft is attached to a pulley, and each pulley has a string wrapped around that is connected to the finger. Each finger has a spring embedded between the first and second joint.
The way the mechanism works is that as the shaft rotates, the pulley rotates and the string wraps, pulling the finger down. The motor should be able to hold the finger in position, but once it rotates in the opposite direction, the string gets loose and the spring takes care of bringing the finger back to its standing position.
The DRV8833 H-bridge was used to drive and control the flow of the current to the motors. Each H-bridge is able to drive 2 motors. A 6V supply was used to drive the motors, and the microcontroller powered the encoders. Almost all the pins on the microcontroller were used for this task. Each motor needed 4 pins from the microcontroller, 2 for the pwm signal, and 2 for the actual encoder values coming from the motors. Almost all of the GPIO pins were used for the pwm wiring, and the rest was used for the encoder wiring. The thumb did not need encoder pins as motion was very limited.
Controller
The hardest part about moving the fingers properly was developing a proper controller to navigate the different dynamics of the fingers. This was our most complex code portion of the project. Functions were made for when the fingers are stretching, and functions were made when the fingers were bending. The motion was non-linear and so different pwm signals needed to be applied at each of the functions and also at different different positions when bending and stretching. A PI controller was developed for this, and the Kp and KI constants had to be adjusted for each finger, for each part of the finger movement.
The controller is not the main focus of this project, but the tuning did take the longest time. It would definitely be the interesting portion of our code, and it gave us an interesting insight on controls.
LabView GUI
On the front page of our GUI, we have two inputs where we type in the IP addresses from each microcontroller to establish the connection over WIFI. Once we run our software and it achieves that connection, the statuses to the glove and hand light up.
Our GUI has different operation modes. General is where you get to interact with the mechanical hand without the need for the glove. You manually drag the control bar to indicate the position you wish the finger to be at and that essentially acts as the “glove signal”. Labview sends that value to the microcontroller on the mechanical hand, and the controller goes ahead with executing the proper values.
Imitation mode is where labview takes the message from the glove and sends it to the mechanical hand. The array shown displays the values of the sensors received from the glove. Our software uses the IP addresses from each microcontroller to establish communication.
The calibration mode was just used to indicate the connection to the fingers once they were calibrated. This mode was not needed after we were able to resolve initial issues and establish connection and functionality of the 5 motors.
Simulation
We were anticipating that the motion of the mechanical hand would not be able to exactly mimic the motion of a real hand exactly how we would've liked it to. To view the ideal motion imitation, we decided to create a simulation code to convey the motion on software. As the glove detected the motion, the simulation moved at the same time, which was another real-time function we had going for us. For this process, there was hardly any time delay.