We may earn an affiliate commission when you visit our partners.
Course image
Emile Ackbarali

The Modbus protocol is the oldest and still by far the most popular automation protocol in the field of process automation and SCADA. Knowing how to create Modbus based networks that run on the RS485 serial communication standard is essential for any electrical technician and engineer working in these fields. Being able to integrate devices from different manufacturers is a skill that is in demand and will ultimately make you more valuable and marketable in the industry.

Read more

The Modbus protocol is the oldest and still by far the most popular automation protocol in the field of process automation and SCADA. Knowing how to create Modbus based networks that run on the RS485 serial communication standard is essential for any electrical technician and engineer working in these fields. Being able to integrate devices from different manufacturers is a skill that is in demand and will ultimately make you more valuable and marketable in the industry.

This course gives you the theory behind the Modbus Protocol as well as RS485. It then goes on to show you how they work together to create a Modbus RS485 network. Two freeware applications are then used to create a Modbus network right on your PC so you can see the communication in action. 

After completing this course, you will be able to integrate devices from the same manufacturers and different manufacturers, that are Modbus compliant, to form a complete seamless network.

Enroll now

What's inside

Learning objectives

  • The origins of the modbus protocol and rs485
  • Understand memory address vs. memory value
  • Memory addressing conventions
  • Typical device memory map
  • Protocol network messaging
  • Rs485 standard and device interconnection
  • Protocol data frame structure
  • Query - response cycle
  • Function codes and master commands
  • Modbus simulation using free simulation software
  • Troubleshooting and exception codes
  • Floating point data structure
  • Modbus communication with programmable logic controller
  • Full course support documentation
  • Show more
  • Show less

Syllabus

Introduction
If you did the "The 1-Hour Modbus RS485 Primer" Course
Accessing Attached Resources and Setting Optimal Video Resolution

The Modbus protocol is the widest used fieldbus protocol in the automation industry. Almost every piece of intelligent device supports the Modbus protocol, which means that a thorough working knowledge of it is essential to knowing how to interconnect devices from the same and different manufacturers together.

Our course goal is simple: To give you the knowledge that will allow you to interconnect devices from various manufacturers using the Modbus protocol over an RS485 network.

We strongly feel that this skill will make you very valuable and marketable in the field of SCADA and Process Automation.

Read more
Some History

Many have used the Modbus protocol for years without understanding the reason for it's existence. In this lecture we look at exactly why and how the Modbus protocol was created. Lecture outline:

Distributed Control Systems - expensive to purchase, operate and maintain
The advent of the PLC from Modicon Corporation
The need for PLC interconnection - the birth of Modbus
Modbus as a simple and open fieldbus
The rapid adoption and spread of Modbus

The precursor to USB was RS232. Besides being used in the computer industry, RS232 found many uses in the automation industry. Efforts to improve on RS232 for automation purposes lead to RS485. In this lecture we will look at:

The original use of RS232
Drawbacks of RS232 for automation
RS485 standard solves RS232 drawbacks
RS485 advantageous properties

Because the Modbus protocol is frequently implemented using an RS485 network, many believe that they depend on one another. This is simply not true. Both RS485 and Modbus can stand on their own in various applications. In this lecture we look at:

Modbus and RS485 key misconception
Modbus Protocol vs. RS485 Electrical Standard
Modbus used over multiple types of media
Why they are frequently implemented together
Course Problem to be Solved

Learning new concepts is always easier and much more effective when we can apply that concepts to a particular problem situation.

That is what we are going to do in this lecture.

In fact, from this point onward, we will refer to this problem at the end of each section of the remainder of this course, each time solving more and more of it until we completely solve it at the end.

The problem involves the interconnection of three PLC's via Modbus RS485 for the purpose of transferring data from two of them into a single one. The latter will then be responsible for transmitting the data wirelessly to a central point.

The Modbus Protocol Memory Map

