Configuring CP143 FETCH/RECEIVE Communication with OPC Server

David Krause15 min read
Industrial NetworkingSiemensTutorial / How-to
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

1. Overview

The Siemens CP143 is a communications processor module for the SIMATIC S5-115U, S5-135U, and S5-155U PLC families. It connects an S5 station to an Industrial Ethernet (SINEC H1 / IEEE 802.3) network using the ISO Transport Class 4 protocol (also referred to as TF - Transport Friendly). When a new PC station running OPC server software must exchange process data with an S5 whose CP143 already serves another peer (such as a CEMAT SCADA station), the engineer faces a controlled integration task: add passive FETCH and RECEIVE jobs to the existing CP database without disturbing the in-service communication.

This reference documents the field-proven procedure to extend an existing CP143 with two new passive jobs (FETCH for PC-side polling reads, RECEIVE for PC-initiated writes), update the COM 143 TF database, burn the new EPROM image, and verify the new link with the existing CEMAT traffic unaffected. The only mandatory S5 program change is extending the SEND-ALL / RECEIVE-ALL loop bound to cover the new ANR (Auftragsnummer) values; no new FETCH or RECEIVE block calls are required for purely passive jobs.

2. System Architecture and Prerequisites

The reference architecture is one Industrial Ethernet segment carrying three logical nodes:

  • S5 station (CPU 115U/135U/155U) with one or two CP143 modules slotted in the central rack. Each CP occupies a physical slot and is referenced internally by an SSNR (Schnittstellennummer) interface number.
  • Existing CEMAT PC station that is already exchanging data with one of the CP143 modules via the SEND/RECEIVE mechanism.
  • New OPC server PC station equipped with an Industrial Ethernet adapter (Woodhead PCI2000ETH or equivalent) running SIMATIC NET OPC Server or any S5-compatible Fetch/Write OPC server.

Prerequisites:

  • COM 143 TF configuration software (Siemens order number 6GK1970-1AB10 or successor) and the COM 143 TF manual set (Volume 1/2 - CP 143 TF with NCM COM 143 TF).
  • Programming device (PG) with EPROM programming hardware for the CP143 memory submodule.
  • STEP 5 programming environment and a current offline copy of the S5 user program.
  • Current EPROM image backup of every CP143 already installed.
  • Documented slot position of every CP143 in the S5 rack (required to determine SSNR).
  • MAC address of every node on the segment, including the OPC server PC's Ethernet adapter.
  • Confirmed free ANR values in the target CP143's existing job table.

3. CP143 Protocol Fundamentals

The CP143 implements ISO Transport Class 4 over Industrial Ethernet. Each module can maintain up to 64 simultaneous logical jobs, each identified by the ANR parameter. Every job is classified by three orthogonal attributes that together determine the role of the S5 endpoint:

  • Direction — FETCH (PC reads from S5) or RECEIVE / WRITE (PC writes into S5).
  • TypeActive (S5 initiates the transfer, calling SEND in the S5 program) or Passive (S5 only responds to a request issued by the remote PC).
  • Priority1 (high, for time-critical process data) or 2 (low, for acknowledgements and SCADA polling).

For the new OPC server link, both new jobs are configured as Passive with Priority = 2 and Read/Write = J. Passive means the CP143 waits for an incoming request and replies without any S5 program intervention. Priority 2 is acceptable because the typical OPC polling cycle is 250-1000 ms — far slower than the S5 scan time, so the lower queue does not introduce latency. Setting Read/Write to J (Ja) allows the PC to use the same logical job for both FETCH and RECEIVE PDUs; the CP143 interprets the request type from the ISO Transport header and either returns data from the configured S5 area or accepts a write to it.

Note that this S5 transport stack is fundamentally different from the TCP-based S7 communication used by modern SIMATIC controllers. For a comparison of the modern approach, see the TIA Portal guide on communication connections to PC stations (S7-300/400/1500). The architectural principle of binding a remote MAC and TSAP to a logical connection is identical, but the transport stack is different.

4. COM 143 TF Database Configuration

COM 143 TF is the offline configuration tool that produces the EPROM image for the CP143 memory submodule. For the new OPC server connection, two new entries must be added to the connection database of the CP that will host the OPC traffic:

4.1 Job 1 — FETCH (passive)

