Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
11 years ago.
Detecting Frequency from HCSr04
Hi
I am working with HCSR04 ultrasonic range finders. Mbed has a library written for it and i can easily get Distance of an object using these modules. Now can anyone help is there a way i can differentiate between humans and other objects using these sensors.
Actually i want to use these sensors for occupancy detection but the behavior of sensor is not very accurate as the wave can bounce of any object and ultimately i have a variation in distances received.
Has anyone worked in this domain ?
Thank you
3 Answers
11 years ago.
Detecting moving humans (or at least living creatures that have a heat signature) is normally done by using a PIR (passive infra red) sensor. That does not give you range info, but it also does not get confused by static objects.
11 years ago.
Considering they just return a distance, you cannot know if it is a human or something else. I use a similar one for a similar goal, and simply have it in a passage, at startup it measures the 'normal' distance (a bunch of times, to deal with the variation you mention), if it is significantly less it assumes someone walks there.
You can also make that normal distance variable, where if for a long time you measure roughly the same value, you update that as the new normal distance.
Thanks Eric Can you share with me what exactly you have done? anycode or library than i can use. the problem with the variation of distances i get from this device. And then i have to detect normal human movements using this device
posted by 20 Dec 2013It runs on an arduino, and I have that code somewhere on an old laptop. But essentially that one simply ranges 10 times after startup, and takes the smallest returned value. Then it keeps ranging, and if a range is returned that is smaller than that stores value minus some threshold value, it assumes someone is there.
But you could improve that alot, however for my situation it was sufficient. And once it assumed someone was occupying the room it went from ranging something like 20 times per second to once per second, since some people with overdeveloped ears could hear it (not because they can hear ultrasonic sounds, but those sensors make clicking noise, at least mine does).
posted by 20 Dec 201311 years ago.
Thanks Wim i am also using PIR but what i have evaluated is PIR does not really detect minor motions whereas an Ultrasonic can. I am using both the PIR and Ultrasonic to improve occupancy detection. It is just the behavior of the ultrasonic sensor that is causing some issue
PIR sensors come in different versions. Depending on the fresnell lens they will either have a wide opening angle or a small area of sensitivity. PIRs will typically detect only horizontal or vertical movement. They dont respond well to movement towards or away from the sensor. Detecting that type of movement will require 2 or more sensors mounted at an angle relative to each other and OR-ing the outputs..
posted by 20 Dec 2013