|
1鱼币
data segment
MA DB 10
LEN DB ?
buffer db 10 dup(0)
data ends
assume cs:code,ds:data
code segment
start:
mov ax,data
mov ds,ax
LEA DX,MA
mov ah,0ah
int 21h
mov cx,0h
mov cl,len
lea bx,buffer
again:mov al,[bx]
sub al,30h
cmp al,9
jbe l5
CMP AL,16H
JBE L6
SUB AL,27H
JMP L5
L6: SUB AL,7H
l5: mov [bx],al
inc bx
loop again
LEA BX,BUFFER
MOV AH,[BX]
INC BX
MOV AL,[BX]
MOV CL,4
SHL AH,CL
XOR AH,AL
MOV DH,AH
INC BX
MOV AH,[BX]
INC BX
MOV AL,[BX]
SHL AH,CL
XOR AH,AL
MOV DL,AH
MOV BX,DX
MOV DX,0H
MOV CX,16
NEXT:SHL BX,1
JC ONE
MOV DL,30H
JMP EXIT
ONE:MOV DL,31H
EXIT :MOV AH,21H
INT 21H
DEC CX
JNZ NEXT
mov ah,4ch
int 21h
code ends
end start
debug 调试时出现 FCB unavailable Abort, Fail?
|
|