Arduino distance measuring using bluetooth HC 05 and Ultrasonic sensor || Dream ideas DIY
ฝัง
- เผยแพร่เมื่อ 28 มี.ค. 2021
- Links
1) Arduino UNO : www.amazon.in/dp/B00H1HR576/r...
2) HC-05 Bluetooth module : www.amazon.in/dp/B00R95Y0AK/r...
3) Ultrasonic sensor : www.amazon.in/dp/B08H2C34KL/r...
4) jumper wires : www.amazon.in/dp/B00ZYFX6A2/r...
5) 9v battery
6) battery holder
••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
Code and Circuit Diagram link here 😁
drive.google.com/folderview?i...
Bluetooth app link
play.google.com/store/apps/de...
••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••
component required:
1) Arduino UNO are Arduino nano
2) Ultrasonic sensor
3) HC 05 are HC 06 bluetooth module
4) 9v battery
5) 9v battery holder
6) mini breadboard
7) Jumper wires
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
🔴video 🎥📷
Camera: Redmi note 9
edited in: filmora 9
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
Music credits:
Track: Ikson-last summer
Listen to the original music : • #37 Last Summer (Offic...
THANKS FOR WATCHING - วิทยาศาสตร์และเทคโนโลยี
Keep supporting friends 😁😁✨
Osm bro
@@creativekingsathu1473 TQ sathish bro 💚 be supporting bro
Sooper
Tq bro
Nice idea
Super bro 💓💓
Can I know what the function of the battery in this project ? Can this project be successful if not using the battery ?
💯💯💯
Tq bro
Which application you used for circuit bro 🤔
Great 😃
NZH creations TQ ❤ Keep Supporting
cool bro
Well done. Keep going ❤️
Thanks. Bro continue
Thanks for u r support bro ❤️😘
Really Liked your work and editing skills✌️🔥...keep going ✨
Thanks dude ☺️
🔥🔥
Tq bro 🤩
Keep supporting bro
My serial bt terminal app says TOO CLOSE 0cm without anything near the sensor...please help
Error404 Bro please check your circuit connections once
@@Dream_Ideas_DIY i am using a power bank to power arduino could this be the issue?
@@error-ts3xt no issues bro ❤️
can someone tell me the problem statement why this dude invent this project?
can i know why did you put LED in your coding when you dont use LED
additional futures i added bro if you want LED you can add it
🤝🤝🤝🤝❤️❤️❤️❤️❤️
cannot connect to sensor to apps
Dear respected brother,
I am beginniner to use Arduino, sir i upload built-in led blink example sketch to Arduino uno and pro mini, both are blinking well, then I upload empty sketch to clear example code, system shows message that sketch upload done 100 %, but both boards runs previously blink example code. I tried to different systems (PC, Laptop,mobile) to clean an upload new sketch, but results are same, where I mistaken i don't understand. Pls help me to solve if you interested.
8867126724 massage me in whatsapp bro 👍
Don't upload empty code bro upload any other code... After uploaded code automatically delete previous code bro ❤️
hi can you sent me the code??
Code is not opening
Pls help me...the apps is connected but cannot give the output ..what is the problem?
Bro connect ultrasonic sensor VCC to 5v bro
bro i was not getting the output
What is the maximum / minimum distance this will measure?
Maximum distance 4 meters / minimum distance 2 cm... if the object comes near in 15 cm it will beeps a buzzer are display as( TO CLOSE )....
FULL CODE AND CIRCUIT DIAGRAM given in diacription bro
@@Dream_Ideas_DIY Thanks a lot, I look forward trying this out. Keep up the excellent posts bro!
@@fredsampson8064 TQ bro 🤩🥰❤️❤️ keep supporting
File not supporting
Hi
Hi appu thanks for watching ✨❤️
do in not cm
I want help sir
S say bro
Sir could you please share the code the sir
/* program by LOHITH KUMAR(Richu)
* subscribe DREAM IDEAS for more updates
*/
int triggerPin = 7; //triggering on pin 7
int echoPin = 8; //echo on pin 8
int LED = 13; //led pin
int info = 0;//variable for the information comming from the bluetooth module
int state = 0;//simple variable for displaying the state
void setup() { //we will be combinig both setups from the codes
Serial.begin(9600); //we'll start serial comunication, so we can see the distance on the serial monitor
pinMode(triggerPin, OUTPUT); //defining pins
pinMode(echoPin, INPUT);
pinMode(LED, OUTPUT); //defining LED pin
digitalWrite(LED, LOW); //once the programm starts, it's going to turn of the led, as it can be missleading.
}
void loop(){ //here we combine both codes to work in the loop
bluetooth();
sensor();
}
void bluetooth() { //loop from the bluetooth code is renamed to "bluetooth" void
if(Serial.available() > 0){ //if there is any information comming from the serial lines...
info = Serial.read();
state = 0; //...than store it into the "info" variable
}
if(info == '1'){ //if it gets the number 1(stored in the info variable...
digitalWrite(LED, HIGH); //it's gonna turn the led on(the on board one)
if(state == 0){ //if the flag is 0, than display that the LED is on and than set that value to 1
Serial.println("LED ON"); //^^that will prevent the arduino sending words LED ON all the time, only when you change the state
state = 1;
}
}
else if(info == '0'){
digitalWrite(LED, LOW); //else, it's going to turn it off
if(state == 0){
Serial.println("LED OFF");//display that the LED is off
state = 1;
}
}
}
void sensor() { //loop from the sensor code is renamed to the "sensor" void
int duration, distance; //Adding duration and distance
digitalWrite(triggerPin, HIGH); //triggering the wave(like blinking an LED)
delay(10);
digitalWrite(triggerPin, LOW);
duration = pulseIn(echoPin, HIGH); //a special function for listening and waiting for the wave
distance = (duration/2) / 29.1; //transforming the number to cm(if you want inches, you have to change the 29.1 with a suitable number
Serial.print(distance); //printing the numbers
Serial.print("cm"); //and the unit
Serial.println(" "); //just printing to a new line
//adding for mesuring distance where the led will turn off, even if we tell it to turn off when we chose so in the app
if(distance
Hi sir .. can you share code for this project..
Hi sir
Code and circuit diagram I given in description please check it out sir 👆
Link එක download කරන්න බෑ
/* program by LOHITH KUMAR(Richu)
* subscribe DREAM IDEAS for more updates
*/
int triggerPin = 7; //triggering on pin 7
int echoPin = 8; //echo on pin 8
int LED = 13; //led pin
int info = 0;//variable for the information comming from the bluetooth module
int state = 0;//simple variable for displaying the state
void setup() { //we will be combinig both setups from the codes
Serial.begin(9600); //we'll start serial comunication, so we can see the distance on the serial monitor
pinMode(triggerPin, OUTPUT); //defining pins
pinMode(echoPin, INPUT);
pinMode(LED, OUTPUT); //defining LED pin
digitalWrite(LED, LOW); //once the programm starts, it's going to turn of the led, as it can be missleading.
}
void loop(){ //here we combine both codes to work in the loop
bluetooth();
sensor();
}
void bluetooth() { //loop from the bluetooth code is renamed to "bluetooth" void
if(Serial.available() > 0){ //if there is any information comming from the serial lines...
info = Serial.read();
state = 0; //...than store it into the "info" variable
}
if(info == '1'){ //if it gets the number 1(stored in the info variable...
digitalWrite(LED, HIGH); //it's gonna turn the led on(the on board one)
if(state == 0){ //if the flag is 0, than display that the LED is on and than set that value to 1
Serial.println("LED ON"); //^^that will prevent the arduino sending words LED ON all the time, only when you change the state
state = 1;
}
}
else if(info == '0'){
digitalWrite(LED, LOW); //else, it's going to turn it off
if(state == 0){
Serial.println("LED OFF");//display that the LED is off
state = 1;
}
}
}
void sensor() { //loop from the sensor code is renamed to the "sensor" void
int duration, distance; //Adding duration and distance
digitalWrite(triggerPin, HIGH); //triggering the wave(like blinking an LED)
delay(10);
digitalWrite(triggerPin, LOW);
duration = pulseIn(echoPin, HIGH); //a special function for listening and waiting for the wave
distance = (duration/2) / 29.1; //transforming the number to cm(if you want inches, you have to change the 29.1 with a suitable number
Serial.print(distance); //printing the numbers
Serial.print("cm"); //and the unit
Serial.println(" "); //just printing to a new line
//adding for mesuring distance where the led will turn off, even if we tell it to turn off when we chose so in the app
if(distance
The link for code is not there
So could copy and paste the code here😢
/* program by LOHITH KUMAR(Richu)
* subscribe DREAM IDEAS for more updates
*/
int triggerPin = 7; //triggering on pin 7
int echoPin = 8; //echo on pin 8
int LED = 13; //led pin
int info = 0;//variable for the information comming from the bluetooth module
int state = 0;//simple variable for displaying the state
void setup() { //we will be combinig both setups from the codes
Serial.begin(9600); //we'll start serial comunication, so we can see the distance on the serial monitor
pinMode(triggerPin, OUTPUT); //defining pins
pinMode(echoPin, INPUT);
pinMode(LED, OUTPUT); //defining LED pin
digitalWrite(LED, LOW); //once the programm starts, it's going to turn of the led, as it can be missleading.
}
void loop(){ //here we combine both codes to work in the loop
bluetooth();
sensor();
}
void bluetooth() { //loop from the bluetooth code is renamed to "bluetooth" void
if(Serial.available() > 0){ //if there is any information comming from the serial lines...
info = Serial.read();
state = 0; //...than store it into the "info" variable
}
if(info == '1'){ //if it gets the number 1(stored in the info variable...
digitalWrite(LED, HIGH); //it's gonna turn the led on(the on board one)
if(state == 0){ //if the flag is 0, than display that the LED is on and than set that value to 1
Serial.println("LED ON"); //^^that will prevent the arduino sending words LED ON all the time, only when you change the state
state = 1;
}
}
else if(info == '0'){
digitalWrite(LED, LOW); //else, it's going to turn it off
if(state == 0){
Serial.println("LED OFF");//display that the LED is off
state = 1;
}
}
}
void sensor() { //loop from the sensor code is renamed to the "sensor" void
int duration, distance; //Adding duration and distance
digitalWrite(triggerPin, HIGH); //triggering the wave(like blinking an LED)
delay(10);
digitalWrite(triggerPin, LOW);
duration = pulseIn(echoPin, HIGH); //a special function for listening and waiting for the wave
distance = (duration/2) / 29.1; //transforming the number to cm(if you want inches, you have to change the 29.1 with a suitable number
Serial.print(distance); //printing the numbers
Serial.print("cm"); //and the unit
Serial.println(" "); //just printing to a new line
//adding for mesuring distance where the led will turn off, even if we tell it to turn off when we chose so in the app
if(distance
Bro where is the coding....
In description bro
fake source code it didnt work
8867126724 send hi in whatsapp bro I will send code and circuit diagram bro
code work
can i contact you pls, cause it didnt give output on that apps plss help me
9731763145 my whatsapp bro ✨