Real-Time Clock Source; Changing Rtcs1/Rtcs0; Real-Time Clock Interrupt/Wake-Up; Reset Sources Affecting The Real-Time Clock - Philips P89LPC938 User Manual

Single-chip microcontroller
Table of Contents

Advertisement

Philips Semiconductors

9.1 Real-time clock source

RTCS1/RTCS0 (RTCCON[6:5]) are used to select the clock source for the RTC if either
the Internal RC oscillator or the internal WD oscillator is used as the CPU clock. If the
internal crystal oscillator or the external clock input on XTAL1 is used as the CPU clock,
then the RTC will use CCLK as its clock source.

9.2 Changing RTCS1/RTCS0

RTCS1/RTCS0 cannot be changed if the RTC is currently enabled (RTCCON.0 = 1).
Setting RTCEN and updating RTCS1/RTCS0 may be done in a single write to RTCCON.
However, if RTCEN = 1, this bit must first be cleared before updating RTCS1/RTCS0.

9.3 Real-time clock interrupt/wake-up

If ERTC (RTCCON.1), EWDRT (IEN1.0.6) and EA (IEN0.7) are set to logic 1, RTCF can
be used as an interrupt source. This interrupt vector is shared with the watchdog timer. It
can also be a source to wake-up the device.

9.4 Reset sources affecting the Real-time clock

Only power-on reset will reset the Real-time Clock and its associated SFRs to their default
state.
Table 40:
FOSC2:0
000
001
User manual
Real-time Clock/System Timer clock sources
RCCLK
RTCS1:0
0
00
01
10
11
1
00
01
10
11
0
00
01
10
11
1
00
01
10
11
Rev. 03 — 7 June 2005
P89LPC938 User manual
RTC clock source
High frequency crystal
High frequency crystal
/DIVM
High frequency crystal
Internal RC oscillator
Medium frequency crystal Medium frequency crystal
Medium frequency crystal
/DIVM
Medium frequency crystal Internal RC oscillator
Internal RC oscillator
© Koninklijke Philips Electronics N.V. 2005. All rights reserved.
UM10119
CPU clock source
High frequency crystal
/DIVM
Internal RC oscillator
/DIVM
51 of 139

Advertisement

Table of Contents
loading

Table of Contents