Today is...
Saturday, July 23, 2016
Welcome to, the global online
community of automation professionals.
Featured Video...
Featured Video
A tutorial introduction to programming using the QuickBuilder Programming Environment.
Our Advertisers
Help keep our servers running...
Patronize our advertisers!
Visit our Post Archive
Modbus to 4...20mA Conversion
how to convert a Modbus output into a 4...20mA using reader Master Modbus, a receiver and a converter Modbus. how the connection should be made? Is the receiver a slave or Master device?

Dear All,

I have a project where I would like to convert Modbus to 4…20mA.

I have the following items: receiver,a reader Modbus master, and a converter from Modbus to 4…20mA.

The connections are made as follow:
A sensor is connected to a transmitter that will send the data wirelessly to a receiver with Modbus output.

Reader connection:
1- RS485 Slave: 3 pins: A,B,GND
2- RS485 Master: 3 pins: A,B,GND
3- Power Supply: 2 pins: 10…40VDC, 19…28VAC

Converter Connection:
1- RS485 : 3 pins : A,B,GND
2- 4…20mA: 2 pins: OUT, GND
3- Power Supply: 2 pins: 10…40VDC, 19…28VAC
4- DIP Switches: to define the Baud Rate, and the address
5- Termination: On, or Off

Receiver Connection:
Wire RS-485 cable------- Fieldgate------- terminal Remarks
RxD/TxD– (RS-485 A) ------- A------- RS-485 differential
RxD/TxD+ (RS-485 B) ------- B------- signal
Shield -------SHD------- Cable shielding

Dip Switches: to define the Bus address, baudrate, RS485 termintaiton

Power Supply: 1,2 : 24VDC
Ethernet connection to connect the receiver to a network TCP-IP

I am a little bit confused how to connect these three items:
As I know that the reader is the Master device and the converter is slave. Is this true? If so, how should I connect them?

Output of the receiver RS485 is connected to Slave connection of the Reader.
The Master connection of the reader is connected to the connection of the converter.

Can you please guide us if this is true? Or the connection should be swapped?

Thank you in advance.

Let me restate the data path from sensor in the field to the analog output, to see if I got this right:

sensor > wireless xmtr > wireless receiver (Modbus/RTU/ASCII slave) > Reader (Modbus/RTU/ASCII Master with ethernet something-or-other) > converter (Modbus/RTU/ASCII slave) with 4-20mA analog output. Correct?

Modbus doesn't have inputs and outputs, Modbus has a 'port'. All the Modbus ports are connected one to another. The wireless receiver's RS-485 connects to the Converter's RS485 which connects to the Reader Master RS-485. It shouldn't matter in what order they're connected.

Theoretically, all the A terminals wire to each other (daisy chain); all the B terminals wire to each other (daisy chain). But different labeling conventions mean that A for vendor X is B for vendor Y. Only empirical testing will show what's what.

Warning - are all these devices Modbus RTU? Unless your wireless receiver and Converter devices provide a Modbus slave table, they might not be Modbus. Lots of devices use RS-485 and do not talk Modbus. Or one device might be Modbus ASCII and the other Modbus RTU (one uses 7 bit data words, the other 8 bit data words). Sometimes a setting or DIP switch allows one or the other. The devil's in the details.

The slaves are silent unless spoken to. The master will have to ask the wireless receiver for specific data (a read operation), wait for the response, the wireless receiver slave will answer with the data, the Master will temporarily hold the data, maybe re-format the data, then write the data to the converter and wait for the slave's confirming reply. Then the master does it all over again.

FYI, some industrial wireless systems are 'wired-in/wired-out' such that an analog signal (an input to the field radio) at the field end is reconstructed as an analog output by the receiver's on-board I/O, like Banner Engineering does. They call the field end 'node' and the receiver end 'gateway'. Doing so minimizes the integration effort, such as you're running into.

Dear David,

Thank you for your reply.

Let me restate what you are trying to say to see if I got this right:
the receiver, and the converter are the slave device.
the reader is the Master.

if this is correct, the slave devices should be connected to the Master port or to the slave port of the master device (reader)?

waiting to hearing you,
thank you

>the receiver, and the converter are the slave device. The reader is the Master.

Hopefully that's the case. Only one master is allowed on a serial Modbus network. Typically field devices and output modules are slaves.

>the slave devices should be connected to the Master port or to the slave port of the master device (reader)?

The receiver and converter slave devices' serial ports should be wired to the (reader) Modbus master's serial port, and the reader's serial serial port must have Modbus master functionality.