Microchip Technology MA240029 데이터 시트

다운로드
페이지 406
 2010-2011 Microchip Technology Inc.
DS39996F-page 287
PIC24FJ128GA310 FAMILY
FIGURE 22-2:
ALARM MASK SETTINGS
22.6
POWER CONTROL
The RTCC includes a power control feature that allows
the device to periodically wake-up an external device,
wait for the device to be stable before sampling
wake-up events from that device, and then shut down
the external device. This can be done completely
autonomously by the RTCC, without the need to wake
from the current lower power mode (Sleep, Deep
Sleep, etc.).
To use this feature:
1.
Enable the RTCC (RTCEN = 1).
2.
Set the PWCEN bit (RTCPWC<15>).
3.
Configure the RTCC pin to drive the PWC control
signal (RTCOE = 1 and RTCOUT<1:0> = 11).
The polarity of the PWC control signal may be chosen
using the PWCPOL bit (RTCPWC<14>). An active-low
or active-high signal may be used with the appropriate
external switch to turn on or off the power to one or
more external devices. The active-low setting may also
be used in conjunction with an open-drain setting on
the RTCC pin, in order to drive the ground pin(s) of the
external device directly (with the appropriate external
V
DD
 pull-up device), without the need for external
switches. Finally, the CHIME bit should be set to enable
the PWC periodicity.
22.7
RTCC V
BAT
 OPERATION
The RTCC can operate in V
BAT
 mode when there is a
power loss on the V
DD
 pin. The RTCC will continue to
operate if the V
BAT
 pin is powered on (it is usually
connected to the battery).
The V
BAT
 BOR can be enabled/disabled using the
VBTBOR bit in the CW3 Configuration register
(CW3<7>).  If the VBTBOR enable bit is cleared, the
V
BAT
 BOR is always disabled and there will be no indi-
cation of a V
BAT
 BOR. If the VBTBOR bit is set, the
RTCC can receive a Reset and the RTCEN bit will get
cleared; it can happen anywhere between 1.95-1.4V
(typical).
Note
1:
Annually, except when configured for February 29.
s
s
s
m
s
s
m
m
s
s
h
h
m
m
s
s
d
h
h
m
m
s
s
d
d
h
h
m
m
s
s
m
m
d
d
h
h
m
m
s
s
Day of
the
Week
Month
Day
Hours
Minutes
Seconds
Alarm Mask Setting
(AMASK<3:0>)
0000
 - Every half second
0001
 - Every second
0010
 - Every 10 seconds
0011
 - Every minute
0100
 - Every 10 minutes
0101
 - Every hour
0110
 - Every day
0111
 - Every week
1000
 - Every month
1001
 - Every year
(1)
Note:
It is recommended to connect the V
BAT
pin to V
DD
 if the V
BAT
 mode is not used
(not connected to the battery).