You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
N64 Arduino Controller with 100% Analog Stick Sensitivity (Fix)
Author: Mariano L. Acosta
What you need:
A Nintendo 64 controller
An Arduino UNO
A set of 3 cables
FreePie Software (Free)
An N64 emulator that allows the mouse axis as a control input (i.e w/the NRange Input plugin)
Optional: Vjoy and UCR (software)
Intro and Motivation
This project is based on the instructable: https://www.instructables.com/id/Use-an-Arduino-with-an-N64-controller/ by quasse. Originally it uses Processing to read the data sent by the N64 controller in order to control the keyboard and mouse. However, the mouse version of the instructable doesn't work properly with an emulator because the playable character in a game get stuck when the cursor reaches the border of the screen. This is due the Java class 'Robot' used by the script in Processing that moves the cursor to an absolute position instead of using incremental deltas which are necessary for the controller plugin to correctly track the movement of the stick. A quick solution to this problem is to use the digital pad instead, but with this the sensitivity of the analog stick is lost and therefore the movement is not accurate.
The Solution
After an exahustive search on the internet I found this I/O emulator: https://github.com/AndersMalmgren/FreePIE/wiki (FreePie). So what I did was to create a simple script that reads the serial data sent by the Arduino, then unpack it and map it to the keyboard and mouse. I solved the problem of using 'deltas' in the cursor and now the analog stick works great with full sensitivity in Project 64. To use this solution, load the program 'N64_Arduino.ino' into an Arduino Uno, connect the cables to a N64 controller as the intructable says and then run the script 'N64Stick.py' with FreePie and now you are able to use the controller in a emulator with its full capability.
UPDATE: USB Controller
Once you have the controller mapped with the mouse and keyboard using this solution, you can use a virtual joystick emulator so that the PC can read the N64 joystick as an USB device. I'm using Vjoy with UCR (Universal Controller Remapper) and so far I didn't report any issue.
Please Note
You have to modify the COM port in the script to match your board. In my case I used the 'COM 3' port.