Society of Robots - Robot Forum
Electronics => Electronics => Topic started by: Jdog on March 15, 2009, 03:39:16 PM
-
I found this instructable which might be beneficial to some people on this sight.
http://www.instructables.com/id/Five_cent_Tilt_Sensor/ (http://www.instructables.com/id/Five_cent_Tilt_Sensor/)
Although, I don't like the way he wired it. I would personally recommend wiring positive to the nickel, negative to a 10k resistor and to the nickel, and then each corner pin to a digital input. I think that makes more sense.
-
You don't need a 10k resistor, or have positive connected. Just connect the nickel to ground and the pins to the digital inputs and treat them as buttons.
-
Every time I've seen a button I've always seen it with a 10k resistor.
-
Every time I've seen a button I've always seen it with a 10k resistor.
Probably because the resistor is when you want a Pull-Up or Pull-Down design - meaning the input pin will constantly be HIGH or LOW until the button is pressed, in which case it becomes the inverse logic value( constant HIGH would become LOW , etc.)
-
With AVRs you can just enable an internal pull-up resistor in the programming.
-
Every time I've seen a button I've always seen it with a 10k resistor.
Probably because the resistor is when you want a Pull-Up or Pull-Down design - meaning the input pin will constantly be HIGH or LOW until the button is pressed, in which case it becomes the inverse logic value( constant HIGH would become LOW , etc.)
Oh that makes sense, I always wondered why they did that.