TASM中未定义的符号

时间:2017-04-25 10:13:45

标签: assembly tasm dosbox

enter image description here

.model small
.code
org 100h
s:
mov ah, 2
mov dl, 47
int 21h
mov dl, 55
int 21h
mov dl, 5A
int 21h
mov dl, 4D
int 21h
mov dl, 41
int 21h
mov dl, 4E
int 21h
mov dl, 41
int 21h
mov dl, 2C
int 21h
mov dl, 20
int 21h
mov dl, 49
int 21h
mov dl, 53
int 21h
mov dl, 48
int 21h
mov dl, 52
int 21h
mov dl, 41
int 21h
mov dl, 45
int 21h
mov dl, 4C
int 21h
mov dl, ' '
int 21h
mov dl, ‘I’
int 21h
mov dl, ’S’
int 21h
mov dl, ‘H’
int 21h
mov dl, ‘R’
int 21h
mov dl, ‘A’
int 21h
mov dl, ‘E’
int 21h
mov dl, ‘L’
int 21h
mov dl, ' '
int 21h
mov dl, ‘G’
int 21h
mov dl, ‘U’
int 21h
mov dl, ‘Z’
int 21h
mov dl, ‘M’
int 21h
mov dl, ‘A’
int 21h
mov dl, ’N’
int 21h
mov dl,10
int 21h
mov dl, ‘M’
int 21h
mov dl, 'A'
int 21h
mov dl, ’N’
int 21h
mov dl, ‘A’
int 21h
mov dl, ‘L’
int 21h
mov dl, ‘O’
int 21h
mov dl, ' '
int 21h
mov dl, 'P'
int 21h
mov dl, '.'
int 21h
mov dl, 'C'
int 21h
mov dl, 'A'
int 21h
mov dl, 'M'
int 21h
mov dl, 'P'
int 21h
mov dl, 'A'
int 21h
mov dl, ' '
int 21h
mov dl, 'S'
int 21h
mov dl, 'A'
int 21h
mov dl, 'M'
int 21h
mov dl, 'P'
int 21h
mov dl, 'A'
int 21h
mov dl, 'L'
int 21h
mov dl, 'O'
int 21h
mov dl, 'C'
int 21h
mov dl, ' '
int 21h
mov dl, 'M'
int 21h
mov dl, 'A'
int 21h
mov dl, 'N'
int 21h
mov dl, 'I'
int 21h
mov dl, 'L'
int 21h
mov dl, 'A'
int 21h
mov dl,10
int 21h
mov dl, 'B'
int 21h
mov dl, 'S'
int 21h
mov dl, ' '
int 21h
mov dl, 'I'
int 21h
mov dl, 'T'
int 21h
mov dl, ' '
int 21h
mov dl, 'D'
int 21h
mov dl, 'I'
int 21h
mov dl, 'G'
int 21h
mov dl, 'I'
int 21h
mov dl, 'T'
int 21h
mov dl, 'A'
int 21h
mov dl, 'L'
int 21h
mov dl, ' '
int 21h
mov dl, 'A'
int 21h
mov dl, 'R'
int 21h
mov dl, 'T'
int 21h
mov dl,10
int 21h
mov dl, 'J'
int 21h
mov dl, 'U'
int 21h
mov dl, 'N'
int 21h
mov dl, 'E'
int 21h
mov dl, ' '
int 21h
mov dl, '8'
int 21h
mov dl, ','
int 21h
mov dl, ' '
int 21h
mov dl, '1'
int 21h
mov dl, '9'
int 21h
mov dl, '9'
int 21h
mov dl, '6'
int 21h
mov dl,10
int 21h
mov dl, '0'
int 21h
mov dl, '9'
int 21h
mov dl, '7'
int 21h
mov dl, '7'
int 21h
mov dl, '4'
int 21h
mov dl, '6'
int 21h
mov dl, '5'
int 21h
mov dl, '3'
int 21h
mov dl, '6'
int 21h
mov dl, '6'
int 21h
mov dl, '9'
int 21h
mov dl,10
int 21h
mov dl, 'm'
int 21h
mov dl, 'a'
int 21h
mov dl, 'c'
int 21h
mov dl, 'h'
int 21h
mov dl, 'i'
int 21h
mov dl, 'k'
int 21h
mov dl, 'o'
int 21h
mov dl, 'j'
int 21h
mov dl, 'a'
int 21h
mov dl, 'v'
int 21h
mov dl, 'i'
int 21h
mov dl, 'e'
int 21h
mov dl, 'r'
int 21h
mov dl, '@'
int 21h
mov dl, 'g'
int 21h
mov dl, 'm'
int 21h
mov dl, 'a'
int 21h
mov dl, 'i'
int 21h
mov dl, 'l'
int 21h
mov dl, '.'
int 21h
mov dl, 'c'
int 21h
mov dl, 'o'
int 21h
mov dl, 'm'
int 21h
mov ah,4ch
int 21h
end s

1 个答案:

答案 0 :(得分:0)

首先,只有org 100h个程序(.com)需要.model tiny。删除.exe个程序(.model small)。

当您使用数字输入TASM时,汇编程序默认需要十进制数字。程序中的数字是十六进制(5A,4D ......)。您可以在每个数字中添加字符“h”以表示这是十六进制数字,或者您可以在程序开头使用指令RADIX 16将数字系统更改为十六进制数字。由于后缀系统仍然存在,由于'D',像4D这样的值将被解释为“十进制4”。因此,将该数字更改为4Dh。不要忘记将后续换行ASCII值(10)更改为0A(十六进制)或10d(带后缀)。

角色必须用引号(双或单)装饰。引号的标志是'(单个)和“(双)。例如:mov dl, 'G'。显然你已经从网上复制了源代码并且有一些不同的unicode引号。你必须将它们改为您在键盘上找到的引用字符。