可编程定时计数器8253 程序讲解
DATA SEGMENTTBL DW524,588,660,698,784,880,988,1048
DATA ENDS
CODE SEGMENT
ASSUME CS:CODE,DS:DATA
START:
MOV AX,DATA
MOV DS,AX
SING:
MOV AH,1
INT 21H
SUB AL,31H
JB EXIT
CMP AL,08H
JAE EXIT
SHL AL,1
MOV BL,AL
MOV AX,0
MOV DX,12H
MOV BH,0
DIV TEL[BX]
MOV BX,AX
MOV AL,0B6H
OUT 43H,AL
MOV AX,BX
OUT 42H,AL
MOV AL,AH
OUT 42H,AL
IN AL,61H
OR AL,03H
OUT 61H,AL
DLY:
IN AL,60H
TEST AL,80H
JZ DLY
CALL DELAY
IN AL,61H
AND AL,0FCH
OUT 61H,AL
JMP SING
EXIT:MOV AX,4C00H
INT 21H
DELAY:MOV BX,300H
DLY1:MOV CX,0
DLY2: LOOP DLY2
DEC BX
JNZ DLY1
RET
CODE ENDS
END START
求每步讲解,谢谢了