Daemonbite SNES controller to USB adapter

Topics regarding the Uzebox hardware/AVCore/BaseBoard (i.e: PCB, resistors, connectors, part list, schematics, hardware issues, etc.) should go here.
User avatar
danboid
Posts: 1881
Joined: Sun Jun 14, 2020 12:14 am

Daemonbite SNES controller to USB adapter

Post by danboid »

I recently built an arcade stick for my Uzebox that I also wanted to use with MAME etc on my laptop, RockPi and TV boxes etc so I'm happy to report that I have successfully built the open source DaemonBite SNES controller to USB adapter:

https://github.com/MickGyver/DaemonBite ... rollersUSB

The projects README uses a micro USB Arduino Pro Micro and micro USB cable but there are USB C versions of the Pro Micro such as the ones made by Diymore which also work fine with the same sketch if you prefer having a reversible connector or if you prefer to use USB C cables because you have more to hand, which is likely the case.

The adapter is simple to make. All you need apart from a Arduino Pro Micro (I used a Diymore Pro Micro which cost me about £10) is a SNES controller extension cable (~£5) and 5x wires with female dupont connectors to solder onto the ends of the extension cable after removing the extension cables male end and stripping its wires. Alternately you could crimp some dupont connectors onto the end of the SNES cable wires if you have a suitable crimp tool or just solder the wires straight to the arduino's PCB if thats more your style.

To flash the code (Sketch) onto the device clone its repo then plug the Micro Pro into your PC with a USB cable, open SNESControllersUSB.ino in Arduino IDE, Verify/Compile and finally Upload the Sketch to the device. Under Linux your SNES controller will become available as /dev/input/js0 once connected. You can test it using jstest-gtk.

Note that to run Arduino IDE under Linux you either have to run it as root or add your user to the dialout group.

If you want to use the daemonbite with cuzebox or any other SDL2 app that doesn't have its own controller config, you need to create a file called gamecontrollerdb.txt in the same dir as your cuzebox binary containing:

Code: Select all

03000000412300003780000001010000,DaemonBite SNES/NES controller USB adapter,platform:Linux,crc:9027,a:b0,b:b1,x:b2,y:b3,back:b6,start:b7,leftshoulder:b4,rightshoulder:b5,dpup:-a1,dpdown:+a1,dpleft:-a0,dpright:+a0,
USBC-SNES-adapter.jpg
USBC-SNES-adapter.jpg (166.63 KiB) Viewed 716 times
SNES2USBC.jpg
SNES2USBC.jpg (726.77 KiB) Viewed 703 times
Last edited by danboid on Mon Jul 10, 2023 12:00 am, edited 16 times in total.
User avatar
danboid
Posts: 1881
Joined: Sun Jun 14, 2020 12:14 am

Re: Daemonbite SNES controller to USB adapter

Post by danboid »

Today I built the Daemonbite SNES to USB adapter using a USB C Arduino Pro Micro so I updated the first post with a pic of it. MAME is better than ever now!
User avatar
uze6666
Site Admin
Posts: 4778
Joined: Tue Aug 12, 2008 9:13 pm
Location: Montreal, Canada
Contact:

Re: Daemonbite SNES controller to USB adapter

Post by uze6666 »

Pretty cool, thanks for the info. Doing some USB device is on my todo list since ever. Specially with AVRs that includes USB support. :ugeek:
User avatar
danboid
Posts: 1881
Joined: Sun Jun 14, 2020 12:14 am

Re: Daemonbite SNES controller to USB adapter

Post by danboid »

I've edited the first post again to include some instructions and a pic of it in use with my arcade stick.
User avatar
D3thAdd3r
Posts: 3172
Joined: Wed Apr 29, 2009 10:00 am
Location: Minneapolis, United States

Re: Daemonbite SNES controller to USB adapter

Post by D3thAdd3r »

Great stuff, that joystick is awesome 8-)
User avatar
danboid
Posts: 1881
Joined: Sun Jun 14, 2020 12:14 am

Re: Daemonbite SNES controller to USB adapter

Post by danboid »

I've updated the OP with the SDL2 controller config to get the daemonbite working with cuzebox.
User avatar
Artcfox
Posts: 1382
Joined: Thu Jun 04, 2015 5:35 pm
Contact:

Re: Daemonbite SNES controller to USB adapter

Post by Artcfox »

danboid wrote: Sun Jul 09, 2023 11:36 pm I've updated the OP with the SDL2 controller config to get the daemonbite working with cuzebox.
Nice! You have the same exact controller config line listed twice. You only need it in there once.

Edit: You could probably also submit that line to the author of the gamecontrollerdb.txt repo, and then it will go out with the next update.
User avatar
danboid
Posts: 1881
Joined: Sun Jun 14, 2020 12:14 am

Re: Daemonbite SNES controller to USB adapter

Post by danboid »

My PR to get this controller added to the controllerdb file got declined because it can also be configured for NES controllers, which obviously uses a different set of mappings.
User avatar
Artcfox
Posts: 1382
Joined: Thu Jun 04, 2015 5:35 pm
Contact:

Re: Daemonbite SNES controller to USB adapter

Post by Artcfox »

danboid wrote: Mon Jul 10, 2023 7:05 am My PR to get this controller added to the controllerdb file got declined because it can also be configured for NES controllers, which obviously uses a different set of mappings.
Bummer, but understandable. A long shot, but I wonder if the NES config is a strict subset of the SNES config, such that a NES controller would work using the SNES config?
Post Reply