As far as I know, LiIon batteries should be kept in about 40%-80% range in order to degrade more slowly.

On my laptop I use the following commands to make it change battery conditionally, only when it's lower than 45% and up to 90% instead of to 100%:

tpacpi-bat -v -s ST 1 45
tpacpi-bat -v -s SP 1 90

How do I do the same for Android? I can control the charger from software, so it should be definitely possible.

Device: Huawei Honor 6 (H60-L04)


I managed to do it for the same device cutting off charging at am upper level. How do I override charging current on Huawei Honor 6? Surely something on those lines can be implemented for lower l level maybe a macro to shutdown the phone ( too drastic) or sound alarms and send text messages or mails if you are not close to the phone Hope this helps

  • I'll probably write a program that periodically polls current charge level and does echo 0 > enable_charger automatically.
    – Vi0
    Oct 29 '15 at 12:17
  • @Vi0 :-) were you able to echo 0.. I couldn't at all and had to copy paste file. Big thanks to you for pointing that file
    – beeshyams
    Oct 29 '15 at 13:29
  • enable_charger is a typical sysfs/proc knob which should be perfectly readable by cat and writable by echo ... > (as root, obviously).
    – Vi0
    Oct 29 '15 at 16:16
  • 1
    Have you received a notification of my reply in the chat? (I'm not sure how reliably this "move to chat" feature works).
    – Vi0
    Oct 30 '15 at 15:18
  • 1
    Yes. Received and replied on chat please
    – beeshyams
    Oct 30 '15 at 16:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.