When the Modbus protocol was developed, the specification implemented two different modes of operation: Modbus RTU and Modbus ASCII. In this lecture we will cover:

Modbus RTU vs. Modbus ASCII
Advantages of RTU over ASCII
Very high prevalence of Modbus RTU over ASCII

Devices that support the Modbus protocol have three things in common. They are the:

1. Microprocessor or Central Processing Unit
2. Modbus Memory
3. Communication Interface

Before we get into the specific way that Modbus memory is arranged, there are a few basic concepts about electronic memory in general that we must cover in this lecture. Lecture outline:

Memory divided into Memory Blocks
Memory Blocks have different sizes
Memory Address vs. Memory Value
PLC Memory block example to illustrate

Memory blocks can come in different sizes. They are designed in different sizes mostly according to their purpose within the device in which they are used. We look closely at the various sizes and uses of Memory blocks. Lecture outline:

Memory block size measured in Bits
Bit = binary digit, binary counting system
1-bit to 32-bit sizes
Typical uses of different sizes
Illustration of use through an example

Within every Modbus compliant device there will be a portion of the memory that will be dedicated to Modbus. This portion is known as the Modbus memory area or Modbus memory map. Lecture outline:

Modbus memory divided into 4 areas
Coils, Inputs, Input and Holding Registers
Memory area ranges and sizes
Purposes of each memory area
How the areas are linked to device I/O

Modbus memory is usually linked to the device I/O. However, more sophisticated devices will use memory for calculations and storage of cumulative or calculated values. This lecture looks at an example of this and explains why this evolution has taken place.

Many of the devices that are Modbus compliant that you will come across will most likely have some form of direct connection to physical parameters in the real world.

It could be anything, motor speed, pressure, temperature, switch or breaker position. These devices would most likely be tied to some form of sensor or actuator that would be interacting with the real world.

Now even though the Modbus memory areas of coils, inputs, input registers and holding registers would be the same from device to device, the usage of the individual memory blocks will most likely be different.

And this is where the device documentation will come in.

Now that we have covered Modbus memory mapping, we will look again now at our design challenge from Lecture 5 and see how Modbus memory applies to it and how we can start on our way toward the solution.

Modbus Protocol Network Messaging

In the previous section we learned all about how Modbus memory is arranged in devices that are Modbus compliant. In this lecture we will start a look at how the actual Modbus communication takes place among devices. Lecture outline:

Request - Respond system
Master/Slave architecture
Single Master - Multiple Slave system
Modbus master permanence

The Modbus Unit ID is a unique identifier given to every Modbus complaint device that is connected to a Modbus network. This Unit ID is essential to the proper operation of the network. Lecture outline:

Modbus Unit ID purpose
Role in network communication
Role in master/slave system
Illustration through example network

The Modbus master device on the network is the one that sends request messages to the slave devices on the network. All request commands, however, are not the same.

In this lecture we are going to look at the major types of request commands that a modbus master device can send to a slave.

Lecture outline:

Read Coil Status
Read Input Status
Read Holding Registers
Read Input Registers
Force Single Coil
Preset Single Register

In this lecture we look at the request commands in detail and explore the concept of block reads. Block reads is the particular way in which Modbus reads data. Lecture outline:

Data read in consecutive blocks only
Master start block and number of blocks
Illustration of block reads - Example

Now that we have covered Modbus messaging, we will look now again at our design challenge from Lecture 5 and see how Modbus messaging applies here and carry the solution still further toward being completely solved.

The RS485 Serial Communication Standard

RS485 is not a protocol but rather a Serial Communication Standard. In this lecture we will look at the characteristics of RS485 and it's physical connection arrangement. Lecture outline:

RS485 port details
Multi-drop connection arrangement
Two wire interconnection style

Every RS485 communications port has configuration parameters associated with it. In this lecture we take a look at these common communication parameters and their meanings. Lecture outline:

Baud Rate
Number of data bits
Number of stop bits
Parity error checking

Now that we have covered the RS485 standard, we will look now again at our design challenge from Lecture 5 and see how RS485 communication applies here.

This will bring us to the complete solution to our Modbus RS485 network problem.

After completing this section, you will be able to recognise Modbus data traffic enabling usage of Modbus software tools.

At this point in the course, we are going to move from a theoretical understanding of Modbus to a more practical view of it. 

The Query-Response cycle is the core of all Modbus communications. Almost all Modbus communication follows the format of the Query-Response cycle. To use the Modbus software tools to their fullest capacities, you must know the Query-Response cycle very well. 

Here we will be looking at the various sections that make up the Query as well as the Response byte streams. Each section will be identified and it's purpose explained. 

This is a short lecture making you aware of the notation that will be used for the rest of the course to describe a single byte in a byte stream. 

In this lecture we set up, using our application design problem, a scenario for an example where the Read Input Registers command must be used. In the lectures to come, we will use this example to create both the Query and Response byte streams.

In this lecture, we begin the process of building the query byte stream for the Read Input Registers example.

In this lecture, we continue the process of building the query byte stream for the Read Input Registers example.

In this lecture, we complete the process of building the query byte stream for the Read Input Registers example.

In this lecture, we begin the process of building the response byte stream for the Read Input Registers example.

In this lecture, we complete the process of building the response byte stream for the Read Input Registers example.

In this lecture we set up, using our application design problem, a scenario for an example where the Read Input Status command must be used. In the lectures to come, we will use this example to create both the Query and Response byte streams.

In this lecture, we build the query byte stream for the Read Input Status example.

In this lecture, we build the response byte stream for the Read Input Status example.

This section introduces you to Modbus software tools that will allow you to practically create and troubleshoot real Modbus RS485 networks.
Basic Guidelines

The 3 Modbus software tools are identified are their purposes given.

This lecture identifies the websites from which the Modbus software tools can be downloaded.

This lecture introduces Virtual Serial Port that allows the creation of a virtual Modbus network on your computer.

This lecture introduces the Modbus Master simulator known as Modscan32. 

This lecture introduces the Modbus Slave simulator known as Modsim32. 

The Modbus software tools are used to simulate a master slave query response cycle involving the Read Input Registers Command.

The mode of Modscan32 is switched to examine the actual byte streams simulated by the Modbus software tools.

The Modbus software tools are used to simulate a master slave query response cycle involving the Read Input Status Command.

The remaining Modbus functions are simulated using the Modbus software tools.

The Modbus software tools are used to simulate a master slave query response cycle involving the Read Holding Registers Command.

The Modbus software tools are used to simulate a master slave query response cycle involving the Read Coils Status Command.

The two remaining Modbus commands are write commands.

Where to go to get the CAS Modbus Scanner.

Using Modscan32 to view the data traffic in hexadecimal format.

In this lecture, two more instruments are added to the application design problem.

A look at the expected query-response cycle for the force single coil example from our application design problem,

Using the CAS Modbus Scanner and Modsim32 to simulate the force single coil command.

A look at the expected query-response cycle for the preset single register example from our application design problem,

Using the CAS Modbus Scanner and Modsim32 to simulate the preset single register command.

Modbus Exception Codes
Exception Codes
The Query-Response Cycle for an Exception Response
Simulating an Exception Response
Will look at the data type limitations of Modbus and how Floating Point solves it.

The limitation of the 16-bit memory block data type representation.

Single Precision and Double Precision floating point forms.

The sign/exponent/mantissa representation used in Floating Point values.

An online tool that is invaluable when dealing with Modbus related Floating Point communication.

Using Modscan32 and Modsim32 to simulate an actual Master-Slave Floating Point data exchange.

The challenge with Floating Point and Swapped Floating Point compatibility.

This is the real thing! Here I show you how to configure a real live PLC for Modbus communication.

Moving from Modbus simulation to a live physical device.

