Anyone know of a Linux (and Windows) program to stop laptop charging past a certain point?

For example, right now I am using my laptop as a desktop replacement, and I want the battery installed for backup. However, by default the battery will be charged to and maintained at 100%.

100% is bad for long term storage. I want it to be maintained at 40% instead.

One way is to use a USB controlled relay that cuts power when battery goes above 40%... but I'm hoping there's a software solution.

01-08-2012

CommonTater

Unless you are using Nickel Cadmium batteries... this old "don't charge constantly" thing is a complete load of crap. I have a 4 year old netbook that's plugged in 90% of the time (it's the remot control for my home theatre) and when I do unplug it to go mobile, guess what... 2 1/2 hours, right on spec.

The newer NI-MH batteries do not get killed from overcharging and newer charging circuits do not overcharge to begin with.

Really... the hardware is designed to work correctly... let it do it's job.

Your best solution in this case is .... no solution at all.

01-08-2012

cyberfish

Yes I'm well aware of the lack of memory effect. One of my major electronic projects was a battery charging circuit for many different types (and termination methods).

At 25C, a LiPo/Li-ion battery loses 4% capacity (permanently) if stored at 40%, vs 20% if stored at 100%.

01-08-2012

cyberfish

The hardware does the right thing for providing you with the longest run time whenever you decide to unplug your computer, not for prolonging battery life.

01-08-2012

cyberfish

And oops, why did I post this in the C programming forum :S. Can a mod please move it to Tech?

Thanks

01-08-2012

CommonTater

Trust me... it's not worth worrying about. Most battery packs now outlive their hosts anyway... So if ever there was a non-issue, this is it.

01-09-2012

cyberfish

At 30C, storing/keeping a LiPo at 100% will make it lose 25%-30% capacity per year. That's definitely something to worry about. I use my laptops for 3-4 years, and constantly hear people swearing at their laptop batteries that will only last 10 minutes.

01-09-2012

CommonTater

Re-read post #2...

At one time I was responsible for maintaining about 250 laptops... in all that time I never once replaced a battery pack except due to breakage (mostly from being dropped).

These people complaining about batteries that only last 2 minutes are full of (synonym for fecal matter from a male bovine). This simply has not been an issue since they stopped using NI-CAD battery packs.

That said... there is a known issue with Windows. It recalibrates it's battery life continuously and will eventually start delivering warnings almost immediately if you are recharging after 10 or 20 minutes of use. The way to force it to recalibrate itself to the REAL life of the batteries is to run the battery right down until the computer shuts off and will not come back on... usually about 10% over spec... about once every 6 months... Now to be clear... this is not for the battery life... it simply forces Windows to recalibrate it's battery timers.

01-09-2012

cyberfish

Quote:

These people complaining about batteries that only last 2 minutes are full of (synonym for fecal matter from a male bovine). This simply has not been an issue since they stopped using NI-CAD battery packs.

This is a real issue with Li-Po batteries. It has nothing to do with the memory effect of NiCad. Totally unrelated.

I know at least a few people with useless batteries because they have kept them at 100% in their computer (~30C), which agrees with experiments.

01-09-2012

phantomotap

@CommonTater: Please stop talking; you are talking about Ni-CAD and Ni-MH when cyberfish is discussing lithium. If nothing else, you may convince some poor bloke that leaving a battery at a constant full charge is fine when it isn't.

