INT 1Ah, 02h (2) Read Real-Time Clock Time many
Reads the time from the computer's real-time clock.
On entry: AH 02h
Returns: CF Set if clock not operating; else cleared
CH Hours (BCD)
CL Minutes (BCD)
DH Seconds (BCD)
DL 1 if daylight saving time option; else 0
--------------------------------------------------------------------------
Notes: All times are in Binary Coded Decimal (BCD). For
example, 9:04.12 am will be reported as CX = 0904;
DH = 12.
The real-time clock is the clock that runs even when
the computer is turned off. A CMOS battery is used
so that, even while the computer is off, the date,
time, and alarm time are maintained.
This service is available only for ATs, XT-286s, and
PC Convertibles. Previous machines will report
unpredictable results (including the state of the
Carry Flag).
The daylight saving time option is not reported on
ATs with dates prior to 6/10/85.
The information returned from this service could
differ from the system time. This is because the
real-time clock is read once upon system startup,
updating the system timer. All other references to
time use the system timer. If either the real-time
clock is changed (via Service 03h) or the system
timer is changed (via Service 01h), the other clock
is not changed accordingly.
Even though the system uses the system timer for
timing information, both the real-time clock and the
system timer are updated continuously.
Seealso:
This page last updated on Fri Nov 30 10:49:50 MSK 2001
Copyright © 1992-2001, Vitaly Filatov, Moscow, Russia
Webmaster