循环读取系统日期时间
assume cs:code
code segment
in al,60h
mov ah,0
int 16h
cmp al,04h
je clock
clock:mov al,9
out 70h,al
in al,71h
mov ah,al
mov cl,4
shr ah,cl
and al,00001111b
add ah,30h
add al,30h
mov bx,0b800h
mov es,bx
mov byte ptr es:[160*12+40*2],ah
mov byte ptr es:[160*12+40*2+2],al
mov byte ptr es:[160*12+40*2+2+2],'/'
mov al,8
out 70h,al
in al,71h
mov ah,al
mov cl,4
shr ah,cl
and al,00001111b
add ah,30h
add al,30h
mov bx,0b800h
mov es,bx
mov byte ptr es:[160*12+40*2+2+2],ah
mov byte ptr es:[160*12+40*2+2+2+2],al
mov byte ptr es:[160*12+40*2+2+2+2+2],'/'
mov al,7
out 70h,al
in al,71h
mov ah,al
mov cl,4
shr ah,cl
and al,00001111b
add ah,30h
add al,30h
mov bx,0b800h
mov es,bx
mov byte ptr es:[160*12+40*2+2+2+2+2+2],ah
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2],al
mov al,4
out 70h,al
in al,71h
mov ah,al
mov cl,4
shr ah,cl
and al,00001111b
add ah,30h
add al,30h
mov bx,0b800h
mov es,bx
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2],ah
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2+2],al
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2+2+2],':'
mov al,2
out 70h,al
in al,71h
mov ah,al
mov cl,4
shr ah,cl
and al,00001111b
add ah,30h
add al,30h
mov bx,0b800h
mov es,bx
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2+2+2+2],ah
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2+2+2+2+2],al
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2+2+2+2+2+2],':'
mov al,0
out 70h,al
in al,71h
mov ah,al
mov cl,4
shr ah,cl
and al,00001111b
add ah,30h
add al,30h
mov bx,0b800h
mov es,bx
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2+2+2+2+2+2+2],ah
mov byte ptr es:[160*12+40*2+2+2+2+2+2+2+2+2+2+2+2+2+2+2],al
jmp clock
code ends
end start
大家帮我看看还有什么问题没
谢了