sigmaxipi / chromium-for-stadia

Quick hack to get Google Stadia running on unsupported Android devices
155 stars 19 forks source link

XBOX CONTROLLER PROBLEMS #7

Open mystikmeg opened 4 years ago

mystikmeg commented 4 years ago

Hi guys. Excellent job you guys have done please keep it up.

I am experiencing 2 issues with using an xbox one controller bluetooth connected to my Huawei Mate 20X 5G.

When I press the Xbox button instead of replicating pressing the stadia button it literally takes me to the home screen of android as soon as its pressed.

This happens regardless of what app is on the screen, chromium, whatsapp, youtube. Anything... As soon as that button is press the phone comes out of whatever app and goes to the android home screen.

Second problem, when i press the "select button" (think old school start and select on ps1 pad) on the pad its brings up the stadia option to resume game or exit game.

With these 2 buttons (xbox button and select button) unusable it renders certain games unplayable, eg destiny 2, you need to press the select button to open ghost and travel to orbit and leave planets.

Model code of my phone: EVR N29

sigmaxipi commented 4 years ago

I think this is an Android OS issue rather than an issue that can be fixed in the app. I'm guessing that the controller mapped the XBox button to Android's Home button and the Select to Back. Is the behavior for controller both buttons the exact same as if you pressed the matching Android buttons on the phone's screen? If so, then I don't think it can be fixed in the app. Either the OS or the controller's firmware needs to be updated.

I think there are 3rd party programs that let you remap input on Android devices, but I've never used them.

Also, does using the controller with a USB cable have the same issue?

sigmaxipi commented 4 years ago

This was fixed in an upstream Chromium change.

tama102 commented 4 years ago

Thank you for working on this. Unfortunately both problems still persists for Xbox One controller in Nvidia Shield. Using apk from 4/19. Tried on multiple controllers both wireless and with USB cable

tama102 commented 4 years ago

Just wanted to clarify a few things. I tried 3 different styles of xbox controller:

The original wired controller works fine.

For the wireless controllers, the select button acts is a system-level back button on my Nvidia Shield running Android 9. My understanding is that this might be fixed as part of Android 10 update, not yet released for the shield. Button remapper app confirms that the keypress is registering as "BUTTON_BACK" where on the wired controller it registers as "BUTTON_SELECT". This happens in wireless mode, or when wired via USB cable. When testing on html5gamepad.com the select button makes the web browser go back a page rather than registering as a controller keypress on the site.

The Xbox button on wireless controllers is registering as keypress "BUTTON_MODE" and takes a person back to the android OS home screen.

sigmaxipi commented 4 years ago

I tested this on an Android 10 device which is why I thought it had been fixed by the Chrome team. It may be possible to hack in a fix for Android 9 into the apk, but that will require more investigation.

Nun-z commented 4 years ago

I'm still experiencing this problem with the latest apk on the Nvdia Shield TV 2019.

Workaround: use the Nvidia Shield native app on an Android phone to send the appropriate keypress when you want to access a menu or whatever using that button.

cirvladimir commented 3 years ago

I made a hack to remap the back button to the select button, the result is in my fork here: https://github.com/cirvladimir/chromium-for-stadia

Note, this will make the normal back button not work as expected.