PowerTools icon indicating copy to clipboard operation
PowerTools copied to clipboard

Additional per-game configs

Open NGnius opened this issue 2 years ago • 3 comments

Please confirm

  • [X] I have searched existing issues
  • [X] This issue is not a duplicate of an existing one
  • [X] I will fill this out to the best of my ability

Describe what you'd like to be able to do

Create multiple PowerTools configs for a game. This could be used for functionality such as having a high-power config for playing plugged in and a more efficient profile for playing on battery.

Changing between profiles could be done manually or automatically for certain scenarios. Manual config select could be done by a dropdown. Automatic could maybe be triggered by events like charger un/plugged, low battery, temperature, etc. (suggestions welcome).

This may be possible to do without breaking existing configs, but will undoubtedly force a file format upgrade which will change things in arbitrary (and possibly undesirable) ways. It may be best to make this a breaking change with no upgrade path.

Describe alternatives you've considered

Multiple configs can currently be accomplished by remembering the settings and applying them manually when desired. I'm not a fan of remembering things that I don't have to, though.

Anything else?

I think this is a misuse of the Steam Deck, since it isn't designed to increase performance like the Nintendo Switch when docked, but I'm not going to force my opinion on others.

NGnius avatar Mar 19 '23 15:03 NGnius

For detecting whether the Deck is plugged in, there's /sys/class/hwmon/hwmon5/in0_input which is the USB PD negotiated voltage (presumably in mV). It's 0 when unplugged, and changes based on the charger's capabilities (non-PD USB is 5000, my PD laptop charger through a dock is 15000).

I'd really like a way to detect that without polling, but I'd rather not have to tie it into the frontend battery event if possible. Frontend tie-in increases risk of breakages, since the JS is not guaranteed to be stable.

NGnius avatar Mar 19 '23 16:03 NGnius

you can try ACPI event or UPOWER dbus, I don't know if it is installed on deck though. I have successfully used rust dbus to connect to it to write something similar for Razer laptops - aka profiles for plugged and unplugged.

phush0 avatar May 15 '23 06:05 phush0

This would be greatly appreciated. I use my deck in handheld mode alot and would like to have per game settings like the system profiles. This would allow me to limit tdp per game so it can be high when needed or capped without needed to tweak every single time.

TedsGitHubEmporium avatar Jul 28 '23 18:07 TedsGitHubEmporium