Blog

How to Control an Electric Gripper with Modbus RTU over RS485

Short answer: To control an electric gripper over Modbus RTU, connect the gripper's RS485 A/B lines to a PLC or USB-RS485 adapter, power it with DC 24 V, match the…

Short answer: To control an electric gripper over Modbus RTU, connect the gripper’s RS485 A/B lines to a PLC or USB-RS485 adapter, power it with DC 24 V, match the serial settings and slave ID from the manual, then write the gripper’s holding registers (position, force, speed, command) and read its status registers. Get the exact register map from the supplier.

Many electric grippers, including Grippersupply’s EPG2-26-15, EPGC-50-150 and ERG-20-80, support Modbus RTU over RS485 as well as simple I/O. Modbus lets you set grip force, position and speed from your controller, and read back whether a part was gripped. This guide explains the general method. It works with most Modbus RTU grippers; the register addresses and serial settings always come from your gripper’s own register map.

Grippersupply customers: we do not publish register addresses, default baud rates or connector pinouts on this page. Contact us for the register map and wiring diagram for your model.

Modbus RTU and RS485 in one minute

  • RS485 is the physical layer: a two-wire differential bus (usually labelled A/B or D+/D−) plus a common ground. It tolerates electrical noise and long cable runs, and lets several devices share one bus.
  • Modbus RTU is the protocol on top: a master (PLC, robot controller or PC) sends requests; each slave (the gripper) has a unique ID (1–247) and answers only to its own ID.
  • Data lives in registers. Grippers usually use holding registers (read/write: target position, force, speed, command) and input or holding registers (read: current position, status, fault codes).
  • Each frame ends with a CRC checksum. Your Modbus library or PLC function block calculates it for you.

I/O vs Modbus RTU: which control mode?

Feature Digital I/O control Modbus RTU (RS485) control
Wiring One wire per signal (open, close, done) Two-wire bus + ground, shared by many devices
What you can command Usually open/close or preset positions Position, force, speed, commands per move
Feedback On/off signals (e.g. “gripped”) Actual position, status, fault codes
Multiple grippers More wires per gripper Several grippers on one bus, different slave IDs
PLC programming Simplest Needs a Modbus function block or library
Best for Fixed, repetitive open/close Mixed parts, fragile items, force tuning
Grippersupply models All EPG/ERG/EPGS (EPGS is I/O only) EPG2, EPGC, ERG series

What you need

  1. An electric gripper that supports Modbus RTU (e.g. EPG2-26-15).
  2. A DC 24 V power supply sized for the gripper current (e.g. EPG2-26-15 is rated 0.3 A, EPGC-50-150 0.6 A, ERG-20-80 1.5 A, per our catalog). Leave margin.
  3. A Modbus master: a PLC with an RS485 port or Modbus RTU module, a robot controller with a tool RS485 port, or a PC with a USB-to-RS485 adapter.
  4. Twisted-pair cable for A/B, ideally shielded.
  5. The gripper’s register map and wiring diagram from the supplier.

Step 1: Wire power and RS485

  1. Switch power off.
  2. Connect +24 V and 0 V to the gripper power wires as shown in its wiring diagram.
  3. Connect the gripper’s RS485 A to the master’s A and B to B. Labels vary between makers; if communication fails later, swapping A and B is a common fix.
  4. Connect a common ground (reference) between master and gripper if the diagram shows one.
  5. On long buses, use a 120 Ω termination resistor at each end of the bus, and connect devices in a daisy chain, not a star.
  6. Ground the cable shield at one end only.

Step 2: Match serial settings and slave ID

Every device on the bus must use the same:

  • Baud rate
  • Data bits, parity, stop bits (often written like “8N1” or “8E1”)

Each gripper needs a unique slave ID. Take the default values from the gripper’s manual and set your master to match. If you run several grippers on one bus, change their IDs one at a time before connecting them together.

Step 3: Understand the function codes

Function code Name Typical gripper use
0x03 Read Holding Registers Read settings, current position, status
0x04 Read Input Registers Read status on devices that use input registers
0x06 Write Single Register Send one value: force, speed, position or a command
0x10 Write Multiple Registers Send several values in one frame

