📄 timer.asm
字号:
; This sample shows the
; use of a timer function
; (INT 15h / 86h)
; This code prints some chars
; with 1 second delay.
#make_COM#
ORG 100h
; set the segment register,
; just in case:
MOV AX, CS
MOV DS, AX
next_char:
CMP count, 0
JZ stop
; print char:
MOV AL, c1
MOV AH, 0Eh
INT 10h
; next ascii char:
INC c1
DEC count
; set interval (1 million
; microseconds - 1 second):
MOV CX, 0Fh
MOV DX, 4240h
MOV AH, 86h
INT 15h
; stop any error:
JC stop
JMP next_char
stop:
RET
count DB 10
c1 DB 'A'
END
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -