[Android] gamepad stops working after loading/closing content
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 14.1k
- Forks
- 2.2k
- Avg merge
- 7h 35m
- Merged PRs (30d)
- 51
Description
Description
I’m using a generic USB gamepad with OTG connection.
The USB gamepad is recognized upon opening RetroArch, I’ve been able to map all the keys properly, the issue is after loading a game or closing the game (content); the gamepad does nothing as if it had been disconnected, not even when returning to the RetroArch menu (the gamepad is still responsive to the OS). The only thing that works is unplugging/plugging back the usb gamepad and pressing any button, then I get the bottom-left notification message about it being detected again and it starts working within the game and RetroArch menus.
I’ve tried saving the autoconfig file too, but it makes no difference at all… works until a game is loaded and I’m back to unplugging/plugging back.
-
This is the config for the gamepad used: https://gist.github.com/ner00/0934c59f65b7de44a5bdfd6a94cf2f49
-
This is the log captured during one session: https://gist.github.com/ner00/b52722b2470275b5c8520b4ba9dfbd38
Expected behavior
Gamepad should not stop working when loading/closing content (ROMs).
Actual behavior
Gamepad stops working after loading/unloading content until being physically unplugged/plugged back.
Steps to reproduce the bug
- Open RetroArch, press a button on gamepad, detected!
- Navigate just with the gamepad, load content (Genesis Plus GX core);
- Content is loaded, gamepad stops working immediately;
- Unplug/replug gamepad, it gets recognized in-game and works fine;
- After playing a few seconds I press the menu hotkey on the gamepad, select 'Close content';
- The game is unloaded, goes back to RetroArch menu and gamepad no longer works again;
- Again, I have to unplug/plug back the gamepad for it to work once more.
Bisect Results
Tested multiple versions, as far back as v1.2.2 (Jul 19 2015).
-
v1.2.2 does not have this issue, but the next release does - v1.3.0 (Feb 25 2016).
-
v1.3.0 seems to be where this issue started and also when introduced the new menu design. It could be just a coincidence and the gamepad issue on content load/unload not being related to the material design menu, nevertheless since then all versions have the same issue with a few controllers and the same workaround applies (holding 'confirm' button and pressing D-Pad when loading content).
Version/Commit
- RetroArch: 1.8.4/f425d8d
Environment information
- OS: Android v8.1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the controller failure on Android using the listed steps, including loading Genesis Plus GX content and then closing it. Compare the linked session log and gamepad configuration with the behavior before and after content load/unload. Done means the gamepad remains responsive in both the content and RetroArch menus without unplugging it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, c
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100