DATA SEGMENT
DATA_1 DB 0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0
DB 0,0,1,1,1,1,0,0,0,0,1,0,0,0,0,0
DB 0,0,0,0,0,1,0,1,1,1,1,1,1,1,0,0
DB 0,0,0,0,1,0,0,0,0,0,1,0,0,1,0,0
DB 0,0,0,0,1,0,1,1,1,1,1,1,1,1,1,1
DB 0,0,0,1,0,0,0,0,0,0,1,0,0,1,0,0
DB 0,0,1,1,1,1,0,1,1,1,1,1,1,1,0,0
DB 0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0
DB 0,0,1,0,0,1,0,1,1,1,1,1,1,1,0,0
DB 0,0,1,0,0,1,0,0,0,0,1,0,0,0,0,0
DB 0,0,0,1,0,1,0,0,0,0,1,0,0,0,0,0
DB 0,0,0,0,1,0,0,1,1,1,1,1,1,1,0,0
DB 0,0,0,1,0,1,0,0,0,0,1,0,0,0,0,0
DB 0,0,1,0,0,0,1,1,0,0,1,0,0,0,0,0
DB 0,1,0,0,0,0,0,0,1,1,1,1,1,1,1,1
DATA ENDS
CODE SEGMENT
ASSUME CS:CODE,DS:DATA
START: MOV AX,DATA
MOV DS,AX
MOV AH,0
MOV AL,12H ;set vga mode 640x480x16
INT 10H
MOV AX,OFFSET DATA_1
MOV SI,AX
MOV AH,0CH
MOV DX,210
LOOP3: MOV CX,200
LOOP1: MOV AL,[SI]
INT 10H ;write pin at 310,200
INC CX
INC SI
CMP CX,216
JZ LOOP2
JMP LOOP1
LOOP2: INC DX
CMP DX,225
JZ END_1
JMP LOOP3
END_1: xor ah,ah
int 16h
MOV AH,0
MOV AL,3
INT 10H
MOV AX,4C00H
INT 21H
CODE ENDS
END START
我直接用Tasm编译通过的,生产的是COM文件,附批处理程序:
@ECHO OFF
tasm %1.asm
if errorlevel 1 goto dela
tlink %1.obj /t
GOTO END
:dela
del %1.map
del %1.obj
pause
:edit %1.asm
goto end