TS-5400 User’s Manual
Technologic Systems
10/31/03
8
5.1 Serial Port Configuration Registers
Because both serial ports are 100% PC compatible, software written for the PC that accesses serial
ports directly or through standard BIOS calls will work without modification on the TS-5400. The details
of the COM port internal registers are available in most PC documentation books or the data sheet for
the National Semiconductor NS16C550 may be consulted.
5.2 Serial Port Hardware
Each RS-232 serial port has 4 lines buffered: the Rx and Tx data lines and the CTS / RTS handshake
pair. This is quite sufficient to interface with the vast majority of serial devices. If additional handshake
lines are required, it will be necessary to add a TS-SER daughter board. The TS-5400 serial signals are
routed to 10-pin header labeled COM2 and a standard 9-pin Sub-D male labeled COM2. A serial
adapter cable can be plugged into the COM2 header to convert this into a standard DB9 male
connector. The pin-outs for the 10-pin header and DB9 male connector are listed above. The RTS
signal also drives the DTR pin on COM2, DTR is always the same state as RTS.
5.3 RS-485 Support
An option is available to add support to COM1 for half
duplex or full duplex RS-485. RS-485 drivers allow
communications between multiple nodes up to 4000 feet
(1200 meters) via twisted pair cable. Half-duplex RS-485
requires one twisted pair plus a Ground connection, while
full duplex requires two twisted pair plus a Ground.
For half-duplex operation, a single twisted pair is used for
transmitting and receiving. Bit 6 at I/O location 75h must
be set to enable RTS mode or bit 7 can be set to enable
Automatic mode. In RTS mode, the serial port RTS signal
controls the RS-485 transmitter/receiver (See Automatic
mode below). When RTS is asserted true, the RS-485
transmitter is enabled and the receiver disabled. When
RTS is de-asserted the transmitter is tri-stated (disabled)
and the receiver is enabled. Since the transmitter and
receiver are never both enabled, the serial port UART
does not receive the data transmitted.
For full-duplex operation, two twisted pairs are used and
the transmitter can typically be left on all the time. Simply
use RTS mode, and set RTS true.
See Figure 2 above for connector pin-outs.
5 GND
Rx - 9
4 Rx +
[in]
CTS
8
3 TX data
[out]
[out]
RTS
7
2 RX data
[in]
Tx - 6
1 Tx +
Figure 2 –
COM1
9-pin Sub D
Pin-out [signal direction is in brackets]
PLEASE NOTE:
COM1 has connections
for the RS-232 port and the RS-485 port
on the same 9 pin connector, only one of
the two functions will be used at a time.
5V Power 10 5 GND
NC
9
4 DTR (RTS) [out]
[in]
CTS
8
3 TX data
[out]
[out]
RTS
7
2 RX data
[in]
NC
6
1 NC
Figure 1 –
COM2
Serial Port Header and
DB9 Pin-out [signal direction is in brackets]
PLEASE NOTE:
The serial port headers
use a non-standard numbering scheme.
This was done so the header pins would
have the same numbering as the corre-
sponding DB-9 pin; i.e. pin 8 (CTS) on the
header connects to pin 8 on the DB-9
RS-485 Quick start procedure:
1. The RS-485 option must be installed
2. Install FD jumper for full-duplex or HD
for half-duplex RS-485 operation
3. Attach the RS-485 cable to the 9-pin
Sub-D connector.
4. Set the COM1 UART serial parameters
(baud rate, data, parity, and stop bits,
interrupts, etc).
5. Run Auto485.exe utility
(configures bits 6 and 7 at I/O 75h)
(and initializes Timer2)
6. For Half-Duplex RTS mode: To
transmit data, assert RTS and write the
data to the UART.
To receive
data, deassert RTS and read the data
from the UART
7. For Half-Duplex Automatic mode: just
read or write data to the UART
Содержание TS-5400
Страница 1: ...TS 5400 User s Manual ...