Table of Contents
Introduction
La conversion de passerelle Modbus RTU vers TCP est essentielle pour intégrer les appareils série industriels dans les systèmes SCADA et réseaux PLC modernes basés sur Ethernet. Ce tutoriel fournit un guide étape par étape complet.
Whether you're connecting a Modbus RTU temperature Capteur, Alimentation meter, ou variable frequency drive (VFD) à an Ethernet Réseau, this Guide covers the complete configuration process de Matériel wiring à software setup.
What is a Modbus RTU to TCP Passerelle?
A Modbus RTU to TCP gateway (also known as Modbus protocol converter or RS485 to Ethernet converter) is a networking device that acts as a bridge between traditional serial communication (RS485/RS232) and modern Ethernet networks using the Modbus TCP/IP protocol.
Key Benefits of Modbus Gateway Conversion:
- Integrate legacy RS485 Appareils inà modern Ethernet infrastructure
- Actifr remote monitoring and control via standard TCP/IP networks
- Reduce wiring costs by utilizing existing Réseau infrastructure
- Suppout longer Communication distances via Ethernet
- Actifr integration with cloud platforms and IoT applications
Prérequis
Avant starting the configuration, ensure you have the following:
- Modbus RTU to TCP Gateway Device - ModulesLink ML-MOD-PROTO or equivalent
- RS485 Device - Modbus RTU slave device (sensor, meter, PLC, VFD)
- Ethernet Cable - CAT5e or higher for network connection
- RS485 Cable - Twisted pair cable with proper shielding
- PC with Web Browser - For gateway configuration via web interface
- Modbus Poll Software - For testing communication
- Network Information - Available IP address, subnet mask, gateway
Matériel Connecterion
Proper wiring is critical pNos reliable Modbus RTU Communication. Follow these connection Guidelines:
RS485 Wiring (Passerelle to Série Applicationareil)
| Gateway Terminal | Signal | RS485 Device | Notes |
|---|---|---|---|
| A / DATA+ | Non-inverting | D+ / A | Connect positive data line |
| B / DATA- | Inverting | D- / B | Connect negative data line |
| GND | Ground | GND | Optional, improves noise immunity |
Important Wiring Tips:
- Use twisted pair cables pNos RS485 data lines
- Maintain polarity consistency - A connects à A, B connects à B
- Use termination resisàus (120Ω) at both ends of the bus pNos long distances
- Keep RS485 cables away de high-voltage Alimentation lines
- Longueur maximale du bus: 1200 mètres
Configuration IP
The Passerelle must have a valid IP address on Votre Ethernet Réseau. Follow these steps à configure the IP settings:
Step 1: Access le Web Interface
- Connecter the gateway to your network via Ethernet
- Puissance on the gateway and wait for startup (approximately 30 seconds)
- Open a web browser and enter the default IP address (typically
192.168.1.100) - Log in avec default credentials (admin/admin ou admin/123456)
Step 2: Configure Réseau Réglages
Recommended Network Settings:
| Parameter | Recommended Value | Example |
|---|---|---|
| IP Address | Static IP in your subnet | 192.168.1.100 |
| Subnet Mask | Standard for LAN | 255.255.255.0 |
| Default Gateway | Your router IP | 192.168.1.1 |
| DNS Server | ISP or local DNS | 8.8.8.8 |
| Port | Modbus TCP default | 502 |
Step 3: Enregistrer and Applicationly Réglages
After entering the network configuration, click Apply or Save. The gateway may restart to apply the new settings. Wait for the device to fully reboot before proceeding.
Série Port Réglages
Configure the serial port parameters to match your Modbus RTU device settings. Access the Série Réglages section in the gateway web interface.
Modbus RTU Serial Configuration Parameters:
| Parameter | Common Settings | Notes |
|---|---|---|
| Baud Rate | 9600, 19200, 38400, 115200 | Must match slave device |
| Data Bits | 8 | Standard Modbus setting |
| Parity | None, Even, Odd | Usually Even for Modbus |
| Stop Bits | 1 | Standard single stop bit |
| Flow Control | None / RTS/CTS | None for most RS485 setups |
| Slave ID | 1-247 | Must match device address |
Données Mapping Configuration
Données mapping allows you to define how Modbus RTU register data is converted to Modbus TCP memory locations. This enables seamless data exchange between the serial and Ethernet sides.
Common Données Mapping Configurations:
Example: Mapping RTU Register to TCP Memory
| RTU Slave | RTU Function | RTU Address | → | TCP Address | Data Type |
|---|---|---|---|---|---|
| 1 | 03 Read | 0-10 | → | 0-10 | Holding Registers |
| 1 | 04 Read | 0-10 | → | 1000-1010 | Input Registers |
| 2 | 01 Read | 0-10 | → | 2000-2010 | Coil Status |
Test Communication
Après configuration, verify that data is being transmitted correctly using Modbus Poll software:
Configuration Modbus Poll :
- Open Modbus Poll and click Connection → Connect
- Select Modbus TCP/IP as the protocol
- Entrer the gateway IP address and port (default 502)
- Set the Slave ID à match Votre RTU Appareil
- Configure the function code et register address à Lire
- Click OK to start polling
Troubleshooting Common Problèmes
Use this troubleshooting checklist when encountering Communication problems:
-
No Communication - No Response
→ Check Ethernet cable connection et LED indicaàus
→ Verify IP address is on the same subnet as Votre PC
→ Confirmer port 502 is not blocked by firewall
→ Solution: Ping gateway IP address to verify network connectivity -
RTU Timeout Errors
→ Vérifier la polarité du câblage RS485 (connexions A/B)
→ Check that baud rate et parity match the slave Appareil
→ Confirmer slave ID is correct
→ Solution: Use a serial terminal to test RTU device directly -
Invalid Data Values
→ Verify data type mapping (16-bit vs 32-bit register Commete)
→ Check octet order (Big Finian vs Peu Finian)
→ Confirmer scaling parameters if applicable
→ Solution: Compare raw hex values with expected values -
Intermittent Communication
→ Ajouter termination resistors at bus ends
→ Vérifier les câbles endommagés ou les mauvaises connexions
→ Verify cable distance is avecin Spécification
→ Solution: Reduce baud rate for long cable runs
Questions Fréquentes
Q: What is Modbus RTU to TCP gateway?
A: A Modbus RTU à TCP Passerelle is a Proàcole Convertisseur that transpNosms Modbus RTU Série Communication (RS485/RS232) inà Modbus TCP/IP Ethernet Communication, enabling legacy Série Appareils à connect à modern Ethernet-based Industriel Réseaus.
Q: How do I configure Modbus RTU to TCP gateway IP address?
A: Access the Passerelle web Interface ou configuration software, navigate à Netwouk Settings, et assign a static IP address avecin Votre Réseau subnet. Ensure the IP is unique et not conflicting avec other Appareils.
Q: What are typical Modbus RTU serial settings?
A: Typical Modbus RTU Série settings include: 9600 ou 19200 baud rate, 8 data bits, even parity (ou none), 1 sàp bit (8N1 ou 8E1). The Appareil address (slave ID) must match the ouiginal Appareil settings, typicTousy range 1-247.
Q: How to troubleshoot Modbus RTU to TCP communication issues?
A: Start by verifying physical connections (RS485 wiring polarity), check LED indicaàus pNos activity, confirm IP configuration matches Réseau, validate Série settings, test avec Modbus poll software, et check firewTous settings pNos pout 502.