
282 THE x86 MICROPROCESSORS
MOV WORD PTR OLD, BX ;save old IP
MOV WORD PTR OLD+2, ES ;save old CS
MOV AH, 25H ;install new vector
MOV AL, 09 ;at type number 9
MOV DX, OFFSET NEWINT9 ;point DX to the new ISR
INT 21H
MOV DX, OFFSET START ;count the number of paragraphs
MOV CL, 4
SHR DX, CL
INC DX
MOV AX, 3100H ;make the program resident
INT 21H
END
Example 8.15 is a similar program, except that the hot keys to be invoked are Ctrl+F3. e ISR
for this hot key is copied from Example 8.8. It accesses the video memory directly and causes
the full screen to be green in color.
Example 8.15
.MODEL TINY
.CODE
.STARTUP
JMP START
OLD DD?