Ultrasonic sensor detect obstacle's size

Discussion specific to the intelligent brick, sensors, motors, and more.
Post Reply
shaoxiaojun
Posts: 13
Joined: 30 May 2012, 06:53

Ultrasonic sensor detect obstacle's size

Post by shaoxiaojun »

Hi All,
I try use the US sensor to detect the obstacle's size, like height or width, the theory is simple, there's an object in front of sensor with distance 'line distance', move the US sensor which dirven by a motor, the motor move looply by a tiny steps each time, like:

Code: Select all

RotateMotor(OUT_B, 10, 5);
when the detected distance jumped a big step, it means the the ultrasonic just passed by the edge of the object, then record the degree that motor rotated, like:

Code: Select all

rotationTotalDegree = MotorTachoCount(OUT_B);
so base on 'line distance', 'edge point distance', 'rotated degree', I can easily cacualted the object's size(use the tan(int degreee)).

But I got some problem when use the sensor, it didn't work as I imagined, instead send a single line ultrasonic signal, it actually send 'bunch' of singlal to an object, like a single point light source, it's a Radial, I guess the cross section is like a retangle or sth, and the area of this retangle depens on the distance from the sensor, so this make it nearly impossible to get a clear edge, because from my test, even the sensor passed by the edge of object for a long distance, the distance still displayed very near.
Do you have any idears?
this is shawn.
mcsummation
Posts: 220
Joined: 23 Jan 2012, 17:07
Location: Round Rock, TX

Re: Ultrasonic sensor detect obstacle's size

Post by mcsummation »

Yes, the ultrasonic sensor a "cone of detection", not a line. Even the IR distance sensors from MindSensors have a "cone of detection". To get what you want, you would need a laser rangefinder.
shaoxiaojun
Posts: 13
Joined: 30 May 2012, 06:53

Re: Ultrasonic sensor detect obstacle's size

Post by shaoxiaojun »

oh, that's too bad, is that possible to add a special mask with a line mouth in front of US sensor to simulate the 'line siginal' though i guess it might reflect the ultrasonic and make the data mess...
this is shawn.
HaWe
Posts: 2500
Joined: 04 Nov 2014, 19:00

Re: Ultrasonic sensor detect obstacle's size

Post by HaWe »

I have 4 US sensors mounted "reverse T-shaped" in a distance of at least 15 (-30) cm to the next one, in doubt aligned to each other in a slight angle and all driven in single shot mode. In this case I can get a vague idea of the object size.
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests