|
马上注册,结交更多好友,享用更多功能^_^
您需要 登录 才可以下载或查看,没有账号?立即注册
x
assume cs:code
stack segment
db 128 dup(0)
stack ends
code segment
start:
mov ax,stack
mov ss,ax
mov sp,128
mov ax,cs
mov ds,ax
mov si,offset int9 ; ds:si
mov ax,0
mov es,ax
mov di,204h ;es:di
mov cx, offset int9end - offset int9
cld
rep movsb
push es:[9*4]
pop es:[200h]
push es:[9*4+2]
pop es:[202h]
cli
mov word ptr es:[9*4],204h
mov word ptr es:[9*4+2],0
sti
mov ax,4c00h
int 21h
int9:
push ax
push di
push cx
push es
mov ax,0
mov es,ax
pushf
call dword ptr es:[200h]
in al,60h
cmp al,3bh ;F1
jne int9ret
mov ax,0b800h
mov es,ax
mov di,1
mov cx,2000
s:
inc byte ptr es:[di]
add di,2
loop s
int9ret:
pop es
pop cx
pop di
pop ax
int9end:
nop
code ends
end start
不知道哪里出问题了 运行后卡住
int9 服务例程没有返回指令,别的没细看。
int9end:
nop
iret
|
|