avr-chat
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-chat] Crystals (was ATmega32 @ 16MHz : fuse bits ??)


From: Graham Davies
Subject: Re: [avr-chat] Crystals (was ATmega32 @ 16MHz : fuse bits ??)
Date: Sat, 12 Nov 2005 09:31:17 -0500

Taking a position somewhat contrary to a regular contributor to this group
(regarding the difficulty of choosing a crystal) has really given me the
heebie-jeebies.  So, I've been experimenting.  How bad can things get before
an Atmel MCU no longer works with a crystal?  You'll have to excuse more
mention of my products, but after all that's what I have to work with.

I have an Atmel STK500 into which I have plugged one of my STK500 Expansion
Boards.  That has a JTAG header and onto that I plug an AVR ICE-Cube.  Now,
the STK500 connects the crystal pins of the MCU to both the PORTE/AUX header
and the EXPAND1 socket.  The STK500 Expansion Board further connects them to
a crystal footprint, complete with places for capacitors.  That's one heck
of a lot of wiring with a lot of stray capacitance - far more than you'd
expect even in a breadboard setup.  So, I have no capacitors, just a crystal
socket (more strays).  Will this work?

The answer is, apparently, yes.  I pull the XTAL1 header to isolate the
on-board clock generator of the STK500 and plug my crystal into the socket
on the Expansion Board.  Using AVR Studio and the AVR ICE-Cube, I fiddle
with the clock select fuses.

I started with an ATmega32L-8PC in SCKT3100A3 and that worked fine with a
7.3728 MHz crystal.  It did not work with a 15.36 MHz crystal, as you'd
expect (which is why I asked Vincent for the exact part number of his MCU).
I don't have an ATmega32-16PC, so I had to switch to an ATmega16-16PC to
test a higher frequency.  This worked fine with my 15.36 MHz crystal (I
don't have 16 MHz).  There must be 6 inches of PCB trace between the crystal
and MCU and no load capacitors at the crystal and still it works.  It
doesn't matter whether the CKOPT fuse is programmed or not.  With CKOPT not
programmed, I've tried CKSEL = 1111 and 1110 with all four values of SUT.
The clock stops for lower CKSEL settings, but these are for medium and low
frequency crystals, so you'd expect that.

So, bascially, I stand by my assertion that this isn't hard and the Atmel
MCUs have robust clock oscillators.  While I have this setup on the bench,
is there anything else I should try?

Graham.
http://www.ecrostech.com





reply via email to

[Prev in Thread] Current Thread [Next in Thread]