protonscr

Steam doesn't hotplug uinput devices.

steamclosed General controller / Steam InputDistro Family: NixOS
ValveSoftware/steam-for-linux#7746 · opened 2021-04-10 by YellowOnion · updated 2022-10-08 · 4 comments · github
1 matching comments, n / p to jump
YYellowOnion 2021-04-10 github

Your system information

Please describe your issue in as much detail as possible:

I wrote a script to emulate an xbox controller

Steam doesn't detect the new device until I restart Steam.

Steps for reproducing this issue:

  1. start steam
  2. use pyevdev to create a virtual xbox controller
  3. steam doesn't see it.
YYellowOnion 2021-07-18 github

udevadm log:

$ udevadm monitor 
monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[520375.842949] add      /devices/virtual/input/input30 (input)
KERNEL[520375.842968] add      /devices/virtual/input/input30/event22 (input)
KERNEL[520375.842978] add      /devices/virtual/input/input30/js1 (input)
UDEV  [520375.843935] add      /devices/virtual/input/input30 (input)
UDEV  [520375.844898] add      /devices/virtual/input/input30/js1 (input)
UDEV  [520375.884209] add      /devices/virtual/input/input30/event22 (input)
Bbaracoder 2021-08-08 github

I have the same issue on NixOS. I have retested with the flatpak version on NixOS and it recognizes controllers no problem, so I think this is related to the native FHS environment.

Ssbruder 2022-09-07 github

This got resolved in NixOS by https://github.com/NixOS/nixpkgs/pull/189961.

For everyone not using NixOS, but still running steam inside a container environment, it can be fixed by setting the environment variable SDL_JOYSTICK_DISABLE_UDEV=1, which forces SDL to use inotify instead of udev (which is unreliable inside containers) for discovering joysticks.

Because this is not an error on Steam’s side, I think this issue can be closed, @kisak-valve .

This also applies to the related issue #7729.

Kkisak-valve maintainer 2022-10-08 github

Closing per the last comment.

Launch options