Hand gesture controled robot


Tired of controlling your robot with joystick ? Ever thought of controlling it with your hands.Wished I could control everything with my hands 😀 .Sitting in chair and controlling things like a BOSS 😀 . I loved it.So I finally came out with a cool DIY hand gesture recognition robot, which can follows the commands shown by hand. Sounds crazy but I promise it’s very simple.
Making a gesture control robot is actually very simple. This robot is  a improvement of my another DIY project RC car using RF module

Here also the robot is divided into two session, Transmitter and Receiver.The Receiver circuit is same as that of the old post and there is a slight change in the transmitter circuit ,here we need to program the transmitter circuit.So I will be using a arduino as the programming platform to recognise the gestures made by hand i will be using a accelerometer sensor .So let’s building 🙂

Stuff you need 

Watch the Robot in Action

What is that and how does it work ?


What is a Accelerometer (ADXL335)?

DXL335 Accelerometer
ADXL335 Accelerometer

In brief an accelerometer is a three-axis acceleration measuring device.The accelerometer used here is ADXL335 it has 3 axis (X Y Z).

The accelerometer is now there in almost all smartphones (We are not going to take it from a smartphone 😉  )You might definitely played motion games in your mobile (Eg Temple run) the character in the game moves left and right when you tilt your phone left and right respectively it is done by the accelerometer.

There is  another sensor called Gyroscope found in smartphone which we don’t  need now

How does it work and recognize the gestures ?

Here the brain of the robot is arduino uno(Atmega32) it is fed with some set of code.
The gestures/motion made by hand is recognised by a acceleration measuring device called accelerometer (ADXL335)

Gesture controled robot flow chartWorking

Here the Accelerometer reads the X Y Z coordinates when we make gestures by hand and send the X Y Z coordinates to the arduino (Here we don’t need the Z axis we need only two coordinated X and Y So neglect the Z coordinate) The arduino check the values of coordinates send a 4bit data to the Encoder IC accordance to the data received from the accelerometer.The Encoder passes the data to RF Transmitter and the transmitted data is received by the RF Receiver, The receiver sends the 4bit data to Decoder IC and the decodes it passes to Motor Driver IC,Later the motor driver make decision to turn the two motor in required direction

Make the power supply

First we will start with the power supply circuit. We need two power supply circuit one for the transmitter and one for receiver.The receiver circuit need to powered using 12v supply(Since I’am using a 12V motor) and transmitter circuit can be powered using 9v battery
Power supply

You can see the circuit for the receiver power supply on the right. Using this diagram, wire up the supply circuit. You can also add an LED via a 1k resistor to indicate the state of power supply.

  • IC 7805 which regulates the 12v supply to 5v (if cant get a 12v supply you can use a 9v supply)
  • 0.1uf & 470uf capacitor
  • And 1k resistor for status led

NOTE: Use heat sink for 7805 because we are dropping 7v (12-5 )so lots of heat will be produced to burn the regulator so use heat sink is recommended

Let’s Start Making  the Transmitter (Remote)

The receiver session consist of  accelerometer which detects the gesture made by hand sends the data to the arduino, Later arduino send data to the Encoder IC accordance to the data received from accelerometer and the data  is transmitted to the receiver

Wire up as per below circuit

NOTE : Please, be aware that some accelerometers use 3.3V power supply and might be damaged by 5V. Check the supplier’s documentation to find out which is the correct voltage. 

tx circuit_schem

This is just a illustration of the transmitter

Upload Code to Arduino

Get the code from here

* Gesture Recognition Robot - Avishkar
* Coder - Mayoogh Girish
* Website - http://bit.do/Avishkar
* This program lets you to control your robot with gesture made by your hand

 |Ø           Z    Ø| 
 |        X<---•    | 
 |             |    | 
 |             |Y   | 
 |             ∨    |
 |                  |
 |                  |
 | O  O  O  O  O  O |
   ST Z  Y  X  -  +

 Forward <------|------>Backward
1) Upload ADXL3xx Sketch from examples [ File >> Examples >> Sensor >> AdXL3xx ]
2] Connect the sensor the arduino [ X --> PIN A3
                                    Y --> PIN A2
                                    Z --> PIN A1 ]
