;ChoongHong Oh

TITLE PGM3: TIMER TICK
;timer interrupt procedure
        EXTRN TIMER_FLAG : BYTE
        PUBLIC TIMER_TICK
.MODEL SMALL

IF1
        INCLUDE macro.ASM
ENDIF

.CODE
;timer routine
TIMER_TICK PROC
        SAVE_REGS <DS, AX>
;set up DS
        MOV AX, SEG TIMER_FLAG  ;get segment of flag
        MOV DS, AX              ;put in DS
        MOV TIMER_FLAG, 1       ;set flag
;restore registers
        RESTORE_REGS <AX, DS>
        IRET
TIMER_TICK ENDP                 ;end timer routine        
        END     
