Blog Home

Substituting a flex sensor for an inexpensive light-dependent resistor

Arduino TeamJanuary 16th, 2023

In order to build wearables that react to motion, most people tend to reach for accelerometers, gyroscopes, and flex sensors. But due to their higher cost, teacher Gord Payne wanted to create a low-cost alternative that could be easily sourced and integrated into projects — like that of his student who had designed a hand sculpture and approached Payne for help automating its fingers.

A typical glove with finger movement tracking normally incorporates flexible strips, which vary in resistance based on the extent of their deviation from the starting angle. By reading this value with an Arduino board’s analog-to-digital converter (ADC) and mapping the resistance with a formula, the total angle can be found with decent accuracy. Payne’s idea, however, substituted this special material for a flexible tube that has an LED on one end and a light-dependent resistor (LDR) on the other. When kept at the starting position, all of the light from the LED is able to hit the LDR, and any bends introduced from bending the tube cause less light to reach the other side.

After performing a few test runs to determine the exact mapping of resistance values coming from the LDR compared to the angle of the finger, Payne’s code could accurately calculate the angle based on a simple formula. To demonstrate this project, a servo was connected to the microcontroller and made to mimic how the hand is moved.

More information can be found here on Payne’s Hackaday.io write-up.

Categories:Arduino

Leave a Reply

You must be logged in with your Arduino account to post a comment.