View previous topic :: View next topic |
Author |
Message |
40inD
Joined: 30 Jul 2007 Posts: 112 Location: Moscow, Russia
|
DS1307 starting at faster frequency |
Posted: Thu Apr 10, 2014 12:13 am |
|
|
Has anyone encountered a problem when DS1037 starts at frequency about 10 times faster, and when touch the chip contacts or quartz by finger chip goes then to run normal?
What can that be? Bad quartz? Or bad pcb routing? |
|
|
Jerson
Joined: 31 Jul 2009 Posts: 126 Location: Bombay, India
|
|
Posted: Thu Apr 10, 2014 2:32 am |
|
|
Check capacitors across quartz and verify voltage supply to the DS1307 is correct. |
|
|
ezflyr
Joined: 25 Oct 2010 Posts: 1019 Location: Tewksbury, MA
|
|
Posted: Thu Apr 10, 2014 6:16 am |
|
|
Jerson,
What are you talking about? The DS1307 does not require any "capacitors across quartz". Specifically, here is what the datasheet says about that issue: "The oscillator circuit does not require any external resistors or capacitors to operate."
To the OP, have *you* read the datasheet? It clearly states the specifications for the crystals that can be used, and details the recommended board layout. In my experience, as long as you've got a 'standard 32.768KHz crystal", it should pretty much work..... Key point is read the datasheet!
John |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19587
|
|
Posted: Thu Apr 10, 2014 7:14 am |
|
|
Agreed.
Another point is that once the oscillator is started, it should never stop. So why are you seeing it 'start'?. Provided you have the correct battery connections, the oscillator should still be running is several years time.... |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9269 Location: Greensville,Ontario
|
|
Posted: Thu Apr 10, 2014 7:21 am |
|
|
also agree...
I've got a couple test setups from 3 years ago on 'bad' white breadboards and they are still running fine.Breadboards aren't 'great' but work OK for test purposes.
You _must_ use a coin cell battery( it's in the specs) and have a 'good' xtal though the cheap ones work fine,just not accurate in the long term...
hth
jay |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Thu Apr 10, 2014 7:43 am |
|
|
Quote: | Or bad pcb routing? |
You probably have PCB tracks from other circuits running next to the
crystal and the crystal pins on the ds1307. These pcb tracks will couple
extra impulses into the crystal circuit, which could result in the RTC
running too fast. Maxim has on their website, detailed explanations of
how to properly do the pcb layout for the ds1307 crystal circuit. |
|
|
40inD
Joined: 30 Jul 2007 Posts: 112 Location: Moscow, Russia
|
|
Posted: Thu Apr 10, 2014 7:52 am |
|
|
I mean, when I turning on my device, in more than 50% cases the ds1307 begins to run more faster until I thouch it X1, X2 contacts or crystal.
Of course I have read datasheet, and i have many other devices with 1307 working fine.
Just wonder about this case.
I will try to replace crystal. |
|
|
40inD
Joined: 30 Jul 2007 Posts: 112 Location: Moscow, Russia
|
|
Posted: Thu Apr 10, 2014 8:15 am |
|
|
PCM programmer wrote: |
You probably have PCB tracks from other circuits running next to the
crystal and the crystal pins on the ds1307. |
|
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Thu Apr 10, 2014 8:46 am |
|
|
It's not the ideal layout that Maxim wants. Maxim shows the preferred
layout about halfway down this page:
http://www.maximintegrated.com/app-notes/index.mvp/id/504
This guy discusses ds1307 crystal layouts. Most of the layouts that work
have ground hatch under the crystal. The one layout that doesn't work
has no ground plane and has pcb tracks all around the crystal.
https://rayshobby.net/?p=5962
Your board could have some other problem, maybe in the individual
crystal, but the layout still isn't perfect. |
|
|
ezflyr
Joined: 25 Oct 2010 Posts: 1019 Location: Tewksbury, MA
|
|
Posted: Thu Apr 10, 2014 9:06 am |
|
|
Hi,
Are you sure that you are using the correct crystal? I'm not saying they don't exist, but every '32.768 KHz' crystal I've ever seen has come in a cylindrical style package. I just checked Digikey, and they don't sell anything else! I suppose you may have just placed a footprint you had on hand without attempting to match your physical crystal?
Anyway, the datasheet says this: NOTE: AVOID ROUTING SIGNAL LINES IN THE CROSSHATCHED AREA (UPPER LEFT QUADRANT) OF THE PACKAGE UNLESS THERE IS A GROUND PLANE BETWEEN THE SIGNAL LINE AND THE DEVICE PACKAGE. You appear to be violating this recommendation with the placement of the etch passing underneath your crystal....
John |
|
|
newguy
Joined: 24 Jun 2004 Posts: 1911
|
|
|
ezflyr
Joined: 25 Oct 2010 Posts: 1019 Location: Tewksbury, MA
|
|
Posted: Thu Apr 10, 2014 11:05 am |
|
|
Hi,
Sorry, I should have said "in a thru-hole package" as well..... The point remains, however, that he's got an 'odd' thru-hole footprint for the expected 'standard' 32.768 KHz watch crystal.
John |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19587
|
|
Posted: Thu Apr 10, 2014 2:47 pm |
|
|
The package is not that unusual. HC49.
However the point is valid, since most HC49 32KHz crystals require larger load capacitors than the DS1307 wants.
Pulled a list from my supplier. Several 32K crystals in this format, but only one has the load capacitance required by the DS1307. The rest all required higher capacitance's, ranging up from 18pF.... |
|
|
40inD
Joined: 30 Jul 2007 Posts: 112 Location: Moscow, Russia
|
|
Posted: Thu Apr 10, 2014 10:57 pm |
|
|
I use cylindrical crystal with diameter 2mm |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19587
|
|
Posted: Fri Apr 11, 2014 8:41 am |
|
|
In which case, why layout the board for HC49?. Stupid.
As others have said, look at the recommended layout, and get as close to this as you can. It is important. Manufacturer's don't make recommendations like 'avoid running tracks here', without good reason.
The crystal doesn't have to 'contact' the track underneath. There is enough capacitive coupling, for a high frequency signal to be picked up by the oscillator input.
Puzzled by your picture. Either this is from the bottom of the board, in which case the text would normally be reversed, or you have the chip reversed?.
Laid out properly, the DS1307, is reliable. |
|
|
|