标题:汇编中的获取系统时间
取消只看楼主
sally08913
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2011-4-10
结帖率:0
已结贴  问题点数:20 回复次数:0 
汇编中的获取系统时间
dymamictime proc
    s: db 9,8,7,4,2,0
     s1: db '/','/',' ',':',':',' '
start22: mov cx,6
         mov bx,offset s
         mov si,offset s1
         mov di,0
start1: push cx         
         mov al,cs:[bx]        
         mov dl,cs:[si]
         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 bp,0b800h
         mov es,bp
         mov byte ptr es:[1980+di],ah
         mov byte ptr es:[1982+di],al
         mov byte ptr es:[1984+di],dl
         inc bx
         inc si
         add di,6
         pop cx
         loop start1


in al,60h

cmp al,10h ;Q键的扫描码

je quit

jmp start22

           ;以上4句为动态获取系统时间的关键

quit:   mov ax,4c00h

        int 21h
ret
 dymamictime endp 哪位能帮忙解释下这个子程序呢?有些地方看不懂
搜索更多相关主题的帖子: 时间 
2011-04-10 17:16



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-336205-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 1.295995 second(s), 8 queries.
Copyright©2004-2025, BCCN.NET, All Rights Reserved