Searching \ for '[AVR] About that CKOPT fuse..' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page:
Search entire site for: 'About that CKOPT fuse..'.

Exact match. Not showing close matches.
PICList Thread
'[AVR] About that CKOPT fuse..'
2006\01\22@214319 by David VanHorn

picon face
If you aren't using AVRs, you can ignore this.

This issue just popped up again, and bit a friend of mine pretty hard.
He was on the verge of having to issue a total recall for everything he'd

Atmel AVRs have a bunch of "fuse bits" that control settings like the
oscillator mode.
One particularly interesting one is the CKOPT fuse, which ships from the
factory in the "unprogrammed" state.  The text shown in the AVR programming
dialog with the AVRISP programmer for this bit is vague, and I think most
people ignore it.

In this default, unprogrammed state, the crystal oscillator is in a low
power "Vittoz mode" (Google it)   To date, atmel has shown me nothing on how
to select crystals that will work with this mode.
Now if you're using the AVR, and not programming this fuse, you may say
"well all my stuff works".

You'd be sadly mistaken, unless you know more about the AVR than atmel
apparently does.

In this mode, with a typical 18pF crystal, you'll see the oscillator running
from ground to about half VCC.

One of several things will happen:

Dosen't go..  Lucky you!
Dosen't go, you replace the crystal, and now it goes.   Unlucky you!
Intermittent to rare cases of non-deterministic execution.
Intermittent to rare cases of corrupted values in RAM or registers.
Serial or timer timings just a bit off.. Long.

Now if you're really unlucky, everything will look fine till you've shipped
a bunch of systems, and the temperature changes, VCC changes, or you get a
new bunch of crystals in, or new AVRs of a different date code with slightly
different drive to the crystal.

This mode is documented (sort of) in the current data sheets, it's casually
mentioned as a low power mode, and that's all the guidance you get.

I wrote some Tiny-11 (portable to pretty much any AVR) code for a little
"fixer" that will plug in to the standard programming header, and re-write
those fuse bits. It needs the connector, a programmed tiny-11, and a
resistor to pull up /Reset.  A one-chip wonder.  Code's posted in the
tiny-11 group on Yahoo, or by request from me.

2006\01\22@220923 by Chen Xiao Fan


> From:
> [] On Behalf Of David VanHorn
> Sent: Monday, January 23, 2006 10:43 AM
> To: Microcontroller discussion list - Public.
> Subject: [AVR] About that CKOPT fuse..
> If you aren't using AVRs, you can ignore this.

I think this pops up from time to time. I do not use AVRs
but I do monitor some lists (mainly AVR-GCC and AVR-LIBC)
from time to time.

Here is another discussion in the BASCOM list dated 10-Jan-2006. I
think Russel is subscribing to that list.

{Quote hidden}


2006\01\22@222347 by David VanHorn

picon face
> I think this pops up from time to time. I do not use AVRs
> but I do monitor some lists (mainly AVR-GCC and AVR-LIBC)
> from time to time.

Yup, this is the same issue..

BTW my friend wrote his version of Fuser, in Bascom.
About 3X larger than my version, and I wasn't EVEN trying.

> >>But regarding specifically the CKOPT bit.  You should not need to set
> >>this just to run an external crystal.

Well, it will run usually.. Sort of.  With a tail wind.

> >Notice the "half wave" after the first cycle. This happens constantly,
> btw.
> >These "missed cycles" is raising all sorts of Hell with serial comm.

I think he may have been quoting me there.. :)

More... (looser matching)
- Last day of these posts
- In 2006 , 2007 only
- Today
- New search...