只是為了練習int 21h?還是單純為了讀時間日期值?
如果只是單純為了讀時間我覺的直接去讀cmos的date and time會比較簡單一點!!!
幫你補充一點點關於int 21h ah = 2Ah的東東^_^
INT 21 - DOS 1+ - GET SYSTEM DATE
AH = 2Ah
Return: CX = year (1980-2099)
DH = month
DL = day
---DOS 1.10+---
AL = day of week (00h=Sunday)
INT 21 - DOS 1+ - SET SYSTEM DATE
AH = 2Bh
CX = year (1980-2099)
DH = month (1-12)
DL = day (1-31)
Return: AL = status
00h successful
FFh invalid date, system date unchanged
Note: DOS 3.3+ also sets CMOS clock; due to the limitations of the CLOCK$
driver interface, the CMOS time is also updated to the current
DOS time (which is the BIOS time-of-day clock with the default
CLOCK$ driver)
[deeping 在 2007-5-26 01:22 AM 作了最後編輯]