转换大小写int 7ch 中断处理程序
Posted 隐无影
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了转换大小写int 7ch 中断处理程序相关的知识,希望对你有一定的参考价值。
assume cs:codedata segment
db 'conversation',0
data ends
code segment
start :
mov ax,cs
mov ds,ax
mov si,offset capital ;指向源代码地址
mov ax,0
mov es,ax
mov di,200h
mov cx,offset capitalend-offset capital
cld
rep movsb ;目的地址
;安装中断处理程序 int 7ch自动跳转到 7ch*4+2:7ch*4处
mov ax,0
mov es,ax
mov word ptr es:[7ch*4],200h
mov word ptr es:[7ch*4+2],0
;测试程序
mov ax,data
mov ds,ax
mov si,0
int 7ch
push di
push si
push cx
mov ax,0b800h
mov es,ax
mov di,12*160+36*2
mov cx,12
s: mov al,[si]
mov es:[di],al
inc si
add di,2
loop s
pop di
pop si
pop cx
mov ax,4c00h
int 21h
;程序处理程序
capital: push cx ;子程序需要用到cx,si,入栈
push si
change: mov cl,[si]
mov ch,0
jcxz ok ;当cx=0时,跳转到ok
and byte ptr [si],11011111b
inc si
jmp short change
ok:pop si
pop cx
iret
capitalend:nop
code ends
end start
code ends
end start
以上是关于转换大小写int 7ch 中断处理程序的主要内容,如果未能解决你的问题,请参考以下文章