Friday, May 22, 2009

Arduino Pinball Hacking

My pinball machine does not have a functional MPU. The MPU is the board that has the logic for the rules of the particular game, and it communicates with the phyisical aspects of the pinball machine (the solenoids, the lights, and the switch matrix). Without a working MPU, the pinball machine doesn't do much of anything at all. Luckily for me, replacement MPUs exist for older machines like mine, and are relatively inexpensive.

I've been messing around with the Arduino lately. It's an excellent little embedded platform for hobbyists and goofing around, and you can do serious work with it as well.

I decided that it would be pretty spiffy if I were to create an MPU replacement using an Arduino. The interfaces to the other boards (lights, solenoids) and the switch matrix is documented with great detail in the manual for the machine itself. There are full schematics, as well as a number of repair tutorials available on the internet. There was even a project to create an ISA controller card doing just what I want my Arduino to do.

I envision my project progressing as such:
  1. get a switch matrix scanning routine and associated hardware working. This will permit me to monitor the ball on the playfield from a PC connected to my Arduino via the USB cable.
  2. get a lamp refreshing routine and associated hardware working. This will permit my controlling PC to set the state of the playfield lights
  3. get a solenoid triggering routine/hardware working. This will permit my controlling PC to pop bumpers and play chimes, etc.
  4. get a score display routine/hardware working. This gets me the ability to set the scores on the back-box, and is the last piece of direct interaction.
  5. write a simple game rule set that runs on the PC that allows me to play the pinball machine
  6. figure out how to make the Arduino autonomously follow that game rule set (either a library of the hard-coded game rules, or some sort of super-simple byte-code indicating events to watch for and what to do to the score and bumpers and lights, etc)
It's auspicious, but it seems like it could be many hours of fun!

This would permit me to take off-the-shelf Bally replacement parts and create my own pinball games!

Given the above features as a "version 1.0" of the project, I've already got some "2.0" plans in my head. For instance, the hardware for the controller could act as a man-in-the-middle for an authentic MPU. It could both monitor exactly what the real MPU is doing (and report it to the PC) and it could completely override the MPU. It could trick the MPU by showing fake switch presses.

Tuesday, May 19, 2009

The Mechanical Sudoku Turk

I've come up with an excellent art/tech project just now. The basic concepts are to create a Mechanical Turk aimed at solving sudoku puzzles. A player would input the puzzle via a keypad and switches on the panel of the machine, and pull a lever. The turk would come alive and start banging and clacking and tooting and clunking as it "mechanically solved" the puzzle. The actual brains would be a simple program on an embedded platform hiding inside the console, obscured by the gearing and woodwork. Different solution steps would produce different mechanical events, set to a specific metre. If the puzzle could not be solved, then an error buzzer would fire, and it would go into "tilt" mode. Instructions on the face would indicate how to reset the tilt mode, and claim your fortune. A successful solve would play a short unique sequence of notes and emit the fortune card.