134 lines
6.6 KiB
PHP
134 lines
6.6 KiB
PHP
|
; INS8250 ACE Register Offsets And Bit Definitions
|
||
|
|
||
|
|
||
|
ACE_RBR equ 0 ;Receiver Buffer
|
||
|
ACE_THR equ 0 ;Transmit Holding Register
|
||
|
|
||
|
ACE_IER equ 1 ;Interrupt Enable
|
||
|
ACE_ERBFI equ 00000001b ; Received Data Available
|
||
|
ACE_ETBEI equ 00000010b ; Transmitter Holding Register Empty
|
||
|
ACE_ELSI equ 00000100b ; Receiver Line Status
|
||
|
ACE_EDSSI equ 00001000b ; Modem Status
|
||
|
|
||
|
ifdef NEC_98
|
||
|
ACE_FCR equ 8 ;FIFO control register
|
||
|
ACE_EFIFO equ 00000001b ; Enable FIFO
|
||
|
ACE_CRFIFO equ 00000010b ; Clear receive FIFO queue
|
||
|
ACE_CTFIFO equ 00000100b ; Clear transmit FIFO queue
|
||
|
RLInt_Enable equ 00001000b ; Receiver Line Status
|
||
|
MSInt_Enable equ 00010000b ; Modem Status
|
||
|
ACE_TRIG01 equ 00000000b ; Trigger receive int on every char
|
||
|
ACE_TRIG04 equ 01000000b ; Trigger receive int on every 4th char
|
||
|
ACE_TRIG08 equ 10000000b ; Trigger receive int on every 8th char
|
||
|
ACE_TRIG14 equ 11000000b ; Trigger receive int on every 14th char
|
||
|
else ; NEC_98
|
||
|
ACE_FCR equ 2 ;FIFO control register
|
||
|
ACE_EFIFO equ 00000001b ; Enable FIFO
|
||
|
ACE_CRFIFO equ 00000010b ; Clear receive FIFO queue
|
||
|
ACE_CTFIFO equ 00000100b ; Clear transmit FIFO queue
|
||
|
ACE_TRIG01 equ 00000000b ; Trigger receive int on every char
|
||
|
ACE_TRIG04 equ 01000000b ; Trigger receive int on every 4th char
|
||
|
ACE_TRIG08 equ 10000000b ; Trigger receive int on every 8th char
|
||
|
ACE_TRIG14 equ 11000000b ; Trigger receive int on every 14th char
|
||
|
endif ; NEC_98
|
||
|
|
||
|
ifdef NEC_98
|
||
|
ACE_IIDR equ 6 ;Interrupt Identification
|
||
|
ACE_IIP equ 00000001b ; Inverted Interrupt Pending (0=int)
|
||
|
ACE_IID equ 00000110b ; Interrupt ID
|
||
|
ACE_MSI equ 00000000b ; Modem Status
|
||
|
ACE_THREI equ 00000010b ; Transmitter Holding Register Empty
|
||
|
ACE_RDAI equ 00000100b ; Received Data Available
|
||
|
ACE_RLSI equ 00000110b ; Receiver Line Status
|
||
|
AOBA_RECTO equ 00001000b ; Receive Charactor Time-out
|
||
|
AOBA_PRS0 equ 00100000b ; AOBA Present
|
||
|
AOBA_PRS1 equ 01000000b ; AOBA Present
|
||
|
else ; NEC_98
|
||
|
ACE_IIDR equ 2 ;Interrupt Identification
|
||
|
ACE_IIP equ 00000001b ; Inverted Interrupt Pending (0=int)
|
||
|
ACE_IID equ 00000110b ; Interrupt ID
|
||
|
ACE_MSI equ 00000000b ; Modem Status
|
||
|
ACE_THREI equ 00000010b ; Transmitter Holding Register Empty
|
||
|
ACE_RDAI equ 00000100b ; Received Data Available
|
||
|
ACE_RLSI equ 00000110b ; Receiver Line Status
|
||
|
ACE_FIFO_E1 equ 01000000b ;set, if FIFO enabled on 16550A
|
||
|
ACE_FIFO_E2 equ 10000000b ;set, if FIFO enabled on 16550 or 16550A
|
||
|
endif ; NEC_98
|
||
|
|
||
|
ACE_LCR equ 3 ;Line Control
|
||
|
ACE_WLS equ 00000011b ; Word Length Select Bits
|
||
|
ACE_WLS0 equ 00000001b ; Word Length Select Bit 0
|
||
|
ACE_WLS1 equ 00000010b ; Word Length Select Bit 1
|
||
|
ACE_5BW equ 00000000b ; 5 Bit Words
|
||
|
ACE_6BW equ 00000001b ; 6 Bit Words
|
||
|
ACE_7BW equ 00000010b ; 7 Bit Words
|
||
|
ACE_8BW equ 00000011b ; 8 Bit Words
|
||
|
ACE_STB equ 00000100b ; Stop Bits
|
||
|
ACE_1SB equ 00000000b ; 1 Stop Bits (1.5 for 5 bit words)
|
||
|
ACE_2SB equ 00000100b ; 2 Stop Bits
|
||
|
ACE_PEN equ 00001000b ; Parity Enable
|
||
|
ACE_PSB equ 00110000b ; Parity select bits
|
||
|
ACE_EPS equ 00010000b ; Even Parity Select
|
||
|
ACE_SP equ 00100000b ; Stick Parity
|
||
|
ACE_SB equ 01000000b ; Set Break
|
||
|
ACE_DLAB equ 10000000b ; Divisor Latch Access Bit
|
||
|
|
||
|
ACE_MCR equ 4 ;Modem Control
|
||
|
ACE_DTR equ 00000001b ; Data Terminal ready
|
||
|
ACE_RTS equ 00000010b ; Request To Send
|
||
|
ACE_OUT1 equ 00000100b ; Output Line 1
|
||
|
ACE_OUT2 equ 00001000b ; Output Line 2
|
||
|
ACE_LOOP equ 00010000b ; Loopback
|
||
|
|
||
|
ifdef NEC_98
|
||
|
ACE_LSR equ 2 ;Line Status
|
||
|
ACE_THRE equ 00000001b ; Send FIFO and CCU Send Register All Empty
|
||
|
ACE_TSRE equ 00000010b ; Send FIFO Empty
|
||
|
ACE_DR equ 00000100b ; FIFO Data Enable
|
||
|
ACE_PE equ 00001000b ; Parity Error with Current FIFOed Data
|
||
|
ACE_OR equ 00010000b ; CCU Overrun Error
|
||
|
ACE_FE equ 00100000b ; Framing Error with Current FIFOed Data
|
||
|
ACE_BI equ 01000000b ; Break/SYNC with Current FIFOed Data
|
||
|
AOBA_ERF1 equ 10000000b ; Error in Receive FIFO
|
||
|
else ; NEC_98
|
||
|
ACE_LSR equ 5 ;Line Status
|
||
|
ACE_DR equ 00000001b ; Data Ready
|
||
|
ACE_OR equ 00000010b ; Overrun Error
|
||
|
ACE_PE equ 00000100b ; Parity Error
|
||
|
ACE_FE equ 00001000b ; Framing Error
|
||
|
ACE_BI equ 00010000b ; Break Interrupt
|
||
|
ACE_THRE equ 00100000b ; Transmitter Holding Register Empty
|
||
|
ACE_TSRE equ 01000000b ; Transmitter Shift Register Empty
|
||
|
endif ; NEC_98
|
||
|
|
||
|
ifdef NEC_98
|
||
|
ACE_MSR equ 4 ;Modem Status
|
||
|
else ; NEC_98
|
||
|
ACE_MSR equ 6 ;Modem Status
|
||
|
endif ; NEC_98
|
||
|
ACE_DCTS equ 00000001b ; Delta Clear to Send
|
||
|
ACE_DDSR equ 00000010b ; Delta Data Set Ready
|
||
|
ACE_TERI equ 00000100b ; Trailing Edge Ring Indicator
|
||
|
ACE_DRLSD equ 00001000b ; Delta Receive Line Signal Detect
|
||
|
ACE_CTS equ 00010000b ; Clear To Send
|
||
|
ACE_DSR equ 00100000b ; Data Set ready
|
||
|
ACE_RI equ 01000000b ; Ring Indicator
|
||
|
ACE_RLSD equ 10000000b ; Receive Line Signal Detect
|
||
|
|
||
|
ACE_DLL equ 0 ;LSB Baud Rate Divisor
|
||
|
|
||
|
ACE_DLM equ 1 ;MSB Baud Rate Divisor
|
||
|
|
||
|
ifdef NEC_98
|
||
|
NOT_ACE_EFIFO equ 11111110b ; disable FIFO
|
||
|
;------------------------------------------------------------------------------
|
||
|
; AOBA-bug ins 94.11.19 KBNES
|
||
|
;------------------------------------------------------------------------------
|
||
|
FIFO_Set_Buf_Clr equ RLInt_Enable OR ACE_TRIG04 OR ACE_EFIFO OR ACE_CRFIFO OR ACE_CTFIFO
|
||
|
Set_FIFO equ RLInt_Enable OR ACE_TRIG04 OR ACE_EFIFO
|
||
|
Set_8251 equ RLInt_Enable OR ACE_TRIG04
|
||
|
;------------------------------------------------------------------------------
|
||
|
; AOBA-bug ins end 94.11.19 KBNES
|
||
|
;------------------------------------------------------------------------------
|
||
|
endif ; NEC_98
|