Play Nintendo Switch using an original N64 controller via an Arduino Uno!

N64 -> Arduino Uno -> Nintendo Switch

Description

By connecting an original N64 controller to an Arduino UNO R3 running this code, and plugging the USB from the Arduino into a Nintendo Switch, you can use your original N64 controller as a Switch controller! The button mappings were made using The Legend of Zelda: Ocarina of Time on Nintendo Switch Online and the buttons are mapped 1:1.

Inspiration

Due to:

  • the unavailability of Wireless Nintendo Switch N64 controllers
  • no restocks in sight
  • a growing library of nostaligic N64 games on Nintendo switch online

I wanted to try to somehow interface my original N64 controllers with my Nintendo Switch. From creating several macro programs in the past based on the Splatoon pixel art drawer by shinyquagsire23, I knew I could send button presses to the Switch. I just had to figure out how to get N64 controller data from the controller and to the Atmega16u2 on the UNO. Then I found the project by twinone, that allowed you to use an N64 controller with an emulator, but not a switch. So I Frankenstein Monster'd those projects together and made this!

Setup

To program the Atmega328P

  1. Plug in your Arduino to a PC and open 'N64Simplified.ino' in the Arduino IDE.
  2. Install the Arduino N64 Controller Interface Library
  3. Upload to your Arduino To program the Atmega16uP (dfu-programmer required on linux/osx, flip on windows)
  4. Plug in your Arduino to your PC if it's not already
  5. Short the Reset and Ground pins for the USB-Serial Processor
  6. In the root directory of this project, run ./flash.sh Joystick.hex. This will make it so you will no longer be able to program your Arduino's Atmega328P. If you want to restore that ability, you can run ./flash.sh uno.hex and you should be back in business.

Once both these steps are done, you should be able to wire your N64 controller with your data wire on pin 2, then plug your USB cable from the Arduino into a Switch and play some games!

Notes

While looking into converting the joystick x/y axis, I found an article talking about how joysticks rarely have the full range and how developers should only rely on about 1/2 of the full axis range. To fix this, when initially started, I added logic so the joystick will start at 2x sensitivity and auto-scale sensitivity per-side of each axis to allow even old joysticks to get full range.

Many thanks to the work of shinyquagsire, twinone, MickMad, Andrew Brown, Peter Den Hartog, Kai Luke, pothos, Dean Camera, Darran Hunt and many more!

Similar Resources

Read Books On Your Nintendo Switch

Read Books On Your Nintendo Switch

eBookReaderSwitch Features: Saves last page number Reads PDF, EPUB, CBZ, and XPS files Dark and light mode Landscape reading view Portrait reading vie

Nov 23, 2022

A decompilation of the Nintendo Switch version of Captain Toad: Treasure Tracker [v1.3.0].

cttt-decomp A decompilation of the Nintendo Switch version of Captain Toad: Treasure Tracker [v1.3.0]. Build Instructions Obtain a clean copy of a mai

Aug 17, 2022

Open source Splatoon 2 save editor for the Nintendo Switch (NX) built on top of the effective-spoon project

Open source Splatoon 2 save editor for the Nintendo Switch (NX) built on top of the effective-spoon project

Open source Splatoon 2 save editor for the Nintendo Switch (NX) built on top of the effective-spoon project

Sep 16, 2022

A cheap,simple,Ongeki controller Use Keyboard Simulation and Mouse Simulation to controller the ongeki game. Using Pro-micro control.

A cheap,simple,Ongeki controller Use Keyboard Simulation and Mouse Simulation to controller the ongeki game. Using Pro-micro control.

N.A.G.E.K.I. A cheap,simple,Ongeki controller Use Keyboard Simulation and Mouse Simulation to controller the ongeki game. Using Pro-micro control. 中文版

Dec 8, 2022

A cheap,simple,Ongeki controller Use Keyboard Simulation and Mouse Simulation to controller the ongeki game. Using Pro-micro control.

A cheap,simple,Ongeki controller Use Keyboard Simulation and Mouse Simulation to controller the ongeki game. Using Pro-micro control.

N.A.G.E.K.I. PLEASE CHECK Main Project A cheap,simple,Ongeki controller Use Keyboard Simulation and Mouse Simulation to controller the ongeki game. Us

Dec 30, 2021

Upgraded from Pixar postcard path tracing, instead of printing Pixar, this program print my name, which pose to be more challenging than the original code. The upgraded is also more readable and run 9x faster than the original source code.

