Rich Grise
Guest
|
Posted:
Sat Feb 12, 2005 1:17 pm Post subject:
Re: Choosing a Crystal for a Microcontroller |
|
|
On Wed, 09 Feb 2005 11:53:30 +0100, Anders F wrote:
| Quote: | "Rich Grise" <richgrise@example.net> wrote in message
On Tue, 08 Feb 2005 12:50:38 +0100, Anders F wrote:
Not that he'll need it of course ;-)
Well, I don't know. He's admitted he's been touched by the Shadows - we
might have to kill him just on GPs. ;-)
GPs? (If its bad I'll throw the first 0201 cap at him ;-)
|
General Principles. ("oh, let's just do that on general principles.") ;-)
Cheers!
Rich
|
|
Pooh Bear
Guest
|
Posted:
Sat Feb 12, 2005 1:42 pm Post subject:
Re: Choosing a Crystal for a Microcontroller |
|
|
Rich Grise wrote:
| Quote: | On Wed, 09 Feb 2005 21:46:53 -0500, Dave VanHorn wrote:
That's because it's an analog circuit, and they're digital weenies. And
they have so little confidence in their analog design skills, that they
just pick a number out of the air that they're fairly sure will work
enough more times than not that nobody will complain.
I've given the answer twice already.
The crystal's load capacitance should be 13 pf, Digi-key has them. The
capacitors should be 22 pf - Atmel says this in the chart at the bottom of
page 25 or 26.
It's not nearly that simple in the low power Vittoz mode.
Been there, done that, had the halted production line.
In the normal rail-rail mode, yes pretty much any parallel resonant AT cut
crystal will work.
So, then, does the chart at the bottom of that page only come into play
for unusual circuimstances?
In rail-to-rail mode, at 16 MHz, what are the recommended capacitors?
Atmel doesn't say, as OP has so eloquently noted.
Personally, I'd have opted for what I had said - is rail-to-rail mode
better? How? And Why? Do you then look for a different crystal? Like a
series crystal, and not bother with caps? Or use caps and a series crystal?
This has been going on for a week, and poor ol' OP still hasn't got a
reliable answer.
|
Hey, I gave some suggested values !
I'm not sure if I'm totally reliable - lol - but I expect they'll make his
crystal oscillate !
Graham |
|
Dave VanHorn
Guest
|
Posted:
Sat Feb 12, 2005 11:54 pm Post subject:
Re: Choosing a Crystal for a Microcontroller |
|
|
| Quote: | In rail-to-rail mode, at 16 MHz, what are the recommended capacitors?
Atmel doesn't say, as OP has so eloquently noted.
|
The crystal determines the cap values.
The only way the chip enters into it, is as a secondary parasitic effect.
So, atmel is right not to give you those values.
As I said before, this is like asking the guys who made your 2N3904 what cap
value to use in your colpitts oscillator circuit. The inductor primarily
determines that, not the transistor.
| Quote: | Personally, I'd have opted for what I had said - is rail-to-rail mode
better?
|
This is an ill formed question, both have their strong points.
The Vittoz mode is very low power, used in most (all?) digital watches.
The rail-rail mode is robust, and rather tolerant of crystal and cap values.
| Quote: | Do you then look for a different crystal?
Yes, typically the rocks for Vittoz mode spec much smaller cap values, which |
of course makes them more sensitive to variability in the parasitics.
Rail to rail mode will typically run on any crystal that will take the drive
level.
Tuning-fork type crystals can have VERY low max drive levels, and you
can/will shatter them if you drive them too hard.
| Quote: | Like a series crystal, and not bother with caps? Or use caps and a series
crystal?
|
It's still a parallel circuit. A series rock may run, but you can't get it
to the right frequency.
That may not matter, if you don't need much accuracy. All crystals have a
parallel and a series resonant point. They are very close to each other, but
they cannot ever be at the same point.
The crystal's impedance is highest at the parallel point, and lowest at the
series point.
| Quote: | This has been going on for a week, and poor ol' OP still hasn't got a
reliable answer.
|
Yes, he has, but it's had a bunch of noise heaped on it.
1: Don't use Vittoz mode unless you have to, and then you'd best be sitting
at the table with a FAE from atmel, and one from your crystal maker. This
is an advanced level project, and you'd also better have a copy of his paper
from IEEE.
2: Using normal mode, pick a nice standard rock that meets your requirements
for price and accuracy/stability. Note max drive level. If it's rather low,
<mW then provision for an extra resistor on the chip's xtal osc out pin to
reduce the drive.
3: Using it's data sheet, calculate the cap values, which will be roughly 2X
the loading C value, minus 5-6 pF for parasitics.
4: Build the real board, and populate.
5: Check drive level, adjust R if needed.
6: Make frequency test, and adjust C values as needed.
7: Make stability ("negative resistance") test.
Now you have a production ready design.
For hobby projects, you can stop at 3, or carry as far as you like to learn
about the whole thing.
If you skip any of these steps, then you don't know how close you are to the
edge, and while it may appear to work for you, the same "design" may not
work for someone else, using the same parts, but different production runs.
The crystal is an RF, Analog circuit. Not a very complicated one, but it's
relatively simple considerations are frequently ignored.
Just slapping an oscillator brick in there isn't all that simple either.
1: Is it TTL, or Cmos output? Which do you need?
2: What is it's power consumption?
3: Is it sensitive to risetime or noise on VCC?
4: What bypassing does it need?
5: Do you need a series R to the processor, if so, what value?
6: Did you provide a solid low impedance ground path between the can and the
processor?
There's nothing magic in those cans, dremel one open and see for yourself.
|
|
John Larkin
Guest
|
Posted:
Sun Feb 13, 2005 1:07 am Post subject:
Re: Choosing a Crystal for a Microcontroller |
|
|
On Sat, 12 Feb 2005 07:15:10 GMT, Rich Grise <richgrise@example.net>
wrote:
| Quote: | Personally, I'd have opted for what I had said - is rail-to-rail mode
better? How? And Why? Do you then look for a different crystal? Like a
series crystal, and not bother with caps? Or use caps and a series crystal?
This has been going on for a week, and poor ol' OP still hasn't got a
reliable answer.
|
That's because there is no "reliable answer."
John |
|