A look at the different physical characteristics of the Direct Logic 05 PLC.

All devices share these 2 common steps in their configuration for Modbus.

I show you my Direct Logic PLC and how it is powered and connected as it resides on my desk.

A look at the part of the documentation that deals with Modbus Port Configuration.

Using the DirectSoft 6 Configuration Software to configure Modbus

A look at how the native memory address and I/O map to standard Modbus addresses.

Switching the Communications Cable from Port 1 to Port 2

Closer look at the Modbus Mapping within the PLC.

Using Modscan32 to Read/Write for Coils.

Using Modscan32 to Read Input Statuses

Essential Documentation
Print These 2 Documents and Keep Them Close
Modbus History and Overview
Modbus RTU vs ASCII
Modbus Message Structure
Modbus Serial Transmission Modes
Modbus Addressing
Modbus Function Codes
RS485 Serial Communication Standard

Good to know

Know what's good
, what to watch for
, and possible dealbreakers
Covers skills, knowledge, and tools that are highly relevant to industry
Develops expertise in a particular topic or set of topics
Builds a strong foundation for beginners
Offers hands-on labs and interactive materials
Requires extensive background knowledge
Course software has a more recent version

Save this course

Save Mastering Modbus RS485 Network Communication to your list so you can find it easily later:
Save

Reviews summary

Modbus network communication

Learners say that this course offers largely positive instruction on the Modbus protocol and the simulation software used with it. While the course has been well received, students mention that it could be improved with the addition of insights on Modbus stack implementation.
Simulation software is a valuable asset.
"Explanation on ... simulation software is really good."
Instruction on Modbus protocol is strong.
"Explanation on Modbus Protocol is really good."
More instruction on Modbus stack implementation is advised.
"It could be more fruitful if the course includes insights on Modbus stack."
"As an example, Modbus stack implementation on a microcontroller."

Activities

Be better prepared before your course. Deepen your understanding during and after it. Supplement your coursework and achieve mastery of the topics covered in Mastering Modbus RS485 Network Communication with these activities:
Review Modbus Protocol Fundamentals
Refreshes essential concepts of the Modbus protocol, solidifying knowledge gained from previous coursework or experience, ensuring a strong foundation for further learning.
Browse courses on Modbus
Show steps
  • Review Modbus protocol basics.
  • Read the Modbus protocol specification.
  • Take a practice quiz.
Modbus for Industrial Networks: Programming and Design Guide
Provides a comprehensive understanding of the Modbus protocol, including its history, implementation, and troubleshooting, serving as a valuable resource for beginners or those seeking to refresh their knowledge.
Show steps
  • Read the book.
  • Highlight important concepts and make notes.
  • Complete the exercises at the end of each chapter.
Modbus Communication Packet Decoder Problem Set
Examines Modbus RTU and simulates communication between master and slave devices, fostering a deeper understanding of Modbus message formats.
Browse courses on Modbus
Show steps
  • Obtain a copy of the Modbus Communication Packet Decoder Problem Set.
  • Review the problem set instructions.
  • Work through each problem, simulating the communication process using Modscan32 and Modsim32.
Five other activities
Expand to see all activities and additional details
Show all eight activities
Create a Virtual Modbus Network
Constructs a virtual Modbus network using Virtual Serial Port, allowing students to explore Modbus communication and troubleshooting in a safe and controlled environment.
Browse courses on Modbus
Show steps
  • Download and install Virtual Serial Port software.
  • Create a virtual serial port pair.
  • Configure Modscan32 and Modsim32 to use the virtual serial ports.
  • Test the virtual Modbus network by simulating communication between master and slave devices.
Modbus Protocol Implementation Workshop
Offers hands-on experience in implementing the Modbus protocol through interactive exercises and demonstrations, enabling students to gain practical skills in configuring and troubleshooting Modbus networks.
Browse courses on Modbus
Show steps
  • Attend the workshop.
  • Participate in the hands-on exercises.
  • Ask questions and interact with the workshop instructor.
