Configuring ET 200SP CM PtP Modbus RTU Master Communication in SIMATIC PCS 7

Configuring ET 200SP CM PtP Modbus RTU Master Communication in SIMATIC PCS 7

In SIMATIC PCS 7, configuring the ET 200SP CM PtP serial communication module (6ES7137-6AA00-0BA0) for Modbus RTU Master operation requires utilizing the dedicated S7-300/S7-400 ET 200SP PtP block library rather than TIA Portal blocks. Communication is orchestrated in CFC charts using Comm_Load (FB 640) for port parameterization during CPU startup and Modbus_Master (FB 641) for cyclic polling of Modbus slave devices over RS-485, with data mapped directly to designated S7 data blocks.

Table of Contents

Hardware Architecture and Library Requirements in PCS 7

The SIMATIC ET 200SP distributed I/O system connects to PCS 7 automation stations (S7-400 / S7-410) via PROFINET IO using the High Feature interface module (IM 155-6 PN HF). Serial communications are provided by the CM PtP module (6ES7 137-6AA00-0BA0), which supports RS-232, RS-422, and RS-485 physical interfaces.

Engineers migrating from TIA Portal frequently encounter difficulty because the standard TIA instructions Modbus_Comm_Load and Modbus_Master cannot be imported directly into STEP 7 V5.6 / PCS 7 CFC.

In SIMATIC PCS 7:
* Dedicated Block Library: Modbus RTU communication utilizes the official Siemens block library: ET 200SP PtP Communication for SIMATIC S7-300/S7-400 (SIOS Entry ID 109477583 / 109748680).
* Core Function Blocks:
* Comm_Load (FB 640): Configures port protocol, baud rate, parity, flow control, and links the hardware port to internal memory structures.
* Modbus_Master (FB 641): Executes Modbus read and write requests (holding registers, input registers, coils) using Modbus function codes (01, 02, 03, 04, 05, 06, 16).
* Modbus_Slave (FB 642): Operates the port as a Modbus RTU slave responder if required.

+-------------------------------------------------------------+
| S7-400 / S7-410 Controller (PCS 7 CFC Program)              |
| 1. Comm_Load (FB 640): Initializes Baud, Parity, Port ID   |
| 2. Modbus_Master (FB 641): Polling Scheduler & DB Mapper   |
+-------------------------------------------------------------+
                              |
                              v PROFINET IO (IM 155-6 PN HF)
+-------------------------------------------------------------+
| ET 200SP Station: CM PtP Module (6ES7 137-6AA00-0BA0)       |
+-------------------------------------------------------------+
                              |
                              v RS-485 2-Wire Serial Bus
+-------------------------------------------------------------+
| Modbus RTU Slaves (Power Meters, Drives, Gas Analyzers)     |
+-------------------------------------------------------------+

Step-by-Step Configuration Procedure for Modbus RTU Master

Follow this procedure to configure the ET 200SP CM PtP module in HW Config and program the Modbus master logic in CFC.

Prerequisites

  • ET 200SP station inserted in HW Config with IM 155-6 PN HF and CM PtP module.
  • ET 200SP PtP library installed on the Engineering Station.
  • Physical 2-wire RS-485 cabling connected (Terminal 12 = Rx/Tx+, Terminal 14 = Rx/Tx-, Terminal 16 = Shield/GND).

Step 1: Configure the CM PtP Module in HW Config

  1. In SIMATIC Manager, open HW Config.
  2. Locate the CM PtP module in the ET 200SP rack.
  3. Double-click the module to open Properties.
  4. Under the Parameters tab:
    * Protocol: Select Freeport / Modbus RTU.
    * Interface: Select RS-485 (2-wire half duplex).
  5. Under the Addresses tab:
    * Note the assigned Hardware Diagnostic Address (or I/O base address, e.g., LADDR = 512).
  6. Click Save and Compile, and download the hardware configuration.

Step 2: Create Data Blocks for Send/Receive Buffers

  1. In SIMATIC Manager, create a global Data Block (e.g., DB 100) to hold Modbus poll data.
  2. Structure the DB with arrays matching the register counts to be read from field devices (e.g., Meter1_Registers: ARRAY[1..20] OF WORD).

