cosmic-applets icon indicating copy to clipboard operation
cosmic-applets copied to clipboard

[Power and Battery] Increase the lifespan of your battery... doesn't stop charging at 80%

Open WatchMkr opened this issue 1 year ago • 2 comments

I think there are two parts to this feature:

  1. Set the firmware to stop charging at 80% (is there a standard interface)
  2. Don't display this option if the firmware can't support it

@jackpot51 @crawfxrd may need your guidance on setting this up.

WatchMkr avatar May 08 '24 23:05 WatchMkr

Hello all! I am pasting the issue I created a few days ago according to @leviport 's instructions. I'm sorry for making a duplicate issue.


I have a Lenovo Legion 5 Pro laptop (details shown below), but this issue is also applicable to Lenovo IdeaPad laptops, as can be seen on the following links:

  1. https://wiki.archlinux.org/title/Laptop/Lenovo (section 2.1. Battery conservation mode)
  2. https://bugs.kde.org/show_bug.cgi?id=441057
  3. KDE's Implementation https://invent.kde.org/plasma/powerdevil/-/commit/53f688de8eff37a52efed55b52d9e51f5217a185

At the moment, I can enable the battery charge limit (60% maximum charge) using the following command: echo 1 > /sys/devices/pci0000:00/0000:00:14.3/PNP0C09:00/VPC2004:00/conservation_mode, but a connection with the battery applet's builtin functionality would be much appreciated.

Additional Info:

sudo dmidecode | grep -A3 '^System Information'

System Information
	Manufacturer: LENOVO
	Product Name: 82JQ
	Version: Legion 5 Pro 16ACH6H
sudo apt show cosmic-applets

Package: cosmic-applets
Version: 0.1.0~1739478579~24.04~e9848a2
Priority: optional
Section: admin
Maintainer: system76 <[email protected]>
Installed-Size: 74.1 MB
Provides: system76-power-applet-virtual
Depends: cosmic-icons, libc6 (>= 2.38), libdbus-1-3 (>= 1.9.14), libgcc-s1 (>= 4.2), libpulse0 (>= 0.99.4), libudev1 (>= 183), libxkbcommon0 (>= 0.5.0)
Recommends: pipewire-pulse
Homepage: https://github.com/pop-os/cosmic-applets
Download-Size: 14.0 MB
APT-Sources: http://apt.pop-os.org/release noble/main amd64 Packages
Description: Cosmic Applets

AAnzel avatar Feb 18 '25 12:02 AAnzel

I am also observing this in Pop!_OS 24.04 (Alpha 7) on the HP Dev One. In addition, the OS doesn't seem to remember the state of the toggle for this option after reboot.

taivlam avatar May 17 '25 18:05 taivlam

I followed this for my laptop (ASUS TUF DASH F15) and it worked to set a stop charging battery threshold. From my understanding, this should work for all ASUS laptops: https://www.linuxuprising.com/2021/02/how-to-limit-battery-charging-set.html

The toggle does nothing as mentioned by other users.

esuriddick avatar Jul 25 '25 11:07 esuriddick

I think I will close this issue for now, but work could be done on https://github.com/pop-os/system76-power to improve support. We can reopen this issue if it's better to track support here though.

wash2 avatar Jul 28 '25 19:07 wash2

As of today, August 1, 2025, this issue remains. The toggle (on) is not remembered on subsequent boots, plus the 80% maximum charge continues to be exceeded to 100%. (I just installed a new battery on my Dell Latitude E6330.)

waburden avatar Aug 02 '25 02:08 waburden

What version of the applets do you have installed?

wash2 avatar Aug 02 '25 05:08 wash2

As of today, August 1, 2025, this issue remains. The toggle (on) is not remembered on subsequent boots, plus the 80% maximum charge continues to be exceeded to 100%. (I just installed a new battery on my Dell Latitude E6330.)

Where can i find this toggle? Does this feature require installing an applet?

nalladev avatar Nov 04 '25 18:11 nalladev

As far as I can tell, the toggle is removed/hidden if you don't have System76's power daemon thingy running: https://github.com/pop-os/cosmic-applets/blob/fddfc0b6844df7ae2ee9bdb81684e84b0478d5d6/cosmic-applet-battery/src/backend/mod.rs#L227

It would be nice if it supported PPD :)

craftyguy avatar Nov 04 '25 20:11 craftyguy

Is there like an alert system that can be set to custom low and high for non system76 laptop's where stopping charging might not be possible.

nalladev avatar Nov 22 '25 10:11 nalladev