Android Let's get controllers on Android fully working for v20.4 (jk! i mean v21.2)
#31
Sorry I wasn't sure where to post this so thought I might just mention it here because I think it might all be related. Ever since Omega beta v3 (arm 64) if I connect a game controller to kodi on my samsung galaxy then kodi will immediately crash if I use the dpad or thumbstick. Any of the buttons work fine and function correctly but as soon as I tap a direction like left or right kodi will crash immediately. Doesn't seem to matter what your currently doing in kodi it will crash immediately. I've tried a ps4, xbox 1 and gamesir controller and all three do the same thing. I've been using kodi for years without issue but I just can't manage to fix this recent bug. I tested by reinstalling nexus build and it works fine... and then tested and found it works right up till omega beta 2 and broke on omega beta 3. My gut feeling is joystick.peripheral because it seems to be the component that changes version. However even with that disabled kodi will still crash as soon as I press a directional button on a controller. If I disable the default controller in game addons then the buttons stop functioning as expected however the dpad will still make kodi immediately crash. I also tried the test build in this thread however it also immediately crashes as well as the latest night build. I'm happy to post somewhere else I just thought some one here might know what might be going on and might be of interest to this thread. BTW a remote control works fine. Thanks...
Reply
#32
(2024-07-02, 10:03)dannymosquito Wrote: Sorry I wasn't sure where to post this so thought I might just mention it here because I think it might all be related. Ever since Omega beta v3 (arm 64) if I connect a game controller to kodi on my samsung galaxy then kodi will immediately crash if I use the dpad or thumbstick. Any of the buttons work fine and function correctly but as soon as I tap a direction like left or right kodi will crash immediately. Doesn't seem to matter what your currently doing in kodi it will crash immediately. I've tried a ps4, xbox 1 and gamesir controller and all three do the same thing. I've been using kodi for years without issue but I just can't manage to fix this recent bug. I tested by reinstalling nexus build and it works fine... and then tested and found it works right up till omega beta 2 and broke on omega beta 3. My gut feeling is joystick.peripheral because it seems to be the component that changes version. However even with that disabled kodi will still crash as soon as I press a directional button on a controller. If I disable the default controller in game addons then the buttons stop functioning as expected however the dpad will still make kodi immediately crash. I also tried the test build in this thread however it also immediately crashes as well as the latest night build. I'm happy to post somewhere else I just thought some one here might know what might be going on and might be of interest to this thread. BTW a remote control works fine. Thanks...

That's a weird one. I've never come across indiscriminate crashing with the dpad. I'll check for PRs merged between Omega beta 2 and beta 3. Can you grab the version of peripheral.joystick from beta 2 and beta 3?
RetroPlayer releases: https://github.com/garbear/xbmc/releases

Donations: eigendude.eth
Reply
#33
Hey thanks so much for your reply garbare. Just to confirm is peripheral.joystick the 'joystick support' addon under peripherals? If so the version in beta 2 is v21.1.8. And under beta 3 is v21.1.11.
Also I just thought I'd clarify that from beta 3 version onwards the dpad causes a crash immediately. It's not intermittent.
BTW I just tested on my nvidia shield and latest version works fine with game controllers. I'm starting to wonder if this is just affecting Android devices with touchscreens.
Reply
#34
It would be great if the peripheral.joystick from your build garbear could be put back into the core kodi 21 build. Would save all the hassle.
Reply
#35
(2024-07-04, 20:46)sc769812 Wrote: It would be great if the peripheral.joystick from your build garbear could be put back into the core kodi 21 build. Would save all the hassle.

My builds ship peripheral.joystick v21.1.18, this should be the same that ships with v21 right?
RetroPlayer releases: https://github.com/garbear/xbmc/releases

Donations: eigendude.eth
Reply
#36
The only substantial change in the release notes I found is for v21.1.11:
 
Code:

Changes since v21.1.10:
  * Stabilize peripheral locations
  * Reverted Android buttonmaps

I doubt that a peripheral's "location" (basically its driver index or add-on ID) would crash a d-pad.

