Nandana AjithGeorgeTHOMAS CYRIACALEX THOMAS
Published

GloveTalk (Converting Sign Language to Words)

Smart wearable gloves with flex sensors that translates sign language gestures into real time text helping the impaired in communication.

IntermediateFull instructions providedOver 1 day331
GloveTalk (Converting Sign Language to Words)

Things used in this project

Hardware components

ESP32
Espressif ESP32
×1
Resistor 10k ohm
Resistor 10k ohm
×3
6 DOF Sensor - MPU6050
DFRobot 6 DOF Sensor - MPU6050
×1
Flex Sensor
×3

Software apps and online services

Arduino IDE
Arduino IDE

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)
Solder Wire, Lead Free
Solder Wire, Lead Free

Story

Read more

Schematics

glove_translator_img_3Ao4R1iunt.png

The gyroscope reads the angle which the flex sensor bends and the code displays the intended gesture based on the threshold value of each flex sensor.

Code

Code

Arduino
#include <Wire.h>
#include <MPU6050.h>

#define INDEX_PIN 33
#define MIDDLE_PIN 34
#define RING_PIN 35

int flexThreshold = 50;   // Adjust based on sensor
int shakeThreshold = 20000; // For MPU6050 acceleration

MPU6050 mpu;

void setup() {
  Serial.begin(115200);
  Wire.begin();

  mpu.initialize();
  if (!mpu.testConnection()) {
    Serial.println("MPU6050 not connected!");
    while (1);
  }
  Serial.println("MPU6050 connected.");
}

void loop() {
  // FLEX SENSOR READINGS
  int indexVal = analogRead(INDEX_PIN);
  int middleVal = analogRead(MIDDLE_PIN);
  int ringVal = analogRead(RING_PIN);

  // MPU6050 READINGS
  int16_t ax, ay, az, gx, gy, gz;
  mpu.getMotion6(&ax, &ay, &az, &gx, &gy, &gz);

  // PRINT SENSOR VALUES
  Serial.print("Flex -> Index: "); Serial.print(indexVal);
  Serial.print(" | Middle: "); Serial.print(middleVal);
  Serial.print(" | Ring: "); Serial.println(ringVal);

  Serial.print("Accel -> X: "); Serial.print(ax);
  Serial.print(" | Y: "); Serial.print(ay);
  Serial.print(" | Z: "); Serial.println(az);

  Serial.print("Gyro -> X: "); Serial.print(gx);
  Serial.print(" | Y: "); Serial.print(gy);
  Serial.print(" | Z: "); Serial.println(gz);

  // FLEX CONDITIONS
  bool indexBent = indexVal > flexThreshold;
  bool middleBent = middleVal > flexThreshold;
  bool ringBent = ringVal > flexThreshold;

  // MPU6050 CONDITIONS
  bool isShaking = abs(ax) > shakeThreshold || abs(ay) > shakeThreshold || abs(az) > shakeThreshold;
  bool isTiltingLeft = ax < -10000;
  bool isTiltingRight = ax > 10000;
  bool isTiltForward = ay > 10000;
  bool isTiltBackward = ay < -10000;

  // GESTURE DETECTION BASED ON FLEX + MPU6050
  if (!indexBent && !middleBent && !ringBent && !isShaking) {
    Serial.println("Gesture: HELLO");
  } 
  else if (indexBent && middleBent && ringBent && isShaking) {
    Serial.println("Gesture: EMERGENCY SHAKE");
  }
  else if (!indexBent && middleBent && !ringBent && isTiltForward) {
    Serial.println("Gesture: MOVE FORWARD");
  }
  else if (!indexBent && middleBent && !ringBent && isTiltBackward) {
    Serial.println("Gesture: MOVE BACKWARD");
  }
  else if (indexBent && !middleBent && !ringBent && isTiltingLeft) {
    Serial.println("Gesture: TURN LEFT");
  }
  else if (indexBent && !middleBent && !ringBent && isTiltingRight) {
    Serial.println("Gesture: TURN RIGHT");
  }
  else if (!indexBent && !middleBent && ringBent) {
    Serial.println("Gesture: STOP");
  }
  else {
    Serial.println("Gesture: UNKNOWN");
  }

  Serial.println("---------------------------");
  delay(500);
}

Credits

Nandana Ajith
1 project • 1 follower
George
1 project • 1 follower
THOMAS CYRIAC
1 project • 0 followers
ALEX THOMAS
2 projects • 1 follower

Comments