Upgraded from Pixar postcard path tracing, instead of printing Pixar, this program print my name, which pose to be more challenging than the original code. The upgraded is also more readable and run 9x faster than the original source code.

SDF-Sphere-Tracing Upgraded from Pixar postcard path tracing, instead of printing Pixar, this program print my name, which pose to be more challenging

Dec 29, 2022

Original hVNC has been recoded to work with all version of windows above XP. Thanks to the original author for this wonderful tool.

hVNC - Recoded This is the recoded version of the hVNC found in TinyNuke trojan. Compiling Compile tested with Visual Studio 2017. No compile errors.

Jan 22, 2022

Library of useful C++ snippets and reusable classes I've created as I build out Arduino Uno and ESP32 projects.

Arduino Snippets Library of useful C++ snippets and reusable classes I've created as I build out Arduino Uno and ESP32 projects. Button A simple butto

Feb 5, 2022

USB serial TTY for the Arduino Uno with ILI9341 LCD screen shield

USB serial TTY for the Arduino Uno with ILI9341 LCD screen shield

ILI9341TTY USB serial TTY for the Arduino Uno with ILI9341 LCD screen shield [video] Semigraphics, ANSI, unicode, and an Arduino LCD-screen terminal I

Sep 30, 2022
Comments
  • LUFA Problem

    LUFA Problem

    I am trying to compile your project as discribed by you, but i get following error. exit status 1 LUFA/Drivers/USB/USB.h: No such file or directory how did you add LUFA to your project ?

Use Nintendo Switch JoyCons as a virtual Xbox 360 controller in Windows

XJoy XJoy allows you to use a pair of Nintendo Joy-Cons as a virtual Xbox 360 controller on Windows. XJoy is made possible by ViGEm and hidapi. Suppor

Jan 3, 2023
Design files and resources for building a wireless N64 controller
Design files and resources for building a wireless N64 controller

wireless-n64-controller This project and its documentation is a Work-In-Progress. I'm still working on writing everything down and working out kinks i

Dec 23, 2022
A Fingerprint Door Lock using a microprocessor named Arduino UNO and programming through Arduino IDE
A Fingerprint Door Lock using a microprocessor named Arduino UNO and programming through Arduino IDE

INSTRUCTIONS - The codes for the Fingerprint Door lock are present in the Code For Fingerprint Door Lock folder The instructions of how to operate the

Mar 3, 2022
a pc heat verifier using arduino uno and oled screen(ssd1306)
a pc heat verifier using arduino uno and oled screen(ssd1306)

pc-heat-check a pc heat verifier using arduino uno and oled screen(ssd1306) to this application works needs this other application running: https://gi

Oct 5, 2022
A Nintendo Switch homebrew for importing and exporting Miis.
A Nintendo Switch homebrew for importing and exporting Miis.

MiiPort A Nintendo Switch homebrew for importing and exporting Miis. Installation Download a release and then place the .nro file at sd:/switch/MiiPor

Aug 23, 2022
Moonlight port for Nintendo Switch
Moonlight port for Nintendo Switch

Moonlight-Switch Moonlight-Switch is a port of Moonlight Game Streaming Project for Nintendo Switch. Thanks a lot to Rock88 and his Moonlight-NX, lots

Jan 5, 2023
Gamepad firmware for RP2040 microcontrollers supporting Nintendo Switch, XInput and DirectInput

GP2040 Firmware GP2040 is a gamepad firmware for the RP2040 microcontroller that provides high performance and a rich feature set across multiple plat

Jan 8, 2023
Tesla cheat trainers for Grand Theft Auto: The Trilogy - The Definitive Edition for the Nintendo Switch.

nxGTA-Trainers This is a set of tools for cheating in Grand Theft Auto: The Trilogy - The Definitive Edition for the Nintendo Switch. While I will try

Oct 4, 2022
English Translation Mod for Air Nintendo Switch version

AIR-ENX English translation mod for Nintendo Switch version of "Air" 1.0.1 Current status: Alpha Chapters translation status: Dream 100% Summer 100% A

Sep 6, 2022
Nintendo Switch Emulator
Nintendo Switch Emulator

yuzu yuzu is the world's most popular, open-source, Nintendo Switch emulator — started by the creators of Citra. It is written in C++ with portability

Dec 31, 2022