Parameter Value Notes
ANR (Auftragsnummer) Next free number in CP job table Audit existing CEMAT jobs first; do not collide.
Direction FETCH Passive from S5 perspective.
Priority 2 Low — SCADA polling.
Read/Write J Allows both read and write on this job.
Local TSAP READREAD ISO Transport endpoint on the CP143 side.
Remote TSAP READREAD Must match the OPC server Fetch connection configuration.
Local MAC From SYSID field of EPROM database printout 6-byte hex, colon-delimited.
Remote MAC MAC of the OPC server PC's Ethernet adapter Woodhead PCI2000ETH label or ipconfig /all output.
Remote SSNR 0 No meaning for a PC partner — leave zero.
Data area (DB, DW range) Define per S5 memory layout Bounds the FETCH return buffer.

4.2 Job 2 — RECEIVE / WRITE (passive)

Parameter Value Notes
ANR Next free number (different from Job 1) One ANR per logical job.
Direction RECEIVE Passive from S5 perspective.
Priority 2 Match FETCH job priority.
Read/Write J Allows write PDUs on this job.
Local TSAP WRITWRIT ISO Transport endpoint on the CP143 side.
Remote TSAP WRITWRIT Must match OPC server Write connection configuration.
Local MAC Same SYSID as Job 1 Identical physical module.
Remote MAC Same as Job 1 Same PC partner.
Remote SSNR 0 PC has no SSNR.
Data area Same or different from Job 1 Bounds the write buffer.

Save the database, generate the EPROM image, and burn it onto the CP143 memory submodule. After insertion and power-cycle, the CP143 reads the database, registers the new jobs internally, and the RUN LED remains steady. Refer to the official CP 143 TF with NCM COM 143 TF Volume 1 of 2 manual for the full parameter reference and connection-table layout.

Critical note on Remote SSNR: The Remote SSNR field is reserved for the S5 interface number of a remote S5 station (used in active S5-to-S5 links where the SSNR is needed to route inside the remote rack). For a PC partner, this parameter is meaningless and must be left as 0. The TSAP pair (READREAD / WRITWRIT) is what actually identifies the connection endpoint to the ISO Transport layer.

5. S5 Program Block Configuration

The S5 user program must register every job on the CP143 with two organization blocks. They are typically FB 244 (SEND-ALL) and FB 245 (RECEIVE-ALL), although customer-named FBs are also used:

  • SEND-ALL — Called once per PLC cycle (OB 1). Activates every active job on the CP so the CP can transmit data on its own initiative.
  • RECEIVE-ALL — Called once per PLC cycle. Polls the CP for incoming data from passive jobs initiated by remote stations.

For the new passive FETCH / RECEIVE connection, the existing SEND-ALL and RECEIVE-ALL blocks are sufficient — provided they iterate over the full ANR range configured in the CP143 (typically ANR 1 to ANR 64). The CP143 accepts the request, executes the FETCH or RECEIVE internally, and exchanges data with the configured S5 memory area without any S5 program involvement.

Two cases require attention:

  1. Extending an existing CP (the case in this guide): If the existing SEND-ALL/RECEIVE-ALL blocks only iterate over a partial ANR range (e.g., ANR 1 to ANR 16 because only that many jobs were originally configured), the loop bounds must be extended to cover the new job numbers. This is the only mandatory S5 program change.
  2. Adding a second CP143 to the rack: Each CP has a distinct SSNR. The blocks must be called with the SSNR of the new CP, a SYNC block call is required to initialize the second CP, and a separate SEND-ALL/RECEIVE-ALL pair must iterate the ANRs of the new CP. This is more invasive than case 1.

6. PC Station and OPC Server Configuration

On the PC side, the Industrial Ethernet adapter (Woodhead PCI2000ETH) is bound to the segment using the MAC address entered as Remote MAC in the CP143 database. The OPC server is configured with two logical connections:

6.1 Fetch connection

  • Local TSAP: READREAD
  • Remote TSAP: READREAD
  • Local MAC: Woodhead PCI2000ETH MAC (card label / Device Manager / ipconfig /all)
  • Remote MAC: CP143 MAC (from SYSID)

6.2 Write connection

  • Local TSAP: WRITWRIT
  • Remote TSAP: WRITWRIT
  • Local MAC: Same as Fetch connection
  • Remote MAC: Same as Fetch connection

Leaving the Remote MAC or Remote SSNR as 00:00:00:00:00:00 / 0 in the OPC server is functionally acceptable because the ISO Transport layer resolves the endpoint via the TSAP pair, but populating them is best practice. Doing so allows the OPC server to validate the destination before issuing a request, which shortens connection establishment time and produces cleaner diagnostics in the trace log when troubleshooting intermittent faults.

