Це відео не доступне.
Перепрошуємо.
Distance Meter / Range Finder using Arduino Uno & HC -SR04 ultrasonic sensor || Arduino Project
Вставка
- Опубліковано 13 сер 2024
- Hello friends,
In today's video I am going to show you how to make a distance meter using Arduino Uno & HC -SR04 ultrasonic sensor. The distance meter is used to measure very accurately the distance to different objects. The range of measurement is also very high upto 4 metres. This can also serve as a range finder.
In this video, I am also showing the comparison of the measured distance using the distance meter and a standard measuring tape.
Link to download code:
drive.google.c...
Link for purchasing components used:
1. Arduino Uno board : amzn.to/3RPzXw8
2. SSD 1306 OLED Display : amzn.to/4eVaBqA
3. HC-SR04 Ultrasonic Sensor : amzn.to/3XFNCd4
4. 9V Battery with connector : amzn.to/3L8Opfe
5. Rocker Switch : amzn.to/4eOuCiO
6. Jumper wire : amzn.to/3xG4FB0
🎵 Song: 'Markvard - Dreams' is under a creative commons license license.
www.youtube.co...
🎶 Music promoted by BreakingCopyright:
• 🛀 Soothing & Chill Out...
Please share, like the video and SUBSCRIBE to my channel for watching more interesting videos in future. Thank You...❤
#arduinoproject
Super bro
Thank you dear friend..🙂❤️
Great project, good detailed description. I really like the comparison you did with the ruler to test the accuracy of the ultrasonic sensor. Keep up the great work! I subscribed to your content, looking forward to more of your innovative videos.
Thank you dear friend. Words of appreciation like these are the motivation to do more such projects and share with everyone.Thanks a lot once again.🙂❤️
Super😊👌
Thank you..🙂
It doesn't show 0 and 1cm, it shows some random no like 1191cm, what should we do?
Hi friend. That is most probably because the ultrasonic sensor that you have used is faulty. Replacing the sensor should solve the problem..
why does it give me an error?
Hi friend. What is the error that it is showing?
im all right but it doesnt give me an out put
@@Science_4U_
const int ledPin = 13; // You can connect an LED to pin 13 to simulate a clock ticking
void setup() {
pinMode(ledPin, OUTPUT);
Serial.begin(9600);
}
void loop() {
static unsigned long lastMillis = 0;
const unsigned long interval = 1000; // Update every 1000 milliseconds (1 second)
unsigned long currentMillis = millis();
if (currentMillis - lastMillis >= interval) {
// Update the clock every second
lastMillis = currentMillis;
// Simulate the clock ticking by toggling the LED
digitalWrite(ledPin, !digitalRead(ledPin));
// Print the time to the Serial Monitor
printTime();
}
}
void printTime() {
// Get the current time
unsigned long seconds = millis() / 1000;
unsigned long minutes = seconds / 60;
unsigned long hours = minutes / 60;
// Print the time to the Serial Monitor
Serial.print(hours % 24); // Use % 24 to keep the time within a 24-hour format
Serial.print(':');
printDigits(minutes % 60);
Serial.print(':');
printDigits(seconds % 60);
Serial.println();
}
void printDigits(int digits) {
// Add leading zero if the value is less than 10
if (digits < 10) {
Serial.print('0');
}
Serial.print(digits);
}
That is correct friend. That light blinking according to clock ticking will make it more interesting. .