王爽实验12

assume cs:codesg
codesg segment
start:
    ;mofify interrupt table
    mov ax,0
    mov es,ax
    mov di,ax
    mov es:[di],200H
    mov word ptr es:[di+2],0
    ;copy interrupt proc
    mov ax,cs
    mov ds,ax
    mov si,offset interrup0
    mov di,200H
    mov cx,offset interrup0end - offset interrup0
    ;start copy
    cld
    rep movsb
    mov ax,4c00h
    int 21h
;interrupt 0 process    
interrup0:
    jmp short realstart
    db "divide error!"
realstart:
;src data address
  mov ax,0
  mov es,ax
  mov di,202H
;dest data address
  mov ax,0b800H
  mov ds,ax
  mov si,(160*12+34*2)
;start copy
    mov cx,13
startcopy:
    mov al,es:[di]
    mov ds:[si],al
    mov ax,0a0H
    mov ds:[si+1],ax
    inc di
    add si,2
    loop startcopy
    mov ax,4c00h
    int 21h
interrup0end:
    nop
codesg ends
end start
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值