This might be a crash specific to the samsung galaxy, which a weird glitchy firmware bug would indicate. As it turn out, I worked Samsung's VR with Kodi booth at SDC in 2017 showing off Kodi on the VR headset and the DeX dock. They gave me an S8 in thanks which I used for years. I'll see if I can reproduce on the S8.
RetroPlayer releases: https://github.com/garbear/xbmc/releases

Donations: eigendude.eth
Reply
#37
Hi, 

No, the kodi 21 build doesn't have peripheral.joystick package included. For some reason on the android 64bit build it is not present. Odd thing is it is present and works on the android 32bit build. 

That's why copying peripheral.joystick v21.1.18 from your retro build works.
Reply
#38
(2024-07-05, 10:27)garbear Wrote: The only substantial change in the release notes I found is for v21.1.11:
 
Code:

Changes since v21.1.10:
  * Stabilize peripheral locations
  * Reverted Android buttonmaps

I doubt that a peripheral's "location" (basically its driver index or add-on ID) would crash a d-pad.

This might be a crash specific to the samsung galaxy, which a weird glitchy firmware bug would indicate. As it turn out, I worked Samsung's VR with Kodi booth at SDC in 2017 showing off Kodi on the VR headset and the DeX dock. They gave me an S8 in thanks which I used for years. I'll see if I can reproduce on the S8.

Thanks again for taking the time with this... Actually... I have a couple of old devices here. A Samsung note 8 running Android 8 and a Samsung Galaxy tablet running Android 11 and I've just now installed and tested kodi on both of these and the latest kodi doesn't crash at all on either of those with the dpad. So I'm now updating the tablet to the latest Android version to see if it's to do with the Android version. My phone is a Samsung galaxy s21 running Android 14. I use the phone with kodi in either a game controller bracket or I use it tethered to my xreal glasses using dex.
I'm hoping it's not just my phone but is strange it works fine with versions of kodi before omega beta 3.
I'll let you know how the galaxy tablet goes in a later version of Android.
Reply
#39
Ok... Interesting... So I slowly upgraded my Samsung tablet from Android v11 and kodi was fine for Android v12 and Android v13. But as soon as I upgraded to Android V14 and OneUI V6 then kodi started crashing as soon as I used the Dpad. So it seems two different updates converged around the same time, one from kodi and the other from Android to cause this issue. Interesting both updates became available around the same time frame. Probably just a coincidence.
Unfortunately I don't have any non-samsung Android phones or tablets to test whether this is just Samsung or all Android phones and tablets.
Reply
#40
So v12 and v13 work, but as soon as you update to v14, then Kodi crashes on Omega Beta 3 but not Omega beta 2?

I went through the input-related Beta 3 PRs. There's a lot, as I was really active in Kodi dev back in January. I found:

https://github.com/xbmc/xbmc/pull/24382 - Android specific, but only affects the new Player Window
https://github.com/xbmc/xbmc/pull/24392 - Stable peripheral locations
https://github.com/xbmc/xbmc/pull/24501 - Large input refactor
https://github.com/xbmc/xbmc/pull/24512 - Keyboard and mouse changes
https://github.com/xbmc/xbmc/pull/24525 - Keyboard optimization
https://github.com/xbmc/xbmc/pull/24524 - Player Viewer keyboard + mouse
https://github.com/xbmc/xbmc/pull/24651 - Follow up to Player Viewer keyboard + mouse

You'll notice that there was no controller changes - but the D-pad is maybe still affected if it's being handled as a keyboard press. In v12 and v13, when you press the dpad, do you hear a sound?

To fix the crash, we'll need to know where in Kodi the crash is occurring. Can you grab a v14 debug log (or preferably an Android logcat) showing Kodi start up, and then crashing when the dpad is pressed? That will at least give us a place to start looking for possible code errors.

Also, I just made a big change for controllers that was merged into master a few days ago. Can you try the latest nightly on Android v14 and see if it still crashes?
RetroPlayer releases: https://github.com/garbear/xbmc/releases

