In the previous post we have discussed about how to manufacture robot motor drivers and how to make robots with PC keyboard controls.
This time we will discuss how to make a robot using ultrasonic sensor HC-SR04 (proximity sensor), with the addition of this distance sensor, the robot will automatically move forward during the front there is no obstacle, and when there is something blocking the direction of motion, the robot will automatically turns in the direction that there is nothing blocking the flow of his motion.
The good news ... here we can set at what distance will the robot will automatically turn by utilizing the function of this ultrasonic sensor.
Okay...
Immediately wrote, the schematic below is a simple design avoider robot. You can directly assemble it in accordance with the picture below.
From the picture above is known that the components you need are: Arduino Uno (Can Arduino what kind), ultrasonic sensor HC-SR04, Battery 1.5 volts 4 pieces, IC L293D as a robot driver motor, 2 pieces dynamo (recommended aja, better pake nice dynamo yes ... this option aja), cable jumper or rainbow cable to taste, and 1 piece PCB Board.
If you are new to robotics like me ... hehe
So it is advisable to do the first simulation using the software Proteus (free to proteus Version of how much), it is useful to minimize errors, especially if you will do this robot pembutan by way of soldering components on the PCB.
SIMULATION PLANNING
Below is an overview of avoider robot simulation version in Proteus.
To know how to do the simulation in proteus software and how to run it you can check here yes.
This is a robot program AVOIDER 1 sensor for Arduino software, can you develop further yes. This is just the basis just live copy and paste wrote.
Additionally ... to start the simulation using the hc-sr04 sensor in proteus you must have the first .hex file ...
If not there please download here.
.... to govern his car
Double click on the HC-SR04 sensor image
Then the image will appear below, which is given a red box, that's where to enter the file.hex.
After that stay Play / Run in its proteus software.
now we check, if there is a robot barrier will turn automatically, then just set aja like in the picture below.
Done...
D..
READ MORE :
= Super Admob Pro Mastery White Hat Version =
= Bikin Landing Page Pake Blogspot =
= Cara Mempermudah Berbisnis Dropship =
= Membuat Video Profesional dengan Power Point =
This time we will discuss how to make a robot using ultrasonic sensor HC-SR04 (proximity sensor), with the addition of this distance sensor, the robot will automatically move forward during the front there is no obstacle, and when there is something blocking the direction of motion, the robot will automatically turns in the direction that there is nothing blocking the flow of his motion.
The good news ... here we can set at what distance will the robot will automatically turn by utilizing the function of this ultrasonic sensor.
Okay...
Immediately wrote, the schematic below is a simple design avoider robot. You can directly assemble it in accordance with the picture below.
From the picture above is known that the components you need are: Arduino Uno (Can Arduino what kind), ultrasonic sensor HC-SR04, Battery 1.5 volts 4 pieces, IC L293D as a robot driver motor, 2 pieces dynamo (recommended aja, better pake nice dynamo yes ... this option aja), cable jumper or rainbow cable to taste, and 1 piece PCB Board.
If you are new to robotics like me ... hehe
So it is advisable to do the first simulation using the software Proteus (free to proteus Version of how much), it is useful to minimize errors, especially if you will do this robot pembutan by way of soldering components on the PCB.
SIMULATION PLANNING
- It is true whether or not the series we will make
- whether or not the program we created
- Know more about the function and workings of a component
- Can do research as we want without having to buy components first
- Can add a brilliant idea on the work of work that we will make
Below is an overview of avoider robot simulation version in Proteus.
To know how to do the simulation in proteus software and how to run it you can check here yes.
This is a robot program AVOIDER 1 sensor for Arduino software, can you develop further yes. This is just the basis just live copy and paste wrote.
const int pingPin = A3;
const int echoPin = A2;
const int penghalang = 15 ;
int kiriA = 13;
int kiriB = 12;
int kananA = 11;
int kananB = 10;
long duration, cm;
void setup()
{
Serial.begin(9600);
//kepala.attach(2);
pinMode(kiriA,OUTPUT);
pinMode(kiriB,OUTPUT);
pinMode(kananA,OUTPUT);
pinMode(kananB,OUTPUT);
}
void loop()
{
int jarak = ping();
Serial.println(jarak);
if (jarak>penghalang)
{
digitalWrite(kiriA,HIGH);
digitalWrite(kiriB,LOW);
digitalWrite(kananA,HIGH);
digitalWrite(kananB,LOW);
}
else if (jarak<penghalang)
{
digitalWrite(kiriA,LOW);
digitalWrite(kiriB,HIGH);
digitalWrite(kananA,HIGH);
digitalWrite(kananB,LOW);
}
}
long ping()
{
pinMode(pingPin, OUTPUT);
digitalWrite(pingPin, LOW);
delayMicroseconds(2);
digitalWrite(pingPin, HIGH);
delayMicroseconds(10);
digitalWrite(pingPin, LOW);
pinMode(echoPin, INPUT);
duration = pulseIn(echoPin, HIGH);
cm = microsecondsToCentimeters(duration);
Serial.println(cm);
return duration / 29 / 2;
}
long microsecondsToCentimeters(long microseconds){
return microseconds/29/2;
}
If not there please download here.
.... to govern his car
Double click on the HC-SR04 sensor image
Then the image will appear below, which is given a red box, that's where to enter the file.hex.
After that stay Play / Run in its proteus software.
now we check, if there is a robot barrier will turn automatically, then just set aja like in the picture below.
Done...
D..
READ MORE :
= Super Admob Pro Mastery White Hat Version =
= Bikin Landing Page Pake Blogspot =
= Cara Mempermudah Berbisnis Dropship =
= Membuat Video Profesional dengan Power Point =
No comments:
Post a Comment