# Laptop battery management



## octix (Feb 27, 2009)

Does anyone know how can I control charging process of a laptop battery?

For example to stop and start charging while is on AC.

Why do I need this? 
I want to be able to control/set level of charge of laptop battery.
For example to start charging if it's below 30% and stop at 40%.
Power manager from Lenovo(I assume there are other vendors also) can do this, but this is in windows only.

I don't need an entire app for this, just a way to stop and start charging will be more than  enough, I could write a small script for that.

Thank you in advance.


----------



## SirDice (Feb 27, 2009)

To be honest, that's the first laptop I've heard of that's able to do it.

If you're constantly on AC it's better to remove the battery altogether. Continues charging and heat seriously impacts a battery's lifetime.


----------



## octix (Feb 27, 2009)

Yes, that's why I want to stop charging at some point. I guess for now I'll take battery out.. for some reason didn't think about this..


----------



## Nicholas (Feb 28, 2009)

> If you're constantly on AC it's better to remove the battery altogether


Is it really safe?


----------



## trev (Feb 28, 2009)

Nicholas said:
			
		

> Is it really safe?



So long as the power doesn't fail, yes.


----------



## morbit (Mar 20, 2009)

> I want to be able to control/set level of charge of laptop battery.
> For example to start charging if it's below 30% and stop at 40%.



It is not controlled by OS. If you set it from Lenovo app and install FreeBSD then it will stay that way.


----------



## Oxyd (Mar 25, 2010)

SirDice said:
			
		

> To be honest, that's the first laptop I've heard of that's able to do it.



My Dell laptop (Inspiron 11z) can also do it through a Dell-supplied Windows app for measuring battery charge -- there's a checkbox to "Disable battery charging".  AFAIK, it can also be disabled through the BIOS in my laptop.

I don't know how to do it on FreeBSD, though. :/


----------



## Markand (Apr 7, 2010)

Nicholas said:
			
		

> Is it really safe?



That was real a long time ago, but now good laptops have a full ACPI support which â€œremoveâ€ the battery if it's completely charged. That means the AC line will only supply the mainboard and the battery is like â€œdisconnectedâ€

David.


----------



## morbit (Apr 7, 2010)

Yes, but the moment battery charge will drop bellow 100%, charging will start, thus harming
Li-Ion cell capacity (which should be stored at ~40-45% charge).


----------



## fronclynne (Apr 7, 2010)

According to IBM docs (& I can't speak for anything else out there) their machine won't start charging again until the battery drops below 95%.


----------



## morbit (Apr 7, 2010)

That's good but my point is still valid.

Best solution is setting appropriate charging threshold as in IBM/Lenovo

(e.g. My laptop's battery is serving as UPS so I set max. charge as 43%)


----------



## swirling_vortex (Apr 7, 2010)

I still don't understand why you would want to do that. At least on the old Ni-Cads, if you only charged the battery to say, 50%, it would "remember" that limited capacity. I don't know how the lithium batteries behave, but I would imagine that over time, it would follow the same effect. I'd leave it alone or disconnect the battery if you're concerned about too much charging/discharging cycles.


----------



## morbit (Apr 7, 2010)

e.g. http://batteryuniversity.com/parttwo-34.htm

(I know, I know.. Battery university is quite a silly name.)


----------



## swirling_vortex (Apr 7, 2010)

morbit said:
			
		

> e.g. http://batteryuniversity.com/parttwo-34.htm
> 
> (I know, I know.. Battery university is quite a silly name.)


Heh, battery university. 

All it says is that for storage you should keep it at 40%. Otherwise, use partial discharges while you're using the battery.


----------



## morbit (Apr 7, 2010)

If I use mains always it's basically storage. Sure, I could just remove battery, but then I would lose "UPS".


----------



## swirling_vortex (Apr 7, 2010)

morbit said:
			
		

> If I use mains always it's basically storage. Sure, I could just remove battery, but then I would lose "UPS".


Ah, I see where you're getting at. Well, I don't know the answer.  Maybe you could do something with sysctls, but I don't know. I don't know if I could do it on Windows, let alone FreeBSD.


----------



## morbit (Apr 8, 2010)

tp_smapi or windows driver (hardware access, so once set it stays that way)

http://www.thinkwiki.org/wiki/Tp_smapi#Battery_charge_control_features


----------

