This part will cover the wiring of your electronics, this includes the computer, DMD Screen, Audio, TV, buttons, plunger… It will take quite some time wiring everything up correctly and making sure everything is working as intended. But after this guide, it’s just software that remains.
DIY Virtual Pinball
Introduction & Design
Building the cabinet
Installing computer, controls, special effects
Adding games & tables
Setup PinballX & Controllers
Photo Album
With the cabinet now done, we still have a lot of space to put our parts in. I highly advise doing your best at cable management, you will probably fail at some point 🙂 as I did but try to keep it as organized as possible for your own good.
For turning ON and OFF the electronics in your pinball machine, I used a large industrial switch I had laying around. This switch has 2 modes: The usual ON/OFF and a temporary spring-loaded start function when you twist past the “ON” indication. The switch has two terminals, one can be used to switch the main power and the secondary terminals will be the temporarily closed contact that I will use to turn on the PC later. These switches are quite hard to get so alternatively you could add a momentary push-button next to your power switch.
Then I used the terminals to split both power lines and the ground.
I added a normal power strip because we will still have to power a lot of electronics that have a normal plug. Just mount it somewhere centered in your cabinet. Alternatively, you could use strong double-sided tape to secure it in place. Then cut off the wall plug of the cable and wire it onto your incoming power terminals. Make sure to connect the ground as well.
To power all of our special effects, I will repurpose an old PC Power Supply to provide +5V and +12V. Power supplies usually have 5 colors of cables with red being +5V, yellow +12V and black the GND. The green wire should be permanently connected to black to hotwire the power supply to turn on automatically whenever it’s plugged in (this is usually controlled by the motherboard). I connected these wires to a separate terminal for easier installation later when connecting the electronics.
I used double-sided tape to secure the power supply in the cabinet and screwed the terminals onto the side and bottom of the cabinet, Most of the 5V electronics are located in the front (button LEDs) so I recommend placing the 5V terminal to the front, 12V is used throughout the whole cabinet so try to place the 12V terminals somewhat centered.
Assemble the computer on your motherboard box and make sure it is booting as you don’t want to troubleshoot this when installing in your cabinet. After assembling the computer, I connected all peripherals and installed windows 10 (windows installed is required for the following steps) I also mounted some feet into the motherboard standoff holes that will be screwed into the cabinet. These feet are very cheap and I ended up using them for every chip that needs to be mounted.
This computer will be powered by its own power supply (not the one we use special effects). I used double-sided tape to stick the Power supply to the back and bottom of the cabinet. Then connected the CPU and Motherboard cable to the motherboard. I also connected the boot SSD and HDD and stuck it to the side of the cabinet using double-sided tape (this tape gave problems when I wanted to back up the file system, I recommend using something less permanent).
To turn on and off the computer without having to open the cabinet, I added some wires to the power switch pins on the motherboard. The pin layout may be different for each motherboard so make sure to check the manual. Depending on your choice these will be connected to the large switch or a dedicated Power button that was installed earlier. The computer will register a power button press whenever the wires are connected/shorted. make sure the switch is only momentary as keeping these wires shorted for over 6 seconds will force your computer to shut off again.
The motherboard I chose was equipped with 4 USB ports, we need at least 7 ports so I bought and stuck a powered 8-port USB3.0 hub to the side of my cabinet using double-sided tape. This will be used to connect all the peripherals to the computer, as well as the DMD, Saintsmart, Controls… I strongly recommend a USB hub with external power because powering all those boards can be pretty much for a single USB port and this will also minimize the risk of random disconnect issues.
Now connect the monitor that is already installed in our backbox to the HDMI on your graphics card. Turn on the computer and make sure everything is working as intended.
Most of our lighting will be controlled from our LEDWiz including the button LEDs. Since most of the lights we need to control are in our front panel I recommend placing somewhere in the front of your cabinet. I used the handy feet I used to secure the motherboard in place. The LEDWiz requires external power and should be powered by the same PSU as the LEDs. The GND terminal on the LEDWiz should be connected to the previously repurposed PSU.
Testing software for the LEDWiz
I recommend downloading LEDBlinky and run the handy “SimpleLEDTest.exe” utility. In the left bottom corner, there is a checkbox to apply the slider intensity on all outputs, or you could manually select the output you want to test. This will come in handy while wiring your LEDs.
⚠️ it’s important to power down everything when you are working on the electronics, wiring hot wires to the LEDWiz while powered on may cause damage.
Button and Coin Door LEDs
It is important you know what voltage your button lights are. The VirtuaPin set comes with regular 12v bulbs which I replaced with longer-lasting 5V extra bright LEDs. I will only require 5V for my lights. You can keep the regular bulbs to make the build more authentic but remember to connect them to the 12V terminal on the repurposed PSU instead.
⚠️ I recommend switching to 5V LEDs as the regular bulbs draw as much power as 10-15 LEDs combined. , Secondly, the LEDWiz will get very hot, and the new models come with heatsinks installed on the 4 main chips.
The positive +5V wire can be daisy-chained but each button will require a single (negative) wire to your LEDWiz. The LEDWiz will basically act as a USB controllable pack of 32 ON/OFF switches.
I attached 4 LED strip profiles on the bottom and back of my cabinet. I will use 144/M RGB LED strips to put in these profiles, simply slide off the cover, stick your led strip to the inside of the profile and reseat the cover. I kept the original connectors for an easier replacement if needed. I drilled a small hole to feed through the cables on the back and on the underside in the front of the cabinet
- The underside of the cabinet Left and Right (2x 1m30cm)
- The backside of the cabinet ( 2x 60cm)
- The Backside of the backbox (2x 70cm).
I used the attached plugs to conned the strip on the back of the cabinet with the strip on the back of the backbox
This way I end up with 4 RGB controllable ‘zones’. To wire these strips to the LEDWiz we need small LED Amplifier chips. These LED strips draw quite some power which will be too much for the little LEDWiz to handle. With these Amplifiers, we can offload the power draw to our repurposed Power Supply and have the LEDWiz control this power with little to no load on itself. Also when connecting the amplifier to your LEDWiz, make sure to connect them in RGB order, this is required due to a limitation of the software we will use later. The wiring for the amplifier should look like this:
Then I wrapped the amplifier in some electrical tape to prevent it from shorting with other electronics.
Create 4 LED amplifiers like shown above and connect the main 12V to your repurposed Power Supply. This will provide the actual power for the strips to turn on. Then connect the input wires (RGB) to your LEDWiz, and the positive to your 12V repurposed PSU. To test your wiring, use the LEDBlinky simpleledtest tool.
Backbox Flashers
I also mounted 2 – 12v Flashers on top of my backbox, wiring these to the LEDWiz is fairly easy but you have to find a way to get the wire from the top of the backbox all the way to your LEDWiz. I recommend leaving some extra because when you flip down your backbox (for transport), You will need some extra. This will be for every part inside the backbox, leave some extra to allow the backbox to be folded down. The two backbox flashers run on 12V volts from the repurposed Power Supply. The negative wires can be connected directly onto your LEDWiz.
In-cabinet lighting
Since I was building the pinball table in my basement, I added 2 ZebsBoard flashers to provide extra light while working inside of my cabinet (and I’m very happy I did). These flashers are quite cheap and run off 12V. Just screw this on the side of your cabinet, connect them directly to the 12v terminals on the repurposed PSU. They light the inside just fine.
First, we have to install the main controller board, this should be installed as close as possible to your plunger and the rest of the control panel so the right bottom corner is perfect. Since this board has a build-in gyro sensor to simulate table nudging, the angle you mount it in your cabinet is very important. As shown in the pictures below, you want to mount it to the USB ports are facing the left of your cabinet. I used the same feet I used for the motherboard and ledWiz to mount it in place.
When the board is installed, you will need to connect a wire to every button on your front panel, to make this easier. I used terminals on every one of these wires. The order of the buttons is not really important as we’re going to map the buttons differently later using the software. As long as they are connected and recognized by windows you are fine. A handy tool for this is windows joystick panel, this will show all buttons on your controller and when they are pressed. You can also see an analog input which represents the nudging sensor and the actual plunger. Try hitting your cabinet and it should move slightly. The sensitivity can be adjusted later using the VirtuaPin software.
Wiring Normal Buttons
Cabinet buttons are very easy to connect, just connect one of the terminals to your VirtualPin controller and connect the other to the black wire or GND of the VirtualPin controller, this GND wire can be daisy-chained from one button to the next. The dedicated wires on the controller board are the positive ones, every button needs a dedicated wire to one of these. For attaching the wires to the buttons I will use terminal clamps. This makes the buttons easier to replace in case of breakdown. The process is easy, strip a wire, feed it through the hole and use tweezers to flatten the cable insert. Then I usually add a bit of solder to make sure it won’t come loose from an accidental yank.
When all buttons are installed and you verified all buttons are working in the windows joystick manager, your control panel should look something like this:
Wiring Flipper Buttons
Leaf switches are made to ensure a clean connection every time you press the button, these are mainly used for the flipper buttons as it’s very important they don’t skip/miss a single press. The wiring is basically the same. The installation requires a few extra parts in contrary to normal arcade buttons. Solder wires to both metal plates and attach them to the VirtuaPin controller just like a normal button. I chose not to daisy chain these as it will be easier to replace one in case of damage.
Wiring Analog Plunger
The plunger installation is very easy, connect the sensor tube to your board and slide the sensor tube over your plunger. The sensor tube can detect the pull distance of the plunger but also acts as a button when pressing it down into the cabinet. This can be used for skill shots or if the software does not support analog plunger input this will make sure your ball launches. Connect the wire for the sensor tube onto your virtual controller, then slide the tube over the plunger shaft. The sensor tube should fit tightly on the plunger’s base. Make sure when pulling back the plunger it does not hit or move the sensor tube, the plunger should move freely. (there is a distance sensor at the end of the tube registering its pullback distance.
The Saintsmart USB Relay board comes with 8 independently controllable relays which will be used to trigger the (larger) relays and the rotary light on top of the backbox. I used the same feet I used earlier to mount the Saintsmart in the center of the bottom cabinet. The Saintsmart requires 12V external power from our repurposed power supply.
Test Tool
To test the Saintsmart, download and install “8 Relay Board Manager” (link), This tool allows you to turn ON and OFF every relay manually for testing. You should hear a click when pressing the corresponding relay in the software. I also recommend testing each relay before starting any wiring to make sure your board is fully functional.
⚠️Make sure everything is powered down and the cabinet is unplugged before wiring stuff to your Saintsmart. These relays will be used to switch high voltage effects
Rotary Light
The rotary light I found had mounting feet which I used to secure it on top of the backbox. Then I cut off the plug from the cord and connected one of the wires to the Saintsmart and the other one directly onto the wall power terminals installed in the first step.
⚠️ We are working with high power here, it’s recommended to add a fuse somewhere in the chain if the light did not come with one. Keep in mind the voltage is deadly as well as your other electronics which can ruin your complete build, take your time and double-check every connection. Since the rotary light is AC, we need following the wiring
DIAGRAM SOON
Relays
Did I mount 4 relays throughout the cabinet for reenacting the mechanical sound and feel of a real pinball table. Relays usually have a. A+ and A- contacts, these are the terminals to the actual coil which makes the contacts close. We only need the sound of the contacts closing so no need to wire an actual load to the relay. We also need to add a small diode to minimize kickback
⚠️ Some relays depend on a load to get triggered, make sure the ones you order do not require any load and will close even with no load connected.
DIAGRAM SOON
The flasher bar will require a secondary LEDWiz to be controlled. Each of the 5 RGB flashers requires 3 wires and the outer flashers each require another port on the LEDWiz for a total of 17 ports. I installed the LEDWiz in the rear of the cabinet and connected the GND to the repurposed PSU. The LED’s draw a lot of power so we need to lower this using a small resistor board. I used small breadboards and the following resistors per color:
- Red: 33 Ohm, 5W
- Green: 27 Ohm, 5W
- Blue: 27 Ohm, 5W
Then wire the RGB wires from each of the LEDs onto the resistors. Then on the other side of the resistors add some RGB wiring to connect to your LEDWiz. I then used electrical tape to cover any exposed wiring.
Then connect the RGB wires onto your LEDWiz in the RGB order. Also, wire the black wire of each of the boards onto the 12v of the repurposed power supply
Now to test your flasher bar, open SimpleLedTest and see if each LED and color is working. The outer flashers do not require any resistor board and can be wired directly onto the LEDWiz.
PinDMD
The pinDMD is powered by the same PSU that’s powering the computer. This will make the DMD only turn on when your computer is turned on. This way you can have the cabinet lighting powered on showing off your table even when you are not playing. The pinDMD works with +5V and comes with a long Molex cable that should plug directly into one of the Molex connectors of your PSU
Audio
For the audio system, I’m using one of the kits which are very easy to connect. Just connect the backbox speaker and subwoofer to the corresponding terminals using speaker wire and plug in the power cable for the amplifier.
Then use a 3.5mm –> RCA cable to connect your computer, the amplifier has a crossover knob for the subwoofer, this will allow you to adjust the sound to your hearing. Then I launched Spotify. The audio quality is not bad, the subwoofer is pretty flexible and makes the cabinet shake which is a great special effect.
The TV will rest on the wooden bars on the sides of the cabinet. To keep the TV from flexing, I placed a wooden board on top of these bars and then put the TV flat on top, Then connected the power and HDMI. I recommend drilling some ventilation holes for your TV as I was running into troubles with my TV running too hot and shutting off.
Playfield Glass
The playfield glass can now slide in over the TV and the Lockbar can be put on.
All the electronics are now done and your control panel is now fully operational.