Documente Academic
Documente Profesional
Documente Cultură
AN96103
Philips Semiconductors
Abstract
<Almost since the introduction of microcontrollers as electronic components there always has been an oscillator
circuit on the device to make it work. From application point of view only some external components were
required to make it work. However, to make sure that it will always work required more effort. This report is based
on feedback from the market from customers applying 8-bit mircrocontrollers.>
2
Philips Semiconductors
APPLICATION NOTE
AN96103
Author(s):
Andre Pauptit
Systems Laboratory Eindhoven,
The Netherlands
&
Erik Nordberg
Telecom Products Group
Zuerich
Keywords
<80C51,P83CLxxx,P33xx,P84Cxxx,X-tal,Oscillator>
3
Philips Semiconductors
Summary
Designing-in 8-bit microcontrollers occasionally raises questions regarding the crystal oscillator circuit. The sup-
port groups in Eindhoven and Zuerich have gained some experience in responding to these kind of customer
questions. This report reflects some of this experience. For engineers in the field as well as development engi-
neers involved in microcontroller based products that do not have specific oscillator knowledge, reading this
report may result in some awareness of the oscillator issues making it easier to approach questions on this sub-
ject.
4
Philips Semiconductors
4. Oscillation condition. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
8. Ceramic resonators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
8.1 muRata CSA Ceramic resonators. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
8.2 muRata CSU Ceramic resonators. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
12. References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
5
Philips Semiconductors
6
Philips Semiconductors
Vdd
Rbias
Xtal2
Xtal1
Figure 1.
Vss
channel transistor. The main difference with a digital inverter stage is an integrated bias resistor (also called:
feedback resistor) connected between output and input. This (semiconductor-) resistor feeds back the output
voltage to the input which will balance (bias) the stage in its analog working area. In the quiescent situation this
will generate a DC- input and output level of about 1/2 Vdd for CMOS devices (For TTL compatible versions it is
just a little less).
2.1 Transconductance.
When this oscillator stage is driven with an input voltage variation then this will result in an output current varia-
tion through an external load. This relation (dVi/dIo) is defined as the transconductance of the oscillator stage.
7
Philips Semiconductors
Figure 2.
Rbias
Vi Io
~
Vss
microcontroller
Vdd
Xtal1 Xtal2
Vss
X-tal
C1 C2 Figure 3.
8
Philips Semiconductors
X-tal
L
===
Co
C
Rx
Figure 4.
Note that in an application the total equivalent value of Co is also highly influenced by the two external capacitors
in the basic Pierce oscillator circuit figure 3. In fact the two capacitors in series shunt the crystal, meaning the Co
is in fact increased.
4. Oscillation condition.
An oscillator stage and external components are supposed the generate the clock signal. Is just connecting the
external components to the oscillator stage the only condition for oscillation? Again, there are theories on the
oscillation condition and the Barkhausen rule covers the oscillation condition basics. In a practical situation how-
ever there are many circuit parameters that will determine whether an oscillator circuit will show reliable oscilla-
tion.Here are just some of them:
- Vdd, supply voltage.
- fosc, oscillator frequency.
- gm, oscillator stage transconductance.
- Rx, equivalent resistor value.
- C0, equivalent total parallel capacity.
- Closed loop gain.
Only for the crystal there are more then ten parameters. For a practical evaluation it is almost impossible to
include all of them. A second reason for this is that many parameter values are not known to those engineers
applying the component. Does this mean that oscillation will be a matter of luck?
9
Philips Semiconductors
ohm
No oscillation area
Rx
Oscillation area
C0 pF
Figure 5.
10
Philips Semiconductors
All the 5V microcontrollers have a Pierce oscillator circuit (Xtal1,Xtal2) that will oscillate with an external X-tal and
two capacitors. This standard circuit is presented in most data sheets. In some cases there may be good reasons
to modify the standard circuit e.g. to reduce interference and/or to compensate external influences.
470 470
Figure 6.
56 pF 18 pF 18 pF 56 pF
Figure 5. C1
C2
C1 C2
6.2 DC-offsets
The main reason for modifying the circuit with a capacitor in series with the input (see circuit of figure 7) had to do
with the influence of moisture on the oscillator circuit components. This could effect the basic circuit of figure 5.
because due to the conductance of moisture a DC-offset is introduced to the XTAL1 input resulting in an asym-
metric bias of the oscillator stage which may affect start-up and/or event prevent the stage from oscillating. When
this is due to the PCB-tracks and/or oscillator circuit external components it could be eliminated by using an extra
capacitor with a non critical value when it is much larger then the value C1 and C2 (see figure 7).
11
Philips Semiconductors
47nF 470
Vss
Figure 7.
56 pF 18 pF
C1 C2
Another possibility of reducing the sensitivity for environmental conditions like DC-offsets is shunting the oscilla-
tor stage with a resistor rather than shunting the X-tal. This way the input sensitivity is reduced but also the loop
gain. It can also be used for amplitude reduction. It may be necessary to modify the value of the C1. See figure 8:
.
XTAL1 XTAL2 Vdd
52 51
0.56..1 M 470
Vss
18....56 pF 18 pF Figure 8.
C1 C2
All these circuit examples were tested with a 559 device. They all start oscillating already at about 3 Volts Vdd.
12
Philips Semiconductors
microcontroller 1 microcontroller 2
N.C.
C1 C2 Figure 9.
Figure 9. shows this situation when using the standard oscillator circuit. The Xtal2 output (micro 1) is directly con-
nected to the Xtal1 input of the second microcontroller. The Xtal2 output from the second microcontroller remains
not connected.
The circuit for the microcontroller 1 may be modified as described earlier in this report. In these cases always
connect the input of the microcontroller 2 to the Xtal2 output of microcontroller 1 rather than direct on the X-tal.
This is to minimize the effects of the extra load on the oscillator circuit. To avoid any DC-offset for microcontroller
2 (a DC offset may result in more asymmetric duty cycle of the signal on Xtal2) the connection between uC1 and
2 may be DC-decoupled by using a capacitor. Figure 10 shows the situation.
microcontroller 1 microcontroller 2
C1 C2
Both circuits are applicable for most microcontrollers. Some controllers however have two on-board oscillators
one for a direct clock signal and one for a PLL clock. In this last case the X-tal frequency is normally 32 kHz. This
oscillator stage has pulldown devices on the input and output.This means that transistors are added (on-chip)
which are switched on under certain conditions, e.g. when the oscillator is disabled.These transistor then connect
Xtal1 and Xtal2 to the ground. To avoid the flow of (too) much current into the pulldown transistor it is recom-
mended to insert a resistor in the interconnection to the Xtal4-input. Figure 11 shows this situation.
13
Philips Semiconductors
microcontroller 1 microcontroller 2
100K
32k
Figure 11.
C1 C2
14
Philips Semiconductors
For other emulators there may be other restrictions. Always consult the emulator documentation on this issue.
Resuming: It can be concluded that the X-tal oscillator usually needs some special attention when using an emu-
lator. Many designers may be focused on the functionality of their application program so this issue may easily be
overlooked.
15
Philips Semiconductors
87c750 or 87c552()
XTAL1 XTAL2
11(35) 10(34) Vdd
Vdd
CSA
12.0MTZ
Vss
Vss
C1 C2 Figure 12.
30 pF 30 pF
16
Philips Semiconductors
1 3
Figure 13.
These types of resonators are attractive because of the internal capacitors which saves components and PCB-
space in the target system. However it should be considered that when applying these components this elimi-
nates the possibility for reducing the capacitor values which sometimes may be a solution in case the microcon-
troller is not oscillating.
17
Philips Semiconductors
9.1 CCO
A Current Controlled Oscillator is already applicated in a new microcontroller. This type of oscillator is replacing
the X-tal oscillator in the P83C434 to generate the CPU-clock. This type of oscillator design doesn’t use any
external components and is fully on-chip. Since no bonding wires of the oscillator make a connection to the pack-
age it is extremely EMC friendly. Its frequency is stable and it can be tuned by software. The frequency values
however are not fixed and vary from device to device. So when used for critical timing the oscillator needs a ref-
erence. In the P83C434 there is also a simple 32KHz oscillator for a low cost crystal. Note however that these
kind of oscillators can not be driven by an external signal and/or drive other circuits.
9.3 ACO
Amplitude Controlled Oscillator is another development in embedded oscillator circuitry. These designs are capa-
ble of maintaining a constant amplitude level of the oscillator output signal. This way it allows tolerances on crys-
tals or ceramic resonators without affecting the output signal. Another important feature of the ACO is that it
minimizes the power consumption of the oscillator by adapting the transconductance to the crystal/resonator
used.
18
Philips Semiconductors
Figure 14
Rf
C1e C2e
In the Power-down/Stop mode the oscillator is stopped and XTAL1pin is pulled HIGH. The oscillator inverter is
switched off to ensure no current will flow regardless of the voltage at XTAL1.
To drive the device with an external clock source, apply the external clock signal to XTAL1, and leave XTAL2
unconnected. There are no special requirements on the duty cycle of the external clock, since the input to the
internal clocking circuitry is buffered by a flip-flop.
The transconductance (gm) of the inverter stage can be mask-programmed on certain types, thereby optimizing
the oscillator for a specific frequency range and resonator/crystal and thereby achieving a minimum power
consumption.
For the PCF84Cxx and certain PCD33xx micros, three standard transconductance options referred to as gmL,
gmM and gmH, can be chosen from by the user depending on the device selected. The transconductance options
for the P83CLxxx micros (types 8xCL31/51/410/580/781/782 only!) are named OSC1, OSC2, OSC3 and OSC4.
Examples of the transconductance values for the various options are shown in table, and. The required option is
to be stated directly on the type-specific order entry form when ordering.
With C1i = C2i = 8 to 10 pF (typical values) internal load capacitance, external capacitors are mostly not required
if a quartz is used. However, for adequate frequency stability, ceramic PXE resonators may in certain cases need
19
Philips Semiconductors
2 2 1
g > 4.2 R ω ( C + C + C ) + -------- 1
m X L 0 F R
P
C1 × C 2 2
g < -----------------------------------------------------------------------
m
2 1
R ( C + C ) + ----------------
X 0 F 2
ω R
P
X-tal
L Ro
===
Co
C
Rx
Figure 15
The oscillator options offered for the PCF84Cxx and PCD33xx families are shown in table 2. Please note that for
certain PCD33xx micros, only one option corresponding to ”gmL” is available. Please refer to the product data
sheet for the exact transconductance values available.
20
Philips Semiconductors
21
Philips Semiconductors
Note
1. The OSC1 option does not include any internal feedback resistor between pin XTAL1 and XTAL2.
10.3 Example
Below an example is shown, illustrating the calculations necessary to check if a specific quartz or resonator can
be used together with a certain oscillator option.
The parts to be checked are the PCD3351A microcontroller to be used at 3.58 MHz with the resonator
CSA3.58MG310VA from muRata.
The parameters of the chosen muRata resonator are found in table 5 (see also data book for muRata resonators).
The PCD3351A microcontroller has only one oscillator option available corresponding to gmL as shown in table 2.
22
Philips Semiconductors
TABLE 6 muRata: Recommended ceramic PXE resonators for PCF84Cxx and PCD33xx micros
EXTERNAL
OSCILLATOR RESONATOR PART FREQUENCY LOAD
SMD/LEADED
OPTION NUMBER (MHZ) CAPACITANCE
C1E = C2E (PF)
gmL CSA3.58MG310VA 3.58 Leaded 0
gmL CSBxxxxJ 1.00 - 1.25 Leaded 100
gmL CSAxxxxMK 1.26 - 1.99 Leaded 30
gmL CSTxxxMG 2.00 - 2.44 Leaded 0
gmL CSTxxxMGW 2.45 - 6.00 Leaded 0
gmM CSTxxxMTW 6.01 - 8.00 Leaded 0
gmH CSTxxxMTW 8.01 - 13.0 Leaded 0
gmH CSTxxxMXWDC3 13.1 - 16.0 Leaded 0
Note
1. The “xxxx” in the muRata resonator part number corresponds to the frequency chosen.
In addition to the resonators presented Table 6, muRata is also offering resonators for SMD mounting, including
the new CSTCC-MG series.
TABLE 7 Kyocera: Recommended ceramic PXE resonators for PCF84Cxx and PCD33xx micros
EXTERNAL
OSCILLATOR RESONATOR PART FREQUENCY LOAD
SMD/LEADED
OPTION NUMBER (MHZ) CAPACITANCE
C1E = C2E (PF)
gmL KBR3.58MSATRPC10 3.58 Leaded 0
gmL PBRC3.58ARPC10 3.58 SMD 0
gmL KBR6.0MSA 6.0 Leaded 0
gmL PBRC6.0A 6.0 SMD 0
gmM KBR10.0MSA 10.0 Leaded 0
gmH KBR8.0M 8.0 Leaded 0
gmH PBRC8.0A 8.0 SMD 0
gmH KBR12.0M 12.0 Leaded 0
gmH KBR12.0M 12.0 Leaded 0
gmH KBR12.0M 12.0 Leaded 0
gmH KBR14.31MY 14.31 Leaded 0
gmH KBR16.0MY 16.0 Leaded 0
23
Philips Semiconductors
24
Philips Semiconductors
12. References
“Integrated X-tal Oscillators“ Philips Research Laboratories, Centre for Technical Training.
“Recommendations to reduce the interference of 558 oscillator” by Mr. Schutte, PCALE.
“PDS51 Development System for Philips 80C51 and Derivatives” Philips Semiconductors (user manual)
“P83CL434 Data Sheet,Preliminary specification” 1995 Mar 02, Philips Semiconductors.
“AN456 Using LC oscillator circuits with Philips microcontroller”,William Houghton,Application note.
25