@cyberfish: The best you can really do with ACPI is setup a few components to "hover" the power level between %35-%55 or about that. (People like to pretend, but ACPI didn't really deliver on some promises.) I've tried this while using the temperature monitors from Asus (manufacturer.) It wound up with temperature and voltage profiles similar to simply leaving it on the charger. I wound up with a slightly less max charge than what my dad gets who nearly never has his off mains. (The same exact laptop; I bought them at a clearance sale for only slightly more than what one would have cost.)

It sucks, but I think the traveler's suggestion of simply charging/discharging the battery to around %40 and removing it from the laptop while at "base" and throwing it on the charger the night before you know you are going to need it is still the best advice.

[Edit]
And of course that only applies if you are mostly at "base" with casual battery use.
[/Edit]

Soma

01-09-2012

MK27

Quote:

Originally Posted by CommonTater

Unless you are using Nickel Cadmium batteries... this old "don't charge constantly" thing is a complete load of crap.

You're wrong. While lithium-ion batteries don't suffer from the memory effect, they will last longer if you store them at 40%, and if you discharge them less at a go.

Similar to a mechanical device that wears out faster with heavy use, so also does the depth of discharge (DoD) determine the cycle count. The smaller the depth of discharge, the longer the battery will last. If at all possible, avoid frequent full discharges and charge more often between uses.

People do statistical tests on this kind of thing. Just saying anecdotally, "Oh I have lots of batteries, I don't pay attention to this, but they are all fine, trust me" is no kind of science.

I'd assume the reason there is no software to limit the charge is because most hardware is not capable of it. I just leave my battery out at 40% except when I need to use it. That also saves it getting warm.

01-09-2012

CommonTater

The charge limit is done in hardware by circuitry designed for the specific batteries being used. The circuit actually does shut down when the maximum safe charge is reached, then it just provides a small trickle charge to keep the batteries topped up.

And, FWIW... you'd be amazed how much pure BS there is out there about battery life.

01-09-2012

laserlight

Quote:

Originally Posted by CommonTater

The charge limit is done in hardware by circuitry designed for the specific batteries being used. The circuit actually does shut down when the maximum safe charge is reached, then it just provides a small trickle charge to keep the batteries topped up.

So, what conclusions do you intend to draw by providing this tid bit? It seems to me that it addresses overcharging, but cyberfish stated in post #3 that he is not talking about overcharging.

01-09-2012

CommonTater

Based on 30 years of professional experience in electronic repair you mean?

Older rechargeable batteries with plain old diode/resistor charge circuits would deteriorate as described, sometimes to the point of outright quitting ... as was common in older cordless phones; leave them in the cradle all the time and pretty soon you're lucky to get 5 minutes of talk time.

Since switching from NI-CAD batteries and incorporating "smart chargers" a lot has changed in the last few years. Where the old notion was simply "charge the heck out of it" now the newer regulator based circuits actually monitor battery voltage (and sometimes temperature) to keep charging within safe limits for the particular battery type... NI-MH or newer Lithium ion batteries can be recharged hundreds of times with no serious degredation in performance.

Where it was once common practice to replace your battery packs once a year, we are now seeing batteries that outlive their host computers... most people will upgrade before the run time per charge ever becomes a problem.

My earlier example of my netbook is pretty much on pace... I've had it for 4 years, it's on charger power 90% of the time and I still get at least the 2 hours specified by Acer on each charge. Often I'll get 2 1/2 hours of runtime, 8 hours on standby... which exceeds their spec. And this is with the original battery pack. (The consideration being that Windows is known to give false warnings about battery life)

It may make a difference to discharge batteries down somewhat if they are simply being stored outside the computer but when installed the system's hardware knows what to do to give you the longest run times commensurate with the longest battery life... it's part of the design.

My conclusion is that as computer problems go... this one's a total non-starter. Just use the thing. It'll be fine.

01-09-2012

MK27

The oldest lithium-ion laptop battery I have is 7 or 8 years old. It has not been able to hold a charge longer than 1 hour for about half that time. Right now, it will not hold a charge longer than 30 minutes.

Most people I know with laptops older than 3-4 years report similar problems.

Quote:

Originally Posted by wikipedia

Cell life

Charging forms deposits inside the electrolyte that inhibit ion transport. Over time, the cell's capacity diminishes. The increase in internal resistance reduces the cell's ability to deliver current. This problem is more pronounced in high-current applications. The decrease means that older batteries do not charge as much as new ones (charging time required decreases proportionally).High charge levels and elevated temperatures (whether from charging or ambient air) hasten capacity loss.[46] Charging heat is caused by the carbon anode (typically replaced with lithium titanate which drastically reduces damage from charging, including expansion and other factors).

The consensus online suggests the lifespan is about 1000 charges, or 3 years of daily use, if you charge/discharge 100%. Presumably, the capacity is significantly reduced halfway thru that. Which about fits with my experience, and what I've heard from everybody else in the world except CommonTater.

Quote:

Originally Posted by CommonTater

when installed the system's hardware knows what to do to give you the longest run times commensurate with the longest battery life... it's part of the design.

Malarky. You just make tish up. The "design" is intended to provide you with the longest charge. If that were compatible with the longest battery life, what you are saying might be true. But it isn't.

It also does not make logical sense unless the battery had an infinite lifetime. Since using the battery causes it to wear out, not using it at all would be "commensurate with the longest battery life". Obviously, that is not "the design". The design is a compromise.

Most people would not buy a laptop that prolonged battery life by limiting charge time to 1/2 hour, especially since you can make that choice yourself anyway. So what sells, sensibly enough, is a long operating time on a 100% charge.