I have tested and used 2 of them and they work perfectly.
I have read through the older thread here with horror. But I have not encountered any problems at all.
I do not have a schematic for these modules.
The batteries are not rechargeable. Should I be expecting an explosion?
Everything works on these but I have written my own libraries. Maybe the public ones are bad. I do not know if anyone has ever paid attention to the fact that the DS1307 can only work at 100KHz...
DS1307s are fine but not that accurate. I believe they can be quite INaccurate in a wider temperature range like you might get outdoors. I understand this is because there is no temperature compensation. Nothing is going to explode, there is nothing wrong with the existing libraries, and it can work just fine with no library.
I have a chinese board with a DS1307 on it. It works fine. I only bought it because the US made board that I wanted (and is a copy of) was out of stock. In this case it worked out for me, but it was a very cheap board sent with very cheap shipping. I don't know how a US company can compete against that, unless of course some fraction of the copycat boards don't work properly.
I'm not too worried about it exploding though.
The DS1307 isn't as accurate as some other RTCs, partly due to tolerance of the crystal and partly due to temperature dependence of the crystal frequency. Some people have reported rather large errors necessitating software kludges to correct for it. For a few extra extra bucks you can get an RTC chip with much greater accuracy. It just depends on the application and how important pennies are in your project.
Mine is okay for what I need, but if it were a $10 digital watch I would be very disappointed. It doesn't keep time all that well.
According to the datasheet: "Backup Supply Input for Any Standard 3V Lithium Cell or Other Energy Source." So it shouldn't matter as long as it is between 2 and 3.5V. The LI2032 has a nominal voltage of 3.7V -- it's too high.
The DS1307 datasheet says that a battery with 48mAh should last about 10 years. A CR2032 has over 200mAh and costs about $1. So why bother with a rechargeable?
edit: I was wrong, the battery I have is a CR1220, with only 40mAh. So that means it will only last about 8 years. I wonder if I will even still have this board in 2023.
This is the schematic as posted in the other thread.
According to this schematic, the battery is being fed through a silicon diode and a R5=200R resistor, the full Vcc voltage. Whatever current flows, it will flow straight into the battery, as the DS1307 has max 500nA consumption on that battery pin. The potentiometer R6/R4 will draw 1.5uA, 3 times as much. Total is 2uA. Therefore the voltage drop on the R5=200R is negligible at 400uV. Whatever voltage drops over R5 it will be due to the CR2032 pulling current, plus the 0.6V on the diode.
So it seems we are attempting to chanrge a CR2032 Lithium battery, nominal 3V, with a 4.4V source through a 200R resistor.
That seems dangerous to me.
Maybe that schematic does not apply to this module ?
Oh, I see. The board is supposed to use an LI2032. But wouldn't that be too high a voltage for the DS1307? Maybe you can get away with just being a few tenths of volt high. Seems weird to bother with a rechargeable though.
Are you even sure the board matches the schematic? Maybe get out the ohmmeter and try to figure it out?
I scanned through that thread. What a train wreck! Sometimes the cheaper item isn't really cheaper. This one would allow better sleep at night.
akis_t:
suggests that the batteries will explode... It also suggests that the modules are flaky and almost noone can get them to work...
Well, I guess that is the trouble with an internet forum. Seeing that there is probably a million or two TinyRTCs out there, what you need to read about are instances of batteries exploding. I also put it to you that nearly everybody can get them to work but they don't find sufficient motivation to write to the forum to tell you the bleeding obvious, thereby allowing those who can't to spook you.
Clearly, the device is designed to run with LIR2032 and, as far as I'm aware, if it comes with a battery, it is always an LIR. I had one die and have replaced it with a CR2032 I had to hand, which does not seem to be a problem, but can't be a good idea, even though a rechargeable on such a device doesn't seem to be a such good idea either. It is notable that there seems to be an increasing number of Tinys offered with no battery, and maybe a problem lies there - people are putting the wrong battery in them.
It's also notable that you can get 3231s for about the same price now, so I have just ordered another one. I understand the 3231 has the accuracy the DS1307 doesn't. The disadvantage of the 3231 is that it isn't anywhere near as tiny as the Tiny and it has taken me years to think laterally enough to find a satisfactory way of installing it in my gear. I am now putting it on its own little shield and won't use the DS1307 any more, even though I'm still not sure if it caused my recent problem.
I have received a bunch of "Tiny DS3231" from ebay. They are very similar to the "Tiny RTC DS1307" from ebay. Both ICs use same registers, 0 to 7, to access their RTC with very small differences. Both modules include an AT24C32 EEPROM that contains 4K bytes with 1 million cycles and 100 years retention. Both modules have an idiotic resistor/diode network to charge the onboard lithium cell. It is advised to remove the diode and use a CR2032. The "Tiny RTC DS1307" in addition has a resistor potentiometer that would drain the lithium cell unnecessarily so it would be best to remove that too.
One advantage of the RTC DS1307 is that it comes with an additional 56 bytes of nvRAM which is a useful place to squirrel away some data to survive during power cycles.
Another place to store data would be the Atmega328 EEPROM, but that has a limited number of write cycles (c. 100K) and if you want to be making regular writes it is not ideal. An example of a regular write would be "the last time I was switched on, with a 10 second accuracy". In that case you are oblidged to record the time once every 10 seconds thus making excessive use of the EEPROM.
For what its worth I use the DS1307 in two devices I have built, with its onboard CR2032, and have not bothered to modify it. I sort of half-expect it to blow up.