Hackster is hosting Hackster Holidays, Ep. 6: Livestream & Giveaway Drawing. Watch previous episodes or stream live on Monday!Stream Hackster Holidays, Ep. 6 on Monday!

Neuro Glove: Smart Hand Rehabilitation Assistant

Neuro Glove is a smart rehabilitation assistant that uses AI and advanced sensors to enhance hand recovery

294
Neuro Glove: Smart Hand Rehabilitation Assistant

Things used in this project

Hardware components

Flex sensor
A flex sensor is a sensor that measures the amount of deflection or bending of the finger
×4
ECG Sensor
An ECG (electrocardiogram) records the electrical signals that make the heartbeat
×1
LED
To visualize the function of Proposed Prototype.
×1
Breadboard
To Connect the sensors.
×1
Multimeter
Checking the resistance of Flex Sensor
×1
Kria™ KR260 Robotics Starter Kit
AMD Kria™ KR260 Robotics Starter Kit
×1

Software apps and online services

Jupyter Notebook
Jupyter Notebook
Python Code
Arduino IDE
Arduino IDE
Arduino Code

Story

Read more

Custom parts and enclosures

Neuro Glove: Smart Hand Rehabilitation_1

Neuro Glove: Smart Hand Rehabilitation_2

Neuro Glove: Smart Hand Rehabilitation_3

Schematics

Neuro Glove: Smart Hand Rehabilitation_Block-Diagram

Neuro Glove: Smart Hand Rehabilitation_Circuit-Diagram

Neuro Glove: Smart Hand Rehabilitation_Hand

Code

Neuro Glove: Smart Hand Rehabilitation

Arduino
const int heartPin = A0; // Pin connected to the OUTPUT of the AD8232
int flexSensorPin = A1;
const int led = D13;
int sensorValue = 0;

void setup() {
  Serial.begin(9600); // Initialize serial communication
  pinMode(heartPin, INPUT);
  pinMode(flexSensorPin, INPUT);
  pinMode(led, OUTPUT);
  digitalWrite(led, HIGH); 
  
}

void loop() {
  digitalWrite(led, LOW);
  int sensorValue = 0;
  while(sensorValue<700){
    delay(100);
  sensorValue = analogRead(heartPin); // Read the analog value from the heart sensor
  Serial.print("heart Sensor Value: ");
  Serial.println(sensorValue*0.05*3); // Print the sensor value to the Serial Monitor
  }
  //if(sensorValue>=3 )
  {
    
    //digitalWrite(led, LOW);
    //delay(100);
    digitalWrite(led, HIGH); 
  }
  int fsensorValue = analogRead(flexSensorPin);
  
  while(fsensorValue<4)
  {fsensorValue = analogRead(flexSensorPin);
  Serial.print("Flex Value: ");
  Serial.println(fsensorValue);
  delay(500);}
  digitalWrite(led, LOW);
   // Read the value from the flex sensor
  Serial.print("Flex Sensor Value: ");
  Serial.println(fsensorValue);
  delay(10000);
}

/*int flexSensorPin = A1; // Pin connected to the flex sensor

void setup() {
  Serial.begin(9600); // Initialize serial communication
}

void loop() {
  int sensorValue = analogRead(flexSensorPin); // Read the value from the flex sensor
  Serial.print("Flex Sensor Value: ");
  Serial.println(sensorValue); // Print the sensor value to the Serial Monitor
  delay(500); // Delay for half a second
}*/

Neuro Glove: Smart Hand Rehabilitation

Python
from pynq import Overlay
from pynq.lib import AxiGPIO
from time import sleep

# Load the overlay
overlay = Overlay("/path/to/your/bitstream.bit")

# Setup GPIO
heart_sensor_pin = overlay.AxiGPIO(0).channel1
flex_sensor_pin = overlay.AxiGPIO(1).channel1
led_pin = overlay.AxiGPIO(2).channel1

# Initialize pins
heart_sensor_pin.set_direction('in')
flex_sensor_pin.set_direction('in')
led_pin.set_direction('out')

# Function to read analog value from GPIO
def read_analog_pin(pin):
    return pin.read()

def main():
    print("Starting the program...")
    led_pin.write(1)  # Turn on LED
    
    while True:
        led_pin.write(0)  # Turn off LED
        sensor_value = 0
        
        while sensor_value < 700:
            sleep(0.1)
            sensor_value = read_analog_pin(heart_sensor_pin)  # Read heart sensor value
            print(f"Heart Sensor Value: {sensor_value * 0.05 * 3}")

        led_pin.write(1)  # Turn on LED

        flex_sensor_value = read_analog_pin(flex_sensor_pin)  # Read flex sensor value
        
        while flex_sensor_value < 4:
            flex_sensor_value = read_analog_pin(flex_sensor_pin)
            print(f"Flex Value: {flex_sensor_value}")
            sleep(0.5)
        
        led_pin.write(0)  # Turn off LED
        print(f"Flex Sensor Value: {flex_sensor_value}")
        sleep(10)

if _name_ == "_main_":
    main()

Credits

CHANDANI POOJARA

CHANDANI POOJARA

1 project • 0 followers
RAMANI SAGAR

RAMANI SAGAR

1 project • 1 follower
GAJJAR NAIMISH

GAJJAR NAIMISH

1 project • 1 follower
TRIVEDI CHINTAN

TRIVEDI CHINTAN

1 project • 1 follower
Meen Patel

Meen Patel

1 project • 1 follower

Comments