11 April 2015

Modding RTC DS1307 for non-rechargable battery

I wanted a stand-alone clock for my solar irradiance monitor. So I bought a batch of 5x DS1307 RTC modules for Arduino. The item description and pictures claimed their backup battery was a rechargeable R2032 cell, but they all arrived with a standard CR2032 battery.

Click to zoom
Not a bad purchase, considering the overall cost and how much I would pay for a single CR2032 battery here in Italy (the same price of the whole RTC module), or the stand-by current consumption of the RTC, in the order of uA (microAmps!) that equals the self-discharge current of most battery chemistry.

The problem is that the RTC board includes charging circuitry and when supplied with 5V it tries to recharge a non-rechargable battery. This process damages the backup battery and can cause all sort of troubles (failure to retain clock time, leak, fire). How to fix it?

This is the relevant portion of the backup circuitry:

You may apply two different mods, both valid.

First of all, the recharge can be disabled by removing the (voltage drop) diode. This is enough, but purists may wish to go further.

A fully charged CR2032 cell exhibits a voltage of 3-3.2 Volts, while a rechargable Lithium battery reaches 4.2 Volts. Therefore the module designer added a resistive voltage divider to drop 4.2 V to 3.2 V or so. That's what R4 and R6 do.

So, now you may operate in two different ways, both shown in the picture above. Either remove R4 that goes to ground or also remove&short R6 to feed the battery voltage directly to the DS1307 RTC chip. In the first case the current drawn is so small that the voltage drop across R6 is irrilevant. The second choice is obviously the best fix.

Please note that the procedure described above needs to be reversed if you want to use a LIR2032 in the future.