Using ID Shift with Legacy Modbus Serial Devices

If the Modbus serial slaves have the same default or un-configurable ID, the way to communicate to these slaves is to shift their IDs to be different from each other when talking to the master. To do this, following formula can be used for shifting the ID on the gateway configuration.

The Real Slave ID = Virtual Slave + Offset

You’ll see with the two examples below where two devices with the same ID can still be address by one master only by using a Modbus Gateway.  In our 2nd case you can connect two separate networks to a single master by utilizing a modbus gateway.  By using the ID shift on one network you can continue to communicate to multiple devices that are daisy chained.

 

Case 1: Multiple slave devices with same ID number, one slave device per serial port.

TCP master send request to on ID 4 and 7 based on the existing software settings, and two slave devices with fixed ID 7 connect to port 1 and 2.  A virtual ID can be assign on one of them by the offset function.

When the request send to ID 7 from master, the request will be sent to port one which has no offset value.  The request will be passed through the gateway directly.  When the request send to ID 4, the gateway will process the request and adds the offset value on the request to make it ID 7 and then send to the slave device.

In this case, no setting or configuration needs to be changed on the TCP Master.  The offset value can be a positive or negative number.

Modbus ID offset
Modbus ID offset

 

Case 2: More than one RS-485 daisy-chain networks with duplicate IDs connect to the same Modbus master such as following.

Modbus ID Daisy Chain
Modbus Daisy Chain w. Same ID

With the virtual ID enable and set the offset to -10, these two networks can be placed in different ID segments.

Modbus ID Shift
Modbus ID Shift

 

The benefits of using Modbus Gateways with ID Shift function can increase the usefulness of legacy sensors, I/O, PLC and other devices with the same default or un-configurable ID.  This saves both on the cost of deployment and reduces the need of rewiring or purchasing new equipment.

Contat our sales team about Modbus Gateways supporting this ID Shift function.