libretro / RetroArch

Cross-platform, sophisticated frontend for the libretro API. Licensed GPLv3.
http://www.libretro.com
GNU General Public License v3.0
10.23k stars 1.82k forks source link

Remote RetroPad: 11 of 24 buttons does not work #16263

Closed davidhedlund closed 3 months ago

davidhedlund commented 8 months ago

Description

Tested with PlayStation DualSense in Ubuntu 20.00 based distro.

Expected behavior

[What you expected to happen]

Actual behavior

[What is actually happening]

Steps to reproduce the bug

These controllers don't work with the "udev" controller driver:

The thumb sticks didn't work at all, but they have now been added:

Bisect Results

[Try to bisect and tell us when this started happening]

Version/Commit

You can find this information under Information/System Information

Environment information

zoltanvb commented 7 months ago

In current RetroArch, remote retropad should be able to display also analog sticks, can you check if this brings an improvement? I have not changed actual packet transfer (i.e. the remote part), but analog axes were sent also earlier, just not displayed.

davidhedlund commented 7 months ago

In current RetroArch, remote retropad should be able to display also analog sticks, can you check if this brings an improvement? I have not changed actual packet transfer (i.e. the remote part), but analog axes were sent also earlier, just not displayed.

Thank you very much for fixing most of this. The thumb sticks are working 100% in 1.18.0, but these buttons don't work for controller driver "udev":

They are working fine with controller driver "sdl2".

zoltanvb commented 6 months ago

How is L2/R2 mapped in (auto)config? (Note that remote retropad behaves as a core, so it may have remap file.)

davidhedlund commented 6 months ago

How is L2/R2 mapped in (auto)config? (Note that remote retropad behaves as a core, so it may have remap file.)

sdl2 (and the values are correct since they are assigned these values when I map a key with them in Hotkeys):

input_l2_axis = "+4"
input_r2_axis = "+5"

udev:

input_l2_btn = "6"
input_r2_btn = "7"
zoltanvb commented 6 months ago

I can't make sense of this, may be driver+device dependent quirk, I can register R2/L2 with udev and another controller. R2/L2 is frequently set up as an axis, but it should still work, I tried checking if for some reason only the analog button part is being sent in that case, but nope.

If you try to bind R2/L2 with udev, does it still end up with buttons 6 and 7? And does L2/R2 work in games with the DS controller + udev?

davidhedlund commented 6 months ago

I can't make sense of this, may be driver+device dependent quirk, I can register R2/L2 with udev and another controller. R2/L2 is frequently set up as an axis, but it should still work, I tried checking if for some reason only the analog button part is being sent in that case, but nope.

I wish I could help, but I don't know C, and I don't really know Git.

If you try to bind R2/L2 with udev, does it still end up with buttons 6 and 7?

Yes. Actually I submitted the PR specifically for this that is responsible for the "6" and "7" values.

And does L2/R2 work in games with the DS controller + udev?

Yes.

davidhedlund commented 6 months ago

Do you have a controller with L1 and R1?

Are the working in Remote RetroPad for you?

zoltanvb commented 6 months ago

Yes and yes. I have a PR waiting that would show also the analog values for the triggers, once it gets merged it may be interesting to see if there is anything detected differently.

zoltanvb commented 3 months ago

The analog trigger display has been merged since a while, can you try what it shows for L2/R2 with your controller?

davidhedlund commented 3 months ago

In current RetroArch, remote retropad should be able to display also analog sticks, can you check if this brings an improvement? I have not changed actual packet transfer (i.e. the remote part), but analog axes were sent also earlier, just not displayed.

Thank you very much for fixing most of this. The thumb sticks are working 100% in 1.18.0, but these buttons don't work for controller driver "udev":

* L2

* R2

They are working fine with controller driver "sdl2".

The L2/R2 issue for the DualSense controller was that the controller file was incorrectly generated by Retroarch, so it had to be fixed manually: https://github.com/libretro/retroarch-joypad-autoconfig/pull/1135

davidhedlund commented 3 months ago

The analog trigger display has been merged since a while, can you try what it shows for L2/R2 with your controller?

It's working now, with the new controller file for DualSense. Can you please make sure that you didn't add unnecessary code? I'm sorry but it was really just an issue with the controller file for these two buttons.

This issue should be fixed to prevent RetroArch from generating wrong autoconfig files:

zoltanvb commented 3 months ago

No code was harmed while investigating this issue :) analog trigger test was added to remote retropad for generic use.

davidhedlund commented 3 months ago

Yes and yes. I have a PR waiting that would show also the analog values for the triggers, once it gets merged it may be interesting to see if there is anything detected differently.

So should we not revert this PR? If not, feel free to close this issue.

zoltanvb commented 3 months ago

I was referring to #16390, it is merged and should remain in the code. I can't close the issue, but eventually someone with the necessary rights will swing by.

davidhedlund commented 3 months ago

I was referring to #16390, it is merged and should remain in the code. I can't close the issue, but eventually someone with the necessary rights will swing by.

Thank you very much for your help! People can now evaluate their controller configurations with RetroPad, which is great for evaluating new autoconfig files before they are uploaded.

davidhedlund commented 3 months ago

Remote RetroPad: Analog trigger indicator disappears on release for L2/R2 buttons