Home

Awesome

joycon

Joy-Con input driver for Linux

The current main code, written in Go, lives in the prog4/jcdriver folder, as it was the fourth attempt at making this program.

Compiling

sudo apt install libudev-dev go git

go get -u github.com/riking/joycon/prog4/jcdriver # Download and build the program
cp $(go env GOBIN)/jcdriver ./jcdriver # Copy the binary out of where Go drops it
sudo ./jcdriver # Run the driver

If an old Go version is installed and it complains about GOPATH not set, run:

export GOPATH=$HOME/go

and try again.

Basic Instructions

After starting the program as root, connect the Joy-Cons over Bluetooth. Once the program has picked them up, the player lights will begin flashing. Press L+R on the joycons to "pair" them up as a single controller device, which is then available to the rest of the system.

If you want the joycons to function as a pair of controllers with analog sticks, press the SL + SR buttons to pair as a single controller.

If your game needs a stick axis to be inverted, specify --invert LV (or LH, RV, RH) when running jcdriver.

TODO: Interface to switch between the modes / drop controllers for re-pairing

Limitations

The code will not actively scan and connect to the joycons. When the code is run on Mac, the "press button to reconnect" works due to the OS bluetooth driver (though the code cannot provide the device to other programs, as that requires a kext).

TODO: Scan and reconnect mode for bluez.

TODO List

PRs and help for any of this is appreciated! If I neglect your contributions, try pinging me on Twitter (@riking27); I may have missed the notification.