Accelerometer Based Hand Gesture Controlled Robot Using Arduino
by electronicsinteresting in Circuits > Electronics
360 Views, 2 Favorites, 0 Comments
Accelerometer Based Hand Gesture Controlled Robot Using Arduino
All industries, including the military, healthcare, manufacturing, and construction, are heavily automated thanks to robots. After creating several fundamental robots like the line follower robot and computer controlled robot, we used the Arduino Uno to create this accelerometer-based gesture controlled robot. In this project, the robot is controlled by hand motion. We have an accelerometer that functions based on acceleration for this reason.
Original: Accelerometer Based Hand Gesture Controlled Robot using Arduino
Supplies
- Arduino UNO
- DC Motors
- Accelerometer
- HT12D
- HT12E
- RF Pair
- Motor Driver L293D
- 9 Volt Battery
- Battery Connector
- USB cable
- Robot Chasis
Circuit Diagram
Gesture Controlled Robot is divided into two sections:
- Transmitter part
- Receiver part
In transmitter part an accelerometer and a RF transmitter unit is used. As we have already discussed that accelerometer gives an analog output so here we need to convert this analog data in to digital. For this purpose we have used 4 channel comparator circuit in place of any ADC. By setting reference voltage we gets a digital signal and then apply this signal to HT12E encoder to encode data or converting it into serial form and then send this data by using RF transmitter into the environment.
At the receiver end we have used RF receiver to receive data and then applied to HT12D decoder. This decoder IC converts received serial data to parallel and then read by using arduino. According to received data we drive robot by using two DC motor in forward, reverse, left, right and stop direction.
Working
Gesture controlled robot moves according to hand movement as we place transmitter in our hand. When we tilt hand in front side, robot start to moving forward and continues moving forward until next command is given.
When we tilt hand in backward side, robot change its state and start moving in backwards direction until other command is given.
When we tilt it in left side Robot get turn left till next command.
When we tilt hand in right side robot turned to right.
And for stopping robot we keeps hand in stable.
Arduino Code
#define FD 16
#define BD 17
#define LD 18
#define RD 19
#define m11 3
#define m12 4
#define m21 5
#define m22 6
void forward()
{
digitalWrite(m11, HIGH);
digitalWrite(m12, LOW);
digitalWrite(m21, HIGH);
digitalWrite(m22, LOW);
}
void backward()
{
digitalWrite(m11, LOW);
digitalWrite(m12, HIGH);
digitalWrite(m21, LOW);
digitalWrite(m22, HIGH);
}
void left()
{
digitalWrite(m11, HIGH);
digitalWrite(m12, LOW);
digitalWrite(m21, LOW);
digitalWrite(m22, LOW);
}
void right()
{
digitalWrite(m11, LOW);
digitalWrite(m12, LOW);
digitalWrite(m21, HIGH);
digitalWrite(m22, LOW);
}
void Stop()
{
digitalWrite(m11, LOW);
digitalWrite(m12, LOW);
digitalWrite(m21, LOW);
digitalWrite(m22, LOW);
}
void setup()
{
pinMode(FD, INPUT);
pinMode(BD, INPUT);
pinMode(LD, INPUT);
pinMode(RD, INPUT);
pinMode(m11, OUTPUT);
pinMode(m12, OUTPUT);
pinMode(m21, OUTPUT);
pinMode(m22, OUTPUT);
}
void loop()
{
int temp1=digitalRead(FD);
int temp2=digitalRead(BD);
int temp3=digitalRead(LD);
int temp4=digitalRead(RD);
if(temp1==1 && temp2==0 && temp3==0 && temp4==0)
backward();
else if(temp1==0 && temp2==1 && temp3==0 && temp4==0)
forward();
else if(temp1==0 && temp2==0 && temp3==1 && temp4==0)
left();
else if(temp1==0 && temp2==0 && temp3==0 && temp4==1)
right();
else
Stop();
}