← All Posts

Modbus RTU Troubleshooting: CRC Errors, Timeouts, and RS485 Wiring

Modbus RTU is the workhorse of industrial communication. It runs on Modbus over RS485 serial lines, connecting PLCs, VFDs, energy meters, temperature sensors, and countless other devices on factory floors, solar plants, and building management systems. When it works, it is invisible. When it breaks, the symptoms are confusing and the documentation scattered across device manuals that contradict each other on pin labels.

This guide walks through how to diagnose and fix every common Modbus RTU communication error, from no-response timeouts and CRC checksum failures to intermittent dropouts and wrong register values. For the fundamentals of the protocol itself, see our introduction to Modbus and our comparison of Modbus RTU vs TCP.

Common Modbus RTU Error Symptoms

Before reaching for an oscilloscope, classify the symptom. Each pattern points to a different root cause:

  • No response at all — The master sends a request and receives nothing back. Usually a wiring problem, wrong slave address, or serial parameter mismatch.
  • CRC error — A response arrives but the CRC-16 checksum does not match. The frame was corrupted in transit. Electrical noise, bad termination, or ground loops are the usual suspects.
  • Exception response — The slave responds with an error code (function code + 0x80). The frame is valid, but the device is rejecting the request. Wrong register address, unsupported function code, or value out of range.
  • Wrong data values — Responses are valid but the values make no sense. Typically a byte order problem (big-endian vs little-endian) or wrong register map.
  • Intermittent failures — Communication works sometimes but drops randomly. Often a timing issue, marginal wiring, or bus loading problem on multi-drop networks.
Symptom
Most Likely Cause
First Fix
No response
Wiring or address mismatch
Verify A/B polarity and slave address
CRC error
Noise or missing termination
Add 120Ω termination at bus ends
Exception code response
Invalid register or function code
Check device register map documentation
Wrong data values
Byte order mismatch
Swap word order (big/little endian)
Intermittent dropouts
Timing or bus loading
Increase inter-frame delay, check device count
Devices drop off under load
Excessive bus capacitance or grounding
Reduce cable length, add bias resistors

Physical Layer: RS485 Wiring Checks

The majority of Modbus RTU problems originate at the physical layer. Fix the wiring first before investigating protocol or timing issues.

A/B Polarity

RS485 uses a differential pair labeled A and B (sometimes D- and D+, or Data- and Data+). The single biggest source of no-response errors is swapped A and B lines. The problem is compounded because manufacturers do not agree on labeling:

  • Some label A as Data+ (mark condition, idle high) and B as Data- (space condition, idle low).
  • Others reverse this entirely. B&B Electronics, Modbus protocol specs, and many device manuals use opposite conventions.
  • The safest approach: if swapping the two wires makes communication work, they were reversed.

On a properly wired idle bus, the voltage difference between A and B should be negative (B higher than A in the EIA-485 standard convention). Measure with a multimeter: if you see a positive idle voltage, swap the lines.

Termination Resistors

RS485 signals travel as voltage waves along the cable. When the signal reaches an unterminated end, it reflects back and interferes with the original signal. This causes data corruption and CRC errors, especially at higher baud rates.

  • 120-ohm resistor between A and B at each end of the bus. Not at every device — only at the two physical endpoints.
  • Required when cable length exceeds roughly 10 meters or baud rate is above 19200.
  • Many USB-to-RS485 adapters and Modbus devices have built-in termination that can be enabled via jumper or DIP switch.
  • Do not add more than two termination resistors. Over-termination loads the bus and reduces signal amplitude.

Bias Resistors

When no device is transmitting, the RS485 bus is in an undefined state (floating). This can cause the receiver to interpret noise as start bits, generating garbage frames. Bias resistors hold the bus in a known idle state:

  • Pull-up resistor (680Ω to 1kΩ) from B to VCC (+5V).
  • Pull-down resistor (680Ω to 1kΩ) from A to GND.
  • Place biasing at one point on the bus, typically at the master end.
  • More critical on buses that use parity = None, since the receiver has fewer error-detection mechanisms.

Shield Grounding

Use shielded twisted-pair cable for Modbus RTU. Ground the shield at one point only (typically the master end) to prevent ground loops. Grounding at both ends creates a path for circulating currents that inject noise into the data lines. In environments with high electromagnetic interference (VFDs, motor controllers), proper shield grounding is the difference between reliable communication and constant CRC errors.

Wiring checklist: (1) Verify A/B polarity with a multimeter or by swapping. (2) Add 120Ω termination at both bus ends. (3) Add bias resistors at the master if the bus floats. (4) Use shielded twisted-pair cable. (5) Ground the shield at one point only. (6) Keep RS485 wiring away from VFDs and motor power cables.

Serial Parameter Verification

