Battery Maximum % based on presence of dock #141
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Describe what you'd like to be able to do
Ideally while my deck is docked at home, the battery is kept at a lower % to extend the life, however any time I plug it straight into a charger I want it to charge to 100% (eg, in a hotel, in the airport, etc)
Describe alternatives you've considered
I can just turn on and off the setting, but it's easy to forget and leave for the airport with 80% power. Then you plug it in in the hotel, and again you only end up with 80% power...
Anything else?
I don't know rust, or have a ton of free time to dig in now, but it looks relatively easy enough to add conditionals to
charge_limit
However, I'm not seeing a lot of code I could crib from to know how you'd want me to handle detecting device attachment. I don't think it would have to identify the Steam dock or any various devices used for docking, per-se, but maybe there are other system devices that would work as a proxy for "is it docked?" like external display, keyboard+mouse, ethernet connectoi?"
The UI could be let you choose how you want it to detect when to limit, or just set the limit as it is now.
It might be better to add a new power event variant and a new event trigger variant to handle setting charge mode/limit when that event fires.
How to display it in the UI is a whole other kettle of fish. I'm a bit hesitant to expose it at all, which is why it is currently only possible to achieve by editing the settings files. The UIs I can think of all seem too complex, but maybe that's a necessary evil that just needs to be hidden behind some sort of advanced options toggle.
Made an account to suggest this then found this post :)
My Deck is on a dock 90% of the time, I'd love if it only charged to 80-85% while docked, but if I throw it directly on a charger (or even if I clicked a button that said "for the rest of this session, go ahead and charge fully) it would be nice to have a bypass for that setting.
For my use case, if anything else is connected (external display, other USB devices, etc) that isn't just a charger, then I'd like it to adhere to the reduced charge limit. But if I'm direct to a battery bank or a charger, then go ahead and charge to 100%.