Introduction: Making a USB Game Controller
Here at NextFab, we designed a fully functional, USB game controller for Philly Tech Week. This project will be particularly tricky without some more serious electronics equipment or a local makerspace with the proper tools, but we thought we would post our walk-through in case you do have the access and would like to make your own!
- Laser Cutter
- 3D printer
- Stencil Printer
- Pick and Place machine - Manual or Automatic
- Reflow oven
- Soldering iron
- Electronic components (list attached later)
- PCB (Order from our Gerber files)
- 1/8" Acrylic
- NinjaFlex filament
- Hardware (list provided later)
Step 1: Circuit Board
The first step in making your own USB game controller is to grab an Arduino and start prototyping. It is important to make sure you use an Arduino Leonardo, Micro, or Due as they have HID (human interface device) capabilities. Essentially this means that they can act as a keyboard or a mouse and hooked up to a computer via USB. So to start interfacing, we hooked up 10 buttons to the Arduino Micro on digital pins 2-6, 8-10, 12 and 13 using a couple current-limiting resistors on the 3 LEDs.
To make a final controller, it was necessary to condense the whole perf-board - Arduino and all - to fit on one small PCB. We designed the board for this using Altium Designer and have exported and attached the Gerber files needed for board manufacture. So feel free to download ours and send them to your favorite fab house to make your custom controller.
Step 2: Board Assembly
In order to make your controller, once you get your board, you have to assemble it. Due to the surface-mounted microcontroller chip, this assembly will be difficult without a stencil and a pick and place machine. If you have access to a pick and place, the process is pretty easy. However, in assembling this board, you must mount all the surface-mounted components first if you plan to use solder paste and a reflow oven rather than a soldering iron. After doing this, you can mount all of your through-hole components and solder them in place. Attached is a list of the components needed to assemble the board. You can cross reference the component names in the attached materials list with the silk screen on the PCB to see what components belong where.
Step 3: Programming
Now that you have your fully functional PCB, it's time to program that microcontroller! We attached our functional code for the microcontroller, but feel free to customize your own. We are using the microcontroller to make keyboard presses that are typical for computer games, with the rightfour buttons mapping to the ASWD keys, and the left four mapping to to the arrow keys. The start button maps to the enter key and the select button maps to the space bar. The code can be fully customized and you just need to follow the comments to see how to change the mapping of the buttons. This can be customized for many different games!
Step 4: 3D Printed Buttons
The next step is making the rubber buttons! For this part of the process, we used a 3D printer and a material called NinjaFlex to print a rubber-like material. The 3D file we designed for the buttons is attached here.
Step 5: Laser-cut Enclosure
We then designed a simple laser-cut acrylic enclosure for the controller for which the illustrator file is attached. We countersunk the top 4 screw holes so that the screws wouldn't protrude. We used 1/8 inch acrylic - opaque for the top and translucent fr the bottom - but use whatever looks best!
Step 6: Assemble!
Grab your assembled boards, buttons, acrylic, and hardware and assemble! We used:
- (4) Flat 3/4" #4-40 screws
- (12) #4-40 hex nuts
- (4) #4 0.185" spacers
The assembly order should be (face down):
- 4 Screws
- Front plate
- 4 Nuts
- 4 Spacers
- 4 Nuts
- Back plate
- 4 Nuts
We have a be nice policy.
Please be positive and constructive.
Thank you for sharing your project. I'm able to burn the Leonardo bootloader and also to programm it with your code (via icsp-port). My problem is, that the usb-port seems not to work. My computer can't detect any usb-device. Do I need an additional driver, i though the Leonardo bootloader should be enough, right? Thanks!
I'm Paralized.. My fingers don't work. I need a arcade style controller for ps3_4 with an joystick for the camera . can I get help or lead me who can ?