feasible maximum inputs/outputs?

Hi! My Arduino is coming in the mail today and I had a question about expanding outputs and inputs using shift registers and/or analog multiplexing.

I've read the shift registering and multiplexing tutorials, but neither tell me what the conceivable maximum inputs and outputs you can achieve are.
For that matter: is it possible to use shifting to increase inputs and outputs simultaneously? If not, would it be possible to multiplex analog inputs and use a shift register to increase the outputs?

For the curious: I'm trying to figure out if I can use the Arduino to power a homemade pinball machine. The pinball machine I already own (a 1973 OXO) and whose timeframe/feel I am trying to mimic has 25 switches and around 50 outputs (including indicator lights, scorewheels, and bells). I'm trying to figure out where I will need to cut corners and find alternate solutions in my final design. I know that using additional chips will likely be necessary (i.e. LED drivers, external memory to store scores, possibly a second Arduino board for sound) but due to the lack of information on Arduino projects of this scale and the fact that everyone else seems to be trying to serial interfaced computers to do this sort of thing, I'm slightly concerned as to whether this is possible.

Thanks in advance for any advice!

ps: is possibly a software question as it's really a question of whether coding the above simultaneously is possible, but hardware seems like a more appropriate forum :smiley:

hi

6 output pins driving a binary decoder will give 2^6 outputs, or 64 outputs.
For the input pins, you can use something like the mulitplexing scheme described in the Playground examples page by Fluidforms.. they use 63 resistive input sensors.

D

So in other words: doable, assuming I use digital for the outs and analog for the ins.

Great, thanks! I'll start with figuring out the inputs.

-j

hi

yes very doable... if you just want digital in/outs, you could have lots using a binary decoder like the CD74HCT4514. that will take 4 pins and turn them into 16. The one problem with getting enough outputs is finding a chip that has, say, 64 output pins. You could also use a shift register, like the Philips 4794 shown in this tutorial, but you sould have to check and see if the outputs can be set to "open collector" state when you are shifting the data in, so that your relays would not get triggered in domino-sequence fashion.

D

See, I knew there would have to be some kind of trick. I'll see what I can come up with (either on finding a 64 pin chip, yeep, or shifting). Thanks so much!

Hi

I looked at the data sheet and there are strobe and enable inputs on the 4794 that will let you load the appropriate data without triggering the outputs.

D

Hej,

we made a project two years ago that included 64 inputs and 64 outputs. we used 4051 multiplexing the inputs and 4794 for shifting the outputs. As a result we got some eagle files for the multiplexers. The circuit is about 180x120mm if you are interested I will post them somewhere for you (and the rest) to download it and use it.

/d

David:
Please do! I'd be really interested in seeing it!