Mark Baldridge is just out of high school, and wanted to tackle a project in a medium he knows and loves: pinball! He hand-built a pinball machine based on the online comedy duo Rhett&Link and controls all the electronics with a Raspberry Pi.

Being familiar with Python and Linux, Mark thought the Raspberry Pi to be a logical choice as a controller, but realized there were some limitations. The Pi only has a limited number of I/O pins, whereas his pinball machine would have many more switches, solenoids, and LEDs that would have to be individually controlled.

To overcome this hurdle, Mark used I2C, a master/slave buss interface for microcontrollers and peripherals. This interface was used with the MCP23017 microchip. This configuration makes it possible to increase the number of addressable GPIO pins on the Pi from 16 to 112!

The increased power needed by such components as the solenoids was handled by several transistors. The final product is quite impressive, with bumpers, flippers, lights, and a vertical-mounted LCD display. This young maker has created a formidable pinball machine.

In addition to being an online editor for MAKE Magazine, Michael Colombo works in fabrication, electronics, sound design, music production and performance (Yes. All that.) In the past he has also been a childrens’ educator and entertainer, and holds a Masters degree from NYU’s Interactive Telecommunications Program.

Might want to add a 1N4004 across that solenoid so he doesn’t blow up the IRL520

bill

What ka1axy said.. A snubber diode across the solenoid would be a good idea. The diode’s cathode on the +24 side of the solenoid and it’s anode on the transistor side of the coil. Here is an example. http://www.prc68.com/I/Images/Coil-Diode.jpg