ATtiny & LiPo - setting them up to maximize battery cycle life.

This is a theoretical question, just something I have been wondering:

Lets say I am powering a small device controlled by an ATtiny with a Lithium Ion or Polymer battery. In order to prolong battery cycle life, I want the ATtiny to switch off when the voltage drops below 3.6V.

So in theory I could hook up +V of my LiPo to an anlog input. I then say:

  • If the voltage drops below 3.6V, go into power-down Mode
  • once in power-down mode the ADC no longer works, so even if I recharge the battery, it will stay in power down mode.
  • the interrupts are still checked though, so I could add an external sensor or switch to turn the ATtiny back on.

Alternately I could also go into ADC noise reduction mode and save some energy that way, which would allow the ATtiny to wake up automatically once the battery is charged again.

*

How would you build an ATtiny circuit which tries to extend battery cycle life by limiting depth of discharge? Is there any way that I can access these functions from within Arduino? Is there any library I might use?

Can anyone recommend me some reading or a link or a tutorial on this topic? Reading the documentation leaves me a bit confused...

Thanks

P.

You need to set analogReference(INTERNAL1V1) and use a resistor divider to bring the LiPo voltage into that 1.1V range. If you skip this step then you’ll be comparing the LiPo voltage to the VCC voltage which probably isn’t what you want. This will also have ramifications if you’re doing other analog readings, of course.

Aside from that your only option is to put the chip to sleep and wake up periodically to check the battery voltage. When in sleep mode it uses very, very little power (microamps). Assuming a decently-sized battery and recharging schedule it should work fine.

http://www.insidegadgets.com/2011/02/05/reduce-attiny-power-consumption-by-sleeping-with-the-watchdog-timer/

fkeel:
So in theory I could hook up +V of my LiPo to an anlog input. I then say:

  • If the voltage drops below 3.6V, go into power-down Mode
  • once in power-down mode the ADC no longer works, so even if I recharge the battery, it will stay in power down mode.
  • the interrupts are still checked though, so I could add an external sensor or switch to turn the ATtiny back on.

You can wake up periodically (eg. every two seconds) and check the voltage.

If it looks OK then come back to life! If not, go back to sleep again…

cool. thanks for your input. I'll be playing around with this in a little while. I'll post what my solution will be.

Chagrin: You need to set analogReference(INTERNAL1V1) and use a resistor divider to bring the LiPo voltage into that 1.1V range.

For some (most?) ATtiny processors, the voltage divider is not necessary... http://arduino.cc/forum/index.php?topic=38119.5

Just as a related subject your 3.6vdc 'cut-off' voltage is a little high in my opinion and you are leaving out useful charge left in the LiPo and not getting the full advantage of the mah capacity you paid for.

A 3.0vdc cutoff is a more commonly used value for single cell LiPos where you will then recover more of the useful charge capacity of the cell but while still preventing any cell damage due to over discharge. 3.0 to 4.2vdc is the useful and safe voltage range of a Lipo cell.

Lefty

Hi lefty

True, 3.6 is high (and also arbitrarily chosen), however, I think there is no such thing as 'discharging without cell damage'. The impression I get is that its simply a matter of degree.

Discharge it to 2.75 you get 250 to 350 cycles. Discharge to 3.0 you get around 500 cycles.

Every once in a while you will see a battery boast a cycle life of say 10.000 cycles. Usually this will be at 10% discharge.

*

This brings me to another question. Does anybody know if depth of discharge (%) is measured relative to ground or relative to absolute minimum ratings of battery?

EDIT: Thanks CodingBadly for that link. Will be useful.