Every device on a Modbus RTU bus must agree on the serial configuration. A single mismatched parameter means no communication:

  • Baud rate — 9600, 19200, 38400, 115200 are common. All devices must match exactly. Start at 9600 if you are unsure of the device configuration.
  • Parity — Even, Odd, or None. Modbus specification recommends Even parity, but many devices default to None. This is a common mismatch.
  • Stop bits — 1 or 2. The Modbus spec requires 2 stop bits when using no parity, and 1 stop bit with even or odd parity. Not all devices enforce this, but the master should be configured to match.
  • Byte order (endianness) — Modbus uses big-endian by default (most significant byte first). Some devices send registers in little-endian or swap the word order in 32-bit values. If your data looks wrong but communication succeeds, byte order is the likely culprit.

The most reliable way to verify serial parameters is to connect a serial terminal and watch the raw bytes. If the baud rate is wrong, you will see garbage characters instead of structured frames. If parity is wrong, you may see occasional valid frames mixed with errors.

Reading Modbus RTU Frames

Understanding the raw hex frame is the core debugging skill for Modbus RTU. A frame consists of four parts: slave address, function code, data, and CRC. For background on the protocol structure, see what is Modbus.

Request Frame Example

A master requests 3 holding registers from slave 1, starting at register 107:

01 03 00 6B 00 03 76 87

  • 01 — Slave Address (1)
  • 03 — Function Code (Read Holding Registers)
  • 00 6B — Starting Address (107, big-endian)
  • 00 03 — Quantity of Registers (3)
  • 76 87 — CRC-16 (low byte first)

Response Frame Example

The slave responds with 6 data bytes (3 registers x 2 bytes each):

01 03 06 02 2B 00 00 00 64 F8 64

  • 01 — Slave Address (1)
  • 03 — Function Code (Read Holding Registers)
  • 06 — Byte Count (6 bytes follow)
  • 02 2B — Register 107 value (555)
  • 00 00 — Register 108 value (0)
  • 00 64 — Register 109 value (100)
  • F8 64 — CRC-16

Exception Response

When a slave rejects a request, it responds with the function code + 0x80 and an exception code:

01 86 02 C3 A1

  • 01 — Slave Address
  • 86 — Function Code 0x03 + 0x80 = 0x86 (exception)
  • 02 — Exception Code 02 (Illegal Data Address)
  • C3 A1 — CRC-16

Modbus Exception Codes

When you receive an exception response, the exception code tells you exactly what the device rejected:

Code
Name
Meaning
01
Illegal Function
Device does not support this function code
02
Illegal Data Address
Register address does not exist on this device
03
Illegal Data Value
Value is outside the acceptable range
04
Slave Device Failure
Internal device error (firmware bug, hardware fault)
05
Acknowledge
Command accepted, processing (long operation)
06
Slave Device Busy
Device is processing another request, retry later

Timing Issues

Modbus RTU defines strict timing rules. Violating them causes devices to misinterpret frames or drop them entirely:

  • Inter-character timeout — The maximum gap between consecutive bytes within a single frame. Must not exceed 1.5 character times. If a byte arrives after this gap, the receiver treats it as the start of a new frame. At 9600 baud with 11-bit characters (start + 8 data + parity + stop), one character time is about 1.15ms, so the inter-character timeout is roughly 1.7ms.
  • Inter-frame delay (t3.5) — A silent period of at least 3.5 character times must separate consecutive frames. At 9600 baud, this is about 4ms. The master must wait this long after the last byte of a response before sending the next request.
  • Turnaround delay — The time a slave takes to process a request and start transmitting a response. The Modbus specification allows up to 1 second. If your master timeout is set too short, it will give up before a slow device responds. Start with a 500ms timeout and increase if needed.

Timing problems are the most common cause of intermittent failures. A system that works at 9600 baud may break at 115200 because the inter-frame delays become proportionally shorter. If you are upgrading baud rates, verify that your master library inserts the correct t3.5 delay for the new speed.

Multi-Drop Bus Issues

RS485 supports up to 32 unit loads on a single bus (more with modern low-load transceivers). Multi-drop introduces problems that do not appear in a simple point-to-point setup:

  • Address conflicts — Two devices with the same slave address will both try to respond simultaneously, corrupting the bus. Symptoms include CRC errors that only happen when certain devices are addressed. Verify each device has a unique address.
  • Cumulative loading — Each device adds input impedance to the bus. With many devices, the signal amplitude drops below the receiver threshold. Use a repeater for buses approaching 32 devices or long cable runs.
  • Daisy-chain topology — RS485 must be wired as a daisy chain (line), not a star. Stubs (short branches off the main trunk) should be kept under 0.3 meters. Star wiring causes reflections at every junction.
  • Galvanic isolation — Devices powered from different sources can create ground potential differences that exceed the RS485 common-mode range (±7V). Isolated RS485 transceivers or repeaters solve this. This is a frequent issue in solar plants and building management systems where devices are spread across large physical areas.

Using a Serial Monitor to Capture Frames

The most effective debugging technique for Modbus RTU is to capture the actual traffic on the bus. A serial terminal with hex view lets you see exactly what is being transmitted and received, byte by byte.

Using MacTools Serial Terminal or a similar tool with protocol analysis:

  1. Connect the USB-to-RS485 adapter to the bus. Wire it in parallel with the existing master so you can observe both request and response traffic.
  2. Configure serial parameters to match the bus: baud rate, parity, stop bits.
  3. Enable hex view to see raw bytes. ASCII mode is useless for Modbus RTU since most bytes are non-printable.
  4. Capture traffic while the master polls. Look for: slave addresses that match your target device, function codes in each frame, CRC validation status, and response timing relative to requests.
  5. Analyze failures by comparing the captured frames against the expected format described above. A missing response means the slave never received the request or could not transmit. A response with invalid CRC means the frame was corrupted. An exception response means the request was received but rejected.

Step-by-Step Troubleshooting Flowchart

Follow this sequence to systematically isolate any Modbus RTU problem:

Troubleshooting sequence:

1. Verify power — Is the slave device powered on? Check status LEDs.
2. Check wiring — Confirm A/B polarity, continuity on both lines, and ground connection. Swap A/B if unsure.
3. Verify serial parameters — Baud rate, parity, stop bits must match on master and all slaves. Default to 9600/8/E/1 if unknown.
4. Confirm slave address — Read the device configuration (DIP switches, config software) and verify it matches what the master is sending.
5. Add termination — Place 120Ω resistors at both bus ends if cable is longer than a few meters.
6. Capture traffic — Use a serial monitor to see what is actually on the wire. Are requests leaving the master? Are responses coming back?
7. Check timing — Increase the master timeout to 500ms+. Add inter-frame delay of at least 4ms at 9600 baud.
8. Isolate the device — Remove all other devices from the bus. Test point-to-point. If it works, the problem is bus loading or address conflicts.
9. Check register map — Read the device documentation. Verify register addresses, data types, and byte order.
10. Replace hardware — If everything else checks out, suspect a failed RS485 transceiver on the device or adapter.

Symptom, Cause, and Fix Reference

Symptom
Root Cause
Fix
No response from any device
A/B wires swapped or disconnected
Verify continuity, swap A/B lines
No response from one device
Wrong slave address or baud rate
Check device config, verify address
CRC errors on all frames
Missing termination or ground loop
Add 120Ω termination, check shielding
CRC errors at high baud only
Signal reflections, cable too long
Reduce baud rate, add termination
Exception code 01
Unsupported function code
Use correct function code for device
Exception code 02
Register address out of range
Check device register map
Valid response, wrong values
Byte order mismatch
Swap words or bytes in master config
Works sometimes, fails under load
Bus overloaded, timing too tight
Reduce polling rate, increase delays
Communication degrades over distance
No termination, wrong cable type
Add termination, use shielded twisted pair

Frequently Asked Questions

What causes Modbus RTU CRC errors?

CRC errors on a Modbus RTU bus are caused by electrical noise, incorrect RS485 wiring (A/B polarity swapped), missing termination resistors, ground loops, or baud rate mismatch between master and slave. On long cable runs without 120-ohm termination, signal reflections corrupt the frame and produce invalid CRC values. Check wiring first, then verify serial parameters, then add termination resistors at both ends of the bus.

Why is my Modbus RTU slave not responding?

A Modbus RTU slave that returns no response typically indicates a physical layer problem or a serial configuration mismatch. Verify that the slave address in the request matches the device configuration, that baud rate, parity, and stop bits are identical on master and slave, and that the RS485 A and B lines are connected with correct polarity. Also check that the timeout setting on the master is long enough for the slave's response time, especially at lower baud rates.

How do I read a Modbus RTU frame in hex?

A Modbus RTU frame starts with the slave address (1 byte), followed by the function code (1 byte), then data bytes (variable length), and ends with a 2-byte CRC-16 checksum. For example, 01 03 02 00 0A F8 64 means slave address 1, function code 03 (Read Holding Registers), 2 data bytes (value 10 in decimal), and CRC F8 64. Use a serial monitor with Modbus protocol analysis to decode frames automatically.

Do I need termination resistors on RS485?

Yes, for cable runs longer than a few meters or baud rates above 9600. Place a 120-ohm resistor between the A and B lines at each end of the bus. This prevents signal reflections that cause data corruption. On short buses at low baud rates (under 1 meter at 9600 baud), termination may not be necessary, but it is good practice to include it. For multi-drop buses with more than 2 devices, termination is essential.

Debug Modbus RTU Faster

MacTools Serial Terminal captures and decodes Modbus RTU frames in real time on macOS. Hex view, CRC validation, timestamped logging, and user-space USB drivers for RS485 adapters. $9.99 one-time.

Get MacTools Serial Terminal

Poll Modbus Devices on macOS

MacTools Modbus Poll reads and writes holding registers, coils, and input registers over Modbus RTU and TCP. Built-in register monitoring, multi-poll scanning, and data logging. $19.99 one-time.

Get MacTools Modbus Poll

Related: Full SCADA System

Need continuous monitoring with dashboards, alarms, and trending across all your devices? Voltrus SCADA supports Modbus, OPC-UA, Siemens S7, Allen-Bradley, DNP3, BACnet, MQTT, and more. Lifetime license from $249.

Further Reading