2 Pin Button HELP

Hi,

I have a 2 pin momentary button that I want to connect to my Arduino UNO. I have tried all the tutorials online and on here that I can find but it wont work!!

I have tried connecting one side to the arduino pin 8 and one side to ground and enabling the internal resistor and also using my own 10K resistor but still no look!

Any ideas?

Thanks

Hi,

I have a 2 pin momentary button that I want to connect to my Arduino UNO. I have tried all the tutorials online and on here that I can find but it wont work!!

I have tried connecting one side to the arduino pin 8 and one side to ground and enabling the internal resistor and also using my own 10K resistor but still no look!

Any ideas?

Thanks

Insufficient information. Does the "button" show it works with an ohmmeter? A quick schematic showing how you have the "button" connected would be a big help, as well as posting one of the code examples that doesn't work.

Have you substituted other "buttons"? Result?

Paul

We can't see what you might have done wrong unless you show us. How about some pictures?

sorry everyone for the lack of info, ill post some pics soon but for now I can tell you I have done EXACTLY what is done here:

both in code and the electronics side.

Wire diagonally across the button. The way the buttons are designed, two of the four legs are always connected and two of them are switched. When you connect diagonally across the switch you will always get a switched pair.

Delta_G:
You should take your multimeter and investigate your button a little. See which legs are connected when pthe button is pressed and which are connected when it is not.

Don't follow instructables. Try to look for something a little better. Instructables are pretty much known for being crap. That's where you go to post your tutorial if you're some raw n00bie who barely gets it and the other sites keep taking your half assed wrong tutorials down.

Try something more like this: Gammon Forum : Electronics : Microprocessors : Switches tutorial

Thank you sooooooo much for the link! I worked from the tutorials there and its now all working! :slight_smile: quick question.. if I have 4x buttons do I need a 10k resistor for each or can I use 1x for all 4 switches?

@wreckitsteve, do not cross-post. Threads merged.