DaemonBite/Arduino Pro Micro - not enough inputs?? (Atari 2P arcade controller)

Discussion of keyboards, gamepads, joysticks and other input related peripherals.
bankshot
Posts: 68
Joined: Thu Dec 16, 2021 5:13 pm
Has thanked: 19 times
Been thanked: 29 times

DaemonBite/Arduino Pro Micro - not enough inputs?? (Atari 2P arcade controller)

Unread post by bankshot »

Greetings all,

I've been lurking here for a few months after getting my first MiSTer in the summer, decided it was finally time to join the party.

I've tried hard to research this situation before asking for advice. I have this Atari arcade controller that I can use to a certain extent with the MiSTer:

https://www.microcenter.com/product/623 ... controller

It came built in with this USB brain:

http://www.xin-mo.com/dual_player.html

Here's the issues:

1.). The built-in trackball does not tie into the XinMo USB brain and has no associated buttons. It is a separate device with its own PS/2-USB cable on it. The input tester will recognize the trackball as a mouse if plugged in but since it has no buttons of its own, I cannot figure out how to play a core like Centipede with it.

2.) I am interested in purchasing an additional one of these controllers to replace the arcade sticks with flight sticks and replace the trackball with a push-pull spinner so I can play games like Discs Of Tron and Battlezone.

I have read the conversation between Sorgelig and Thorr in this thread:

https://github.com/MiSTer-devel/Arcade- ... /issues/13

It does not appear to me that the Daemonbite/Arduino Pro Micro option has enough inputs on the board to handle all of the buttons and stick inputs needed to create a Class 1 Two-player arcade controller, as well as not having any analog inputs for trackballs and spinners.

Am I incorrect in this assumption? If so, are there any other solutions available for replacing the USB brain with something that has all of the inputs necessary for this setup? Thanks for any feedback.
thorr
Top Contributor
Posts: 1311
Joined: Mon Jul 06, 2020 9:37 pm
Has thanked: 634 times
Been thanked: 308 times

Re: DaemonBite/Arduino Pro Micro - not enough inputs?? (Atari 2P arcade controller)

Unread post by thorr »

A trick is to program the controls to use the Mame keyboard keys. This will allow both players to work with one device (assuming they are all digital joysticks, etc.). You can try using your keyboard with the trackball and if everything works, then you can program your buttons and joystick to be keyboard keys. An Arduino Pro Micro is not required to be the Arduino device. There are plenty of other options that have more inputs. You can also get more than one Pro Micro and plug them all into a hub. I have been using Teensy Arduinos which have lots of inputs. The Daemonbite stuff is just a fancy name for regular Arduino code that someone came up with. I wrote my own code for my Teensy Arduinos. With that being said, I am in the process of building some Mr. Spinner stuff in an attempt to get Atari paddles working. Regarding the Discs of Tron spinner. I suggest to wait just a bit. I have been in contact with GRS and they are working on a solution for the MiSTer but it is not ready yet. Same with an updated Tron joystick with the extra button on it. Also, if you get Arduino Pro Micros, I suggest the USB-C type. https://www.amazon.com/gp/product/B09J4MP1QK/
bankshot
Posts: 68
Joined: Thu Dec 16, 2021 5:13 pm
Has thanked: 19 times
Been thanked: 29 times

Re: DaemonBite/Arduino Pro Micro - not enough inputs?? (Atari 2P arcade controller)

Unread post by bankshot »

Hi thorr,

Thanks for the reply. It looks like you and I are trying to achieve some of the same goals for MiSTer. GroovyGameGear has a nice looking push-pull spinner but it is 2x the price of the GRS, and I haven't inquired yet about the direct pin situation for their version. I purchased a 2600-daptor D9 for my Atari paddles and cannot get them to work on MiSTer. I have been in contact with the D9 creator about it and he told me he will be acquiring a MiSTer soon so hopefully things will get resolved on that front. I was going to start a D9 thread at some point for discussion of successes/failures on various controllers.

I am not exactly clear on how you program the USB brain to use Mame keymap. Thorr, I noticed in the JPAC/IPAC tutorial that you were able to do it with your Arduino. What exactly did you have to do to make it work? Caad said something about making your Arduino emulate a keyboard. I intend to contact XinMo about this but I suspect it does not have this capability.
thorr
Top Contributor
Posts: 1311
Joined: Mon Jul 06, 2020 9:37 pm
Has thanked: 634 times
Been thanked: 308 times

Re: DaemonBite/Arduino Pro Micro - not enough inputs?? (Atari 2P arcade controller)

Unread post by thorr »

bankshot wrote: Fri Dec 17, 2021 3:28 pm I purchased a 2600-daptor D9 for my Atari paddles and cannot get them to work on MiSTer.

I am not exactly clear on how you program the USB brain to use Mame keymap. Thorr, I noticed in the JPAC/IPAC tutorial that you were able to do it with your Arduino. What exactly did you have to do to make it work? Caad said something about making your Arduino emulate a keyboard. I intend to contact XinMo about this but I suspect it does not have this capability.
Hi bankshot,
You should be able to get the D9 to work with one paddle. Read through the Atari 7800 / 2600 thread and somewhere in there, I got it to work with one paddle and described how to do it (with help and clues from others).

Arduino's are pretty easy to program. You just need to find example code and modify it for your needs. I have not yet converted my code to keyboard keys, but plan to once I finish building my arcade cabinet. Instead of setting up and sending out a joystick to the USB connection, you set up and send out keyboard keys. You can also do any combination you want. The input code would likely be the same since the inputs are still wired the same to the physical joysticks and buttons. If all this scares you, you can get an IPAC2 or similar and use their utility to program everything as keyboard keys or joysticks, etc.

I am even thinking about double or triple wiring up my controllers to multiple Arduinos so I have the option to just switch the USB connection if I want them to be separate joysticks, keyboard keys, two joysticks acting as one joystick plus buttons for the other, etc. Most likely I will try to get everything to work as keyboard keys and that should work for most things.
bankshot
Posts: 68
Joined: Thu Dec 16, 2021 5:13 pm
Has thanked: 19 times
Been thanked: 29 times

Re: DaemonBite/Arduino Pro Micro - not enough inputs?? (Atari 2P arcade controller)

Unread post by bankshot »

Thanks thorr! Unfortunately my 7800 core isn't working right which is disappointing because it's a stock install. I have a bunch of garbled pixels on the bottom section of the screen on all games, and an update_all from a few days ago didn't fix it like I hoped it would. So I'm stuck with the 2600 core for now.

Thanks also for that link on the USB-C Arduino Micros on Amazon!! Just ordered a couple. USB-C plug so much nicer than USB Micro, time to move on from that POS plug.

I would love to get one 2-player controller fully functional on a single Arduino Micro. At this point I'm kinda shocked that we're the ones trying to blaze this trail on the MiSTer platform, I figured this would all be sorted out by now. Please let me know how it goes with the keyboard mapping and I will do the same when I have time to work on it.
bankshot
Posts: 68
Joined: Thu Dec 16, 2021 5:13 pm
Has thanked: 19 times
Been thanked: 29 times

Re: DaemonBite/Arduino Pro Micro - not enough inputs?? (Atari 2P arcade controller)

Unread post by bankshot »

Unfortunately it appears that Pro Micro does not have enough inputs for 2 player controls plus trackball or spinner without additional kludge circuitry. Pro Micro only has 18 inputs. 2 sticks plus one trackball or spinner now occupies 12. Coin, 1P Start, 2P Start buttons take 3 more. Leaving only 3 pins available for game buttons. Disappointing.

I guess Teensy board is the only simple one-stop shopping solution available.
Post Reply