Step 5: Wiring

Picture of Wiring
With all of the components securely fitted inside the enclosure, it's time to work out what needs to be wired where.

The ATMega328 chip used on the Arduino contains internal pull-up resistors, so we won't need to wire individual resistors for each of the arcade buttons. This greatly simplifies the controller wiring. So all that needs to be done to wire the arcade buttons is to solder one leg to ground, and connect the other leg to one of the digital inputs on the Arduino board.

That said, pin 13 can not be used as a digital input with the internal pull-up resistor. See the pullup resistors section in the Digital Pins article on the Arduino website for the reasons why. For this pin we'll be using an external pull-down resistor. If you're unsure what a pull-up/pull-down resistor does, check out this great tutorial on ladyada.net .

Wiring the potentiometers requires a ground wire, a wire to the one of the Arduino analogue inputs, and a third +5V wire. As the potentiometer is rotated or adjusted, the resistance of the potentiometer changes between the ground and +5V wire. According to Ohm's law, voltage = current*resistance, so with a constant input current and a variable input resistance, the output voltage will be variable. It's this variable voltage that the Arduino reads on the analogue pins.

The attached wiring diagram (created with the great Fritzing software) shows how to wire up each of the components to the Arduino board. The black wire represents ground, the red wire represents +5V, the purple and orange wires are digital inputs to the Arduino, and the blue and green wires are analogue inputs to the Arduino. Note that the ground wires and +5V wires have been bridged between the buttons and potentiometers.

Before proceeding to the next step you may find it helpful to print out a copy of the wiring diagram to refer to whilst you solder.

hey , is it possible to make a controller with two faders , 8 knobs?

djozmo2 years ago
hmmmm.....would this work with Teensy? This is sort of a thinking out aloud question, I am very new to this...and have my research to do..I think it would work. care to comment? :) By the way GREAT instructable, thanks for the awesome work!
headsdeep4 years ago

you rule .
thank you so much for this perfectly put down info

i hope you make piles of cash and or happiness

question one can i extend this with the arduino mega

by just following the above diagram but with many more buttons and sliders?

question 2 is it possible to insert simple leds that only light up when you hit the button?

if so where would theey go in this scematic?
thank you much
fraganator (author)  headsdeep4 years ago
Thanks for the kind comments :)

You should be able to run this on the Mega no problems by simply adding more buttons and sliders.

Connecting an LED to each button shouldn't be a problem either. Just connect the LED's cathode (short leg) to the button's leg (the one which connects back to the Arduino input), and connect the LED's anode (long leg) through a resistor to 5V. When you press the button the LED should light up, and switch off when you release the button.
redtraceur4 years ago
IS it possible to re upload the wiring diagram for Fritzing or give an alternate link i try to download but it is a .tmp file not matching withc fritzing .fz
fraganator (author)  redtraceur4 years ago
I just tried it out in Chrome and it does indeed save it with a .tmp extension. Simply rename the file with a .fz extension and it should work.
Lol that was more than simple thanks a lot for the reply, im trying this may be on weekend till i get the materials and components.
trainables4 years ago
Thanks for the wiring diagram! Much easier to follow than schematics only.