Input on plans for a Pinball Machine

I should probably start by saying that I'm completely self taught electronics and programming wise. I decided it would be cool to build a full size Pinball Machine, and my first thought was that an anduino would probably work well. I've never used an anduino before, and some of the electronics concepts are also new to me, so I was hoping to verify that my thoughts are ball correct before going out and ordering parts.

The problems:

At first count, my design for a Pinball Machine will require ~100 IO ports, much more than the biggest anduino I've found (either the mega 2560 or the due, which both have 54).

24 lights
20 solenoids
29 inputs

The inputs I don't think will be a problem besides from the amount of them. I'm not really sure if there's anything you can do about that though.

The solenoids have the additional problem of voltage/current. My research suggests they'll draw anywhere from 0.1A to 5A at various voltages. (it's hard to find general numbers, since it will end up being per solenoid most likely. I read that the flipper solenoids use 46V). Obviously the anduino can't supply this directly, and after a bit of googling I think the correct answer is to use transistors, which would let a strong current pass through only when the weak signal from the anduino is put in the third contact. (just want to verify I'm understanding that right)

The lights are the biggest problem. These 24 are just a minimum, I'd prefer to have more, but I also realized that they won't change very often, and latency isn't very important either. Theoretically, I feel like there should be sleeping extra circuit out there where I could just pulse, in binary, the number of the light I'd like to toggle, which would mean I'd only need 5-6 pins for the lights. Does something like this exist? I assume a similar method could be used for the solenoids as well, or at least the ones that are less important latency wise, which would allow me to squeak in under the 54 io limit.

I'm hoping someone can verify what I've said here, and maybe point me in the right direction towards this "switching circuit", as well as point out any other problems I might run into?

Thanks

which would allow me to squeak in under the 54 io limit.

There is no I/O limit. If you want more outputs you simply use shift registers, a different type of shift register also works for inputs as well.
The other options are I2C or SPI port expander chips which typically can give you and extra 64 I/O pins for each bus.

One possibility is something like the Centipede shield:

That has 64 pins that can be configured for input or output individually (it uses 4 x MCP23017 I2C expander chips).

It has an address jumper so you can actually have a second one on the same I2C bus.

An alternative is to use the 74HC595 (or similar) shift registers. This post shows 4 of them controlling 32 LEDs:

You can always use more than 4, daisy-chained together.

There are also such things as input shift registers, like the 74HC165, for your inputs.

You will need, as you acknowledge, some way of converting logic level outputs to drive your solenoids and things. Looks like you will need a lot of them. MOSFETs are probably what you want, as they act more like switches than amplifiers. I think you can get them in packages (eg. 4 in one IC) if you are trying to run a lot of them.

Those all look great, thanks!