Your register map tells you which function code and which address to use for each parameter, plus units and scaling (for example, whether position is in 0.01 mm or force in percent).

Step 4: Typical command sequence

Most Modbus grippers follow a sequence like this (names are generic; use the names in your map):

  1. Initialize / home — the gripper finds its zero position after power-up.
  2. Read status until initialization is complete.
  3. Write force (and speed, if supported).
  4. Write target position (or a close/open command).
  5. Read status until motion is done; check the “object gripped” or “position reached” flag.
  6. Handle faults — read the fault register and reset if needed.

Step 5: Example in Python (pymodbus)

This example shows the structure only. Replace every REG_... placeholder and serial setting with values from your gripper’s register map.

from pymodbus.client import ModbusSerialClient

# Fill these in from the gripper manual / register map
PORT = "/dev/ttyUSB0"          # or "COM3" on Windows
BAUD = None                    # from the manual
SLAVE_ID = None                # from the manual
REG_INIT = None                # register map: initialize command
REG_FORCE = None               # register map: force setting
REG_POSITION = None            # register map: target position
REG_STATUS = None              # register map: status

client = ModbusSerialClient(port=PORT, baudrate=BAUD, parity="N",
                            stopbits=1, bytesize=8, timeout=1)
client.connect()

client.write_register(REG_INIT, 1, slave=SLAVE_ID)      # initialize
client.write_register(REG_FORCE, 50, slave=SLAVE_ID)    # value/units per map
client.write_register(REG_POSITION, 0, slave=SLAVE_ID)  # e.g. close

status = client.read_holding_registers(REG_STATUS, count=1, slave=SLAVE_ID)
print(status.registers)
client.close()

(Parameter names such as slave= can differ between pymodbus versions; check your installed version’s docs.)

Step 6: PLC integration

  • Siemens, Mitsubishi, Omron, Delta, Inovance and others provide Modbus RTU master function blocks or instructions for their RS485 ports or communication modules.
  • Configure the port with the same serial settings as the gripper.
  • Create one read block (status) and one write block (commands) per gripper, triggered in sequence, not at the same moment, because RS485 is half-duplex.
  • Add a timeout and retry counter, and raise an alarm if the gripper stops answering.

Troubleshooting checklist

Symptom Common cause What to check
No response / timeout Wrong baud, parity or slave ID Match the manual exactly
No response, settings correct A/B swapped Swap A and B
CRC errors, random failures Noise, no termination, long stubs Shielded twisted pair, 120 Ω ends, daisy chain
Exception code 02 Illegal data address Wrong register address or offset (0- vs 1-based)
Exception code 03 Illegal data value Value out of range or wrong scaling
Moves but weak grip Force set too low Check force units in the map
Works alone, fails with others Duplicate slave IDs Give each device a unique ID

FAQ

Can I control an electric gripper with Modbus RTU and I/O at the same time?
It depends on the model’s mode settings. Many grippers let you choose one main control mode. Check the manual, or ask us for your model.

How many grippers can share one RS485 bus?
Modbus allows slave IDs 1–247, but the practical limit depends on the RS485 transceivers and cable. Keep each gripper’s slave ID unique and poll them one after another.

Which Grippersupply grippers support Modbus RTU?
The EPG2, EPGC and ERG series, for example the EPG2-26-15, EPGC-50-150 and ERG-20-80. The EPGS series (EPGS-6-10, EPGS-12-15) uses I/O control.

Where do I get the register map and wiring diagram?
Contact us on WhatsApp or by email with your model, and we will send the register map for that gripper.

Do I need a separate controller?
Not for our EPG/ERG grippers: the controller is built into the gripper. You only need DC 24 V and your Modbus master.

Can I buy one gripper to test Modbus integration?
Yes. MOQ is 1 piece. Lead time confirmed on quote.

Get the register map and a quote

Application review

Turn the guide into a model shortlist.

Share your application details and we will help narrow the gripper series, stroke, force range, and control method before quotation.

Get Selection Help
Next reading

Related gripper guides