Unstable distane measurement with PING)))
jdviper
Posts: 3
I discovered some weird operation with the PING))) sensor the other night. I am building an autonomous quad rotor for a robotics competition, and I am using the PING))) for altitude hold, and a Pimoroni Propeller Hat mounted and powered separate from a Raspberry Pi. Right now for testing I have the PING))) sensor mounted on the front of foam core poster board. The PING))) sensor is pointed straight down. When I hold the Quad with the sensor about 25cm above the competition board which is made of 3/4" plywood the distance reading jumps between 1cm and 25cm. Trying to replicate the results I tried two PING))) sensors both mounted to the foam board and not mounted. To eliminate variables the foam board and PING))) were removed from the quad while trying to replicate the results. When mounted to the foam board both sensor's distance reading would jump back and forth between 1 and 25cm, but would be stable and display 25cm when they were not mounted. To make things more confusing if I put my hand under the sensor when it was mounted to the foam board it would work fine. I came up with the theory that the foam board might be reflecting the the sound back to the sensor, so I came up with another test. To test my theory I held the PING))) sensor vertically above the board and held a small piece of 1/8" plywood behind the PING))) about an inch. I varied the angle of the small plywood and noticed that at angles close to parallel the distance would jump between 1 and 25cm but as I increased the angle from parallel the distance became more stable. That test appears to support my theory. I was wondering has anybody seen similar operation and do you have any suggestions?
Sincerely,
Jason
Sincerely,
Jason
Comments
-Phil
Thank you,
Jason
Interesting project. Would you like to share your code and hardware layout?
It may help others down the road.
So for ping, the range being 4 meters, the interval time should be greater that 0.12 seconds?
-Phil
I've been surprised how often I've seen multiple Pings triggered at the same time in projects. IMO, triggering multiple ultrasound sensors at once is an easy way to get erroneous readings.
I'll throw in one more possible ultrasound problem for free. I attempted to use an ultrasound sensor with a small quadcopter and the motors of the small quadcopter produced a lot of ultrasonic noise. The sensor worked great with the motors off but as soon as they were turned on I the distance measurements were way off.
I've often wondered if there are situations with a larger quadcopter where ultrasonic noise becomes an issue.
BTW, welcome to the forum Jason. I agree with Jim (aka Publison) this sounds like an interesting project. It would be great to hear more details.
Duane thank you for the heads up because I have not had a chance to run the motors and Ping at the same time, so I'll keep an eye out for weird values.
Jason