Donations: eigendude.eth
Reply
#41
Thanks garbear, shield tv 2017 controllers and toblerone remote working perfectly on 2024-07-02 nightly.
Reply
#42
Hi, Sorry but I am a bit of a newbie when it comes to this stuff. I am currently have an Nvidia Sheild running Kodi Omega 21. However, I installed a Kodi build called Diggz Xenon Plus AIO version 21 that basically configures my Kodi for me. A question I have is, do I have to install the Github apk file Android ARM64? If I do install this apk, does it allow my Nvidia Shield controller to work properly in retroplayer, or does it wipe my current Kodi Diggz build and reinstall Kodi to default? Is there a way to install this Github Retroplayer 21 build without wiping my current Diggz build, and if so, how do I do it (please be specific, as I am a little bit of a newbie)? Any help would be greatly appreciated.
Reply
#43
(2024-07-13, 18:24)pbrisebois Wrote: However, I installed a Kodi build called Diggz Xenon Plus AIO version 21 that basically configures my Kodi for me.

And as it's a piracy build that is on our banned addons (wiki) list, it also means that your device is completely ineligible for any support here.

Please go and actually read the forum rules (wiki) that you accepted and agreed to abide by when you signed up here.
But the best advice is don't install such junk on your device and use Kodi properly. There's plenty of newbie advice on our wiki, links in my sig below.
|Banned add-ons (wiki)|Forum rules (wiki)|VPN policy (wiki)|First time user (wiki)|FAQs (wiki) Troubleshooting (wiki)|Add-ons (wiki)|Free content (wiki)|Debug Log (wiki)|

Kodi Blog Posts
Reply
#44
@pbrisebois Similar to the piracy sites I do my own "builds" of Kodi, but unlike shady unknown actors running code on your device, you can judge my legitimacy.

I do builds mainly for my own media center, but also share them so that testers and users can have my curation of the latest state-of-the-art game features.

Builds are at https://github.com/garbear/xbmc/releases (and I just did a release today).
RetroPlayer releases: https://github.com/garbear/xbmc/releases

