Created attachment 146574 [details] output of ls -Flavh /sys/class/power_supply/BAT0/ SUMMARY The option to set the battery charge limit does not show up on my Asus Vivobook laptop. I suspect that the MR: "Support new charge_control_*_threshold" - https://invent.kde.org/plasma/powerdevil/-/merge_requests/70)" Did not account for the case where "charge_control_start_threshold" does not exist, as outlined in this comment: https://invent.kde.org/plasma/powerdevil/-/merge_requests/22#note_110418 STEPS TO REPRODUCE 1. In the terminal run "systemsettings" 2. Navigate to Power Management > Advanced Power Settings OBSERVED RESULT The charged limit settings are not shown. The terminal logs: Warning from helper: Failed to open "/sys/class/power_supply/BAT0/charge_control_start_threshold" for reading Warning from helper: Failed to open "/sys/class/power_supply/BAT0/charge_start_threshold" for reading Warning from helper: Failed to open "/sys/class/power_supply/BAT0/charge_stop_threshold" for reading org.kde.powerdevil.chargethresholdhelper.getthreshold failed "Charge thresholds not supported" EXPECTED RESULT The charge limit settings should be supported and shown. SOFTWARE/OS VERSIONS Operating System: KDE neon Unstable Edition KDE Plasma Version: 5.24.80 KDE Frameworks Version: 5.91.0 Qt Version: 5.15.3 Kernel Version: 5.13.0-28-generic (64-bit) ADDITIONAL INFORMATION - Using the command line to set the charge threshold works as expected. - Probably related bug: bug 440297
Seems quite likely. Would you be interested in submitting a merge request to fix this? Seems like it shouldn't be too hard to do, and I can help guide you through the process.
A possibly relevant merge request was started @ https://invent.kde.org/plasma/powerdevil/-/merge_requests/77
(In reply to aeneid from comment #0) > STEPS TO REPRODUCE > 1. In the terminal run "systemsettings" Correction: "systemsettings5" > 2. Navigate to Power Management > Advanced Power Settings > > OBSERVED RESULT > The charged limit settings are not shown. > > The terminal logs: > Warning from helper: Failed to open > "/sys/class/power_supply/BAT0/charge_control_start_threshold" for reading > Warning from helper: Failed to open > "/sys/class/power_supply/BAT0/charge_start_threshold" for reading > Warning from helper: Failed to open > "/sys/class/power_supply/BAT0/charge_stop_threshold" for reading > org.kde.powerdevil.chargethresholdhelper.getthreshold failed "Charge > thresholds not supported" I repro this with a KDE Slimbook and Plasma 5.24. Looking forward to the merged fix :)
Git commit f7b1f2f182ab97aab1590ad47804c1dd7f04ef1f by Nate Graham, on behalf of Méven Car. Committed on 14/02/2022 at 21:15. Pushed by ngraham into branch 'master'. Support hardware with only one charging threshold, not both getthreshold will return -1 for unsupported thresholds. setthreshold will tollerate receving no value or -1 to ignore setting a threshold. FIXED-IN: 5.24.1 M +24 -15 daemon/chargethresholdhelper.cpp M +2 -2 daemon/powerdevilcore.cpp M +11 -10 kcmodule/global/GeneralPage.cpp https://invent.kde.org/plasma/powerdevil/commit/f7b1f2f182ab97aab1590ad47804c1dd7f04ef1f
Git commit 29154c13a186f5d13191db4bca1984ba2a21b839 by Nate Graham, on behalf of Méven Car. Committed on 14/02/2022 at 21:18. Pushed by ngraham into branch 'Plasma/5.24'. Support hardware with only one charging threshold, not both getthreshold will return -1 for unsupported thresholds. setthreshold will tollerate receving no value or -1 to ignore setting a threshold. FIXED-IN: 5.24.1 (cherry picked from commit f7b1f2f182ab97aab1590ad47804c1dd7f04ef1f) M +24 -15 daemon/chargethresholdhelper.cpp M +2 -2 daemon/powerdevilcore.cpp M +11 -10 kcmodule/global/GeneralPage.cpp https://invent.kde.org/plasma/powerdevil/commit/29154c13a186f5d13191db4bca1984ba2a21b839
(In reply to Buovjaga from comment #3) > I repro this with a KDE Slimbook and Plasma 5.24. Looking forward to the > merged fix :) I discovered that Slimbook and other TongFang-based laptops lack kernel support for charging limits: https://slimbook.es/en/forum/tag/amd/question/5384-pro-x-amd-set-max-battery-charge-percentage