Wiring Forum
Bugs >> Website,  Reference,  Examples Bugs >> Error in GP2D12 Ranger example

Message started by roypardi on 05/10/08 at 02:47:00

Title: Error in GP2D12 Ranger example
Post by roypardi on 05/10/08 at 02:47:00
Hi - it looks like there is an error in the GP2D12 example here:


The pull-up resistor means that the pin will always see 5v and (I assume) ignore input from the sensor - at least I just tried it and that is the result.

A pull-down resistor works; also works without any resistor (I guess it doesn't hurt to have one)

fwiw - a decoupling capacitor is critical for that GP2D series- they draw a lot of current. Without a cap I was getting very erratic readings. A good article on this is here: http://www.robotroom.com/DistanceSensor3.html


Wiring Forum » Powered by YaBB 2.5 AE!
YaBB Forum Software © 2000-2010. All Rights Reserved.