ADAP485
User’s Guide

 

1. Introduction

The ADAP485 adapter is a general purpose, auto-turnaround RS232-to-RS485 converter that can be used to convert any standard RS232C port into a two-wire RS485 port and vice versa.

When used with programmable controllers, it greatly expands the PLC’s serial I/O capabilities by allowing multiple PLCs to be linked to a single PC for programming, file services or internet connectivity. It can also be used to convert the PLC’s RS485 into an additional RS232 port for connections to third party RS232 devices such as HMI, frequency inverters, barcode scanners, smart card readers, external modems etc.

The ADAP485 requires a power supply input of between 9V and 24V DC to operate properly. You can use a 9V alkaline battery for quick test or you can use the same 12V or 24V power supply that powers the PLC for permanent installation.

The power supply as well as the RS485’s ‘+’ and ‘-‘ terminals are connected via a 4-way detachable screw terminal as shown Figure 1. The RS232 port is a female DB9 connector and is of a DCE configuration. This means that it can be connected directly to a PC’s serial port using a straight-through DB9 cable. The RS232 pin-outs are shown in Figure 2a.

Note that there are some external so called "line-powered" RS232 devices on the market which actually "steal" power from the DSR pin of the RS232 port. To cater to such devices, the ADAP485 adapter also makes available a +9V output on its DSR pin (pin #6).

Figure 2 (b) shows the wiring method for connecting the ADAP485 to another RS232 DCE device that also has a female DB9 connector (e.g. a barcode reader which is designed for straight-through connection to a PC).

2. What is RS485 Transmit/Receive Turnaround?

A two-wire RS485 is a half duplex serial interface that utilizes a differential pair of wires to carry signal to long distance. It is the relative potential difference between the RS485 "+" and the "-" that determines whether a signal bit is a ‘0’ or a ‘1’. As such, common mode noise that is imposed onto the two-wires simultaneously has no effect on the signal quality, giving it ability to travel a much longer distance (1200 m or 4000 ft) compared to RS232 interface.

In an RS485 network, all devices are attached to a single pair of RS485 wire as shown in the following diagram:wpe6F.jpg (8685 bytes)

Since there is only a single pair of wires that are connected to all the RS485s, the same two wires will thus have to carry the serial data input to the each device as well as the serial data output from the device.

Each RS485 device has a "transmit" and "receive" driver called the "transceiver". The transceiver is either in "transmit" or "receive" mode. To avoid having more than one device sending data on the RS485 wires at the same time (which will most certainly result in garbled data), a device should always be in "receive" mode so that its transmit driver is turned OFF, except when it intends to send out data. When a device is ready to send data on the RS485, it will then enter "transmit" mode and drive the data out onto the two RS485 wires. After the device completes sending out data it should then return to "receive" mode. This process is called "turnaround".

3. Turnaround Selection

So how does the ADAP485 converter know when to turnaround its RS485 transceiver? Since the primary purpose of the ADAP485 is to convert the RS232 signals into RS485, the data and the control pins from the RS232 device can thus be used to control the RS485 transceiver direction.

ADAP485 supports two turnaround methods thawpe71.jpg (3388 bytes)t can be selected by placing the Jumper cap at one of the two positions:

 

a) Turnaround controlled by the RS232 ‘s RTS signal:

The RS485 transmit/receive state is directly controlled by the logic state of the /RTS signal on its RS232 interface. Hence, the external RS232 device must turn ON its /RTS signal to put the RS485 transceiver into "transmit" mode before sending out its data. Once the last data bit has been sent out, the external RS232 device should immediately turn OFF the /RTS signal to return the RS485 interface into "receive" mode.

This turnaround control method is only possible if the external RS232 device can control its /RTS (Request to Send) signal and is able to synchronize this action with its data transmission need.

b) Auto-Turnaround

The ADAP485 adapter also supports automatic turnaround of the RS485 transceiver. When in this configuration the adapter immediately turns the transceiver to "transmit" mode upon sensing a "start bit" (a high to low transition) from its RS232 data transmit line (TxD). The transceiver will continue in "transmit" mode as long as there is logic ‘0’ on the TxD line.

When the data transmission is completed the TxD line will be returned to logic ‘1’ due to the action of the "stop bit" (a low to high transition). If the RS232 transmit line is at logic ‘1’ for longer than a certain "turnaround delay" time, the transceiver will be turned around automatically and the RS485 will then re-enter the "receive" mode.

There is a small preset potentiometer on the ADAP485, which allows you to adjust the turnaround time from 0.5ms to 1.5ms. The factory default is set at 0.5ms (maximum clockwise turn) which works well with the M-series PLCs at 38400 bps. You may want to increase the turnaround delay when using it with slower serial devices.

Note that unlike the turnaround control by /RTS scheme where the transceiver direction is controlled precisely by the /RTS signal, the turnaround time in this configuration is only an approximation. Therefore, if two devices are to communicate using the auto-turnaround RS485 drivers, they should always give some allowance time for the RS485 driver to turnaround by inserting a delay of at least 1 ms before switching direction, i.e. a device should wait for a short while before responding to an incoming command to avoid driving the RS485 line too soon (before the last driver relinquishes the RS485 line).

ADAP485 page

Robotics Controllers Instrumentation Sensors Parts Micros Software

SCM International, Inc.
Fax: +1 (530)3256895

Asistencia en espaņol por e-mail
English assistance by e-mail

 Mailing Address:
SCM International, Inc.
2648 E. Workman Ave. suite 527
West Covina, CA 91791 
USA

Corporate Headquarters POBOX:
SCM International, Inc.
POBOX 9793

Reno, NV . 89507
USA

SCMStore.com, license and Conditions of use

SCM International, Inc. license the user to use this application by the term of a session, only under the following terms and conditions: