Go Down

Topic: Accuracy of DS1307 Real Time Clock module (Read 20853 times) previous topic - next topic

ninja2

I have a couple of these RTC modules based on DS1307 :
http://littlebirdelectronics.com/products/real-time-clock-module

I am finding they loose a  few seconds every day which is more than I would have expected, enough to cause a problem over time (no pun!). The DS1307 datasheet and AN58 explain that accuracy depends on the crystal qualities and how it is installed - no surprises there.

Curious to hear from others who have noticed similar inaccuracy in this or equivalent RTC modules and how you have handled it. e.g. an option I am considering is to monitor the lost seconds and come up with a correction factor to apply in the sketch once per day, or week.


cmiyc

I have a couple of different circuits based on the 1307.  Two boards are different ground plane designs.  It doesn't seem to matter.  Circuits using either of my two designs either lose 2-3 seconds per day or 2-3 minutes per day.  The boards are consistant to whatever their loss is, but I can't seem to predict what loss will be.

After my supply of 1307s run out, I'm done with them.  I'm going to use DS3231 moving forward.  More expensive, but much more accurate.
Capacitor Expert By Day, Enginerd by night.  ||  Personal Blog: www.baldengineer.com  || Electronics Tutorials for Beginners:  www.addohms.com

dc42

The DS1307 is specified for a 32768khz crystal that takes a load capacitance of 12.5pF. However, those crystals are available for various load capacitances values from 6pF to 12.5pF. Maybe they used the wrong crystal. Or maybe they put a ground plane opposite the crystal pads, thereby increasing the load capacitance, which decreases the frequency.
Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

cmiyc

Did they solder the crystal's body to the board?

The datasheets for the crystals I bought said specifically *not* to do that.  The heat of soldering can crack the crystal.

As I recall, the boards I used kapton tape to hold the crystal closer to the board perform slightly better.
Capacitor Expert By Day, Enginerd by night.  ||  Personal Blog: www.baldengineer.com  || Electronics Tutorials for Beginners:  www.addohms.com

macegr

The DS1307 and matching crystals are supposed to operate best within a rather narrow range near room temperature. Even the best matched, calibrated DS1307 and crystal will drift when subjected to lower or higher temperatures. That's why the DS3231 is so accurate...not only does it have a built-in, pre-trimmed and calibrated crystal, but it modifies the load capacitance in response to temperature measurements. It also keeps track of how old it is, and applies an aging factor to the load capacitance as well.
Unique RGB LED Modules and Arduino shields: http://www.macetech.com/store

Jack Christensen

I recently did some accuracy testing on a half-dozen DS1307 breakout boards. After letting them run nearly 10e6 seconds, the errors were -44, -30, -28, -20, -7, and 14 ppm. Five of the six had parts I bought from various sources, and while the crystals were not all identical, all had ±20 ppm specs, and I believe all were 12.5pF. The sixth was a kit I purchased, so I'm not sure about that one (the kit had the -30 ppm error).

So pretty disappointing. I'm a fan of the DS3231 too. Simultaneous with the above tests, I checked a Chronodot that had run nearly 1.5e6 seconds, and it was 1 ppm off. Thank you, macegr! XD

Not a scientific test, small sample size, etc. etc., but I still found it interesting.

Jack Christensen


Did they solder the crystal's body to the board?

The datasheets for the crystals I bought said specifically *not* to do that.  The heat of soldering can crack the crystal.

As I recall, the boards I used kapton tape to hold the crystal closer to the board perform slightly better.


I use a small drop of gel-type super glue to hold the crystal to the board. Then I solder one lead at a time, with a micro alligator clip on the crystal lead as a heat sink, and taking care not to heat it longer than necessary.

cmiyc


I use a small drop of gel-type super glue to hold the crystal to the board. Then I solder one lead at a time, with a micro alligator clip on the crystal lead as a heat sink, and taking care not to heat it longer than necessary.


This sounds like a reasonable (and effective) installation method.
Capacitor Expert By Day, Enginerd by night.  ||  Personal Blog: www.baldengineer.com  || Electronics Tutorials for Beginners:  www.addohms.com

Jack Christensen


This sounds like a reasonable (and effective) installation method.


So I thought. Lot of good it seems to have done for accuracy! :P

Jack Christensen

But here is a very tempting solution!

http://www.ebay.com/itm/Original-FE-5680A-10MHz-Out-Rubidium-Atomic-Frequency-Standard-/250921757978?pt=LH_DefaultDomain_0&hash=item3a6c1a2d1a

cmagagna

Quote
After my supply of 1307s run out, I'm done with them.  I'm going to use DS3231 moving forward.


I echo this. The ds3231 can use the 1307 library without modification so it's easy to use. I've had a 1307 project running since October and it's about 5 minutes off now. Another project with a 3231 has been on since mid December and is still within 1 second of my computer's clock.


CrossRoads

Can always go extreme and add GPS time ...
http://www.dipmicro.com/store/DSSC-0104
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

stevemarple

The DS3231 looks like a good alternative to the DS1307, especially as it can operate at 3.3V and 5V, but SOIC package only it seems. I have a project where I really want to avoid using SM devices as other people will be building them. Are there any alternatives to the DS1307 that operate at both 3.3V and 5V and are available in a through-hole package?

ninja2


xenocid

#14
Jan 20, 2012, 02:18 pm Last Edit: Jan 20, 2012, 02:21 pm by xenocid Reason: 1

Are there any alternatives to the DS1307 that operate at both 3.3V and 5V and are available in a through-hole package?


DS1302 is a DIP-8, 3-Wire, RTC. It operates from 2 to 5.5V and as a bonus point it can trickle charge  the backup battery or capacitor.
A library for arduino IDE is available here

Go Up