Some laptops allow you to set a limit on the battery charge level. This feature is known as a charge threshold. For instance, you can choose to stop charging the battery when it reaches 60%, which may help to prolong the battery's lifespan.
On my Lenovo Thinkbook 14s Yoga it's very easy to do this. Here are the steps:
sudo dnf install tlp tlp-rdw
sudo nano /etc/tlp.conf
add this line to the file:
save and close.
sudo systemctl enable tlp.service sudo systemctl start tlp.service
Done! Now your laptop should stop charging the battery beyond 60%.
To check if your laptop supports this feature run:
sudo tlp-stat -b
On my laptop the output is this:
$sudo tlp-stat -b --- TLP 1.5.0 -------------------------------------------- +++ Battery Care Plugin: lenovo Supported features: charge threshold Driver usage: * vendor (ideapad_laptop) = active (charge threshold) Parameter value range: * STOP_CHARGE_THRESH_BAT0: 0(off), 1(on) -- battery conservation mode /sys/bus/platform/drivers/ideapad_acpi/VPC2004:00/conservation_mode = 1 (60%) +++ Battery Status: BAT1 /sys/class/power_supply/BAT1/manufacturer = Celxpert /sys/class/power_supply/BAT1/model_name = L19C4PDB /sys/class/power_supply/BAT1/cycle_count = 316 /sys/class/power_supply/BAT1/energy_full_design = 60000 [mWh] /sys/class/power_supply/BAT1/energy_full = 52800 [mWh] /sys/class/power_supply/BAT1/energy_now = 31380 [mWh] /sys/class/power_supply/BAT1/power_now = 0 [mW] /sys/class/power_supply/BAT1/status = Not charging Charge = 59.4 [%] Capacity = 88.0 [%]
Supported features: charge threshold
shows that my laptop supports charge threshold.
And this section gives me the line I need to add to /etc/tlp.conf:
Parameter value range: * STOP_CHARGE_THRESH_BAT0: 0(off), 1(on) -- battery conservation mode