flathub / org.DolphinEmu.dolphin-emu

https://flathub.org/apps/details/org.DolphinEmu.dolphin-emu
17 stars 18 forks source link

Enable evdev input please #78

Closed Nine-H closed 3 years ago

Nine-H commented 3 years ago

Dolphin uses evdev to implement IMU support, which is necessary for many wii games. SDL input is only usable for basic gamepads without an IMU, motion controllers like the dualshock3/4 and switch joycons need evdev.

cpba commented 3 years ago

I enabled it but I have no way to test it, the wii remotes I use for testing the new releases work perfectly fine without this.

@Nine-H Could you please test this build to see whether it fixes your issue?

usually with something like this, add --user if you don't want a system install:

flatpak install https://dl.flathub.org/build-repo/51750/org.DolphinEmu.dolphin-emu.flatpakref
ColinKinloch commented 3 years ago

Works for me with a DualShock 4.

I had to allow unprivileged access to the motion sensors by creating the file /etc/udev/rules.d/50-ds4-motion.rules containing

SUBSYSTEM=="input", KERNEL=="event*", ATTRS{name}=="*Motion Sensors", TAG+="uaccess"

then ran sudo udevadm control --reload-rules and reconnected my controller

cpba commented 3 years ago

Thank you @ColinKinloch I assume the udev rule is also necessary when building outside of flatpak? (provided you're not running as root)

ColinKinloch commented 3 years ago

Yes.

I think the motion sensors have restricted access to stop them from interfering when trying to set joystick axes in games.

Nine-H commented 3 years ago

Thanks for making the change and testing it lads, I forked the build manifest and made the change but have been snowed under setting up build and CI on another project. The udev rule in question is also used by rpcs3 to capture raw motion data from IMU enabled controllers, so it is normal, it might be worth adding that as a note in the appdata, haven't seen it in the dolphin docs.

cpba commented 3 years ago

Thank you!

@Nine-H I'll merge #80 and close this issue, feel free to reopen if the issue persists in some way.

cpba commented 3 years ago

Fixed by #80

Nikko-A commented 2 years ago

Works for me with a DualShock 4.

I had to allow unprivileged access to the motion sensors by creating the file /etc/udev/rules.d/50-ds4-motion.rules containing

SUBSYSTEM=="input", KERNEL=="event*", ATTRS{name}=="*Motion Sensors", TAG+="uaccess"

then ran sudo udevadm control --reload-rules and reconnected my controller

Apologies for reopening this thread, but is it necessary to add the ".rules" suffix?