Step 3: Configure Comm_Load in CFC

  1. Open a CFC chart assigned to startup (OB100) or cyclic execution (OB35).
  2. Insert an instance of Comm_Load (FB 640).
  3. Configure the input parameters:
    * PORT: Enter the hardware address of the CM PtP module from HW Config (e.g., 512).
    * BAUD: Set the baud rate (e.g., 9600 or 19200).
    * PARITY: Set parity (0 = None, 1 = Odd, 2 = Even).
    * MODE: Set to 4 (Modbus RTU).
    * MB_DB: Interconnect to the instance DB of the companion Modbus_Master block.
  4. Trigger REQ with an initialization pulse (e.g., from OB100 restart logic).

Step 4: Configure Modbus_Master in CFC

  1. In the cyclic chart (OB35), insert an instance of Modbus_Master (FB 641).
  2. Interconnect the parameters:
    * MB_ADDR: Modbus RTU slave address (e.g., 1 for Node 1).
    * MODE: 0 for Read, 1 for Write.
    * DATA_ADDR: Modbus register start address (e.g., 40001 for Holding Register 1).
    * DATA_LEN: Number of registers to read (e.g., 10).
    * DATA_PTR: Pointer to the destination data block (e.g., P#DB100.DBX0.0 WORD 10).
  3. Create a cyclic pulse timer (e.g., using TimerP or clock memory) to trigger REQ every 500ms once DONE or ERROR confirms previous cycle completion.

Verification

  • In CFC dynamic test mode, monitor the Modbus_Master block:
  • Confirm that DONE pulses true upon each completed polling cycle.
  • Confirm that ERROR remains 0 (false) and STATUS reports 16#0000 (idle/success).
  • Open data block DB 100 in monitor mode: verify that raw field registers (e.g., voltage, current, frequency) populate and dynamically fluctuate with process conditions.
  • Inspect physical LEDs on the CM PtP module: the green TX LED and RX LED must flicker cyclically in rapid succession.

Limitations and Operational Precautions

  • Half-Duplex Bus Polling: Modbus RTU RS-485 is strictly single-master. If polling multiple slave devices, requests must be queued sequentially; triggering multiple Modbus_Master requests simultaneously causes serial collision and bus lockups.
  • Termination Resistors: RS-485 networks require 120-ohm termination resistors at both physical cable ends. The ET 200SP CM PtP base unit does not have automated internal termination; external resistors or an active terminal must be connected.
  • Maximum Message Length: Modbus RTU frames are limited to a maximum of 256 bytes per transaction (equivalent to approximately 120 holding registers per read request).

Engineer FAQ

  • Can I use Modbus_Comm_Load from TIA Portal in PCS 7?
    No. TIA Portal instructions are compiled for S7-1200/1500 and cannot be imported into STEP 7 V5.6. You must install the dedicated S7-300/S7-400 ET 200SP PtP library.
  • How do I poll 10 different Modbus slave meters with one CM PtP?
    Implement a sequential polling state machine in CFC (or using a sequencer block) that increments MB_ADDR and updates DATA_PTR upon each DONE pulse.
  • What does status code 16#80C8 mean on Modbus_Master?
    Error 16#80C8 indicates a response timeout. Check RS-485 cable polarity (+ and - inversion), baud rate matching, slave address correctness, and bus termination.
  • Can the ET 200SP CM PtP communicate over RS-232?
    Yes. The CM PtP module supports RS-232, RS-422, and RS-485; the interface mode is selected in HW Config under module parameters.
  • Is an additional runtime license required for ET 200SP Modbus RTU?
    No. Unlike legacy CP 341 / CP 441 Modbus dongles, the ET 200SP PtP Modbus library does not require hardware dongles or software runtime licenses.

Technical References

  • Siemens Industry Online Support Entry ID 109477583: ET 200SP CM PtP Modbus RTU Library for SIMATIC S7-300 / S7-400.
  • Siemens System Manual: SIMATIC ET 200SP Distributed I/O System - CM PtP Module.
  • Modbus-IDA: Modbus Application Protocol Specification V1.1b3.

Related Articles

Related Tags

  • PCS 7
  • ET 200SP
  • Modbus RTU
  • Serial Communication
  • RS-485
  • CFC
  • STEP 7
  • Industrial Automation
20 respuestas