Application Examples
;***********************************************************
;*
*
;*
INTERRUPT HANDLERS
*
;*
*
;***********************************************************
;
; ONLY ONE SERIAL INTERRUPT HANDLER IS ILLUSTRATED.
OTHER
;
HANDLERS CAN BE ADDED HERE AS NEEDED.
;
CODE
SEGMENT
PARA
;
ASSUME
CS:CODE,SS:STACK,DS:DATA,ES:NOTHING
;
SERIAL_8250
PROC
; THIS PROCEDURE HANDLES INTERRUPTS GENERATED BY THE
;
8259A PIC ON THE ZT 8840.
THE INT_FLAG LOCATION
;
WILL RECORD THAT THE INTERRUPT WAS RECEIVED WITH
;
A ZERO VALUE. IT IS ASSUMED THE FLAG IS INITIALLY 0FFH.
;
; INPUTS:
NONE
; OUTPUTS:
INT_FLAG - 0H
; CALLS:
NONE
; DESTROYS:
NONE
;
PUSH
AX
PUSH
DX
MOV
INT_FLAG,0
; RECORD THAT THE INT WAS RECV’D
MOV
AL,0
PUT
UART1+PORT_INTEN ; DISABLE FURTHER INTERRUPTS
MOV
AL,OCW2_8809A
; SEND EOI’S
PUT
PORT_A_8809A
MOV
AL,OCW2_8840
MOV
DX,PORT_A_8840
OUT
DX,AL
POP
DX
POP
AX
IRET
SERIAL_8250
ENDP
;
4-22