ÛZIATECH
50
7. REAL-TIME CLOCK
The ZT 8907 includes one Motorola 146818-compatible real-time clock. The real-time
clock provides clock and 100-year calendar information in addition to 114 bytes of
CMOS setup static RAM. These functions are battery backed for continuous operation
even in the absence of system power.
The RAM is used by the operating system BIOS to store configuration information. The
system BIOS is also Year 2000 Compliant. For more information on battery backing,
see Chapter 16, "
". The major features of the real-time
clock are listed below.
•
Battery backed
•
Leap year compensation
•
Optional interrupt generation
•
Optional Daylight Savings Time compensation
•
Timekeeping to a 1 second resolution
•
114 bytes of CMOS setup RAM
PROGRAMMABLE REGISTERS
The real-time clock includes 128 register locations. These registers are accessed
through I/O port locations 70h and 71h. A real-time clock register is accessed by first
writing the offset address of the register to I/O port location 70h. Data is then transferred
to or from the register through I/O port location 71h. This sequence must be repeated to
read the same register a second time. The I/O port addressing for the real-time clock is
given in the "
Real-Time Clock Register Addressing
" table below.
I/O port location 70h is a write only register. Bit 7 of this register is used to
enable/disable the non-maskable interrupt (bit 7 = 1: NMI disabled, bit 7 = 0: NMI
enabled). I/O port location 70h bits 6-0 are used for the offset address. Any write to I/O
port location 70h should be followed by an action to I/O port location 71h, otherwise the
real-time clock could be left in an undefined state.