Real-Time Clock
5/DS12C87A
The three alarm bytes can be used in two ways. First,
when the alarm time is written in the appropriate hours,
minutes, and seconds alarm locations, the alarm inter-
rupt is initiated at the specified time each day, if the
alarm-enable bit is high. In this mode, the “0” bits in the
alarm registers and the corresponding time registers
must always be written to 0 (Table 2A and 2B). Writing
the 0 bits in the alarm and/or time registers to 1 can
result in undefined operation.
condition when at logic 1. An alarm is generated each
hour when the don’t-care bits are set in the hours byte.
Similarly, an alarm is generated every minute with
don’t-care codes in the hours and minute alarm bytes.
The don’t-care codes in all three alarm bytes create an
interrupt every second.
All 128 bytes can be directly written or read, except for
the following:
1) Registers C and D are read-only.
2) Bit 7 of register A is read-only.
The second use condition is to insert a “don’t care”
state in one or more of the three alarm bytes. The don’t-
care code is any hexadecimal value from C0 to FF. The
two most significant bits of each byte set the don’t-care
3) The MSB of the seconds byte is read-only.
Table 2A. Time, Calendar, and Alarm Data Modes—BCD Mode (DM = 0)
ADDRESS
BIT 7
BIT 6 BIT 5
BIT 4
BIT 3
BIT 2
BIT 1
BIT 0
FUNCTION
RANGE
00H
0
10 Seconds
Seconds
Seconds
00–59
01H
02H
03H
0
10 Seconds
10 Minutes
10 Minutes
Seconds
Minutes
Minutes
Seconds Alarm
Minutes
00–59
00–59
00–59
0
0
Minutes Alarm
AM/PM
0
0
0
10 Hours
10 Hours
10 Hours
10 Hours
1–12 +AM/PM
00–23
04H
05H
0
0
Hours
Hours
Hours
0
AM/PM
1–12 +AM/PM
00–23
Hours Alarm
0
0
0
0
06H
07H
0
0
0
0
0
Day
Day
Date
01–07
01–31
01–12
00–99
—
10 Date
Date
Month
Year
08H
0
10 Months
Month
Year
09H
10 Years
0AH
UIP
SET
IRQF
VRT
X
DV2
PIE
PF
0
DV1
AIE
AF
0
DV0
UIE
UF
0
RS3
RS2
RS1
RS0
DSE
0
Control
Control
Control
Control
RAM
0BH
SQWE
DM
0
24/12
—
0CH
0
0
X
0
0
X
—
0DH
0
0
—
0EH-31H
32H
X
X
X
X
X
—
10 Century
Century
Century*
RAM
00–99
—
33H-7FH
X
X
X
X
X
X
X
X
X = Read/Write Bit.
*DS12C887, DS12C887A only. General-purpose RAM on DS12885, DS12887, and DS12887A.
Note: Unless otherwise specified, the state of the registers is not defined when power is first applied. Except for the seconds regis-
ter, 0 bits in the time and date registers can be written to 1, but may be modified when the clock updates. 0 bits should always be
written to 0 except for alarm mask bits.
____________________________________________________________________ 13