Datasheet

I
2
C RTC/Supervisor with Trickle Charger
and 512 Bytes EEPROM
Maxim Integrated 11
DS1388
ADDRESS
BLK WORD
BIT 7 BIT 6 BIT 5 BIT 4 BIT 3 BIT 2 BIT 1 BIT 0 FUNCTION RANGE
0h 00h Tenth Seconds Hundredths of Seconds
Hundredths of
Seconds
0099
0h 01h 0 10 Seconds Seconds Seconds 0059
0h 02h 0 10 Minutes Minutes Minutes 0059
AM/
PM
10 Hour
0h 03h 0 12/24
10 Hour
Hours Hours
1–12+
AM/PM
0023
0h 04h 0 0 0 0 X Day Day 0107
0h 05h 0 0 10 Date Date Date 0131
0h 06h 0 0 X
10
Month
Month Month 0112
0h 07h 10 Year Year Year 0099
0h 08h Watchdog Tenths of Seconds Watchdog Hundredths of Seconds
Watchdog
Hundredth
Seconds
0099
0h 09h Watchdog Ten Seconds Watchdog Seconds
Watchdog
Seconds
0099
0h 0Ah TCS3 TCS2 TCS1 TCS0 DS1 DS0 ROUT1 ROUT0 Trickle Charger
0h 0Bh OSF WF 0 0 0 0 0 0 Flag
0h 0Ch EOSC 0 0 0 0 0 WDE WD/RST Control
1h 00FFh 256 x 8 EEPROM EEPROM 00–FFh
2h 00FFh 256 x 8 EEPROM EEPROM 00–FFh
Figure 4. Address Map
Note: Unless otherwise specified, the state of the registers is not defined when power (V
CC
and V
BACKUP
) is first applied.
X = General-purpose read/write bit.
0 = Always reads as a zero.
Clock and Calendar
The time and calendar information is obtained by read-
ing the appropriate register bytes. Figure 4 illustrates
the RTC registers. The time and calendar are set or ini-
tialized by writing the appropriate register bytes. The
contents of the time and calendar registers are in the
binary-coded decimal (BCD) format. The end of the
month date is automatically adjusted for months with
fewer than 31 days, including corrections for leap years
through 2099. The day-of-week register increments at
midnight. Values that correspond to the day-of-week
are user-defined but must be sequential (i.e., if 1
equals Sunday, then 2 equals Monday, and so on).
Illogical time and date entries result in undefined oper-
ation. The DS1388 can be run in either 12-hour or 24-
hour mode. Bit 6 of the hours register is defined as the
12- or 24-hour mode-select bit. When high, the 12-hour
mode is selected. In the 12-hour mode, bit 5 is the
AM/PM bit with logic-high being PM. In the 24-hour
mode, bit 5 is the 20-hour bit (20–23 hours). Changing
the 12/24 bit requires that the hours data be re-entered
in the proper format.