3

If I use keyboard/mouse Xorg server understand that then computer involved into user input activity.

How to enable support for indicating user activity through gamepad so monitor suddenly doesn't turn off when I play game with gamepad.

Note that I don't ask about xset -dpms s off.

Pierre.Vriens
  • 1,088
  • 21
  • 13
  • 16
gavenkoa
  • 521
  • 6
  • 11

2 Answers2

1

Looking to xinput --list as suggested by Alexander Barakin shown that my gamepad isn't handled by Xorg.

Games directly communicate with /dev/input/js* so Xorg doesn't know about any activity through gamepad.

Possible solutions:

  • wrapper scripts around commands that xset -dpms s off; COMMAND; xset +dpms s on
  • detecting X properties, like class/resource pattern names and running xset .... It is possible to disable DPMS when application run if full-screen mode, etc.
  • make CRON job that detect particular processes and disable DPMS
gavenkoa
  • 521
  • 6
  • 11
0

https://github.com/foresto/joystickwake is a python script meant to solve exactly this problem. It monitors joystick/gamepad inputs and runs (configurable) screensaver-inhibiting commands when there's activity and it hasn't run one in a certain (configurable) amount of time.