Develop a Modbus-Based Data Acquisition System
Combines knowledge of Modbus with data acquisition principles to design and build a system for collecting and transmitting data from sensors and devices, facilitating hands-on experience in industrial automation settings.
Browse courses on Modbus
Show steps
  • Define the requirements and specifications for the system.
  • Select appropriate sensors and data acquisition hardware.
  • Implement the Modbus communication protocol.
  • Configure the system for data acquisition and transmission.
  • Test and validate the system.
Design and Implement a Modbus-Enabled Device
Applies the principles of Modbus to design and implement a real-world device that can communicate using the Modbus protocol, fostering hands-on experience and practical application.
Browse courses on Modbus
Show steps
  • Identify the requirements and specifications for the device.
  • Select appropriate hardware and software components.
  • Implement the Modbus communication protocol.
  • Test and debug the device.
Write a Technical Article on Modbus Troubleshooting
Develops advanced problem-solving skills by guiding students through the process of identifying and resolving common Modbus communication issues, ultimately enhancing their ability to troubleshoot in real-world scenarios.
Browse courses on Modbus
Show steps
  • Gather information and resources on Modbus troubleshooting.
  • Organize and outline the structure of the article.
  • Write the article.
  • Review and edit the article.
  • Publish the article online or in a technical journal.

Career center

Learners who complete Mastering Modbus RS485 Network Communication will develop knowledge and skills that may be useful to these careers:
Electrical Engineer
Responsible for designing and developing electrical equipment. This includes power systems, lighting systems, and control systems. Electrical Engineers typically have a strong understanding of both electrical theory and practical engineering. The course "Mastering Modbus RS485 Network Communication" can help build a foundation for this role as it provides a thorough overview of the Modbus protocol and its implementation using the RS485 serial communication standard. This knowledge is essential for designing and troubleshooting Modbus-based networks.
Electrical Technician
Install, maintain, and repair electrical equipment. Electrical Technicians typically have a strong background in electrical theory and practical engineering. The course "Mastering Modbus RS485 Network Communication" can help build a foundation for this role as it provides a detailed overview of the Modbus protocol and its implementation using the RS485 serial communication standard.
Automation Engineer
Design, implement, and maintain automated systems. These systems may be used in a variety of industries, including manufacturing, transportation, and utilities. Automation Engineers typically have a strong background in electrical engineering, computer science, and control theory. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in automated systems.
Controls Engineer
Control Engineers apply engineering principles to design and implement control systems. These systems may be used to control industrial processes, building automation, or other applications. Control Engineers must have a strong understanding of control theory, feedback systems, and electrical engineering. The course "Mastering Modbus RS485 Network Communication" can be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in control systems.
Process Engineer
Responsible for the design, operation, and optimization of industrial processes. Process Engineers typically have a strong background in chemical engineering, mechanical engineering, or a related field. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in process control systems.
Field Service Engineer
Install, maintain, and repair electrical and electronic equipment in the field. Field Service Engineers typically have a strong background in electrical engineering or a related field. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in industrial networks.
Instrumentation Technician
Install, maintain, and calibrate instrumentation equipment. Instrumentation Technicians typically have a strong background in electronics and a working knowledge of industrial processes. The course "Mastering Modbus RS485 Network Communication" can help build a foundation for this role as it provides a detailed overview of the Modbus protocol and its use in industrial instrumentation systems.
Product Test Engineer
Design and execute test plans to ensure that products meet specifications. Product Test Engineers typically have a strong background in electrical engineering or a related field. The course "Mastering Modbus RS485 Network Communication" can help build a foundation for this role as it provides a detailed overview of the Modbus protocol and its use in product testing systems.
Industrial Electrician
Install, maintain, and repair electrical equipment in industrial settings. Industrial Electricians typically have a strong background in electrical theory and practical experience in industrial electrical systems. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in industrial networks.
Project Manager
Plan, execute, and close projects. Project Managers typically have a strong background in business administration or a related field. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in industrial projects.
Maintenance Mechanic
Perform maintenance and repairs on a variety of equipment, including electrical, mechanical, and hydraulic systems. Maintenance Mechanics typically have a strong background in practical engineering and a good understanding of how different systems work. The course "Mastering Modbus RS485 Network Communication" can help build a foundation for this role as it provides a detailed overview of the Modbus protocol and its use in industrial maintenance systems.
Sales Engineer
Sell and support technical products and services. Sales Engineers typically have a strong background in both engineering and sales. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in industrial systems. This knowledge can help Sales Engineers better understand the needs of their customers and provide them with the best possible solutions.
Quality Control Inspector
Inspect and test products to ensure that they meet quality standards. Quality Control Inspectors typically have a strong attention to detail and a good understanding of quality control principles. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in quality control systems.
Technical Writer
Write and edit technical documentation, such as user manuals, white papers, and training materials. Technical Writers typically have a strong background in writing and editing, as well as a good understanding of technical concepts. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in industrial systems. This knowledge can help Technical Writers better understand the subject matter they are writing about and create more accurate and informative documentation.
Professor
Teach and research in a college or university setting. Professors typically have a strong background in their field of expertise, as well as a commitment to teaching and research. The course "Mastering Modbus RS485 Network Communication" may be helpful for this role as it provides a detailed overview of the Modbus protocol and its use in industrial systems. This knowledge can help Professors better understand the subject matter they are teaching and develop more engaging and informative lectures and materials.

