Industrial Protocol

Modbus RTU/TCP Gateway: Connect Your PLCs to IP

Converting Modbus RTU (RS-485) to Modbus TCP (Ethernet) or to the cloud: the role of the gateway, possible architectures, use cases, and compatibility.

Quick answer
A Modbus RTU/TCP gateway is a converter that translates Modbus RTU requests (serial, over RS-485) to Modbus TCP (Ethernet/IP) or vice versa. It allows legacy RS-485 devices to be connected to an Ethernet network, an IP-based SCADA system, or the cloud—without modifying the PLC program or replacing field devices. It is the most common IoT modernization component in existing industrial facilities.

Modbus RTU and TCP: Two Variants, One Protocol

Modbus comes in two physical variants:

Modbus RTU — a serial variant using RS-485 or RS-232. Compact protocol (no header), frames with CRC-16. The master polls the slaves one by one on the shared bus. Data rate: 9,600 to 115,200 bps. Widely used in industrial installations since the 1980s.

Modbus TCP — Modbus encapsulated in TCP/IP. Same registers, same functions (FC01 through FC23), but over Ethernet via TCP port 502. No CRC (TCP handles integrity), multiple simultaneous connections possible, no distance limit on an IP network.

The Modbus RTU/TCP gateway bridges the two: it exposes RTU devices as TCP servers, or converts TCP requests into RTU requests, depending on the configured direction.

Operating Modes of a Modbus Gateway

Mode 1 (RTU → TCP): The gateway acts as a Modbus TCP server. It receives requests from TCP masters (SCADA, cloud-based monitoring) and translates them into Modbus RTU requests to the RS-485 devices.

Mode 2 (TCP → RTU): The gateway acts as a Modbus RTU master. It receives process data from an Ethernet PLC (Modbus TCP) and transmits it in Modbus RTU format to RS-485 slaves.

Address and Register Mapping

The gateway handles the mapping between Modbus RTU addresses (slave address 1–247 + register address) and TCP addresses (IP address + port 502 + unit ID). Typical configuration:

RS-485 DeviceModbus RTU AddressModbus TCP Access
Energy MeterSlave 1, reg 40001–40030IP 192.168.1.50:502, Unit ID 1
DriveSlave 2, reg 40001–40050IP 192.168.1.50:502, Unit ID 2
Temperature SensorSlave 3, reg 30001–30010IP 192.168.1.50:502, Unit ID 3

Modbus Gateway + Cloud: A Winning Combination

A Modbus RTU/TCP gateway alone exposes devices on the local Ethernet network. To send data to the cloud, an additional step is required: either SCADA software that reads Modbus TCP and publishes data via MQTT, or an IoT gateway that does both (RTU/TCP conversion + cloud upload via 4G).

The Eziwan Gateway does it all: it queries Modbus RTU devices directly via its RS-485 port and Modbus TCP devices via Ethernet, and publishes the data to the Eziwan Cloud via MQTT and VPN.

For more information: Modbus Cloud, RS-485 Cloud Gateway, and Industrial MQTT.

Frequently Asked Questions

You might also like