Fail Safe Mechanisms
C513AO
User’s Manual
8-7
05.99
The Oscillator Watchdog is able to detect a recovery of the on-chip oscillator after a failure. If the
frequency derived from the on-chip oscillator is again higher than the reference, the watchdog starts
a final reset sequence which takes typ. 1 ms. Within that time, the clock is still supplied by the RC
oscillator and the device is held in reset. This allows a reliable stabilization of the on chip oscillator.
After that, the watchdog switches the clock supply back to the on-chip oscillator and releases the
reset request. If no external reset is applied in this moment, the part will start program execution. If
an external reset is active, however, the device will keep the reset state until the external reset
request is released.
Furthermore, the status flag OWDS is set if the Oscillator Watchdog reset was active. The status
flag can be evaluated by software to detect a reset caused by the Oscillator Watchdog. The flag
OWDS can be set or cleared by software. An external reset request, however, also resets OWDS
(and WDTS).
If software power-down mode is activated, the RC oscillator and the on-chip oscillator are stopped.
Both oscillators are started again in power-down mode when a low level is detected at the INT0
input pin and when bit EWPD in SFR PCON1 is set (wake-up from power-down mode enabled).
After start-up of the watchdog circuitry in power-down mode, a power-down mode wake-up interrupt
is generated (instead of an internal reset).
8.2.2 Fast Internal Reset after Power-On
The C513AO can use the Oscillator Watchdog for a fast internal reset procedure after power-on.
Normally, members of the 8051 family (for example, SAB 80C52) enter their default reset state not
before the on-chip oscillator starts. The reason is that the external reset signal must be internally
synchronized and processed to bring the device into the correct reset state. Especially if a crystal
is used, the start up time of the oscillator is relatively long (typ. 10 ms). During this time period, the
pins have an undefined state which could have severe effects (for example, to actuators connected
to port pins).
In the C513AO, the Oscillator Watchdog unit avoids this situation. After power-on, the Oscillator
Watchdog’s RC oscillator starts working within a very short start-up time (typ. less than 2
µ
s). The
watchdog circuitry detects a failure condition for the on-chip oscillator because it has not yet started
(a failure is always recognized if the watchdog’s RC oscillator runs faster than the on-chip
oscillator). As long as this condition is valid, the watchdog uses the RC oscillator output as clock
source for the chip. This allows correct resetting of the device and brings all ports into the defined
state. The maximum delay time between power-on and correct reset state is 34
µ
s.