In this project we will learn how to make Wireless Bluetooth Controlled Robot using Arduino and control it via Android App.
Overview
In this project, we will learn how to make Wireless Bluetooth Controlled Robot Car Using Arduino. The robotic car can be controlled wirelessly via a Smartphone. The smartphone has an Android app through which the user can send commands directly to Robot. The robot can move forward, backward, left, and right and can also be stopped.
The Arduino’s Bluetooth-controlled robot car is interfaced with a Bluetooth module HC-05 or HC-06. We can give specific voice commands to the robot through an Android app installed on the phone. At the receiving side, a Bluetooth transceiver module receives the commands and forwards them to the Arduino, and thus the robotic car is controlled.
Previously we made some other robotic projects. You can check a few of them below:
1. Wireless Gesture Controlled Robot Using Accelerometer & Arduino
2. Wireless Voice Controlled Robot Car Using Arduino
3. WiFi Controlled Robot using ESP8266
4. Make an Automatic Grass Cutting Robot using Arduino
Bill of Materials
The components required for this project are given below. All these components can be purchased from the Amazon Link.
| S.N. | Components | Quantity | Purchase Links |
|---|---|---|---|
| 1 | Arduino UNO Board | 1 | Amazon | AliExpress |
| 2 | Bluetooth Module HC-05/06 | 1 | Bluetooth Amazon | AliExpress |
| 3 | Motor Driver IC L293D | 1 | Amazon | AliExpress |
| 5 | Battery 9V | 1 | Amazon | AliExpress |
| 6 | Robot Chasis & Wheels & Screws | 1 | Amazon | AliExpress |
| 7 | Connecting Wires | 10 | Amazon | AliExpress |
| 8 | Breadboard | 1 | Amazon | AliExpress |
Block Diagram
The block diagram of Arduino Wireless Voice Controlled Robot is given below.
The Arduino Wireless Voice Controlled Robot consists of a transmitter and a receiver section. The transmitter end consists of Smartphone Bluetooth and the Android app installed on it. Similarly, the Receiver section has an Arduino board as a processor, HC-05 Bluetooth Module as a wireless communication module, L293D for driving motors, and pair of DC geared as a part for moving robot.
Circuit Diagram & Connections
The circuit consist of Arduino UNO Board, HC-05/HC-06 Bluetooth Module, L293D Motor Driver IC, a pair of DC Geared Motors of 200 RPM and a 9V Battery.
The TX, RX pins of Arduino is connected to Rx, Tx pins of Bluetooth Module. The Bluetooth Module is supplied with 5V. Similarly, the left DC motor is connected to pins no 3 & 6 of L293D and the right DC motor to pins no 14 & 11 of L293D. Arduino digital pins 2,3,4,5 is connected to L293D 2, 7, 10, 15 respectively.
The L293D IC Pins 2, 5, 12, and 13 are GND pins, and 9, 1, and 16 is supplied with 5V. But pin 8 of L293D is directly supplied with 9V.
The Android App
The app for this project is given below. It is designed using MIT App Inventor. The UI looks something like this.
The internal architecture and programming has also been implemented so that the Android app can wirelessly control the Robot with Bluetooth.
After final design the Android App looks something like this. You can download the APK file below and directly install it on your smartphone.
Working of the Project
As mentioned above App Logic Command are processed by phone. The command is then sent to the receiver side via Bluetooth. Command received via Bluetooth is forwarded to Arduino Uno board using UART serial communication protocol. Arduino code checks the commands received. Whenever the command is a matching string, Arduino controls the movements of the robot accordingly in forwarding, backward, Turning Right, Turning Left & Stop.
Signal logic levels at the different stages of the circuits for proper controlling of the robotic car are given below.
Source Code/Program
The source code for Wireless Bluetooth Robot Arduino is given below. You can copy the code and upload it directly to Arduino Board.
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 |
String readvoice; int k=0; void setup() { Serial.begin(9600); pinMode(2,OUTPUT); pinMode(3,OUTPUT); pinMode(4,OUTPUT); pinMode(5,OUTPUT); } void loop() { while (Serial.available()) { delay(3); char c = Serial.read(); readvoice += c; } if(readvoice.length() > 0) { Serial.println(readvoice); if(readvoice == "forward") { digitalWrite(2, HIGH); digitalWrite(3, LOW); digitalWrite(4, HIGH); digitalWrite(5, LOW); k=1; } if(readvoice == "backward") { digitalWrite(2, LOW); digitalWrite(3, HIGH); digitalWrite(4, LOW); digitalWrite(5, HIGH); k=2; } if(readvoice == "right") { if (k==2) { digitalWrite(2, HIGH); digitalWrite(3, LOW); digitalWrite(4, LOW); digitalWrite(5, LOW); delay(1000); digitalWrite(2, LOW); digitalWrite(3, HIGH); digitalWrite(4, LOW); digitalWrite(5, HIGH); } else { digitalWrite(2, HIGH); digitalWrite(3, LOW); digitalWrite(4, LOW); digitalWrite(5, LOW); delay(1000); digitalWrite(2, HIGH); digitalWrite(3, LOW); digitalWrite(4, HIGH); digitalWrite(5, LOW); } } if(readvoice == "left") { if (k==2) { digitalWrite(2, LOW); digitalWrite(3, LOW); digitalWrite(4, HIGH); digitalWrite(5, LOW); delay(1000); digitalWrite(2, LOW); digitalWrite(3, HIGH); digitalWrite(4, LOW); digitalWrite(5, HIGH); } else { digitalWrite(2, LOW); digitalWrite(3, LOW); digitalWrite(4, HIGH); digitalWrite(5, LOW); delay(1000); digitalWrite(2, HIGH); digitalWrite(3, LOW); digitalWrite(4, HIGH); digitalWrite(5, LOW); } } if(readvoice == "stop") { digitalWrite(2, LOW); digitalWrite(3, LOW); digitalWrite(4, LOW); digitalWrite(5, LOW); } } readvoice=""; } |














1 Comment
a well-explained article, You guys try MIT app inventor to run this with your own custom mobile application. BTW have you guys ever bought PCB from china? Have you ever tried NextPCB, if no i highly recommend it, a Few days ago i ordered a PCB from this website. my idea was to use a PCB as a chassis of the robot. and all the components will be on this. It was my first time with any kind of PCB so I was worried about the quality. But when I get the PCB i was totally amazed by the product they deliver. I highly recommend try http://www.nextpcb.com link is here