Reading list

We've selected nine books that we think will supplement your learning. Use these to develop background knowledge, enrich your coursework, and gain a deeper understanding of the topics covered in Mastering Modbus RS485 Network Communication.
Serves as a comprehensive resource for industrial communication technologies, including Modbus. It provides in-depth knowledge of the protocol's architecture, implementation, and troubleshooting.
Provides a hands-on approach to industrial automation, covering a range of topics including Modbus. It is suitable for learners who prefer a practical approach with real-world examples.
Jan Axelson's book deep dive into serial ports. The book will be of limited use to most students taking this course, but may be very helpful to a student who is already working extensively with serial ports.
Covers PLC programming using Structured Text, a language that has become popular for implementing Modbus communication. It is recommended for readers who want to learn PLC programming and its integration with Modbus.
Provides a solid foundation in PLC programming, which is essential for understanding Modbus implementation. It is suitable for beginners who want to learn the basics of PLC operation and programming.
Covers advanced PLC hardware and programming concepts, including the use of Modbus. It is suitable for experienced PLC programmers who want to expand their knowledge of Modbus implementation.
Is specific to the Siemens S7-1200 PLC, and is of limited use to a student taking this course.

Share

Help others find this course page by sharing it with your friends and followers:

Similar courses

Here are nine courses similar to Mastering Modbus RS485 Network Communication.
An Introduction to the HART Protocol
Most relevant
Enumerating the Network Infrastructure as a Forensics...
An Introduction to Profibus DP Networking
Ansible for Network Automation
Network Protocols and Architecture
Introduction to Cisco Automation and Software Defined...
BMS - Building management system
Master Network Automation with Python for Network...
402: Computer Communications and Networ
Our mission

OpenCourser helps millions of learners each year. People visit us to learn workspace skills, ace their exams, and nurture their curiosity.

Our extensive catalog contains over 50,000 courses and twice as many books. Browse by search, by topic, or even by career interests. We'll match you to the right resources quickly.

Find this site helpful? Tell a friend about us.

Affiliate disclosure

We're supported by our community of learners. When you purchase or subscribe to courses and programs or purchase books, we may earn a commission from our partners.

Your purchases help us maintain our catalog and keep our servers humming without ads.

Thank you for supporting OpenCourser.

© 2016 - 2024 OpenCourser