Qua Tech Inc. warrants the QS-200M/QS-300M
be free of defects for one
purchase. Qua Tech Inc. will repair or replace any board
that fails to perform under normal operating conditions
and in accordance with the procedures outlined in this
document during the warranty period. Any damage that
results from improper installation, operation, or general
misuse voids all warranty rights.
Although every attempt has been made to guarantee
the accuracy of this manual, Qua Tech Inc. assumes no
liability for damages resulting from errors in this
document. Qua Tech Inc. reserves the right to edit or
append to this document at any time without notice.
Please complete the following information and retain
for your records. Have this information available when
requesting warranty service.
DATE OF PURCHASE:
MODEL NUMBER: QS-200M/QS-300M
PRODUCT DESCRIPTION: FOURASYNC.
(1) year from the date of
CHANNEL RS-422/RS-485
COMMUNICATIONS ADAPTER
to
SERIAL NUMBER:
IBM PCTM, PC/XTTM, and PC/ATTM are trademarks of
International Business Machines.
The QS-200M is a four channel RS-422 asynchronous
serial communication adapter. The QS-300M is an RS-485
version of the adapter. Both are designed to be hardware
compatible with the IBM PC/XT/AT personal computers.
Data is communicated through four shielded RJ-11
"modular" phone jack connectors which provide shielding
from environmental noise.
The serial interface is accomplished through four
16450 Asynchronous Communication Elements (ACEs). The
16450 is an improved specification version of the 8250
ACEs used in the IBM PC/XT models. Optional 16550 ACEs
are available to reduce CPU overhead at higher data rates
when used with software supporting this feature.
Addressing for the adapter is selected by a pair of
six position switches. These switches allow a full range
of address choices between 0 and FFFF hex. The QS200M/QS-300M has the option of selecting one of six
possible Interrupt Request lines (IRQ 2 - IRQ 7). A
hardware selectable clock divider is also available for
producing unusual baud rates.
II. BOARD
DESCRIPTION
A component diagram of the QS-200M/QS-300M is shown
in figure 1. The base address is controlled by the
address selection switches SW1 & SW2. The interrupt
level for the adapter is selected using jumper J3.
Channels 1 - 4 are controlled by the 16450 ACEs labeled
U5 - U8 and are output through connectors CON1 - CON4
respectively.
III. 16450/16550
FUNCTIONAL DESCRIPTION
The 16450 is an improved specification version of
the 8250 Asynchronous Communications Element (ACE).
Functionally, the 16450 is equivalent to the 8250. The
ACE performs serial-to-parallel conversion on received
data and parallel-to-serial conversion on data output
from the CPU.
iii
Page 5
BOARD DESCRIPTION
Figure 1. QS-200M/QS-300M board layout.
Page 6
FUNCTIONAL DESCRIPTION
Designed to be compatible with the 16450, the
16550 ACE enters character mode on reset and in this
mode appears as a 16450 to user software. An
additional mode, FIFO mode, can be invoked through
software to reduce CPU overhead. The FIFO mode
increases performance by providing two 16-byte FIFOs
(one transmit and one receive) to buffer data and
reduce the number of interrupts issued to the CPU.
Other features of the 16450/16550 include:
Programmable baud rate, character length, parity,
and number of stop bits.
Automatic addition and removal of start, stop, and
parity bits.
Independent and prioritized transmit, receive and
status interrupts.
Transmitter clock output to drive receive logic.
External receiver clock input.
The following pages provide a brief summary of the
internal registers available within the 16450 and 16550
ACEs. The registers are addressed as shown in figure 2
below. Registers and functions specific to the 16550
will be marked with an asterisk(*).
Indicates highest priority interrupt pending if
any. See IP and figure 5. NOTE: IID2 is
always a logic 0 in character mode.
IP - Interrupt Pending:
When logic 0, indicates that an interrupt is
pending and the contents of the interrupt
identification register may be used to determine
the interrupt source. See IIDx and figure 5.
*
For optional 16550 only
Page 9
FUNCTIONAL DESCRIPTION
+---------------------+----------+---------------------+
| IID2 IID1 IID0 IP | Priority | Interrupt Type |
+---------------------+----------+---------------------+
| x x x 1 | N/A | None |
| 0 1 1 0 | Highest | Receiver Line Status|
| 0 1 0 0 | Second | Received Data Ready |
| 1 1 0 0 | Second | Character Timeout |
| | | (FIFO only)
Figure 5. Interrupt Identification bit definitions.
Receiver Line Status:
Indicates overrun, parity, framing errors or
break interrupts. The interrupt is cleared by
reading the line status register.
|
Received Data Ready:
Indicates receive data available. The interrupt
is cleared by reading the receive buffer.
FIFO mode:* Indicates the receiver FIFO trigger level
has been reached. The interrupt is reset when
the FIFO drops below the the trigger level.
Character Timeout:
*
(FIFO mode only)
Indicates no characters have been removed from
or input to the receiver FIFO for the last four
character times and there is data present in the
receiver FIFO. The interrupt is cleared by
reading the receiver FIFO.
Transmitter Holding Register Empty:
Indicates the transmitter holding register is
empty. The interrupt is cleared by reading the
interrupt identification register or writing to
the transmitter holding register.
MODEM Status:
Indicates clear to send, data set ready, ring
indicator, or data carrier detect have changed
state. The interrupt is cleared by reading the
MODEM status register.
When set (logic 1), RxRDY and TxRDY change from
mode 0 to mode 1 for DMA transfers. (DMA mode
not supported on QS-200M/QS-300M.)
XRST - Transmit FIFO Reset:
*
When set (logic 1), all bytes in the transmitter
FIFO are cleared and the counter is reset. The
shift register is not cleared. XRST is selfclearing.
*
For optional 16550 only.
Page 11
FUNCTIONAL DESCRIPTION
RRST - Receive FIFO Reset:
*
When set (logic 1), all bytes in the receiver
FIFO are cleared and the counter is reset. The
shift register is not cleared. RRST is selfclearing.
FE - FIFO Enable:
*
When set (logic 1), enables transmitter and
receiver FIFOs. When cleared (logic 0), all
bytes in both FIFOs are cleared. This bit must
be set when other bits in the FIFO control
register are written to or the bits will be
ignored.
DLAB must be set to logic 1 to access the baud
rate divisor latches. DLAB must be set to logic
0 to access the receiver buffer, transmitting
holding register and interrupt enable register.
BKCN - Break Control:
When set (logic 1), the serial output (SOUT) is
forced to the spacing state (logic 0).
*
For optional 16550 only.
Page 12
F
UNCTIONAL DESCRIPTION
STKP - Stick Parity:
Forces parity to logic 1 or logic 0 if parity is
enabled. See EPS, PEN, and figure 9.
EPS - Even Parity Select:
Selects even or odd parity if parity is enabled.
See STKP, PEN, and figure 9.
PEN - Parity Enable:
Enables parity on transmission and verification
on reception. See EPS, STKP, and figure 9.
Figure 11. MODEM Control Register bit definitions.
LOOP - Loopback Enable:
When set (logic 1), the transmitter shift
register is connected directly to the receiver
shift register. The MODEM control inputs are
internally connected to the MODEM control
outputs and the outputs are forced to the
inactive state. All characters transmitted are
immediately received to verify transmit and
receive data paths. Transmitter and receiver
interrupts still operate normally. MODEM
control interrupts are available but are now
controlled through the MODEM control register.
Bits OUT2, OUT1, RTS, and DTR perform identical
functions on their respective outputs. When these
bits are set (logic 1) in the register, the
associated output is forced to a logic 0. When
cleared (logic 0), the output is forced to a logic1.
OUT2 - Output 2:
Controls the OUT2 output as described above.
OUT1 - Output 1:
Controls the OUT1 output as described above.
RTS - Request To Send:
Controls the RTS output as described above.
DTR - Data Terminal Ready:
Controls the DTR output as described above.
Used for transmitter enable (see section VIII).
Indicates one or more parity errors, framing
errors, or break indications in the receiver
FIFO. FFRX is reset by reading the line status
register.
*
TEMT - Transmitter Empty:
Indicates the transmitter holding register (or
FIFO*) and the transmitter shift register are
empty and are ready to receive new data. TEMT
is reset by writing a character to the
transmitter holding register.
THRE - Transmitter Holding Register Empty:
Indicates the transmitter holding register (or
FIFO*) is empty and it is ready to accept new
data. THRE is reset by writing data to the
transmitter holding register.
*
For optional 16550 only.
Page 15
FUNCTIONAL DESCRIPTION
Bits BI, FE, PE, and OE are the sources of receiver
line status interrupts. The bits are reset by
reading the line status register. In FIFO mode*,
these bits are associated with a specific character
in the FIFO and the exception is revealed only when
that character reaches the top of the FIFO.
BI - Break Interrupt:
Indicates the receive data input has been in the
spacing state (logic 0) for longer than one full
word transmission time.
FIFO mode:
*
Only one zero character is loaded into the FIFO
and transfers are disabled until SIN goes to the
mark state (logic 1) and a valid start bit is
received.
FE - Framing Error:
Indicates the received character had an invalid
stop bit. The stop bit following the last data
or parity bit was a 0 bit (spacing level).
PE - Parity Error:
Indicates that the received data does not have
the correct parity.
OE - Overrun Error:
Indicates the receive buffer was not read before
the next character was received and the
character is destroyed.
FIFO mode:
*
Indicates the FIFO is full and another character
has been shifted in. The character in the shift
register is destroyed but is not transferred to
the FIFO.
DR - Data ready:
Indicates data is present in the receive buffer
or FIFO. DR is reset by reading the receive
buffer register or receiver FIFO.
*
For optional 16550 only.
Page 16
FUNCTIONAL DESCRIPTION
IIIG. MODEM STATUS REGISTER
+------+
D7 | DCD |----- Data carrier detect
+------+
D6 | RI |----- Ring indicator
+------+
D5 | DSR |----- Data set ready
+------+
D4 | CTS |----- Clear to send
+------+
D3 | DDCD |----- Delta data carrier detect
+------+
D2 | TERI |----- Trailing edge ring indicator
+------+
D1 | DDSR |----- Delta data set ready
+------+
D0 | DCTS |----- Delta clear to send
+------+
Figure 13. MODEM Status register bit definitions.
DCD - Data Carrier Detect:
Complement of the DCD input.
RI - Ring Indicator:
Complement of the RI input.
DSR - Data Set Ready:
Complement of the DSR input.
CTS - Clear To Send:
Complement of the CTS input.
Bits DDCD, TERI, DDSR, and DCTS are the sources of
MODEM status interrupts. These bits are reset when
the MODEM status register is read.
DDCD - Delta Data Carrier Detect:
Indicates the Data Carrier Detect input has
changed state.
TERI - Trailing Edge Ring Indicator:
Indicates the Ring Indicator input has changed
from a low to a high state.
DDSR - Delta Data Set Ready:
Indicates the Data Set Ready input has changed
state.
DCTS - Delta Clear To Send:
Indicates the Clear to Send input has changed
state.
Page 17
FUNCTIONAL DESCRIPTION
IIIH. SCRATCHPAD REGISTER
This register is not used by the 16450/16550. It
may be used by the programmer for data storage.
IV. FIFO
INTERRUPT MODE OPERATION
*
1. The receive data interrupt is issued when the
FIFO reaches the trigger level. The interrupt is
cleared as soon as the FIFO falls below the
trigger level.
2. The interrupt identification register's receive
data available indicator is set and cleared along
with the receive data interrupt above.
3. The data ready indicator is set as soon as a
character is transferred into the receiver FIFO
and is cleared when the FIFO is empty.
V. BAUD
RATE SELECTION
The 16450 ACE determines the baud rate of the serial
output and uses a combination of the clock input
frequency and the value written to the divisor latches.
Standard PC, PC/XT, PC/AT, and PS/2 serial interfaces use
an input clock of 1.8432 MHz. To increase versatility,
the QS-200M/QS-300M uses an 18.432 MHz crystal and a
frequency divider circuit to produce the standard clock
frequency.
Jumper block J1 is used to set the frequency input
to the 16450. It may be connected to divide the clock
input by 1, 2, 5, or 10. For compatibility as stated
above, J1 should be configured to divide by 10 as shown
in figure 14(d). A table of baud rates available using
the 1.8432 MHz input is given in figure 14.
rates using an 1.8432 MHz input clock.
For compatibility, connect jumper in the
divide by 10 configuration (figure 14(d)).
Page 19
BAUD RATE SELECTION
VI. ADDRESSING
The QS-200M/QS-300M uses 8 I/O address locations
per channel. Full sixteen bit address decoding allows
base address selections in the range 0000 - FFFF Hex.
Two six position switches, SW1 & SW2 are used to specify
the base address of the adapter. SW1 controls the
address setting for A15-A10 through positions 1-6
respectively. Switch SW2, positions 1-5 control address
selections for A9-A5. The remaining address inputs are
used by the adapter to determine the channel and register
being accessed.
A switch in the "ON" position indicates that the
corresponding address bit be a logic 0 for selection.
A switch in the "OFF" position forces the corresponding
address bit to be a logic 1 for selection. Some
example switch settings for the QS-200M/QS-300M are shown
in figures 16 and 17.
The base address of each channel is incremented by a
factor of 8 from the base address of the adapter.
Therefore 32 address locations are used by the QS-200M/
QS-300M.
PORT
ADDRESS RANGE
1 Base Address+0 - Base Address+7
2 Base Address+8 - Base Address+15
3 Base Address+16 - Base Address+23
4 Base Address+24 - Base Address+31
The QS-200M/QS-300M is capable of supporting six
interrupt levels, IRQ 2-7. All of the channels share
the same interrupt. The selection of interrupt levels
can be changed through a hardware jumper, J3, as shown
below:
The QS-200M/QS-300M is also equipped with an
interrupt sharing circuit. This circuit allows the QS200M/QS-300M to share its interrupt with other Qua Tech
adapters supporting this feature.
Page 22
INTERRUPTS
INTERRUPT STATUS REGISTER
An interrupt status register is implemented on the
QS-200M/QS-300M to reduce the interrupt servicing
overhead associated with multi-port communications.
Scratchpad / Interrupt Status register selection is
controlled by position 6 on SW2. When position 6 is in
the OFF position, there is no Interrupt Status register,
and all of the 16450/16550s behave normally. When
position 6 is in the ON position, the Interrupt Status
register overrides the ACEs internal Scratchpad register.
In this mode, an input from the Scratchpad register
address (BASE ADDRESS + 7) of any channel will return the
interrupt status of the entire card.
Figure 20. Interrupt Status register for the
QS-200M/QS-300M. IPx set (logic 1),
indicates an interrupt is pending on
the associated channel.
Page 23
OUTPUT CONFIGURATIONS
VIII. OUTPUT
CONFIGURATIONS
The function of jumper J2 is to configure the
communication channels in half or full duplex mode. Half
duplex operation is achieved by installing a jumper block
over the pins for the specific channel (figure 21). This
connection allows the transmitter to be enabled and
disabled using the data terminal ready (DTR) output which
is controlled through the modem control register of the
16450/16550. When DTR is set (logic 1), the transmitter
driver is enabled for output on the channel. When
cleared, (logic 0), the transmitter output enters a high
impedance state. Full duplex operation is restored by
removing the associated jumper.
CAUTION: When operating in half duplex mode, the
transmitter must be disabled before receiving
any information. Failure to do so may result
in multiple output drivers being connected
together which may cause damage to the QS200M/QS-300M, the computer and the peripheral
equipment.