Integrating SIMATIC S7-1200 as PROFIBUS DP Slave to PCS 7 AS 410-5H via CM 1242-5 - I/O Mapping and Addressing Rules

Integrating SIMATIC S7-1200 as PROFIBUS DP Slave to PCS 7 AS 410-5H via CM 1242-5 - I/O Mapping and Addressing Rules

Integrating a SIMATIC S7-1200 controller (such as CPU 1214C) as a PROFIBUS DP slave to a SIMATIC PCS 7 AS 410-5H master via a CM 1242-5 communication module (6GK7242-5DX30-0XE0) is accomplished by importing the CM 1242-5 GSD file into PCS 7 HW Config and configuring consistent I/O transfer areas. If the hardware configuration reports 'Module not available' or asserts a Bus Fault (BF), the root cause is invariably an I/O mapping mismatch. Two fundamental rules must be strictly enforced: First, Inverse Direction Mapping—the configured Input bytes of the S7-1200 slave correspond to the Output bytes of the S7-400 master, and vice versa. Second, Configuration Parity—the exact number of bytes/words and consistency settings (Unit vs Total Length) must match 100% between TIA Portal and HW Config.

Table of Contents

Master-Slave Architecture: S7-400 (PCS 7) and S7-1200 (TIA Portal)

Modern process plants frequently interface packaged equipment skid controllers (such as chemical dosing packages, compressors, or water treatment skids) with the main plant Distributed Control System. A common skid architecture employs a compact SIMATIC S7-1200 PLC programmed in TIA Portal, which must transmit operating status and receive supervisory setpoints from the central PCS 7 AS 410-5H automation system.

Because the S7-1200 does not possess native PROFIBUS ports, a CM 1242-5 communication module (6GK7242-5DX30-0XE0) is attached to the S7-1200 rack to act as a PROFIBUS DP Slave. The PCS 7 S7-400 controller acts as the DP Master (either via onboard DP ports, CP 443-5 Extended, or via a Y-Link if connecting to a redundant H-system).

The Golden Rules of DP Slave I/O Mapping (Inverse Direction and Length Parity)

When establishing communication via GSD files, DP masters and slaves exchange data cyclically across shared buffer registers. Communication failures (such as 'Module not available' or flashing red BF LEDs) almost always result from violating two core configuration rules:

Configuration DimensionMaster Side (PCS 7 HW Config / S7-400)Slave Side (TIA Portal / S7-1200)Alignment RuleData Direction 1Outputs (Q): e.g., 16 Bytes (QW 512..526)Inputs (I): e.g., 16 Bytes (IW 64..78)Inverse Mapping: Master OUT $\rightarrow$ Slave INData Direction 2Inputs (I): e.g., 32 Bytes (IW 512..542)Outputs (Q): e.g., 32 Bytes (QW 64..94)Inverse Mapping: Slave OUT $\rightarrow$ Master INData Block LengthConfigured as e.g., '16 Bytes Consistent'Configured as e.g., '16 Bytes Consistent'Absolute Parity: Lengths must be 100% identicalConsistency TypeTotal Length ConsistencyTotal Length ConsistencyMust match (enables DPRD_DAT / DPWR_DAT)

If HW Config specifies 16 bytes for Slot 1 but TIA Portal configures 8 bytes or two separate 8-byte chunks, the DP master detects a configuration telegram parameter fault during startup, rejecting the slave connection.

Step-by-Step Configuration in HW Config and TIA Portal

To establish clean communication between the S7-400 and S7-1200, execute the following workflow:

1. Slave Configuration in TIA Portal (S7-1200):
- Open the S7-1200 project. In Device Configuration, select the CM 1242-5 module.
- Under Profibus Interface -> Operating Mode, select DP Slave.
- In the I-Device communication / Transfer areas table, define transfer slots:
- Slot 1: Type Input, Length 16 Bytes (S7-1200 receives commands from S7-400).
- Slot 2: Type Output, Length 32 Bytes (S7-1200 sends sensor data to S7-400).
- Compile and download hardware configuration to the S7-1200.

2. Master Configuration in STEP 7 / PCS 7 HW Config (S7-400):
- Install the CM 1242-5 GSD file (SIEM813E.GSD) via Options -> Install GSD Files.
- Locate the module in the catalog under PROFIBUS DP -> Additional Field Devices -> PLC -> SIMATIC -> CM 1242-5.
- Drag the CM 1242-5 onto the PROFIBUS DP master string (or behind a Y-Link for H-systems). Assign the matching DP address.
- Add matching I/O modules to the slave slots:
- Slot 1: Select 16 Bytes Output (consistent over entire length).
- Slot 2: Select 32 Bytes Input (consistent over entire length).
- Save, compile, and download HW Config to the S7-400.

3. CFC Chart Programming:
- In CFC, deploy system function blocks SFC14 (DPRD_DAT) to read consistent inputs and SFC15 (DPWR_DAT) to write consistent outputs cleanly to the configured peripheral addresses.

Verification

Confirm error-free communication across the PROFIBUS DP interface:

  1. LED Diagnostic Inspection: On the CM 1242-5 module, verify that the DIAG LED is solid green and the BF (Bus Fault) LED is completely OFF.
  2. HW Config Online Diagnostics: Open HW Config in online mode (Station -> Open Online). Confirm that the CM 1242-5 icon displays no red cross, slashed lines, or 'Module not available' warnings.
  3. Data Exchange Verification: In the S7-1200 program, force test values into the output byte buffer. Open the CFC chart on the PCS 7 AS and confirm that DPRD_DAT returns RET_VAL = 0 and renders the exact test values in the S7-400 data block.

Limitations and Operational Precautions

When integrating skid controllers via PROFIBUS DP slaves, observe these operational safeguards:

  • Y-Link Baud Rate Derating: If the CM 1242-5 connects to a redundant S7-400H system through a Y-Link, the maximum allowable baud rate on the lower DP slave loop is often limited to 1.5 Mbit/s. Ensure TIA Portal and HW Config baud rates match.
  • Direct Peripheral Access Prohibition: Do not use standard load/transfer instructions (L IW 512) for transfer areas configured with 'Total Length Consistency'. You must use SFC14 / SFC15 to avoid reading corrupted cross-word data.
  • Commercial Procurement and Licensing Disclaimer: The CM 1242-5 (6GK7242-5DX30-0XE0) is a dedicated hardware communication module. Verify exact part numbers, firmware versions, and distributor pricing when preparing skid procurement schedules.

Engineer FAQ

Can I program the S7-1200 PLC directly from SIMATIC PCS 7?

No. SIMATIC PCS 7 does not support S7-1200 or S7-1500 controllers in its engineering database. The S7-1200 must be engineered and programmed independently in TIA Portal.

Is it possible to communicate between S7-1200 and PCS 7 via Ethernet instead of PROFIBUS?

Yes. The S7-1200 and S7-400 can communicate over Industrial Ethernet using an unconfigured S7 connection with PUT and GET communication blocks (FB14 / FB15) executing in the S7-400 CPU.

Why does HW Config say 'Module not available' when the cable is plugged in?

'Module not available' in Siemens HW Config diagnostics indicates that the master cannot establish cyclic data exchange, almost always caused by a slot length or consistency mismatch between the master GSD configuration and the TIA Portal I-Device table.

Technical References

Related Articles

Related Tags

  • S7-1200
  • CM 1242-5
  • PROFIBUS DP Slave
  • AS 410-5H
  • SFC14
  • SFC15
6 respuestas