0

I am totally new to using the Raspberry Pi. Right now I am trying to determine if a Pi could be used to solve my problem or not.

I am trying to detect multiple buttons pressed. With this I also want to know which button was pressed, if multiple buttons were pressed at the same time, and I want to know all the buttons that were pressed. I also need a breadboard or some components where I can possibly connect up to 100 or 200 buttons or what is the max number of buttons I can connect and detect the changes?

How could I do this and what are physical components that I would need?

  • 1
    you could connect more than 100000 buttons ... you said nothing about how responsive the buttons should be – jsotola Jun 22 at 3:01
  • 1
    How many simultaneous presses do you need to be able to reliably identify? – Mark Smith Jun 22 at 6:53
0

Question

  1. How can Rpi be used to detect multiple buttons?

  2. Can Rpi detect 200 butons or even more?

Answer

Now problem for Rpi to detect 256 keys or even more.

The EE guys usually wire the buttons, say 256, into a 16 x 16 button/key matrix. A couple of years ago I read a MagPi article introducing an GPIO expander called MCP23008. I found MCP23008 very interesting and read the datasheet and application note. The app note explains in details how to use MCP23008 to detect a 4 x 4 keypad, and the program to scan the keypad. I goggled one and also found many Arduino C++ programs using GPIO or MCP23017 for 8 x 8 key pads.

For newbies, I usually recommend not to start with MCP23008/MCP23017, because their learning curve is very steep.

I would suggest to:

start testing as simple as possible:

using only 2 Rpi GPIO pins to detect 4 buttons.

The principle of doing 2 x 2 = 4 keys is exactly the same for 16 x 16 = 256 keys. You might like to read my answers to the following posts to get a rough idea of what I am talking about.

Multiple GPIO Buttons

Connecting 32 Magnetic Sensors

keypad 1

keypad 2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.