7. MAC Address Discovery

Locate the CP143 local MAC address from the SYSID field in the COM 143 TF database printout. SYSID contains the 6-byte local MAC in colon-delimited hex format (for example, 08:00:06:01:02:03). Record this value and use it as the Remote MAC on the PC side and the Local MAC in any further COM 143 TF edits.

Locate the Woodhead PCI2000ETH MAC address from the physical card label or via Windows:

ipconfig /all

The entry under the Industrial Ethernet adapter shows the MAC. Update both MAC addresses in the COM 143 TF database, regenerate the EPROM, reinsert, power-cycle the CP143, and confirm the RUN LED stays steady and the PE/PI LED indicates an active Ethernet link.

8. ANR and SSNR Allocation

The ANR range on a single CP143 is 1 to 64. Each unique combination of direction, priority, and remote partner occupies one ANR. When the existing CEMAT communication already uses several ANRs, the new FETCH and RECEIVE jobs must use ANR values that are not already assigned. View the existing COM 143 TF database to identify free slots; document every assignment in a project spreadsheet for future reference.

The SSNR (Schnittstellennummer) is not configured in COM 143 TF — it is a hardware property of the CP slot position. In an S5-115U, the CP143 occupies a specific slot; the SSNR is the corresponding interface number that must be passed as a parameter to SEND-ALL, RECEIVE-ALL, SYNC, and any explicit SEND/RECEIVE FB calls in the S5 program. The COM 143 TF manual prints the SSNR mapping in its hardware configuration section.

If two CP143 modules are installed (one for CEMAT, one for OPC), each CP has a distinct SSNR, and the S5 program must call separate SEND-ALL/RECEIVE-ALL instances with the respective SSNR. The COM 143 TF database for each CP is independent.

9. Verification Procedure

  1. Insert the freshly programmed EPROM submodule into the CP143 and power-cycle. The RUN LED must light steady within 5 seconds; the PE/PI LED must indicate an active Ethernet link.
  2. Open the COM 143 TF diagnostic view (or read the CP143 LED pattern) and confirm the new FETCH and RECEIVE jobs are listed in the active job table.
  3. On the PC, start the OPC server with trace logging enabled. Confirm the Fetch connection transitions to Connected and the Write connection transitions to Connected.
  4. From the OPC client or test tool, perform a read against a known S5 flag (for example, F 0.0) and verify the returned value matches the physical state observed on the PG.
  5. Perform a write against a known S5 flag (for example, F 100.0) and verify the PLC program observes the change in OB 1.
  6. Read from a data block (for example, DB 10, DW 0) and verify content matches the PG online view.
  7. Write to a data block (for example, DB 10, DW 0) and verify via the PG online view that the new value persists.
  8. Poll a known CEMAT-only data point to confirm the existing CEMAT communication remains unaffected by the new OPC jobs.
  9. Repeat steps 4-7 with the OPC server restarted to confirm persistent connection behaviour across PC reboots.

If all checks pass, the configuration is complete. The OPC server can read and write any memory area (Inputs, Outputs, Flags, Data Blocks) of the S5 PLC within the bounds defined in the COM 143 TF job configuration.

10. Troubleshooting Matrix

Symptom Likely Cause Remediation
CP143 RUN LED flashes, then STOP Invalid or corrupted EPROM database Re-burn EPROM with COM 143 TF, verify checksum, reinsert
OPC server reports "Connection refused" on Fetch TSAP mismatch between CP143 job and OPC connection Verify TSAP strings match exactly (case-sensitive in some OPC servers)
OPC server reports "Connection timeout" MAC address mismatch or physical cable issue Ping CP143 MAC from PC; verify Ethernet link LED on Woodhead card; check hub/repeater
Reads return correct data, writes do not persist Read/Write flag in COM 143 TF set to N (read only) on RECEIVE job Set Read/Write = J on RECEIVE job and re-burn EPROM
CEMAT communication breaks after OPC connection added SEND-ALL/RECEIVE-ALL loop bound not extended to cover new ANR; CP database reset Restore previous EPROM; extend loop bound; test CEMAT first, then OPC
FETCH returns "Data area not configured" COM 143 TF job points to an S5 data area outside the configured range Verify DB number and DW range in COM 143 TF match OPC tag address
OPC connects but no data returned Passive job not registered due to missing RECEIVE-ALL call Verify RECEIVE-ALL is called in OB 1 with correct SSNR
Communication works for FETCH but not RECEIVE Only FETCH job added to COM 143 TF; RECEIVE job missing Add RECEIVE (Write) job with TSAP WRITWRIT, Read/Write = J
Multiple connection attempts from same PC fail CP143 has reached the 64-job limit Audit existing jobs; consolidate or add a second CP143 module
Intermittent timeouts during heavy PC polling Priority 2 queue saturated by lower-priority traffic Move time-critical tags to Priority 1 job; reduce OPC poll rate
OPC server logs "Invalid TSAP length" TSAP entered with leading/trailing whitespace or wrong length Re-enter TSAP as exact 8-character ASCII string READREAD / WRITWRIT
OPC server connects once then drops repeatedly RECEIVE-ALL not called, CP143 internal receive buffer overflows Confirm RECEIVE-ALL is unconditional in OB 1 with correct SSNR

