Real-Time Clock (RTC) and Advanced Power Control (APC) (Logical Device 2)
68
APC DETAILED DESCRIPTION
www.national.com
Predetermined Wake-Up
The second, minute, and hour values of the pre-determined
wake-up times are contained in the Seconds Alarm, Minutes Alarm, and Hours alarm registers, respectively (indexes 01h, 03h and 05h of banks 0, 1 and 2). The Day-ofWeek, Day-of-Month, Month, Year and Century of the predetermined date are held in bank 2, registers indexes 43h46h and 48h. These eight registers are compared with the
corresponding Seconds, Minutes, Hours, Day-of-Week,
Day-of-Month, Month and Year, in all banks, register indexes 00, 02, 04, 06, 07, 08, 09 and the Century register which
can be located anywhere in bank 0 or bank 1 - its location
is programmed via the Century Address Register in bank 2.
(The Century bit value - bit 6 0f RTC Control Register d - is
not used for this function).
Any Wake Up register in bank 2 (Index 43h-46h and 48h)
may be set to a "Don't Care" state by setting bits 7,6 to 11.
This results in periodic Match Event activation at an increased rate whose period is that of the Don’t Care location,
e.g., if the Wake Up Day-of-Week location and the Wake Up
Month are both set to a Don’t Care, a Match Event will be
activated once a month during the specified year.
Ring Signal Event
An incoming telephone call is an event that may activate a
transfer from the Power-Off state to a Power-On state, in order to deal with the pending incoming voice, fax or modem
communication.
The PC87317VUL can detect a
RING pulse falling edge or
a
RING pulse train with a frequency of at least 16 Hz, that
lasts at least 0.19 seconds.
During
RING pulse train detection, the existence of falling
edges on
RING is monitored during time slots of 62.5 msec
(16 Hz cycle time). A
RING pulse train detect event occurs
if falling edge(s) of
RING were detected in three consecutive time slots, following a time slot in which no falling edge
of
RING was detected.
This method of detecting a
RING pulse train filters out (does
not detect) a
RING pulse train of less then 11 Hz, might de-
tect a
RING pulse train of 11 Hz to 16 Hz, and guarantees
detection of a
RING pulse train of at least 16 Hz.
RI1,2 Event
High to Low transitions on
RI1 or RI2 indicate communications activity on the UART inputs, and these conditions may
be used as events to “wake-up” the system.
General Purpose Power Management Events
The APC supports additional events that can wake-up the
system from the power off state, or generate an interrupt if
the system is in the power on state.
An event is defined as the detection of falling edge, rising
edge, low level, or high level on a specific signal. Each signal’s event is configurable via software.
The following events may wake up the system from the
Power Off state, or generate an interrupt if the system is in
the Power On state:
●
PME1 Event defined by bits 2-0 of the APCR4 register.
●
PME2 Event defined by bits 5-3 of the APCR4 register.
●
IRRX1 Event defined by bits 2-0 of the APCR5 register.
●
IRRX2 Event defined by bits 5-3 of the APCR5 register.
The following events may generate an interrupt if the system is in the Power On state:
●
GPIO12 Event defined by bits 2-0 of the APCR6 register.
●
GPIO13 Event defined by bits 5-3 of the APCR6 register.
●
GPIO10 Event defined by bits 7-5 of the APCR3 register.
●
P12 Event defined by bits 2-0 of the APCR7 register.
Each of the events has a corresponding status bit in the
GP1_STS0 register. The events can be enabled via two
registers: GP1_EN0 register and GP2_EN0 register.
An event will wake up the system or generate an interrupt,
only if its corresponding status and enable bits are set.
LED Signal
This output signal enables an external LED to be driven directly by the PC87317, and may be programmed to give
various responses under various power conditions.
Three signal outputs may be selected:
●
High - Impedance (HI-Z)
●
Drive 0 level
●
a 1 hz “blink” signal, alternating between the previous
two outputs.
The High Impedance output will leave the LED unlit. The
Drive 0 value will switch on an external LED connected to
an external power source and grounded by the LED signal
output.
The outputs of this signal depend on programmed values
selected at bits 6 and 7 of APCR4, and on the prevailing
power state.
Signal outputs under all conditions are listed in the following
table:
TABLE 4-7. LED signal outputs
The LED signal is functional, when V
DD
and V
CCH
exist or
when only V
CCH
exists. When only V
BAT
exists, the LED signal is not functional (output is set to HI-Z) but its control bits
are saved. Thus, when V
CCH
is applied again, the LED signal returns to the previous state. Upon first power-on (application of one of the voltages V
BAT
or V
CCH
when no
previous voltage was present), the LED signal is configured
to be in the high-impedance state. The One Hz blink requires a 32.768 KHz clock.
APCR4
Bits
7 6
LED State
V
CCH
V
BAT
only
0 0 HI-Z HI-Z
0 1 Drive 0 HI-Z
1 0 1 Hz blink HI-Z
1 1 Reserved HI-Z