3) Open serial [Ctlr + Shift + M]
4) Tilt the sensor in +X, -X, +Y ,-Y direction (forward, backward, left, right) and note down the required x y 
5) Now change the 
              #define forward xxx with new +X value 
              #define backward xxx with new -X value
              #define left xxx with new +Y value
              #define right xxx with new -Y value


#define forward 340 // Change this value to change senstivity for forward direction /-Default 340-/ *X*
#define backward 400 // Change this value to change senstivity for backward direction /-Default 400-/ *X*
#define left 340 // Change this value to change senstivity for left direction /-Default 340-/ *Y*
#define right 400 // Change this value to change senstivity for right direction /-Default 400-/ *Y*

int GNDPin=A4; //Set Analog pin 4 as GND
int VccPin=A5; //Set Analog pin 5 as VCC
int xPin=A3; //X axis input
int yPin=A2; //Y axis input
int zPin=A1; //Z axis input(not used)
int Q1=10,Q2=11,Q3=12,Q4=13; //Output pins to be connected to 10, 11, 12, 13 of Decoder IC

long x; //Variabe for storing X coordinates
long y; //Variabe for storing Y coordinates
long z; //Variabe for storing Z coordinates

void setup()
  pinMode(GNDPin, OUTPUT);
  pinMode(VccPin, OUTPUT);
  digitalWrite(GNDPin, LOW); //Set A4 pin LOW
  digitalWrite(VccPin, HIGH); //Set A5 pin HIGH

void loop()
  x = analogRead(xPin); //Reads X coordinates
  y = analogRead(yPin); //Reads Y coordinates
  z = analogRead(zPin); //Reads Z coordinates (Not Used)

    if(x<forward) // Change the value for adjusting sensitivity forward(); else if(x>backward) // Change the value for adjusting sensitivity
    else if(y>right) // Change the value for adjusting sensitivity
    else if(y<left) // Change the value for adjusting sensitivity

void stop_()

void forward()

void backward()

void left()

void right()


Make the Receiver

RF Receiver circuit

The receiver circuit consist of 2 IC(HT12D decoder , L293D motor driver),RF receiver module
Wire the circuit as per the above receiver schematic. There is 2 led in the receiver board ,one lights up when power supply is given to the receiver and the other when power supply is given to transmitter circuit the led near the IC HT12D should lit and this provides you a valid transmission(VT) when power is given at the transmitter if not there is something wrong with your connection or your RF TX RX module

If you want to know more in details about the  receiver session please read this article

What all gesture will robot recognise  ?

This robot is designed for recognising five set of gesture. Forward , backward, left, right and stop.
You will get a better ideas if check the photos of gestures given below

Enjoying riding your robot 😀

Shrink it and Make it Permanent

Arduino uno will be large and bulky on your hand . And if you are deciding to make another project using arduino you will need to remove the arduino and all connection made on it. and you will loose your old work 🙁
I don’t like doing that, so i came out with a solution to make it permanent one 😀
You can check this article to learn how to shrink your arduino project


Download the PCB layout for standalone version from here (mirror)

Watch this video in which i have transfer the  code to atmega8 MCU
I have only shown the outputs of MCU using LEDs .

Feel free to ask any doubt I will try my level best in helping  😀

14 thoughts on “Hand gesture controled robot

  1. I would require help, with pcb part of the project.
    Your work is good and inspiring.
    Need help for doing this project, can i get your email for askin further queries directly.

  2. I would require help, with pcb part of the project.
    Your work is good and inspiring.
    Need help for doing this project, can i get your email for askin further queries

  3. Need your help,in power supply diagram you’ve mentioned 100uf and 10uf capacitors,but below you’ve written 0.1uf & 470uf capacitor.

    which to use??

  4. i did all the connections as mentioned above and burned the same code given above. But my bot is only moving forward ,right and stop .Its not moving in backward and left direction ,where could i have gone wrong ?

Leave a Reply

Your email address will not be published. Required fields are marked *