Donations: eigendude.eth
Reply
#45
Hello, I also have a problem with gamepads on Samsung. When I press any stick, even if I just slightly touch it, Kodi immediately crashes. Here's the log.
Quote:2024-09-20 02:42:18.121 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:18.121 T:26689   debug <general>: CAndroidKey: key ignored (code: 97)
2024-09-20 02:42:18.124 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:18.125 T:26689   debug <general>: CAndroidKey: key down (dev: 13; src: 1281; code: 4; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:18.173 T:26690   debug <general>: Keyboard: scancode: 0x4, sym: 0x08, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:18.173 T:26690   debug <general>: HandleKey: backspace (0xf008) pressed, window 10016, action is Back
2024-09-20 02:42:18.181 T:26690   debug <general>: CGUIWindowManager:TonguereviousWindow: Deactivate
2024-09-20 02:42:18.255 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:18.255 T:26689   debug <general>: CAndroidKey: key ignored (code: 97)
2024-09-20 02:42:18.258 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:18.258 T:26689   debug <general>: CAndroidKey: key up (dev: 13; src: 1281; code: 4; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:18.483 T:26690   debug <general>: ------ Window Deinit (SettingsCategory.xml) ------
2024-09-20 02:42:18.483 T:26690   debug <general>: FreeVisualisation() done
2024-09-20 02:42:18.489 T:26690   debug <general>: CGUIWindowManager:TonguereviousWindow: Activate new
2024-09-20 02:42:18.489 T:26690   debug <general>: ------ Window Init (Settings.xml) ------
2024-09-20 02:42:18.490 T:26690   debug <general>: Keyboard: scancode: 0x4, sym: 0x08, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:19.157 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:19.158 T:26689   debug <general>: CAndroidKey: key ignored (code: 97)
2024-09-20 02:42:19.161 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:19.161 T:26689   debug <general>: CAndroidKey: key down (dev: 13; src: 1281; code: 4; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:19.230 T:26690   debug <general>: Keyboard: scancode: 0x4, sym: 0x08, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:19.352 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:19.352 T:26689   debug <general>: CAndroidKey: key ignored (code: 97)
2024-09-20 02:42:19.355 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:19.355 T:26689   debug <general>: CAndroidKey: key up (dev: 13; src: 1281; code: 4; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:19.362 T:26690   debug <general>: Keyboard: scancode: 0x4, sym: 0x08, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:19.362 T:26690   debug <general>: HandleKey: backspace (0xf008) pressed, window 10004, action is Back
2024-09-20 02:42:19.362 T:26690   debug <general>: CGUIWindowManager:TonguereviousWindow: Deactivate
2024-09-20 02:42:19.667 T:26690   debug <general>: ------ Window Deinit (Settings.xml) ------
2024-09-20 02:42:19.667 T:26690   debug <general>: FreeVisualisation() done
2024-09-20 02:42:19.672 T:26690   debug <general>: CGUIWindowManager:TonguereviousWindow: Activate new
2024-09-20 02:42:19.673 T:26690   debug <general>: ------ Window Init (Home.xml) ------
2024-09-20 02:42:34.916 T:26689   debug <general>: virtual void CXBMCApp::onLostFocus(): 
2024-09-20 02:42:35.407 T:26689   debug <general>: virtual void CXBMCApp::onPause(): 
2024-09-20 02:42:35.407 T:26689   debug <general>: void CXBMCApp::KeepScreenOn(bool): false
2024-09-20 02:42:35.442 T:26689   debug <general>: virtual void CXBMCApp::onGainFocus(): 
2024-09-20 02:42:35.457 T:26689   debug <general>: virtual void CXBMCApp::onLostFocus(): 
2024-09-20 02:42:40.440 T:26689   debug <general>: virtual void CXBMCApp::onResume(): 
2024-09-20 02:42:40.459 T:26689   debug <general>: virtual void CXBMCApp::onGainFocus(): 
2024-09-20 02:42:42.181 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:42.181 T:26689   debug <general>: CAndroidKey: key down (dev: 13; src: 1281; code: 20; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:42.266 T:26690   debug <general>: Keyboard: scancode: 0x14, sym: 0x112, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:42.267 T:26690   debug <general>: HandleKey: down (0xf081) pressed, window 10000, action is Down
2024-09-20 02:42:42.299 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:42.299 T:26689   debug <general>: CAndroidKey: key up (dev: 13; src: 1281; code: 20; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:42.306 T:26690   debug <general>: Keyboard: scancode: 0x14, sym: 0x112, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:42.603 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:42.603 T:26689   debug <general>: CAndroidKey: key down (dev: 13; src: 1281; code: 20; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:42.614 T:26690   debug <general>: Keyboard: scancode: 0x14, sym: 0x112, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:42.615 T:26690   debug <general>: HandleKey: down (0xf081) pressed, window 10000, action is Down
2024-09-20 02:42:42.702 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:42.702 T:26689   debug <general>: CAndroidKey: key up (dev: 13; src: 1281; code: 20; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:42.715 T:26690   debug <general>: Keyboard: scancode: 0x14, sym: 0x112, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:43.305 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:43.306 T:26689   debug <general>: CAndroidKey: key down (dev: 13; src: 1281; code: 19; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:43.315 T:26690   debug <general>: Keyboard: scancode: 0x13, sym: 0x111, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:43.315 T:26690   debug <general>: HandleKey: up (0xf080) pressed, window 10000, action is Up
2024-09-20 02:42:43.439 T:26689 warning <general>: CPeripheralBusAndroid: ignoring input event for unknown input device with ID 13
2024-09-20 02:42:43.440 T:26689   debug <general>: CAndroidKey: key up (dev: 13; src: 1281; code: 19; repeat: 0; flags: 0x8; alt: no; shift: no; sym: no)
2024-09-20 02:42:43.448 T:26690   debug <general>: Keyboard: scancode: 0x13, sym: 0x111, unicode: 0x00, modifier: 0x0
2024-09-20 02:42:46.488 T:26759   error <general>: SOCK: Error selecting socket(s)
2024-09-20 02:42:46.491 T:26759   error <general>: ES: Exception caught while listening for socket
2024-09-20 02:42:46.491 T:26759    info <general>: ES: UDP Event server stopped
Reply

Logout Mark Read Team Forum Stats Members Help
Let's get controllers on Android fully working for v20.4 (jk! i mean v21.2)0