LED Arcade Buttons
The 30mm arcade buttons in the Adafruit shop are excellent for retrogame projects. They're also quite aesthetically pleasing. They feature a translucent body with a very slim micro switch, so it's great for internal lighting effects.
Although they do not have LEDs built in, you can actually fit NeoPixels into the body with a 3D printed diffuser.
In this tutorial you'll learn how to add NeoPixels to arcade buttons.
Check out the following guides below to get a better understanding of the Trinket micro-controller, NeoPixels and the NeoPixel Arduino library.
Parts, Tool & Supplies
You'll need 30mm arcade button and some NeoPixel mini's (the 8mm x 10mm cuties), an arduino micro-controller and a power source. If you don't have access to a 3D printer, you can send the files to a service or check with your local hackerspace/library.
3D Printed Parts
All you need is these two parts, thats it (for one arcade button, at least).
You can use the settings below as a reference. The parts are oriented in the center of the bed and ready to print "as is". They do not require any support material.
4 top/bottom layers
.2mm layer height
about 5 minutes
about 5 minutes
The parts were modeled in Autodesk 123D Design and available to modify. The file includes the original solids and sketches.
The cap snaps onto the connector piece and they're held together by friction. The tolerances for these parts will vary depending on your print settings, but you can download and modify the design to fit your project.
For a nice soft LED diffusion, ideally you want your diffuser printed a filament with a light colored pigment. White, natrual and of course transparent filament will work best.
In my demos I used glowFill, which is glow-in-the-dark PLA/PHA filament from Colorfabb. It's kinda cool that the NeoPixel LEDs charge up the material so it glows when the lights are turned off.
Arcade Button Anatomy
The arcade button is very modular and really easy to take apart. The button consists of four pieces.
- Mini micro switch
Remove the cap
To get to the clicky center of the button, we need to remove the top cap. Look for the two openings in the side of the button. You'll see a clip on the side, near the top of the opening. Use a screwdriver or flat pliers to push the clip inward and up, so that the cap lifts up from the body.
Pull off cap
If the cap is hard to remove, try pushing in both of the clips from the side. Carefully pull the cap off the button.
Remove Stock Diffuser
The stock diffuser has a stem coming from the center. Grab it and pull it out. You can disgard this or save it for another project.
Install 3D Diffuser
Insert the 3D printed diffuser into the top cap with the cut outs lined up with the clips on the sides. Press it down, all the way into top cap. The tolerances should have a tight hold.
Make sure the two nubs on the side pass through the slits near the clips.
NeoPixel Mini PCB wiring
The NeoPixels require three wires, power, data and ground. These are indicated on the pads near on the bottom of the PCB. The arrow indicates the direction of the chain.
Wiring Multiple Pixels
You'll need to determine how many NeoPixels your project will need. NeoPixel LEDs can be chained together by soldering wires from the data in to the data out.
The wires in between NeoPixels should have a minimum length of about 6cm - This will vary depending on the distance between the buttons in your project.
Carefully insert the chain of NeoPixels through the opening in the side of the arcade button. This opening is just large enough for the NeoPixel mini PCB to pass through.
If your project uses multiple buttons, you need to pull the entire chain of NeoPixels through the body of the first arcade button.
Depending on how many NeoPixels you have, you'll need to thread them all!
Pull the first NeoPixel in the chain to the center of the body and position the wires so you have some slack to work with.
Mount to Connector
Insert the NeoPixel mini PCB into the 3D printed connector using flat pliers. The PCB fits in the center of the part and held in place with the two clips on the sides.
The NeoPixel mini PCB is fitted into the 3D printed part.
The NeoPixel should only be installed into the connector if its installed through the arcade button!
Insert the connector into the diffuser cap with the wires lined up with the cut outs. Press the two pieces together to snap them shut.
Installed NeoPixel Diffuser
The bottom of the 3D printed connector has space for wires to pass through.
Install Cap to Body
Insert the assembled diffuser cap into the body of the arcade button with the clips lined up with the openings on the side.
Be aware of the wires while installing the cap, they could get stuck or kinked!
NeoPixel Wire Check
Ensure the clips from the cap are in place and free to press. There should be enough clearance for the wires to be strain-free.
Once you have the first time complete, you can repeat the process.
Light em' Up!
The NeoPixel works with most arduino micro-controllers. In this example it's wired to the 5V, GND and D0 pins on the 5V Trinket. You can use the strandtest demo sketch included with the NeoPixel Arduino library for a sweet rainbow animation and chasing pattern.