UM10413
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2011. All rights reserved.
User manual
Rev. 1 — 16 December 2011
210 of 268
NXP Semiconductors
UM10413
MPT612 User manual
[1]
These values are incremented at the appropriate intervals and reset at the defined overflow point. They are
not calculated and must be correctly initialized in order to be meaningful.
24.6.13 Leap year calculation
The RTC does a simple bit comparison to see if the two lowest order bits of the year
counter are logic 0. If true, then the RTC considers that year a leap year. The RTC
considers all years evenly divisible by 4 as leap years. This algorithm is accurate from the
year 1901 through the year 2099, but fails for the year 2100, which is not a leap year. The
only effect of leap year on the RTC is to alter the length of the month of February for the
month, day of month, and year counters.
24.6.14 Power control register group
The power control registers are summarized in
. Register PWRCTRL is used to
control the power supply to the main core, SRAM, and RTC oscillator. During Deep
power-down mode, three general-purpose registers (GPREG[2:0]) remain fully powered
up and can be used to store information while the rest of the chip is powered down. The
registers are available in newer versions of the MPT612 only; see
Day of Year
9
Hour
1
365 or 366 (for leap year)
Month
4
Day of Month
1
12
Year
12
Month or day of Year
0
4095
Table 202. Time counter registers
Name
Size
Description
Access
Address
SEC
6
seconds value in the range 0 to 59
R/W
0xE002 4020
MIN
6
minutes value in the range 0 to 59
R/W
0xE002 4024
HOUR
5
hours value in the range 0 to 23
R/W
0xE002 4028
DOM
5
day of month value in the range 1 to 28, 29, 30, or
31 (depending on the month and whether it is a
leap year).
R/W
0xE002 402C
DOW
3
day of week value in the range 0 to 6
R/W
0xE002 4030
DOY
9
day of year value in the range 1 to 365 (366 for
leap years)
R/W
0xE002 4034
MONTH
4
month value in the range 1 to 12
R/W
0xE002 4038
YEAR
12
year value in the range 0 to 4095
R/W
0xE002 403C
Table 201. Time counter relationships and values
…continued
Counter
Size
Enabled by
Minimum value
Maximum value
Table 203. Power control registers
Name
Size
Description
Access
Address
PWRCTRL
3
Deep power-down control register
R/W
0xE002 4040
GPREG0
32
general-purpose storage register 0
R/W
0xE002 4044
GPREG1
32
general-purpose storage register 1
R/W
0xE002 4048
GPREG2
32
general-purpose storage register 2
R/W
0xE002 404C