System does not see controller inputs as activity

Hey, first of all i want to clarify that the usb controller i am using in some games works as intended, it's just that the system logs me off after around 30 minutes, and i have two problems with that: one - i am actively using the controller, and i guess that the system does not get activity from the controller because of discord also showing me as afk. two - i have set the system to not go into sleep/log off at all, and i don't want to forcefully inherit sleeping/logging of every time i wanna play a game with an controller. does someone know something that either lets the system see the controller activity so it won't even count up the idle time, or something so that the system will not go into sleep/log off by itself?
here is a screenshot of the power saving tab in the settings

I don't know if this will be helpful to you or not since I have set my enery saving profile to suspend after a while but in the system tray under battery and brightness when I click this manually block sleep and screen locking it prevents my system from going to sleep no matter how long I am away from it.

By the way just in case this is my energy saving profile:

1 Like

i know that this option exists, but it does not persist across reboots and i don't want to have to do that before each time i want to play with an controller

This won’t persist either, but maybe prefixing the game command with systemd-inhibit can do.

Or maybe some of the “caffeine” tools, for instance:
Caffeine Plus - KDE Store
Caffeine in Launchpad
WhyNotHugo/caffeine-ng: ☕ Tray bar application able to temporarily inhibits the screensaver and sleep mode. - caffeine-ng - Codeberg.org

edit: I know, it’s not a solution, just a work-around.


update:
there are some ideas in this (4 years old) reddit thread:

create a new Activity for games and set the needed power settings for that activity

create a script that will disable the display timeout using dbus when the game is open

Just install this: GitHub - foresto/joystickwake: joystick-aware screen waker It will disable screensaver if you use a controller


Also, I may be wrong, but isn’t “gamemode” supposed to do this?
By the way, on system shutdown I noticed an error about escaping in its unit name.

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.