Go Down

Topic: Sign language with flex sensors (Read 1 time) previous topic - next topic

shrikant_arts

hello,
i'm working on a project for deaf and dumb people.
i'm having flex sensor which is connected to arduino and a lcd display 16x2 connected to arduino.  too
when i bend the flex a flex sensor which is gven as an input A0 to the arduino ,  a corresponding message should be displayed on the lcd.
for example : if a flex sensor is bent,  a message saying  " food "  should display on the lcd.
i'm having difficulty in creating a code for that.can anyone help me out with this? please.

6v6gt

Post a link to the flex sensor you are using for this project.
Are you intending that the arduino can display multiple messages depending on the output of the flex sensor ?

shrikant_arts

no, a single flex sensor on bending should display a text on lcd display .
one value for single flex sensor

6v6gt

In principle, you incorporate each flex sensor in a voltage divider across the power rails with the centre tap connected to an analog pin.
In your program, you poll each analog pin in turn and watch for a change in voltage level since the last poll.
If there is a change, you write a message to the display.
If you use an Arduino Nano, you get 8 analog pins. If you use a Uno you get 6. If these are not enough, you can get an external ADC chip.

shrikant_arts

yes see what actualyy, flex sensors having two pins.
one i have given as an input and second to the gnd and side by side an lcd connection is also attached with the arduino.
i bit confused with this totallt.
i have written a code but it doesnt work can u helpme out.


#include <LiquidCrystal.h>
LiquidCrystal lcd(12,11,5,4,3,2);
int flexPin1 = A0;
int value1;
void setup() {
  // put your setup code here, to run once:
lcd.begin(16,2);
    lcd.setCursor(0,0);
    lcd.print("Sign Language");
  Serial.begin(9600);
  delay(200);
}

void loop() {
  // put your main code here, to run repeatedly:
 value1 = analogRead(flexPin1);
 Serial.print(value1);
   value1 = map(value1, 760, 950, 0, 255);
     if(value1 > 80)
     {
    Serial.print("Food");
    lcd.clear();
      digitalWrite(6, HIGH);
    lcd.print("Foods");
      delay(500);
     }
     
}

TomGeorge

Hi,
Welcome to the forum.

Please read the first post in any forum entitled how to use this forum.
http://forum.arduino.cc/index.php/topic,148850.0.html then look down to item #7 about how to post your code.
It will be formatted in a scrolling window that makes it easier to read.

Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

It is important we see how you have wired your flex sensors.

Have you got the LCD display working?

Thanks.. Tom.. :)
Everything runs on smoke, let the smoke out, it stops running....

6v6gt


shrikant_arts

yes, lcd connecctions are quite working well.
my flex sensor one pin is connected with gnd of arduino and another is as a input to the arduino

shrikant_arts


6v6gt

OP's picture:



The wiring diagram is (probably) incorrect. I've tried to ask 2 times what sensor is being used.
This is the correct wiring diagram for a Sparkfun sensor.

shrikant_arts

yes i told you its a flex sensor 2.2 inches one.
yes i have connected the same way the link which provided the connections.
the circuit i drew is wrong. sry.

ChrisTenone

#11
Feb 16, 2018, 12:40 pm Last Edit: Feb 16, 2018, 01:07 pm by ChrisTenone
no, a single flex sensor on bending should display a text on lcd display .
one value for single flex sensor
It seems like a doable project, but the programming will be complex.

The sketch you posted (without [code]tags [/code]!!) would seem to work for a small number of words formed on a single finger. The range from 760 to 950 will limit you to ten or so unique positions (use an opamp to stretch this range to the full 10 bits Arduino can handle.) Some "fuzzy logic" should help compensate for slight variations. Best would be a sensor for every articulated joint, at least a dozen. Use arrays to translate between words and series of flex sensor values.
.sig

6v6gt

Look very carefully at the link for the wiring diagram of the Sparkfun Flex sensor.
There is a 47K Ohm resistor. between ground and the analog pin. Look also at what part of the sensor is connected to 5 Volt. The sensor together with the resistor form a voltage divider.

shrikant_arts

connecions are pretty good.code isn't working

6v6gt

You've claimed that the LCD code works so my suggestion is to create a new sketch based purely on the Sparkfun code example and get that working. After that, join the your LCD code to the working example.

Go Up