1. Overview
The CP 343-1 Lean (Siemens order number 6GK7 343-1CX10-0XE0) is a low-cost Ethernet communications processor for the S7-300 platform that supports open TCP/IP communication, including the Modbus TCP server role. When a process requires continuity of Modbus TCP connectivity to one or more third-party masters (PLCs, RTUs, SCADA), two CP 343-1 Lean modules can be deployed in a single S7-300 rack to provide a redundant Ethernet pathway. Two distinct deployment modes are supported by the Siemens firmware and add-on libraries:
- Parallel server mode – both CPs act as independent Modbus TCP servers bound to different client masters. There is no failover; each master has its own dedicated CP. This is the configuration Siemens confirms is permitted when two CPs are installed in the same rack.
-
Redundant connection mode – both CPs front the same logical Modbus server endpoint, and one CP is active while the other is standby. Add-on package ModbusTCP RED V2 (article number
2XV9 450-1MB11) is required for this configuration.
The source request specifies a manual switchover (button-press on HMI) rather than hot-standby failover. This article covers the full architectural decision tree, the required hardware and software, and the engineering steps required to implement either mode.
2. CP 343-1 Lean Hardware Specifications
| Parameter | Value |
|---|---|
| Article number (MLFB) | 6GK7 343-1CX10-0XE0 |
| Firmware release covered | V2.x / V3.x (Lean variant) |
| Ethernet ports | 1 × RJ45 10/100 Mbps |
| Supported protocols | TCP/IP, UDP, ISO-on-TCP, S7 communication, Modbus TCP (server, via add-on), PROFINET IO (limited), SNMP |
| Number of connections | Up to 8 S7 connections + 8 open-communication (TCP/ISO) connections (firmware-dependent) |
| IP assignment | Static, DHCP, or via STEP 7 / TIA Portal |
| Slot | S7-300 backplane, occupies one slot, no parameter slot required for CP function |
| Power consumption | Typical 5.8 W from backplane |
| Operating temperature | 0 °C to +60 °C |
| Diagnostic LEDs | SF (group fault), BF (bus fault), LINK, RX/TX, RUN, STOP |
Refer to the Siemens CP 343-1 Lean manual entry page (ID 77378511) for the current edition of the operating instructions. Section 8 of that manual – "Communication via two CP343-1" – is the specific reference Siemens support cites for dual-CP scenarios.
3. Modbus TCP Protocol Stack on the CP 343-1 Lean
Modbus TCP is a self-contained protocol encapsulated inside standard TCP/IP. The CP 343-1 Lean only supports the server role natively through the Modbus TCP add-on blocks (FB blocks MB_CLIENT / MB_SERVER are not available on S7-300; the Lean variant uses Siemens-supplied FB63 / FB64 / FB65 / FB66 family or the MODBUSPN library compiled for the CP).
3.1 Port allocation
- Default Modbus TCP port:
502 - Reserved connection ID range: assignable per CP, each TCP connection requires a free ID
- Each Modbus TCP connection consumes one open-communication (OUC) resource on the CP
3.2 Supported function codes (server side)
| FC | Function | Data type |
|---|---|---|
| 01 | Read Coils | Bit |
| 02 | Read Discrete Inputs | Bit |
| 03 | Read Holding Registers | Word |
| 04 | Read Input Registers | Word |
| 05 | Write Single Coil | Bit |
| 06 | Write Single Register | Word |
| 15 (0x0F) | Write Multiple Coils | Bit |
| 16 (0x10) | Write Multiple Registers | Word |
Function codes above 16 (file record, FIFO, etc.) are not part of the Modbus TCP add-on for the CP 343-1 Lean and must be rejected by the application if the master sends them.
4. Redundancy Architecture Options
Siemens explicitly distinguishes the two-CP scenario for S7-300/400 stations communicating with third-party devices. Per the manual reference quoted in support, the supported topologies are:
- S7-400 H station with two CPs – full redundancy tied to the H-CPU redundancy state.
- S7-300/400 station with two CPs to third-party devices – the case here; either parallel servers or application-managed redundant server.
For the CP 343-1 Lean in a non-H S7-300 rack, the redundancy is application-managed. The CPU itself decides which CP owns the Modbus TCP server role.
4.1 Option A – Two independent Modbus TCP servers
Each CP 343-1 Lean presents a separate Modbus server. CP-A may serve Master-A on subnet 192.168.10.0/24 with IP 192.168.10.10; CP-B serves Master-B on subnet 192.168.20.0/24 with IP 192.168.20.10. Each master reads/writes the same process image but via its own physical path. The CPs do not synchronize Modbus state – the application CPU is responsible for keeping the data coherent in both directions.
Advantage: zero add-on software, both masters see live data continuously.
Disadvantage: not a failover topology – if CP-A fails, Master-A loses connectivity.
4.2 Option B – Redundant CP pair (ModbusTCP RED V2)
Both CPs share the same Modbus register map; only one CP is the active server at a time. The standby CP is silent on port 502 until promoted. The CPU triggers promotion by writing to a control word inside the ModbusTCP RED V2 library, which can be wired to an HMI button. This matches the "button press to switch over" requirement.
Required components:
- ModbusTCP RED V2 article number
2XV9 450-1MB11– contains the FB blocks, example project, and documentation. - Both CPs must have the same firmware major version (V2.x matched, or V3.x matched – do not mix a V2 Lean with a V3 Lean unless the RED V2 library release notes explicitly permit it).
- A free connection resource per CP on the CPU side.
5. Hardware Planning for Two CPs in One S7-300 Rack
5.1 Slot and backplane
The S7-300 backplane supports multiple CPs. Each CP occupies one slot. Both CPs must be on the same backplane segment that is serviced by the same CPU (rack 0, slots 1 to 11 for a 6ES7 390-1xxxxx UR, or extended rack via IM 360/361). Mixing CPs across different IM segments is permitted but introduces latency and is rarely used for redundancy.
5.2 Power budget
Add the CP consumption to the rack budget. Two CP 343-1 Lean modules draw 2 × 5.8 W = 11.6 W from the backplane, which must be subtracted from the PS 307 / PS 305 capacity:
P_PS_remaining = P_PS_rated - P_CPU - (N_DI * P_DI) - (N_DO * P_DO) - (N_AI * P_AI) - (N_AO * P_AO) - (N_CP * P_CP)
Example: a PS 307 5A module delivers 138 W. After subtracting CPU 315-2 PN/DP (≈10 W), 16 DI (≈3.5 W), 16 DO (≈5 W), 8 AI (≈2 W), 4 AO (≈4 W) and 2 × CP 343-1 Lean (≈11.6 W), ≈102 W remains for additional I/O and future expansion – well within budget.
6. STEP 7 (Classic) Configuration Procedure
6.1 Prerequisites
- STEP 7 V5.5 SP4 or later (with HF that supports CP 343-1 Lean V3.x firmware) OR TIA Portal V15.1 and later with CP 343-1 Lean HSP.
- GSD/GSDML not required – CP is inserted from the Siemens hardware catalog.
- ModbusTCP RED V2 install package (for Option B only).
6.2 Insert hardware
- Open the S7 project in STEP 7 / TIA Portal.
- In HW Config / Device View, drag two
CP 343-1 Lean (6GK7 343-1CX10-0XE0)modules into free slots of rack 0. - Assign unique IP addresses and subnet masks to each CP, e.g.:
CP-A: 192.168.10.10 / 255.255.255.0 CP-B: 192.168.20.10 / 255.255.255.0 - Assign the same MAC address pool (do not duplicate MAC addresses across the two CPs – Siemens sets unique MAC per module at delivery).
- Set the CP "Use Modbus/TCP" property flag in Properties → Parameters → Modbus.
6.3 Configure connections
Each CP exposes one or more Modbus server connections. Define them in NetPro / Connections:
| Connection | Local end point | Partner IP | Port | Connection type |
|---|---|---|---|---|
| CONN_1 | CP-A :502 | 192.168.10.50 | 502 | TCP passive (server) |
| CONN_2 | CP-B :502 | 192.168.20.50 | 502 | TCP passive (server) |
Compile and download the hardware configuration. The connection IDs are reported back to the OB1 / cyclic program for parameter wiring to FB blocks.
6.4 Program the Modbus server (Option A – independent servers)
Insert two instances of the Siemens Modbus TCP FB family (commonly FB63 MB_SND / FB64 MB_RCV in some libraries, or MODBUSPN server blocks supplied with the CP). Wire each instance to the connection ID returned by NetPro for its respective CP. The data buffer (DB) is shared between the two FBs – each master reads the same image, both writes propagate to the process.
// OB1 example (STL / LAD-style pseudo)
CALL FB63, DB100 // MB_SND via CP-A (ID = CONN_1)
LADDR := W#16#0100 // CP-A I/O start address
ID := 1 // CONN_1
LEN := 100 // bytes
DB_NR := 200 // data DB
DBB_NO := 0
CALL FB64, DB101 // MB_RCV via CP-A
...
CALL FB63, DB110 // MB_SND via CP-B (ID = CONN_2)
LADDR := W#16#0200 // CP-B I/O start address
ID := 2
...
6.5 Program the redundant server (Option B – ModbusTCP RED V2)
- Install the RED V2 library; it ships the FBs
MOD_RED_V2(control),MOD_RED_DIAG(diagnostics), and the data blockMOD_RED_DB. - Insert
MOD_RED_V2in OB1 with the two CP connection IDs. - Map the control word
MOD_RED_DB.SWITCH_ACTIVE_CPto an HMI tag. A0selects CP-A; a1selects CP-B. - Map the status word to HMI for diagnostics (
ACTIVE_CP,CP_A_OK,CP_B_OK).
7. HMI Logic for Manual Switchover
Because the application uses an HMI button rather than automatic failover, the controller logic should:
- Read
CP_A_OKandCP_B_OKfrom the RED V2 status block. - Accept the operator command only if the requested target CP is healthy.
- On command rising edge, set
SWITCH_ACTIVE_CPto the requested value and toggle aSWITCH_PENDINGflag. - Reset
SWITCH_PENDINGwhenACTIVE_CPreflects the new value.
A typical TIA Portal WinCC tag mapping is shown below:
| HMI tag | PLC tag | Direction |
|---|---|---|
| cmdSwitchCP | DB_RED.cmdSwitchCP : BOOL | HMI → PLC |
| varActiveCP | DB_RED.varActiveCP : INT | PLC → HMI |
| varCPA_OK | DB_RED.varCPA_OK : BOOL | PLC → HMI |
| varCPB_OK | DB_RED.varCPB_OK : BOOL | PLC → HMI |
8. Network Topology
Two physical Ethernet segments should be used so that a switch failure or cable break does not take down both paths:
+-----------+ +-------------+ +-----------+
| Master A |--------| Switch A |--------| CP-A |
+-----------+ +-------------+ | (S7-300) |
+-----------+
+-----------+ +-------------+ +-----------+
| Master B |--------| Switch B |--------| CP-B |
+-----------+ +-------------+ | (S7-300) |
+-----------+
+-------------+
| CPU 315 |
+-------------+
If both masters can share one physical network, a single managed switch with VLAN segmentation is acceptable. If the masters are remote and separated by a WAN, configure independent VPN paths.
9. Diagnostics and Fault Codes
9.1 CP LED indications
| LED | State | Meaning |
|---|---|---|
| SF (red) | ON | Group fault – firmware/configuration error |
| BF (red) | ON | Bus fault – no physical link or no IP negotiation |
| LINK (green) | ON | Ethernet link established |
| RX/TX (yellow flash) | flickering | Frame activity |
| RUN (green) | ON | CP operating normally |
| STOP (yellow) | ON | CP not in RUN |
9.2 ModbusTCP RED V2 status codes
| Status word bit | Meaning |
|---|---|
| 0 (CP_A_OK) | CP-A healthy and ready |
| 1 (CP_B_OK) | CP-B healthy and ready |
| 2 (ACTIVE_CP) | 0 = CP-A active, 1 = CP-B active |
| 3 (SWITCH_PENDING) | Switch request latched, transition in progress |
| 4 (DATA_INCOHERENT) | Standby CP has stale data buffer |
| 5..7 | Vendor-reserved |
9.3 Common fault causes
| Symptom | Likely cause | Remedy |
|---|---|---|
| BF LED on CP, no master connection | Cable/port fault or wrong subnet | Verify link LED; ping CP IP from a service laptop |
| Master sees only one CP responding | Both CPs share same IP | Re-assign distinct IPs in HW Config |
| Connection resets every few seconds | Connection resource clash (both CPs fighting same ID) | Re-allocate connection IDs in NetPro |
| SF LED after firmware update | FW mismatch between the two CPs | Update both to same firmware version |
| ModbusTCP RED V2 reports DATA_INCOHERENT persistently | Process image write from one CP not mirrored to the other | Inspect DB write paths – both CPs must receive the same image; consider using S7 PUT/GET or shared DB via backplane |
10. Verification Procedure
- Download the project to the CPU and both CPs.
- From a service laptop on subnet A, ping
192.168.10.10– should respond. - From a service laptop on subnet B, ping
192.168.20.10– should respond. - Use a Modbus TCP test tool (e.g., Modbus Poll, modbus-cli) to read holding registers from each CP independently. Confirm matching data.
- Press the HMI "Switch to CP-B" button. Observe
varActiveCPtransitioning from 0 to 1 within ≈2 s. - Issue a read from the master previously bound to CP-A through the new active CP. Confirm register values are unchanged.
- Physically disconnect the active CP's network cable. Confirm the RED V2 library reports the corresponding
CP_*_OKbit clearing within the diagnostic cycle (typically 1 s). - Reconnect cable and verify auto recovery (CP returns to ready, but stays standby unless explicitly re-promoted).
11. Engineering Caveats and Field Notes
- Connection resource budget: The CPU's open-communication connection pool is shared with HMI, S7 connections, and other TCP services. With two Modbus TCP servers plus HMI, verify CPU supports the connection count (e.g., CPU 315-2 PN/DP supports 16 total, with up to 8 reserved for S7/PG).
- Firmware consistency: Mixing a V2.x and V3.x CP 343-1 Lean in the same rack is permitted by STEP 7 but is not recommended for redundant configurations; pin both to the same major release.
- Cold start behaviour: After CPU STOP → RUN, ModbusTCP RED V2 starts with CP-A active by default. The HMI screen should reflect this on first scan.
- Wall-clock synchronisation: If both masters log timestamps, drive the timestamp from the CPU (one source of truth) rather than from the CP, because the active CP may change.
- Watchdog on switch command: Use a time-limited enable (e.g., 5 s window after button press) to prevent repeated toggling if the operator holds the button.
12. FAQ
Can two CP 343-1 Lean modules in the same S7-300 rack act as Modbus TCP servers to different clients?
Yes. Each CP presents an independent Modbus TCP server on its own IP address. Siemens confirms this configuration in section 8 of the CP 343-1 Lean manual. It is not redundant in the failover sense, but it is supported and requires no add-on package.
Which article number is required for redundant Modbus TCP failover on the CP 343-1 Lean?
The ModbusTCP RED V2 add-on library, article number 2XV9 450-1MB11. The earlier release 2XV9 450-1MB00 was referenced for a previous generation; for current V2.x / V3.x CP 343-1 Lean firmware use the -1MB11 release.
Do I need hot-standby failover, or can the switchover be manual?
How many Modbus TCP connections does a single CP 343-1 Lean support?
Firmware V2.x supports up to 8 open-communication (TCP/ISO-on-TCP) connections, shared with all other TCP services on the CP. Each Modbus TCP server connection consumes one of those resources. With two CPs the rack total is 16, minus any non-Modbus TCP usage.