Modbus RTU to Modbus TCP protocol converter Development

CASE STUDY SNAPSHOT

Customer : A start up in industrial automation sector
Size : < 50
Project vertical : Industrial Automation
Challenge : Manufacture a Modbus RTU to Modbus TCP Protocol Converter
Solution : Design and develop a NXP LPC54616 based Modbus RTU to Modbus TCP Converter optimized for production
Services Availed :  Turnkey Product Engineering, RAPIDSEA Modbus Stack, Embedded Application Development, DFM Services
Tools and Technologies :
  • MPU/MCU: NXP LPC54616
  • Framework: RAPIDSEA
  • Programming Language: C
  • Compiler: GCC
  • Tools: MCU Expresso

INTRODUCTION

Modbus, an application protocol instrumental in transferring discrete/analog I/O information and register data between industrial control and monitoring devices, plays a foundational role in the industrial Internet of Things (IIoT) ecosystem. Facilitating communication using a master-slave (client-server) technique, it has two primary variants: Modbus RTU and Modbus TCP. Each variant serves distinct applications, leveraging different communication mediums - serial vs TCP/IP and addressing diverse requirements within the industrial sector. Our customer wanted to develop a Modbus RTU to Modbus TCP protocol converter. This comprehensive case study delves into the nuances of this Modbus gateway product development.

CHALLENGE

The following aspects had to be considered for the success of the Modbus RTU to Modbus TCP protocol converter product.

  • Simplicity: Designed with user experience in mind, ensuring a straightforward setup process.
  • Efficiency: Facilitates fast and reliable data transfer between Modbus RTU and Modbus TCP protocols.
  • Versatility: Adaptable to various industrial environments, enhancing its applicability across numerous sectors.
  • Ease of Use: Technicians had to set the Modbus gateway quickly and without much effort and impacting the existing setup.

SOLUTION

The Modbus gateway solution was designed around NXP LPC54616 MCU as it supported both the Ethernet interface and Serial interface to support Modbus/TCP and Modbus/RTU respectively. A 3-port Ethernet switch was added in the design to enable daisy chaining of the Ethernet network as adding this protocol converter must not impact the existing network. RS485 transceiver was added on the serial interface enabling connection to 200+ devices. A configuration switch was provided along with a few LEDs to help users understand the present state of the protocol converter and change the settings as needed.

The entire design was protected against electromagnetic interference and components chosen to ensure compliance for CE certification. A DIN Rail mount was decided for the product considering the universal presence of the rail in an industrial environment. Our mechanical design team worked on the nuances of the enclosure and validated them with rapid prototyping technologies. PCB design was done with that form factor in consideration. The connectors were placed at optimal locations to achieve a good user experience in consultation with our industrial design partners. The entire design was aligned with the customer branding.

Firmware Design

The embedded firmware for the Modbus gateway was developed with our RAPIDSEA stacks to accelerate the development time. The RAPDISEA Modbus server stack was utilized on the Modbus/TCP side while the Modbus Client stack was deployed on the RTU side. A custom request pipe-lining mechanism was designed to enable data transfer between these two interfaces seamlessly. The configuration was stored in the EEPROM and FreeRTOS was used as the underlying OS for the design. To enhance the security, Modbus over SSL was supported so that the communication can be optionally encrypted with TLS based security technologies.

User Interface

Since the communication parameters such as RTU baud rate, parity, timings, IP settings etc. had to be fine-tuned, it was decided to add an embedded web server. Upon pressing the configuration button in the Modbus RTU to Modbus TCP protocol converter, the server will be active for a few minutes within which the user can configure the gateway parameters. LED indications were given to show the operational status and diagnostic information to the user. The firmware for the device could be updated through the web interface itself without any need for another interface.

Mass Production Support

The Modbus RTU to Modbus TCP protocol converter prototype was thoroughly validated by our QA team and tested for both functionality and performance. The Modbus part was tested with the Modbus conformance tools and validated. After limited trials in the field, the mass production of the gateway was done. The enclosure was manufactured using injection molding techniques and the BoM was optimized to reduce overall costing. With support from our EMS ecosystem, the customer was able to scale up his production to meet the market needs. Our adeptness at crafting solutions that significantly bolster connectivity and functionality, reaffirming our status as pioneers in facilitating advanced industrial Internet of Things applications.

BENEFITS

Below, we outline the key results and advantages realized by the customer through this Modbus RTU to Modbus TCP protocol converter development:

  • Enhanced Speed of development: Our product engineering team designed and developed the Modbus gateway very quickly.
  • Cost-Effectiveness: Our BoM was optimized for the lowest cost possible and leveraging the RAPIDSEA Modbus stacks reduced to overall cost of development.
  • Ease of Configuration: With the built-in web server, the device can be configured easily with help of a web-browser
  • Network Security and Integration: Embien offered Modbus TCP with cybersecurity features by providing TLS 1.2 and TLS 1.3 support, optionally.
  • Scalability and Network Topology: With an in-built Ethernet switch, the product could be used to scale the network without the need for external devices there by supporting a wide range of network layouts.
  • DIN Rail Mounting: With the standard form factor and mounting options, its integration was a known process and simplified incorporation into existing industrial setups.

CONCLUSION

Through a multi-faceted approach, we've ensured that our Modbus RTU to Modbus TCP protocol converter solution not only meets the technical requirements but also provides a user-friendly experience, reinforcing our commitment to innovation and efficiency in the industrial automation domain. Our large team of experts in the industrial protocol stacks including Modbus, BACnet, Ethernet/IP, Profibus, CANOpen, ProfiNet can help you realize customer-winning products like this Modbus gateway at highly attractive price points and add significant value thereby giving you a higher RoI than you would have anticipated.

Impressed by our capabilities for this Modbus RTU to Modbus TCP protocol converter development?
Create your own Modbus gateway or other converters leveraging our RAPIDSEA Modbus Stack!