Intermittent hotkeys problem

General chit-chat about what's hot and not in the land of emulated video games.

Moderator: dee2eR

Post Reply
User avatar
triggerhappy
Super Contributor
Super Contributor
Posts: 59
Joined: Thu Sep 17, 2020 11:49 pm

Intermittent hotkeys problem

Post by triggerhappy » Wed Nov 25, 2020 10:44 pm

I’ve noticed that every few times I boot up my arcade cabinet, the hotkeys behaviors fail to operate as expected. For example, pressing P1 Start and P1 Button 1 at the same time does not register as a Coin insert. Likewise, pressing and holding P1 Start does not exit the game back to Attract Mode.

When this occurs, I simply power cycle the cabinet, and the issue goes away - i.e., the aforementioned hotkey combinations start working again. I have not been able to figure out a way to trigger this behavior consistently. It seems to happen at random - about 1 out of every 3 or 4 times I start up the system.

Any idea what could be going on?

I am running ARpiCADE 3.X with a single joystick and P1 controls wired into the JAMMA edge connector. I also have a USB kbd attached and a USB rotary controller, which I have described in previous posts. These devices all appear to operate consistently at present. Only the hotkeys continue to give me some grief. :(

dee2eR
Inventor
Inventor
Posts: 1916
Joined: Tue Aug 22, 2017 2:07 pm

Re: Intermittent hotkeys problem

Post by dee2eR » Thu Nov 26, 2020 1:51 am

Interesting, not sure what would cause that. I don't believe I experience it.

Is the USB rotary controller picked up as a joystick? If so it's possible it messes with the joystick order, possibly only the virtual joystick that's part of the hotkey system. If it's a mouse then that's not so likely...

As a troubleshooting step next time it happens, without rebooting go to the command line and run
jstest /dev/input/js2
and have a look if it is picking up the virtual joystick of the hotkey system (it will be called something like xboxdrv if it's the right one). Another thing you could try on the command line is turning the hotkeys on and off and seeing if any error message appears
hotkeys start (to start)
hotkeys stop (to stop)

User avatar
triggerhappy
Super Contributor
Super Contributor
Posts: 59
Joined: Thu Sep 17, 2020 11:49 pm

Re: Intermittent hotkeys problem

Post by triggerhappy » Thu Nov 26, 2020 3:48 am

dee2eR wrote:
Thu Nov 26, 2020 1:51 am
Is the USB rotary controller picked up as a joystick? If so it's possible it messes with the joystick order, possibly only the virtual joystick that's part of the hotkey system.
Thanks, dee2eR. I'm pretty sure the rotary controller gets detected as a joystick, even tho it technically behaves more like a kbd in my setup (it simply emits the keystrokes 'Z' and 'X' when the joystick knob is twisted left or right).

I'll give your suggestions a try next time the problem crops up and update this thread with my findings.

Thanks again for your help!

User avatar
triggerhappy
Super Contributor
Super Contributor
Posts: 59
Joined: Thu Sep 17, 2020 11:49 pm

Re: Intermittent hotkeys problem

Post by triggerhappy » Wed Dec 02, 2020 9:20 pm

So I think I was able to resolve this issue by editing the /etc/modprobe.d/mk_arcade_joystick.conf file, changing:

Code: Select all

options mk_arcade_joystick_rpi map=1,2
to:

Code: Select all

options mk_arcade_joystick_rpi map=1
I've rebooted several times since making this change, and so far the hotkeys problem has not recurred. Keeping fingers crossed that it remains that way.

Post Reply