Measuring Distance with Raspberry Pi and HC-SR04 Utrasonic Sensor

preview_player
Показать описание

ICStation offers HC-SR04 at discounted rates:
Рекомендации по теме
Комментарии
Автор

Great guide. Some people in RPI forums have said that Python was too slow to always measure distance precisely. However this seems to work great. What Model Pi are you using? Maybe they were using the first generation Pi's, the topic I read was pretty old.

OttosTheName
Автор

Exactly what I was looking for !
Thank you very

vinittodai
Автор

I've found many guides for the HC-SR04. What i dont understand is why every guide has different values for resistors. I've seen some from 330/470, to 1k/2k, to 4, 7k/10k.

Why?

MarcoPaglioni
Автор

Did you format the distance to show precision only to 1 decimal point or is that the default precision of the ultrasonic sensor? I am thinking of making a scale with springs where the ultrasonic sensor measures the distance from the weighing plate before a weight is added and after a weight is added. Because of this the better the precision the more accurate the result.

TheMarkrafter
Автор

It's. Nice demo. Could you pls help me whether the raspberry pi3 built in wifi module can be used to connect to this HC SR 04 sensor or any other sensor? I would like to capture the data from sensor without any wired connections.

vlsnsatyas
Автор

@lean anavi thanks for your tuttorial is very nice

usupsuparma
Автор

Hi Sir, This code is compatible with which model of raspberry pi? The pin to be used for different models will be different right so how will it work on all models? Thank you so much for the tutorial

subeesha
Автор

When I follow the steps in the video, the terminal says "distance.py:21: Runtime Warning: This channel is already in use, continuing anyway. Use GPIO.setwarnings(False) to disable warnings. GPIO.setup(pinTrigger, GPIO.OUT).

And then the distance output doesn't appear. How can I fix this?

adios
Автор

It appears to have 2 sensing parts, does it take input from both or what?

Also what is it's range of detection, straight line of angled and curved?

Rhinofreak
Автор

Quick question: How would I gather the distances as a list in Python?

HowardTheDucksWong
Автор

how can use two ultrasonic sensors together please share some code or any circuit diagram for connections of pins for both the sensors????

smitvaghela
Автор

great video. Can I find the Code in C/C++?

ahmedwalidabid
Автор

Can you please help me in linking this code to html page

chinmaypatil
Автор

how do you turn the program off after you done it?

bobyau
Автор

How to connect 3 sensore to one rasberry pi?

BeilaMohachek
Автор

HC-SR04 ultrasonic module tested
➡ Read this article

josverstraten