https://bugs.winehq.org/show_bug.cgi?id=52204
Bug ID: 52204 Summary: vibration on dualsense controlle rnot working Product: Wine Version: 6.23 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: winmm&mci Assignee: wine-bugs@winehq.org Reporter: etaash.mathamsetty@gmail.com Distribution: ---
When an application requests vibration on my controller (rocket league in this case) it comes in pulses instead of one long pulse like on my xbox one controller. It's really jarring and I would like it fixed. (effects wine 6.22-6.23). lutris wine 6.21-6 the vibration works fine but the controller dosen't. I believe this is a bug winmm.
https://bugs.winehq.org/show_bug.cgi?id=52204
etaash.mathamsetty@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|vibration on dualsense |vibration on dualsense |controlle rnot working |controlle not working
https://bugs.winehq.org/show_bug.cgi?id=52204
etaash.mathamsetty@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|vibration on dualsense |vibration on dualsense |controlle not working |controller not working
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #1 from etaash.mathamsetty@gmail.com --- also I am using arch linux
https://bugs.winehq.org/show_bug.cgi?id=52204
Zebediah Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|winmm&mci |directx-dinput Keywords| |regression Summary|vibration on dualsense |Vibration on DualSense |controller not working |controller works | |incorrectly in Rocket | |League CC| |rbernon@codeweavers.com
https://bugs.winehq.org/show_bug.cgi?id=52204
Gijs Vermeulen gijsvrm@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Distribution|--- |ArchLinux
--- Comment #2 from Gijs Vermeulen gijsvrm@gmail.com --- If possible, it would help greatly if you could do a regression test, see https://wiki.winehq.org/Regression_Testing for intructions.
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #3 from etaash.mathamsetty@gmail.com --- I will try running the test, but I doubt I have the time
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #4 from etaash.mathamsetty@gmail.com --- wait, there are only 24 revisions to dinput between wine 6.21 and 6.22 it should be pretty easy to track down without regression testing
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #5 from etaash.mathamsetty@gmail.com --- luckily dinput8 has some tests that I can run to see what functions are causing the problem
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #6 from Rémi Bernon rbernon@codeweavers.com --- This is more likely something to do with xinput, as I believe any gamepad is with enough joystick and axis is reported as an xinput compatible controller with upstream, although it'll need to be confirmed.
Could you run the game with WINEDEBUG=+xinput,+dinput,+hid,+hidp environment variable set and attach the log here?
You can also try using a different backend than the default SDL, using the registry keys and the regedit steps to add them, described in https://wiki.winehq.org/Useful_Registry_Keys, WineBus keys at the bottom of the page, and the interesting ones to try are "Enable SDL" = 0/1 and "DisableInput" = 0/1, and "DisableHidraw" = 0/1
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #7 from Rémi Bernon rbernon@codeweavers.com --- Enough buttons*
https://bugs.winehq.org/show_bug.cgi?id=52204
Alex Henrie alexhenrie24@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |alexhenrie24@gmail.com
--- Comment #8 from Alex Henrie alexhenrie24@gmail.com --- What is the make and model of your controller?
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #9 from etaash.mathamsetty@gmail.com --- (In reply to Alex Henrie from comment #8)
What is the make and model of your controller?
its the full black dualsense controller. (if you need more specfics I can give you it, I am not sure what you are looking for)
I tried the game with an xbox controller and vibration works fine. I also have a feeling that there wasn't a regression. lutris wine must have had a patch that fixes the vibration.The button mapping in lutris wine is broken though I think that they must have grabbed some patch from proton that expects steam to map the controls.
https://bugs.winehq.org/show_bug.cgi?id=52204
Alex Henrie alexhenrie24@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords|regression |hardware
--- Comment #10 from Alex Henrie alexhenrie24@gmail.com --- (In reply to etaash.mathamsetty from comment #9)
its the full black dualsense controller. (if you need more specfics I can give you it, I am not sure what you are looking for)
I just wanted to make sure that there was enough information in the bug report for someone else to reproduce it. I overlooked the fact that you already said "DualSense controller" in the bug's title, sorry.
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #11 from etaash.mathamsetty@gmail.com --- This is an issue in all games, but in portal 2 in particular, something strange happens. shooting the portal gun results in correct vibration, but other background things moving and stuff causes smaller vibrations that come out wrong. I am guessing the smaller vibration motor of the 2 vibration motors in the xbox one controller is being "emulated" wrong.
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #12 from etaash.mathamsetty@gmail.com --- (In reply to etaash.mathamsetty from comment #11)
This is an issue in all games, but in portal 2 in particular, something strange happens. shooting the portal gun results in correct vibration, but other background things moving and stuff causes smaller vibrations that come out wrong. I am guessing the smaller vibration motor of the 2 vibration motors in the xbox one controller is being "emulated" wrong.
also this bug is a bug in wine 6.22-7.0-rc-3
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #13 from etaash.mathamsetty@gmail.com --- Does anybody here have a dualsense controller to test with? And if you do, have you experienced this issue?
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #14 from etaash.mathamsetty@gmail.com --- doubled checked, it's not a regression
https://bugs.winehq.org/show_bug.cgi?id=52204
Bruno Afonso bruno.ma0738gm@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |bruno.ma0738gm@gmail.com
--- Comment #15 from Bruno Afonso bruno.ma0738gm@gmail.com --- (In reply to etaash.mathamsetty from comment #13)
Does anybody here have a dualsense controller to test with? And if you do, have you experienced this issue?
I'm so glad i found this bug thread!
I also have this same exact issue! Don't know if this will help, but my Dualsense is the default white one, this unit was bought basically when the PS5 launched, so it's more than a year old and it never got a firmware update.
Also running Arch Linux but i DID try others distros, like Pop_OS and Ubuntu on Live Media to be ABSOLUTELY sure that it's not an issue with my arch install.
Adding to what etaash.mathamsetty has already said before the issue happens exactly when the controller gets a constant rumble signal. Instead of a constant rumble the haptic feedback comes in pulses To try and explain it better... pretend that there should be a 1 second constant rumble. Instead what it's happening is I'm getting 10 short pulses of 100 ms each separated by another 100 ms pause so the rumble event actually lasts 2 seconds because of this.
This is definitely an issue with wine... because in native linux games rumble works perfectly, the moment when I use any wine it's when the issue appears. I cannot pinpoint the EXACT release that started this but I believe it was around wine >= 6.18. Since I own this controller since December/2020, I can confirm that it used to work normally, some months ago it is when this issue started.
Game used as test: Broforce (Windows and Native Linux Port)
If I run the native linux version of the game, rumble functionally from the controller behaves normally. Now, when I try to run the Windows version of the game (tried both lutris wine and proton) the pulse pattern behavior appears.
I still haven't tried messing around with the wine registry keys... If I find anything I will report back.
THINGS I TRIED:
-- Used clean installs of other distros (Arch, Pop_OS, Ubuntu, Manjaro) to remove the possibility of something installed on my current Arch
-- Used fftest to test if the rumble functionally is working as intended on it's purest form... and indeed it is. Native linux games, and using the controller on Windows, shows no sings of the issue
-- Tried multiple versions of Wine 6.X and 7.0rcX, both standard and through proton... all behave exactly the same.
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #16 from etaash.mathamsetty@gmail.com --- can we mark this as confirmed now?
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #17 from Rémi Bernon rbernon@codeweavers.com --- Created attachment 71529 --> https://bugs.winehq.org/attachment.cgi?id=71529 Possible XInput / SDL rumble improvements?
I don't have a Dualsense controller to try with, but I would appreciate if anyone with one is able to build Wine from source and try the attached patch to see if it helps.
Wine is sending rumble effect requests every time an application calls XInputSetState, which may be very often and may not be very well handled by devices.
I would say that it's more of an issue to be solved on the device or driver side, but if that proves complicated we can maybe consider adding a throttle mechanism on Wine side (I think I saw people saying that native only sends output reports periodically, every 10 ms at most).
https://bugs.winehq.org/show_bug.cgi?id=52204
Rémi Bernon rbernon@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever confirmed|0 |1
--- Comment #18 from Rémi Bernon rbernon@codeweavers.com --- (In reply to etaash.mathamsetty from comment #16)
can we mark this as confirmed now?
I don't think it really matters, but done.
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #19 from etaash.mathamsetty@gmail.com --- its nice that other people have the issue and it was not only me. I will try those patches later today and see if they work. also @Bruno, the vibration didn't work in proton either? It works great in proton for me at least.
https://bugs.winehq.org/show_bug.cgi?id=52204
etaash.mathamsetty@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Vibration on DualSense |Vibration on DualSense |controller works |controller works |incorrectly in Rocket |incorrectly in all Games |League |
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #20 from etaash.mathamsetty@gmail.com --- update: patches don't work wireless: short pulses wired: slightly longer pulses (slight improvement)
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #21 from etaash.mathamsetty@gmail.com --- I checked the source code and patches appear to be there
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #22 from Bruno Afonso bruno.ma0738gm@gmail.com --- (In reply to etaash.mathamsetty from comment #19)
its nice that other people have the issue and it was not only me. I will try those patches later today and see if they work. also @Bruno, the vibration didn't work in proton either? It works great in proton for me at least.
Sorry to keep you waiting.. was really busy with work and ended up forgetting about this.
Short answer is yes, pure wine-staging+dxvk/lutris/proton, any of these causes the pulse pattern behavior to happen, hence why I was attributing the issue to wine (I may still be wrong, but I can´t think about any other possibility here). Also tried Glorious Eggroll's builds of proton, same deal.
Now the long answer is...
To be honest, rumble behavior is very erratic between different wine/proton versions. Sometimes rumble in a game doesn't work with Proton 6.3 (latest release as of this comment) but works with Proton Experimental and Proton GE, sometimes it's the complete opposite in another game... Sometimes wine-lutris has functioning rumble and proton doesn't, with or without Steam Input. I wasn't going to report on this because the behavior is SO ERRATIC that I could not find a pattern to report on a new bug thread, but since you've asked I decided to write here just to gather more info on the issue. Now the ONE THING that is repeatable is that WHEN RUMBLE WORKS... it has the weird pulse behavior, and that goes for any game, hence why I had previously answered to this post.
One more thing...
@etaash, has your DualSense been updated to the latest available firmware? If not, do you know someone who has a PS5 so that you can update it? Sadly, I neither own nor do I know someone who has the console, but my DualSense certainly only has the original launch firmware.
The reason why I'm persisting on this topic is because halfway through last year Sony issued a firmware update to the controller where one of the major features was to improve haptic feedback with backwards compatible PS4 games... It is known that the controller sort of "emulates" the legacy rumble behavior, so when it receives a legacy rumble signals it has to convert it to something that the voice coils can properly do...
I STILL don't think that is the cause of the issue here, because again native linux games and emulators work perfectly through hid-playstation. I just wanted to eliminate this as a possibility.
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #23 from Bruno Afonso bruno.ma0738gm@gmail.com --- Created attachment 71658 --> https://bugs.winehq.org/attachment.cgi?id=71658 WINEDEBUG XINPUT/HID ouput - HK
Since @Rémi asked for a debug output, I'm attaching one here.
Before anyone asks... Yes, I know it's using proton and not pure wine+dxvk. It was simply more convenient to use Steam to capture the WINEDEBUG. If anyone wishes to see a pure wine debug, feel free to ask. PS: Steam Input was DISABLED for this test. PS-2: It's a 7z file because the log is nearly 100MB decompressed, even for a minute of gameplay.
Wine version: 7.0rc3 (GE Build) Game used: Hollow Knight (Windows version of course)
Steps done: - Booted the game - 3 A button presses to load latest save - Moved the L-Analog Down once to get off bench - Pressed "LB" to dash, this triggers the pulse behavior. Waited until the pulses stopped. Repeated this once. - Double pressed A for double jump, this also triggers the behavior. Waited until the pulses stopped. - ALF+F4 out of the game
If there was a problem during my test or if anyone wishes to do a different test, feel free to ask me and I'll help to the best of my abilities.
Thanks for the help.
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #24 from etaash.mathamsetty@gmail.com --- (In reply to Bruno Afonso from comment #22)
(In reply to etaash.mathamsetty from comment #19)
its nice that other people have the issue and it was not only me. I will try those patches later today and see if they work. also @Bruno, the vibration didn't work in proton either? It works great in proton for me at least.
Sorry to keep you waiting.. was really busy with work and ended up forgetting about this.
Short answer is yes, pure wine-staging+dxvk/lutris/proton, any of these causes the pulse pattern behavior to happen, hence why I was attributing the issue to wine (I may still be wrong, but I can´t think about any other possibility here). Also tried Glorious Eggroll's builds of proton, same deal.
Now the long answer is...
To be honest, rumble behavior is very erratic between different wine/proton versions. Sometimes rumble in a game doesn't work with Proton 6.3 (latest release as of this comment) but works with Proton Experimental and Proton GE, sometimes it's the complete opposite in another game... Sometimes wine-lutris has functioning rumble and proton doesn't, with or without Steam Input. I wasn't going to report on this because the behavior is SO ERRATIC that I could not find a pattern to report on a new bug thread, but since you've asked I decided to write here just to gather more info on the issue. Now the ONE THING that is repeatable is that WHEN RUMBLE WORKS... it has the weird pulse behavior, and that goes for any game, hence why I had previously answered to this post.
One more thing...
@etaash, has your DualSense been updated to the latest available firmware? If not, do you know someone who has a PS5 so that you can update it? Sadly, I neither own nor do I know someone who has the console, but my DualSense certainly only has the original launch firmware.
The reason why I'm persisting on this topic is because halfway through last year Sony issued a firmware update to the controller where one of the major features was to improve haptic feedback with backwards compatible PS4 games... It is known that the controller sort of "emulates" the legacy rumble behavior, so when it receives a legacy rumble signals it has to convert it to something that the voice coils can properly do...
I STILL don't think that is the cause of the issue here, because again native linux games and emulators work perfectly through hid-playstation. I just wanted to eliminate this as a possibility.
I do know people who have a ps5, but honestly it's not worth it to go to their house and update the firmware on the controller, when it works just fine when not using wine
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #25 from etaash.mathamsetty@gmail.com --- I have been trying proton experimental recently and holy crap the controller works really well. (through heroic games launcher) proton GE is still lagging behind, but proton experimental is really good. Are you also having similar behavior?
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #26 from etaash.mathamsetty@gmail.com --- vibration works, correct button symbols in games (square, circle, etc)
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #27 from etaash.mathamsetty@gmail.com --- no vibration in rocket league :( will make a github issue i guess
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #28 from Gabriele gab.pulcio@gmail.com --- it seems that it has been resolved
source: i own a dualsense since 5 days, the issue disappeared with 7.3
https://bugs.winehq.org/show_bug.cgi?id=52204
etaash.mathamsetty@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |FIXED
--- Comment #29 from etaash.mathamsetty@gmail.com --- you are right, I used a clean wineprefix and ran absolute drift (windows version) and the vibration worked great thanks everyone
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #30 from etaash.mathamsetty@gmail.com --- for those who want to use adaptive triggers, I wrote a little project on github you can go download https://github.com/Etaash-mathamsetty/trigger-control
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #31 from Bruno Afonso bruno.ma0738gm@gmail.com --- Not an issue... just to confirm what @Gabriele and @etaash noticed before.
The Dualsense haptics now work perfectly normal after Wine 7.3!
Thanks a lot @Rémi_Bernon! :) (Assuming that it was your fix by looking at the amount of HID haptics changes on the Wine 7.3 changelog)
https://bugs.winehq.org/show_bug.cgi?id=52204
--- Comment #32 from Rémi Bernon rbernon@codeweavers.com --- Well I have no idea what fixed it but good to hear!
https://bugs.winehq.org/show_bug.cgi?id=52204
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #33 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 7.4.