|
ARDUINO NANO |
x 1 | |
|
custom pcbpcbway
|
x 1 | |
|
HC-05 Wireless Bluetooth RF Transceiver Module serial RS232 TTL |
x 1 |
|
Autodesk Fusion 360Autodesk
|
|
|
Ultimaker CURA |
|
|
3D Printer (generic) |
|
|
arduino IDEArduino
|
|
|
OrCad Cadance |
Micro Fighter BOT with Bluetooth
Hey everyone what's up!
So this is my Micro Fighter Bot or Micro Robot V2 which is an easy-to-make Micro Robot that is powered by an Arduino Nano board and L293D Motor driver IC.
I'm using a Bluetooth Based Mobile terminal app which is available on the google play store to control this robot.
https://play.google.com/store/apps/details?id=com.giumig.apps.bluetoothserialmonitor
Yes, I'm using Bluetooth here, the good old HC01 module.
IDEA Behind Robot
The goal for making is Robot was to make a small robot platform that I could use in my next project which is a fighting bot duo. basically, I want to prepare a small but fast Robot that can fight other small robots, not fight to the death but a normal sumo fighting kinda thing.
Previously, I have made a similar Micro RObot which only had 2 wheels, the problem with that BOT was stability.
also, it can not navigate well over obstacles, such as rocky terrain, sharp declines, or areas with low friction.
To improve this, I prepared this Robot which had 4 wheels so it had a sturdy frame with the center of gravity at the centermost part of the robot as this would help in taking sharp turns at high speed.
I designed this robot in Fusion360 First, the idea here was to make a base that will be used to screw motor mounts from the bottom side of the Base, and with 3 pillars, a PCB can be mounted on it. In between the PCB and Base, a Li-ion battery is placed.
So this was the plan.
Materials Required
3D Printed Parts-
- Base x 1
- Motor Mount x 4
- Front Shield x 1
- Pillars x 3
Components
- L293D Motor Driver IC
- Arduino NANO
- Custom PCB (which was provided by PCBWAY)
- Micro Gear DC Motor
- Female Header Pins
- DC Barrel Jack
- AMS1117
- 4.7uf Cap 1206 Package
- 22uf Cap 1206 Package
- SMD LED 0603 Package
- 1K Resistance 0603 Package
- HC01 Module
- Battery JST Connector
PCB Design
The first step for making a PCB Project is to make a schematic that will have all the components that we need to run our project.
I Prepared a simple setup that consists of an Arduino Nano connected with the L293D Motor driver IC in its proper configuration, HC01 is also connected with the Arduino Nano.
I've used a 12V 2.6A Battery in this setup, It's not recommended to add 12V directly with Arduino's VIN port so I added AMS1117 to step down this 12V into 3.3V for Arduino and HC01 to run without any issue.
Here's the schematic that I prepared!
After finalizing this Schematic, I then Imported its netlist and converted this into a PCB Design.
As for the PCB Outline, I used the reference dimensions from the fusion360 Model and then made the PCB based on it.
I exported the Gerber data and then send it to PCBWay for samples.
PCBWAY Review
After sending the PCBs for manufacturing, it only took 7 days to get delivered.
The PCBs that I had received were nice as expected!
PCBWay you guys rock!
Check out PCBWay for getting great PCB service at less cost!
Note-
Before starting the assembly process, here's a quick fact. I'm using an HC01 module which is pretty hard to find, you could easily Find its breakout board on the internet but these modules are not exactly easy to obtain.
also, they cost a lot so what I did was, I took one of my HC05 modules and place it on my reflow hotplate and remove the HC01 module from its Breakout board.
PCB Assembly
After Receiving the PCB, all that was left to do was to apply solder paste to each component pad.
1. Solder paste Dispencing
I used a normal Sn-Pb solder paste which has a melting temp from 140 to 270 °C
The solder paste Dispencing method is relatively easy, we apply a little amount of solder paste to each components pad one by one which will take time.
After Adding solder paste, we need to do the "PICK and place Process"
2. PICK and Place Process
I then used an ESD Tweezer to carefully pick and place each component on their assigned place one by one which took like 3 mins top but end result was a perfect PCB with all the components place in their place in the right orientation.
3. HOTPLATE REFLOW
After the "PICK and Place Process", I carefully lifted the whole circuit board and place it on my DIY SMT Hotplate which is also homemade just like this project.
After Few mins when the hotplate reaches the Solderpaste melting TEMP, all the components will get soldered by this Hot Reflow process.
4. THT Components
Now we have to add THT Components which are Header pins, DC Jack, L293D IC, and Battery JST Connector.
I just use a regular solder iron for this Job.
at last, we put the Arduino Nano on the header pin.
As you can see right here, I have added jumper pins on the PCB, these are connected in series with TX and RX.
You see, if we add RX and TX of Arduino with HC01 on the PCB directly without any Breakout point, we will not able to program the Arduino nano because of the UART Error.
I've added these two header pins on PCB so I can short them and by this HC01 will communicate with the Arduino Nano, when we have to program the Arduino Nano, we only have to remove two jumpers from these header pins.
You could also remove the Arduino Nano and program it with the sketch and then put it back on the PCB, this method will work but it's too much work for me so I prefer to use header pins instead.
Anyways, after doing this our PCB is finally ready. But we still have to check if the Circuit is working or not.
Testing the Circuit!
For Testing this board, I will use two things basically, first, I will use this battery which is a Li-ion battery pack 12V, I have a BMS on it so we don't have to worry about it many things related to its battery protection.
- we first add the battery onto our PCB with the JST connect in the right polarity.
- then we turn on the switch and our Arduino nano along with HC01 are working.
- HC05 LED is blinking and LED is Glowing in Arduino nano, this means that both of these modules are working without any problem.
- Next, I added a 12V 5A SMPS on the DC Barrel jack, this is for charging the onboard battery pack. LED on the DC Jack side is glowing which means everything is nice and dandy.
- now, at last, I took out my phone and paired it with the HC01 Module.
- then I opened a Bluetooth terminal app in my phone and connected the HC01 with it. as soon as it gets connected, The LED Stopped its frequent blinking sequence which is a sign that the module is now connected with the device.
So our PCB has now qualified its testing process and now we will prepare the 3D Printed Base Body which will hold the PCB and other stuff.
3D Printed Parts and Body assembly
here's this lower base that is holding four DC motors with a motor mounting bracket from the bottom side.
Then three pillars are on the opposite side, these pillars will be used to mount PCB and Base together.
In between PCB and Base, a Li-ion battery is placed so it is all a compact setup that holds everything together nicely.
As for the material for these 3D Printed Parts, I'm going with the transparent PLA and Transparent yellow PLA which kinda look like the golden color but it's not.
After adding everything together, I then added the battery in the middle part and connected its terminal with the JST connector.
then I added wires to the motor and PCB in this order
CODE
int motorLpin1 = 2;
int motorLpin2 = 3;
int motorRpin1 = 4;
int motorRpin2 = 5;
int rightMotorENA = 10;
int leftMotorENB = 11;
int motorSpeed = 200;
int turn=50;
void setup()
{
Serial.begin(9600);
Serial.flush();
pinMode(motorLpin1,OUTPUT);
pinMode(motorLpin2,OUTPUT);
pinMode(motorRpin1,OUTPUT);
pinMode(motorRpin2,OUTPUT);
pinMode(rightMotorENA,OUTPUT);
pinMode(leftMotorENB,OUTPUT);
}
void loop(){
String input="";
while(Serial.available()){
input+=(char)Serial.read();
delay(5);
}
if(input=="S"){
MotorStop();
}
else if(input=="F"){
MotorForward();
}
else if(input=="R"){
MotorBackward();
}
else if(input.indexOf("TR")>-1){
MotorLeft();
}
else if(input.indexOf("TL")>-1){
MotorRight();
}
else if(input.indexOf("SQ")>-1){
SQUARE();
}
}
void MotorForward(void)
{
digitalWrite(motorLpin1,HIGH);
digitalWrite(motorLpin2,LOW);
digitalWrite(motorRpin1,HIGH);
digitalWrite(motorRpin2,LOW);
analogWrite(leftMotorENB,200);
analogWrite(rightMotorENA,200);
}
void MotorBackward(void)
{
digitalWrite(motorLpin1,LOW);
digitalWrite(motorLpin2,HIGH);
digitalWrite(motorRpin1,LOW);
digitalWrite(motorRpin2,HIGH);
analogWrite(leftMotorENB,200);
analogWrite(rightMotorENA,200);
}
void MotorLeft(void)
{
digitalWrite(motorLpin1,HIGH);
digitalWrite(motorLpin2,LOW);
digitalWrite(motorRpin1,LOW);
digitalWrite(motorRpin2,HIGH);
analogWrite(leftMotorENB,50);
analogWrite(rightMotorENA,50);
}
void MotorRight(void)
{
digitalWrite(motorLpin1,LOW);
digitalWrite(motorLpin2,HIGH);
digitalWrite(motorRpin1,HIGH);
digitalWrite(motorRpin2,LOW);
analogWrite(leftMotorENB,50);
analogWrite(rightMotorENA,50);
}
void MotorStop(void)
{
digitalWrite(motorLpin1,LOW);
digitalWrite(motorLpin2,LOW);
digitalWrite(motorRpin1,LOW);
digitalWrite(motorRpin2,LOW);
digitalWrite(leftMotorENB,LOW);
digitalWrite(rightMotorENA,LOW);
}
void SQUARE(void)
{
}
The uploading process is pretty easy and simple, we first remove the jumpers from the HC01 Header pins and then connect the Arduino nano with our computer and fash the Bot with Arduino IDE and that is pretty much the uploading process!
Code is pretty simple and you could alter it according to your needs or requirements.
(Do not forget to add jumper after the flashing process back in their place)
Our MicroBot is ready for its first RUN!
APP
Now, the previous version was controller by a blynk app but I'm not using ESP32 or ESP8266 in this project. We required a Bluetooth terminal app here.
I'm using this Bluetooth controller app that you can download from the google play store. https://play.google.com/store/apps/details?id=com.giumig.apps.bluetoothserialmonitor
Open this app and pair your HC01 with it, after that open its controller mode and assign the Buttons their value which is in our case these.
- TL for Turn Left
- TR for Turn right
- F for Forward
- R for Reverse
- S for Stop
Now we just press any button to control this robot!
RESULT/TEST RUN
Conclusion and Improvement
As you can see, our robot is working! and it's pretty fast which was my goal, to make it as fast and sturdy as possible.
Now, this setup works like a development platform, a micro fighter platform.
the idea here is to make multiple of these roots and let them do fighting and stuff. also, we have to add few gimmicks in these bots like normal weapons shield armor, and stuff.
This project is completely open-source so if anyone here wants to make one of these robots then all the documents are attached.
Comment/DM if you need any more help.
If Project was fun then do hit that like button!
Thanks, PCBWAY for providing PCBs for this project,
Check out PCBWay for getting great PCB service for less price.
and I'll see you guys with the next Project!
int motorLpin1 = 2;
int motorLpin2 = 3;
int motorRpin1 = 4;
int motorRpin2 = 5;
int rightMotorENA = 10;
int leftMotorENB = 11;
int motorSpeed = 200;
int turn=50;
void setup()
{
Serial.begin(9600);
Serial.flush();
pinMode(motorLpin1,OUTPUT);
pinMode(motorLpin2,OUTPUT);
pinMode(motorRpin1,OUTPUT);
pinMode(motorRpin2,OUTPUT);
pinMode(rightMotorENA,OUTPUT);
pinMode(leftMotorENB,OUTPUT);
}
void loop(){
String input="";
while(Serial.available()){
input+=(char)Serial.read();
delay(5);
}
if(input=="S"){
MotorStop();
}
else if(input=="F"){
MotorForward();
}
else if(input=="R"){
MotorBackward();
}
else if(input.indexOf("TR")>-1){
MotorLeft();
}
else if(input.indexOf("TL")>-1){
MotorRight();
}
else if(input.indexOf("SQ")>-1){
SQUARE();
}
}
void MotorForward(void)
{
digitalWrite(motorLpin1,HIGH);
digitalWrite(motorLpin2,LOW);
digitalWrite(motorRpin1,HIGH);
digitalWrite(motorRpin2,LOW);
analogWrite(leftMotorENB,200);
analogWrite(rightMotorENA,200);
}
void MotorBackward(void)
{
digitalWrite(motorLpin1,LOW);
digitalWrite(motorLpin2,HIGH);
digitalWrite(motorRpin1,LOW);
digitalWrite(motorRpin2,HIGH);
analogWrite(leftMotorENB,200);
analogWrite(rightMotorENA,200);
}
void MotorLeft(void)
{
digitalWrite(motorLpin1,HIGH);
digitalWrite(motorLpin2,LOW);
digitalWrite(motorRpin1,LOW);
digitalWrite(motorRpin2,HIGH);
analogWrite(leftMotorENB,50);
analogWrite(rightMotorENA,50);
}
void MotorRight(void)
{
digitalWrite(motorLpin1,LOW);
digitalWrite(motorLpin2,HIGH);
digitalWrite(motorRpin1,HIGH);
digitalWrite(motorRpin2,LOW);
analogWrite(leftMotorENB,50);
analogWrite(rightMotorENA,50);
}
void MotorStop(void)
{
digitalWrite(motorLpin1,LOW);
digitalWrite(motorLpin2,LOW);
digitalWrite(motorRpin1,LOW);
digitalWrite(motorRpin2,LOW);
digitalWrite(leftMotorENB,LOW);
digitalWrite(rightMotorENA,LOW);
}
void SQUARE(void)
{
}
Micro Fighter BOT with Bluetooth
*PCBWay community is a sharing platform. We are not responsible for any design issues and parameter issues (board thickness, surface finish, etc.) you choose.
- Comments(6)
- Likes(3)
- Engineer Dec 09,2023
- (DIY) C64iSTANBUL Aug 09,2021
- AbdElhaleem Waheed Aug 09,2021
- 2 USER VOTES
- YOUR VOTE 0.00 0.00
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
-
10design
-
5usability
-
5creativity
-
10content
-
1design
-
1usability
-
5creativity
-
10content
More by Arnov Arnov sharma
- Delete Button XL Greetings everyone and welcome back, and here's something fun and useful.In essence, the Delete Butt...
- Arduino Retro Game Controller Greetings everyone and welcome back. Here's something fun.The Arduino Retro Game Controller was buil...
- Super Power Buck Converter Greetings everyone and welcome back!Here's something powerful, The SUPER POWER BUCK CONVERTER BOARD ...
- Pocket Temp Meter Greetings and welcome back.So here's something portable and useful: the Pocket TEMP Meter project.As...
- Pico Powered DC Fan Driver Hello everyone and welcome back.So here's something cool: a 5V to 12V DC motor driver based around a...
- Mini Solar Light Project with a Twist Greetings.This is the Cube Light, a Small and compact cube-shaped emergency solar light that boasts ...
- PALPi V5 Handheld Retro Game Console Hey, Guys what's up?So this is PALPi which is a Raspberry Pi Zero W Based Handheld Retro Game Consol...
- DIY Thermometer with TTGO T Display and DS18B20 Greetings.So this is the DIY Thermometer made entirely from scratch using a TTGO T display board and...
- Motion Trigger Circuit with and without Microcontroller GreetingsHere's a tutorial on how to use an HC-SR505 PIR Module with and without a microcontroller t...
- Motor Driver Board Atmega328PU and HC01 Hey, what's up folks here's something super cool and useful if you're making a basic Robot Setup, A ...
- Power Block Hey Everyone what's up!So this is Power block, a DIY UPS that can be used to power a bunch of 5V Ope...
- Goku PCB Badge V2 Hey everyone what's up!So here's something SUPER cool, A PCB Board themed after Goku from Dragon Bal...
- RGB Mixinator V2 Hey Everyone how you doin!So here's a fun little project that utilizes an Arduino Nano, THE MIXINATO...
- Gengar PCB Art Hey guys and how you doing!So this is the GENGAR PCB Badge or a Blinky Board which is based around 5...
- R2D2 Mini Edition So here's something special, A Mini R2D2 PCB that speaks ASTROMECH.Astromech is a fictional language...
- C-3PO Blinky Board Hey guys and how you doing!So this is the C3P0 PCB Badge or a Blinky Board which is based around 555...
- WALKPi Breadboard Version Greetings everyone and welcome back, Here's something loud and musical.Similar to a traditional walk...
- BOXcilloscope Greetings to everyone, and welcome back.This is BOXcilloscope, a homemade portable oscilloscope that...
-
-
Helium IoT Network Sensor Development board | H2S-Dev V1.2
90 0 0 -
-
-
-
-
-
3D printed Enclosure Backplate for Riden RD60xx power supplies
176 1 1