loading

Bluetooth-controlled robot, doing some task based on commands: Manual control (RC Mode), Autonomous (Obstacle avoider Mode), shows a text on LCD, also control the Robot's speed.

Step 1: Parts Needed

You will need:

  1. Arduino Uno/Genuino
  2. Motor Driver (I'm using 2A Motor Shield from DFRobot)
  3. Three of Ultrasonic sensors HC-SR04
  4. HC-05 Bluetooth module
  5. 16x2 LCD with I2C
  6. Jumper wires
  7. Mini-breadboard
  8. 9V battery for Arduino, 7.5-12 V battery pack for motors (custom)
  9. Robot chassis (I'm using DFRobot Devastator Tank Mobile Platform)
  10. Soldering tools
  11. Any tools that may help you work easily
  12. Creativity

Next...

Step 2: Modifying Some Parts

Here, you need to modify some parts, the HC-05 bluetooth module and the LCD. You have to make a voltage divider for the bluetooth module and add an I2C module to the LCD.

Step 3: Build It..

Attach your arduino and parts in their proper place, based on your creativity. For good looking, neat the jumper wires.

Step 4: Wiring Diagram & Programming

Follow this wiring diagram to hook up the parts. Instructions also included in the program. Install the libraries then upload the program. Make sure to release the HC-05 RX TX pins from the Arduino pins before uploading.

Step 5: Play With Your Robot

To control Robot from PC, use TeraTerm software. Software download available here: Tera Term

To control over Android, you can use this app: Arduino Bluetooth Controller

Pair your HC-05 with your device first. When it is asking for password, enter 1234 (default HC-05's password).

Then:

If you use TeraTerm: open the software, click 'Serial', choose your bluetooth port, play.

If you use Android, open the app > Proceed > choose HC-05 > open the Controller Mode > set your controller keys (Set Commands), play. You can also use the Vehicle Mode, set the controller keys too.

These commands based on the codes:

w : Move Forward

a: go Left

s: Move Backward

d: go Right

q: Stop

e: decrease speed

r: increase speed

x: LED ON

z: LED OFF

1: Obstacle Avoider Mode

2: Showing the text on LCD

0: Clear n turn off the LCD backlight

You can modify the codes for another commands. If you fail once, don't give up! That's what make this fun. Do troubleshoots. Hope you make it!

<p>Hi, thank you very much for sharing your work/instructions. I'm helping my nephew to building this as his first robot project. I have question about step 2, &quot;Modifying some parts&quot;. It says &quot;You have to make a voltage divider for the bluetooth module&quot;, is this referring to the 1k and 2k resistor as shown in the diagram? Can you please tell me what specific type of resistor to buy? Sorry if I'm asking something very basic...I looked up on ebay and there are many with different Watt and ohm, unsure which is the right one. Thank you for helping out. </p>
Hi! Thank you for your comment. Yes it's referring to the resistors as shown in the diagram. You can use the 1k and 2k carbon film resistor with 5% tolerance and i think it's fine to use 1/4 or 1/2 Watt of them. Thank you.
Thank you for the quick reply. I'm having difficulty finding 2k resistor on ebay, but there are a lot of 2.2k ones....can i use them instead? thanks again.<br><br>Tony
Hi, Tony! Actually i experienced the same with you, so i replaced the 2k resistor with 2x1k resistors in series. Hence, you will need three 1k ohm resistor. Thank you
<p>Hi, i am building this but cant seem to find a L298P motor driver. I can only seem to find a L298 and a L298N. If you can maybe tell me a website to find one or comment a link to it, that would be great.</p>
<p>And another question would be what kinda of motor battery did you use?... And i really dont see it put anywhere in the wiring tutorial</p>
<p>Oh I'm sorry, my bad. I use 6x1.2VNi-Mh Energizer batteries <br>connected to Motor Controller and a 9V Ni-Mh battery connected to <br>Arduino. Remember to place the power connection jumper to <a href="https://www.instructables.com/files/deriv/F7R/AVRH/IM3OF5ZC/F7RAVRHIM3OF5ZC.LARGE.jpg" rel="nofollow"><br> <br> </a>PWRIN connection like in this pict (if you use DFRobot L298P Motor Driver):</p>
<p>that must be hard:c</p>
<p>I need friends</p>
Hi alarch88, actually it's fine to use the L298 or L298N series, as long as you can configure it. In matter where to find L298P, you can find it here: http://www.dfrobot.com/index.php?route=product/product&amp;product_id=69&amp;search=L298&amp;description=true#.VvHQLdCFvig. Thank you:)
<p>I need friends</p>
<p>hi i am getting errors in my compiling it is saying'NEWPING'does not name a type please help i really want to make it THANK YOU</p>
<p>Sorry for slow response. You might not find errors if you use the program and the library that i give in step 4, except if you modified the program with your own codes. Please check your codes again, make sure you have 'initialize' everything before. Thank you</p>
<p>Thank you DimSheldon That helped with the errors. I also had to figure out my I2C</p><p>address and configuration. Now working out my motor controller. Doesn't follow the</p><p>commands quite right.</p><p>Thank you again Peter</p>
ok, you're welcome
<p>Hi, I compiled your code and got errors.</p><p>C:\Users\Peter\AppData\Local\Temp\build6fb2e778</p><p>34053d47e65979797fe94432.tmp/core\core.a</p><p>(Tone.cpp.o): In function `__vector_7':</p><p>C:\Program Files (x86)\Arduino\hardware\arduino</p><p>\avr\cores\arduino/Tone.cpp:539: multiple definition</p><p> of `__vector_7'</p><p>libraries\NewPing\NewPing.cpp.o:C:\Users\Peter</p><p>\Documents\Arduino\libraries\NewPing/NewPing</p><p>.cpp:284: first defined here</p><p>collect2.exe: error: ld returned 1 exit status</p><p>exit status 1</p><p>Error compiling.</p><p>Can you help. Thank you</p>
Hi peterpiper50, you have to comment some codes in the Newping.cpp file first, as seen in this pict, or you can just replace your Newping.cpp file with this Newping library(newping.cpp file included) https://www.dropbox.com/s/dwvqmrhdger92k0/NewPing.rar?dl=0. Thank you
<p>C:\Users\Peter\AppData\Local\Temp\build6fb2e7783</p><p>4053d47e65979797fe94432.tmp/core\core.a</p><p>(Tone.cpp.o): In function `__vector_7':</p><p>C:\Program Files (x86)\Arduino\hardware\arduino\</p><p>avr\cores\arduino/Tone.cpp:539: multiple definition</p><p> of `__vector_7'</p><p>libraries\NewPing\NewPing.cpp.o:C:\Users\Peter</p><p>\Documents\Arduino\libraries\NewPing/NewPing</p><p>.cpp:284: first defined here</p><p>collect2.exe: error: ld returned 1 exit status</p><p>exit status 1</p><p>Error compiling.</p><p>last post didn't print everything. Sorry</p>
<p>Hi, I tried compiling your code and am getting errors.</p><p>C:\Users\Peter\AppData\Local\Temp\build6fb2e77834053d47e65979797fe94432.tmp/core\core.a(Tone.cpp.o): In function `__vector_7':</p><p>C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino/Tone.cpp:539: multiple definition of `__vector_7'</p><p>libraries\NewPing\NewPing.cpp.o:C:\Users\Peter\Documents\Arduino\libraries\NewPing/NewPing.cpp:284: first defined here</p><p>collect2.exe: error: ld returned 1 exit status</p><p>exit status 1</p><p>Error compiling.</p><p>Can you help. </p><p>Thank you</p>
<p>can i use hc 06 in place of hc 05</p>
<p>I haven't try it before, but you can try use it. But I recommend you to use the Hc05, because the HC05 can be a master and slave, where the Hc06 just can be a slave module.</p>
<p>Thanks, this is great! I am making something similar but I'm using PIRs to look for a human and then follow the human (like a pet robot) I'm using ultrasonic sensors for avoidance while it looks for a human... if it cannot find a human after a time, it emits a cry. Feedback welcome! </p>
<p>wow yours is great! i wanna try to make it later!</p>
<p>Cool robot.</p>
<p>thanks..</p>

About This Instructable

7,892views

99favorites

Bio: n e w b i e
More by Dimas Sheldon:MultiTasking Robot 
Add instructable to: