Cookie
Electronic Team, Inc. uses cookies to personalize your experience on our website. By continuing to use this site, you agree to our cookie policy. Click here to learn more.

How to read
Modbus data?

In this article, I will tell you how to read and record Modbus data using the most advanced Modbus reader program - Serial Port Monitor. If you are considering integrating the Modbus standard within your local device network or are an active user of Modbus, this tutorial will be helpful for you.

Modbus

Contents

  1. Modbus reader software
  2. What is Modbus?

Modbus Reader software


Serial Port Monitor is a professional RS485 Modbus reader and data logger utility designed to decode Modbus RTU and ASCII protocol data, read it, and record it for further analysis.

With this software, you will know how to read Modbus data and the traffic coming in and going out of serial devices communicating within a Modbus network. This app supports all serial ports, including RS232, RS422, and RS485.

The program is aimed at developers and testers of serial applications and hardware as well as any other specialists working with Modbus-based equipment and software. It helps to interpret or parse the messages received from or sent by your devices via serial interfaces.

One of the biggest advantages of Serial Port Monitor is its ability to show captured data in a convenient and readable format. There are four data visualizers that the app offers: Table view, Dump view, Line view, and Terminal view. It’s up to you to decide in which mode the data will be shown. You can enable one, two, or all of the visualizers at a time.

What’s also important is that the Serial Port Monitor comes with advanced built-in search and filtering options as well as the Terminal mode that allows executing text commands.

How to read Modbus data?

Here’s how to read Modbus data with this dedicated app:
  • 1.
    First, download the Serial Port Monitor and install it on your machine. blank
  • 2.
    Launch the app, and choose “Session > New session” on the menu. Record Modbus messages.
    Record Modbus messages
  • 3.
    In the “New monitoring session” window that will appear, select the viewing modes that will show the serial data captured during the session. New monitoring session.
    New monitoring session
  • 4.
    As you are going to read Modbus data, next you need to enable the Modbus view that will display Modbus data received and sent via your system’s COM ports.
    Read Modbus data
  • 5.
    If needed, check the “Start monitoring now” and “Start in new window” boxes. blank
  • 6.
    Now, choose which events to capture: Create/Close, Read/Write, Device Control. blank
  • 7.
    Hit “Start monitoring” and your Modbus reading session will be activated.Modbus data acquisition.
    Modbus data acquisition

Now, in the preferences of the Modbus view, you can set the required configuration. All you need to do is go to “Session > Preferences” and select the color for date time, header, structure, details, checksum, and errors. There you can also choose whether to read Modbus data as Modbus RTU or Modbus ASCII.

Some of the other powerful features supported by Modbus Recorder Software:



  • The solution allows identifying Modbus communication issues once they appear, as the tool monitors and displays data in real-time.

  • The app will also give you a way to start sniffing a COM interface even if it’s already in use by another app.

  • With this Modbus reader software, you’ll be able to monitor multiple RS485 ports simultaneously. All Modbus data coming in and going out of the port will be conveniently recorded in a single log based on the first-in-first-out method.

What is Modbus?


Modbus is a serial communication protocol used for transporting data over serial channels between electronic equipment. The standard Modbus communication is set in such a way that one device, Modbus Master, writes data to or requests data from other devices, Modbus Slaves, across a serial network. As a rule, there’s one Master and up to 247 Slaves in a Modbus network. The protocol uses RS-485, RS-422, and RS-232 interfaces, as well as Ethernet TCP/IP networks (Modbus TCP protocol) for data transfer.

How does it work?


As mentioned before, Modbus data can be transmitted via a serial channel connecting two COM-based devices. They communicate information as a series of ones and zeros (data bits) via a standard serial cable. Each bit is sent as a voltage. Modbus connection is rather fast and the normal transmission speed is 9600 baud. The data is sent in blocks of 8 bits called bytes, each of which is represented by one of the 256-character pairs from 00 to FF.

How does Modbus work

What is it used for?


Traditionally, Modbus is applied in industry for transmitting data from control devices to the central data gathering system. This can be a system that measures humidity or temperature and forwards the results to a supervisory computer. The protocol can also serve for connecting the control computer with a remote terminal unit (RTU) in SCADA (Supervisory Control and Data Acquisition) systems. There are Modbus protocol versions for serial communications (Modbus RTU and Modbus ASCII) and Ethernet connections (Modbus TCP).

Modbus Data Integrity


In industrial automation and instrumentation, maintaining data integrity is crucial. Sensor measurements must reach the controller unaltered, and configurations sent from a controller to a Modbus device must arrive intact.

Data corruption during transmission can lead to critical errors. For instance, if a temperature sensor measures 24°C but the transmitted value changes to 18°C due to flipped bits, the system’s response could be compromised.

To prevent such issues, the Modbus frame includes a checksum, essential for ensuring data integrity. This 2-byte checksum is calculated from each byte of the Device ID and PDU and then appended to the Modbus message. When a Modbus frame is received, the device recalculates the checksum and compares it with the transmitted one. If there’s a discrepancy, the device discards the corrupted data packet.

Modbus Distance and Speed


Modbus can operate over RS232, RS485, or Ethernet cables, each supporting different distances and speed limits. For instance, RS232 typically handles up to 50 feet at a 9600 baud rate.

Most installations use RS485, which can support distances up to 4,000 feet at speeds up to 115,200 baud. Ethernet, in contrast, generally supports up to 100 meters, limited by the network switch speeds.

Though Modbus RS-485 theoretically supports speeds up to 115,200 baud, practical applications rarely exceed 19,200 baud. Higher transfer rates are often unnecessary, and many slave devices aren’t equipped to handle extreme baud rates.



small logo Serial Port Monitor
#1 at Serial Port Software
Serial Port Monitor
Log and analyze serial port activity
4.8 rank based on 345+ users (Learn more)
Get a download link for your desktop
Submit your email address to get a link for quick download on your desktop and get started!
or