ping)) not consistently reading beyond 5 inches?
tms1
Posts: 2
I am running a ping)) sensor and it seems to 'stick' at a max distance of about 5 inches. I do get varying values back, and occasionally do get a longer value (typically the wall at which the unit is pointed) which seems accurate, but only for a single ping. After that the readings return to values varying from approx 740-800. If I move something closer I do get appropriate variations in distance below 5 inches, but as soon as I remove the near object, it usually returns to the 5 inch reading instead of reading the wall, which is about 40 inches away.
Is this unit defective? Is there any way to test that theory? What are my options?
Is this unit defective? Is there any way to test that theory? What are my options?
Comments
2) You could have an error in your program. You'd have to post it for help on that regard.
As to code, this is a pretty simple arduino setup using a a very basic code template, so I don't see any issues there. It's almost as though it's falling back to a default reading in lieu of input?
Now you mention that you're using an Arduino. That may well be your problem. The PING works well with both the Stamps and the Propeller, very different microcontrollers. You might want to re-read the documentation for the PING. It's really quite simple. You produce a brief trigger pulse on the bidirectional I/O line, then wait for the leading edge of a pulse from the PING. You time the width of the pulse from the PING and that's proportional to the round-trip distance from the PING to the nearest object.
Earl
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
It is possible that you have a defective module. You can test by gently shaking the module; can you hear any rattle?
If you would like to have it tested, you can you send me your customer at support@parallax.com.·I will set up an RMA to have you send the module·and if it turns out to be defective, we will replace the module at no cost; otherwise we·will offer·half off replacement if the module has been damaged somehow.
If you want to call me to set that up, feel free, the best number to use is 888-997-8267 and you can ask for me.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Respectfully,
Joshua Donelson
www.parallax.com
Post Edited (Joshua Donelson (Parallax)) : 4/3/2009 3:17:17 PM GMT