ST AN2441 Application note

April 2007 Rev 1 1/14
AN2441
Application note
Low cost effective oscillator for STR71x MCUs
Introduction
The STR71x 32-bit MCU family from STMicroelectronics runs with an external oscillator
which is connected to the CK pin.
A straightforward solution for the external oscillator is to purchase an oscillator chip which
note gives the user a low cost oscillator solution with discrete components and based on a
resonator or quartz.
Resonators have shorter start-up time compared to crystals but they have less frequency
accuracy. Depending on the application requirements, users can choose between short
start-up time and frequency accuracy. In this application note, a quartz crystal is used in the
oscillator circuitry.
There are two primary quartz-controlled oscillators circuitries. Such circuitries are generally
described by the type of crystal unit used:
Series resonant oscillator (when a series resonant quartz crystal is used)
parallel resonant oscillator (when a parallel resonant quartz crystal is used).
The advantages of the second solution are low cost and low power consumption.
The aim of this application note is to provide a methodology to design an oscillator solution
based on a quartz crystal operating in parallel resonance mode for the STR71x.
This document is split into two main sections. The first provides a brief description of both
oscillator theory and the quartz characteristics while the second proposes an oscillator
design and details the related components selection.
www.st.com
Contents AN2441
2/14
Contents
1 Oscillator theory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2 Quartz crystal characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
2.1 Frequency vs. mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
2.2 Direct drive . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
3 Pierce oscillator design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
3.1 Amplifier element: 74V1GU04 ST inverter + feedback resistor . . . . . . . . . 7
3.2 C1 and C2 capacitor selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3.3 Rs resistor selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
4 16-MHz oscillator example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
5 PCB hints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
6 Revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
AN2441 Oscillator theory
3/14

1 Oscillator theory

An oscillator consists of an amplifier and a feedback network to provide frequency selection.
The following figure shows the block diagram of the basic principle.
Figure 1. Oscillator principle
Where:
A(f) is the complex transfer function of the amplifier providing energy to the loop in
order to keep it oscillating.
B(f) is the complex transfer function of the feedback which is setting the oscillator
frequency.
To oscillate, the following Barkhausen conditions must be fulfilled. The closed loop gain
should be greater than 1 and the total phase shift of 360° is to be provided.
and
In order to get the oscillator to start up, it needs initial electrical energy. Power-up transients
as well as noise can supply the needed energy. However, the energy level should be high
enough to trigger oscillation at the required frequency. Mathematically, this is represented by
|A(w)|.|B(w)| >> 1 which means that the open loop gain should be much higher than 1. The
time until steady oscillations are reached depends on the open loop gain.
A(f)
B(f)
Active element
Passive feedback element
Vout
Af() Af() e
jfα f()
=
Bf() Bf() e
jfβ f()
=
Af() Bf() 1
α f() βf()+ 2π=
Quartz crystal characteristics AN2441
4/14

2 Quartz crystal characteristics

A quartz crystal is a piezoelectric device transforming electrical energy to mechanical
energy and vice versa. The transformation occurs at the resonant frequency. It can be
modeled as follows:
Figure 2. Quartz equivalent circuitry
Where:
C
0
represents the shunt capacitance resulting from the capacitor formed by the
electrodes and the parasites of the contacts.
L (motional inductance) represents the vibrating mass of the crystal.
C (motional capacitance) represents the elasticity of the crystal
R represents the circuit losses.
Because R is normally negligible, the impedance of this circuitry is given by the following
equation:
The following figure represents the quartz reactance across its operating frequency:
Figure 3. Quartz crystal reactance across frequency
R
LC
C
0
Z
j
w
--- -
w
2
LC 1
C
0
C+()w
2
LCC
0
---------------------------------------------------
×=
capacitive
reactive
Frequency
Impedance
Series Resonance
F
s
Anti Resonance
F
a
0
Area of usual parallel
resonance
AN2441 Quartz crystal characteristics
5/14
Two resonant frequencies can be calculated.
The series-resonance frequency F
s
is attained when the impedance Z approaches 0.
The phase shift at the series resonance frequency is zero. At the series resonance, the
impedance is minimal and the current flow is maximal.
The anti resonance frequency F
a
is attained when the impedance Z approaches the
infinity.
The area between F
s
and F
a
is called the “usual parallel resonance” or simply “parallel
resonance”
When the crystal operates in parallel resonance, its frequency F
p
is between F
s
and F
a
and
has the following expression
Parallel resonance means that a small capacitance called load capacitance C
L
should be
placed across the crystal terminals to obtain the desired operating frequency.
Figure 4 shows load capacitance with the crystal equivalent circuitry.
Figure 4. Load capacitance across a parallel resonant quartz

2.1 Frequency vs. mode

A crystal resonance can occur:
at the F
a
or F
p
frequencies (formulas given earlier). This is the fundamental mode
which is used for frequencies smaller than 30 MHz.
at an odd multiple of the F
a
or F
p
(harmonics of F
a
or F
p
). These are the third, fifth, (...)
overtone frequencies. This mode is used for frequencies above 30 MHz.
The crystal must be specified to operate at the desired frequency and on the desired
overtone. One should never attempt to order a crystal operating at its fundamental
frequency and operate it at an overtone frequency.
F
s
1
2π LC
-------------------=
F
a
F
s
1
C
C
0
------ -+=
F
p
F
s
1
C
C
L
C+
0
--------------------+=
R
LC
C
0
C
L
Loading...
+ 9 hidden pages