Builds

DIY Wireless Nintendo Switch Controller: A Step-by-Step Journey

I recently embarked on an exciting new project—building a wireless Nintendo Switch controller. The inspiration came from my love of Mortal Kombat, a game that’s hugely popular in my household. Playing it with the tiny Joy-Con controllers that come with the Switch? Well, let’s just say it doesn’t feel quite right, especially for an old-school gamer like me. I wanted something more authentic, reminiscent of the classic arcade cabinets with buttons and joysticks. And here’s the kicker: I wanted it to be wireless.

The Challenge: Finding the Right Solution

Building a wireless controller for the Switch seemed simple in theory, but when I started searching online for guides or libraries to help, I hit a wall. There are tons of resources for wired controllers, but I couldn’t find much for wireless setups. One library I found, GP2040-CE, works on a variety of devices like PlayStations, Xbox, and the Switch, but it requires a cable connection. That wasn’t going to cut it—I was determined to go wireless.

The GP2040-CE runs on the Raspberry Pi Pico, which is great since I’ve used it in previous projects. However, even though the Pico has a wireless version, I couldn’t find any proper wireless implementation for GP2040-CE. That was a dead end.

A Breakthrough: Discovering Handheld Legend

After some deep digging online, I came across something called the Handheld Legend. This controller looked fantastic, modeled after the classic Nintendo design, and ran on an ESP32 chip, which offers wireless capabilities. Better yet, it wasn’t just limited to the Switch—you could use it on a computer, GameCube, and other devices.

The Handheld Legend project even had a software installer. You just plug your ESP32 into your computer, head to their website, and install the firmware. It sounded straightforward enough, so I gave it a shot.

Hurdles Along the Way

But of course, no project ever goes off without a hitch. The wiring setup was a nightmare. The Handheld Legend uses a diode keyboard, which meant I had to breadboard the diodes and get everything wired correctly. I finally managed to get the buttons working, but when I checked the terminal, the software was constantly crashing. The issue? It kept trying to communicate with an I2C controller that I didn’t have—some sort of extra controller included in their kit, which I wasn’t using. Without this, the setup would fail, reboot, and crash again. So, another dead end.

A New Hope: OpenController-ESP32

Not one to give up easily, I kept researching and found something called OpenController-ESP32. This software doesn’t explicitly mention Nintendo Switch compatibility, which is why it’s so hard to find. But buried deep in the project is a component called HOJA, an ESP-IDF library with very limited documentation. The library is designed to interface with a wide variety of controllers, including the Switch, without relying on I2C communication. Perfect!

It even had a basic wired gamepad example, which seemed promising. However, I was venturing into unfamiliar territory. I’m comfortable with Arduino and Python, but this was a whole different level of complexity for me.

Fumbling My Way to Success

To get the project working, I downloaded ESP-IDF, the development environment for ESP32 devices, installed it, and followed the basic compilation instructions. I had no idea what I was doing, but to my surprise, it worked! I compiled the software, flashed my ESP32, and it actually ran without a hitch.

Before I committed further, I wired up all the buttons—12 in total—and connected everything. To my delight, it worked on the Switch! The D-pad, triggers, home, and select buttons all functioned perfectly. Now, I had a wireless Nintendo Switch controller. The only thing left was to hook up a battery.

Final Thoughts: It Works (Almost) Perfectly!

With the controller working, I tested it out on the Switch, and it performed great! I could easily pull off all the moves I needed in Mortal Kombat. One minor issue: one of the buttons wasn’t pressing down properly. But since I got these switches from China for a couple of dollars, I wasn’t too surprised. I’ll replace them with proper arcade buttons soon.

If you’ve seen my previous project—a Defender cocktail table—you’ll recognize the style of this build. For those interested, I’ve included links to the libraries I used in the show notes, so you can try it yourself. You could even buy the Handheld Legend hardware and just add an ESP32 for a wireless controller that works with Switch, PlayStation, and Windows!

Next Steps: Building the Arcade Cabinet

Now that the controller is up and running, I’m planning to build a mini arcade cabinet to house the setup. I’ll make the controller part removable so it can be used separately, too. That way, you won’t be stuck with the entire unit in your lap while playing.

So, stay tuned for the next phase of the project! If you love DIY and gaming, this build is definitely worth trying out.