11. Field-Proven Commissioning Tips

  • Always populate both Local and Remote MAC addresses in COM 143 TF. Leaving Remote MAC as zero works in some configurations but produces ambiguous diagnostics when troubleshooting intermittent faults years later.
  • Document every ANR assignment in a spreadsheet cross-referenced to the remote partner, direction, priority, and data area. This avoids silent ANR collisions when adding jobs years later.
  • When extending an existing CP, extend the SEND-ALL/RECEIVE-ALL loop bound by exactly the number of new ANRs — no more, no less — to minimize PLC scan-time impact. Each loop iteration consumes a small but measurable amount of OB 1 time.
  • If adding a second CP143, commission the CEMAT communication on the original CP first and leave it running for at least 24 hours before touching the new CP. This isolates any regression to the correct hardware change.
  • Use Priority 1 (not 2) for time-critical data such as safety-relevant flags or fast interlocks; reserve Priority 2 for SCADA polling.
  • Burn two copies of every EPROM image and label them with date and CP SSNR. EPROM failures are the most common cause of mysterious CP143 STOP faults and a backup image minimizes MTTR.
  • Keep the COM 143 TF project file (.pdb or equivalent) under version control alongside the STEP 5 project. This ensures the offline database can always be reproduced if the EPROM label is lost.

FAQ

How do I add a new OPC server connection to an existing CP143 in an S5 station?

Open the existing COM 143 TF database, add a new FETCH (passive) job and a new RECEIVE (passive) job using free ANR values with Priority = 2 and Read/Write = J. Set the Local MAC from the SYSID, the Remote MAC to the new PC Ethernet adapter, the TSAPs to READREAD and WRITWRIT respectively, and the Remote SSNR to 0. Generate the EPROM image, burn, reinsert, and confirm OPC connectivity from the PC side.

Do I need to add new FETCH and RECEIVE FBs to the S5 program when adding passive jobs?

No. For purely passive jobs, the CP143 handles the entire ISO Transport handshake internally and the S5 program does not need explicit FETCH or RECEIVE FB calls. The existing SEND-ALL and RECEIVE-ALL blocks are sufficient, provided their ANR loop bound is extended to cover the new job numbers.

What is the difference between SSNR and TSAP on the CP143?

SSNR (Schnittstellennummer) is the internal S5 interface number that identifies a CP slot in the rack and is passed as a parameter to SEND-ALL/RECEIVE-ALL blocks. TSAP (Transport Service Access Point) is the ISO Transport layer endpoint identifier exchanged between the CP143 and the remote PC for connection establishment. Both must be configured, but they serve different protocol layers.

How do I find the MAC address of a CP143 module?

Read the SYSID field from the COM 143 TF database printout for that CP. The SYSID contains the 6-byte Local MAC address in colon-delimited hex format. On the PC side, the Woodhead PCI2000ETH MAC is printed on the card label and visible in the Windows ipconfig /all output under the Industrial Ethernet adapter entry.

What happens if I set Remote SSNR to zero in the COM 143 TF database?

Setting Remote SSNR to zero is correct when the remote partner is a PC station — the SSNR has no meaning for a non-S5 device and is ignored by the CP143 at connection time. If the remote partner were another S5 with a CP143, the Remote SSNR would need to match the SSNR of the remote CP for routing inside the remote rack.

Can I run CEMAT and the new OPC server on the same CP143 simultaneously?

Yes, provided the total ANR count on that CP remains under 64 and the SEND-ALL/RECEIVE-ALL loop bound in OB 1 covers the union of all ANRs. If the CP is already near capacity, add a second CP143 and route the new OPC jobs through it with its own SSNR.

Back to blog