I want to read 256 digital input, each of which is driven by a switch. I don't need to read state of all 256 switches more than 5 times a second (or may be even less). Multiple switches can be ON and OFF at any point in time. Obviously that's too much of wiring if I want to do it naively. So I want to do it as simply as possible without using loads of components or wires. My first thought is to have have 16X16 matrix with diodes. But that's too many diodes to add on to breadboard. So essentially I'm looking for some chip that will have 16+16 input pins that I can use it to feed in rows and columns of the matrix. That chip then will have (may be) 8 output pins that I can read somehow 16 times in succession to get all of 256 bits.
Questions I have...
- Does this kind of chip exists?
- Is this the best, cheapest and least messiest way to do it?
- Can it be done without chip with something like Arduno Mega that already have 56 bit input? I do want to reduce component count.
- Should I be using may be combination of chips which does only 8 rows and columns?
If you have any pointer to tutorial/guide to implement this, that had be great as well!