INT 1A time
Posted: Sun Jan 30, 2011 10:03 am
There are some interrupt that give you a date or a time.
This is very strange. It give you a decimal value in a hex output.
AH = 0Ch
CH = hours (BCD)
CL = minutes (BCD)
DH = seconds (BCD)
DL = day of month (BCD)
I made a function to convert a 2 BYTE value to a output on screen. But can I get date and time more easy??
I do not want to use this code if i do not have to!
This is very strange. It give you a decimal value in a hex output.
AH = 0Ch
CH = hours (BCD)
CL = minutes (BCD)
DH = seconds (BCD)
DL = day of month (BCD)
I made a function to convert a 2 BYTE value to a output on screen. But can I get date and time more easy??
Code: Select all
HEX2DATE: ; INPUT AX=VALUE
PUSH AX
XOR CL,CL
DATELOOP:
POP AX
PUSH AX
SHL AX,CL
SHR AX,12
ADD AL,48
MOV AH,0Eh
INT 10h
ADD CL,4
CMP CL,16
JNE DATELOOP
POP AX
RET