Application Examples
;
;***********************************************************
;*
*
;*
SYSTEM EQUATES
*
;*
*
;***********************************************************
;
;
;
EQU
0
; SET TO 0 FOR STD DOS SYSTEM
;
;
* ZT 8809A 8259A REGISTER EQUATES BY PORT ADDRESS *
;
;
REG A ICW,OCW2,OCW3,IRR,ISR,IL
PORT_A_8809A
EQU
0020H
; PORT A
ICW1_8809A
EQU
00010001B
; EDGE, CASCADE, ICW4 NEEDED
OCW2_8809A
EQU
01100010B
; SPECIFIC EOI FOR IR2
;
;
REG B ICW2,3,4,OCW1,IMR
PORT_B_8809A
EQU
0021H
; PORT B
ICW2_8809A
EQU
00001000B
; TYPES 8-15D
ICW3_8809A
EQU
00000100B
; SLAVE ON IR2
ICW4_8809A
EQU
00011101B
; 8088, NORM EOI, BUF MASTER
OCW1_8809A
EQU
00000000B
; ENABLE ALL INTERRUPTS FOR
; STD DOS
;
;
* ZT 8840 8259A REGISTER EQUATES BY PORT ADDRESS *
;
;
REG A ICW,OCW2,OCW3,IRR,ISR,IL
PORT_A_8840
EQU
0E7H
; PORT A
ICW1_8840
EQU
00010001B
; EDGE, CASCADE, ICW4 NEEDED
OCW2_8840
EQU
01100000B
; SPECIFIC EOI FOR IR0
;
;
REG B ICW2,3,4,OCW1,IMR
PORT_B_8840
EQU
0EFH
; PORT B
ICW2_8840
EQU
11111000B
; TYPES 248-255D
ICW3_8840
EQU
00000010B
; SLAVE ID #2
ICW4_8840
EQU
00011001B
; 8088, NORM EOI, BUF SLAVE
OCW1_8840
EQU
11111110B
; ENABLE IR0 ONLY
;
;
* ZT 8809A PRINTER PORT REGISTER EQUATES BY PORT ADDRESS *
;
PRTR_DATA
EQU
0378H
; PRINTER DATA PORT
PRTR_STAT
EQU
0379H
; PRINTER STATUS PORT
PRTR_CTRL
EQU
037AH
; PRINTER CONTROL PORT
;
;
* ZT 8840 UART REGISTER EQUATES BY PORT ADDRESS *
;
BASE
EQU
00E0H
; FACTORY DEFAULT
UART1
EQU
BASE+00H
; UART 1 ADDRESS
;
;
* ZT 8840 8250 REGISTER EQUATES BY PORT ADDRESS *
;
;
REG #0 RECV./TRANS REG (R/W)
PORT_REC50
EQU
000H
; RECV REGISTER
PORT_XMT50
EQU
000H
; TRANS. REGISTER
PORT_DLALB
EQU
000H
; IF DLAB=1, LSB DIV.
;
4-18