求助求助!call 为什么转不过去?~~~~~~~~
以下是我的代码,在A中调用B,实现ASCII转二进制,程序运行不出来,Debug才发现是call没有转过去。。为神马捏?A.asm
程序代码:
extrn atoi:far public exit data segment public 'data1' i dw 20h ;j dw 20h data ends stack segment para stack db 20h dup(0) stack ends code segment assume cs:code,ss:stack,ds:data start:mov ax,data mov ds,ax call atoi ; mov ax,m ;mov i,ax ;jmp input exit: ;mov ax,i ;mov k,ax mov ah,4ch int 21h code ends end start
C.asm
程序代码:
;extrn exit data segment public 'data1' m dw ? data ends stack segment para stack db 20 dup(0) stack ends code segment assume cs:code,ss:stack,ds:data atoi proc far mov ax,data mov ds,ax lop:mov ah,01h int 21h cmp al,0dh jz next xor bx,bx and al,0fh mov bl,al mov ax,m mov cx,10 mul cx add ax,bx mov m,ax jmp lop next:ret atoi endp code ends end