Resolving SFB14 Missing Error on S7-300 GET/PUT Communication

David Krause14 min read
S7-300SiemensTroubleshooting
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

Resolving SFB14 Missing Error on S7-300 GET/PUT Communication

This reference addresses a recurring STEP 7 / CFC compile-time failure when a user configures S7 communication between two Siemens SIMATIC S7-300 CPU 315-2 PN/DP controllers using the integrated PROFINET interface. The reported runtime/compile error is:

E: The system block SFB14 used in the program does not exist in the operating system of the CPU.

The error is not a hardware fault. It is a project-engineering defect caused by inserting the wrong block type (system function block SFB14) into a CPU whose firmware only provides the loadable function block FB14 "GET". The condition repeats on every 31x PN/DP, 31x-2 PN/DP, 31x-2 DP/PN, and 31xF-2 PN/DP generation that lacks a CPU-side SFB14 image. The fix involves correct block selection, correct project type, and proper NetPro binding.

1. Root Cause Analysis

The SFB14 / SFB15 naming convention differs between SIMATIC platforms. The S7-300 firmware contains a loadable copy of the GET/PUT logic, distributed as FB14 and FB15 in the Standard Library → Communication Blocks → CPU_300 folder. The S7-400 firmware contains those same functions as integrated system function blocks SFB14 / SFB15, located in the Standard Library → System Function Blocks folder and stamped into the CPU operating system at firmware build time.

When a CFC chart running on an S7-300 target references an SFB14 symbol directly, the SCL compiler cannot resolve it against the CPU's block catalog, because the catalog is delivered as a loadable FB, not a system SFB. The compiler emits the diagnostic above and refuses to download the resulting system data.

There are three engineering defects that produce the same error class:

  1. Drag-and-drop of SFB14 from the S7-400 system function block library into an S7-300 chart (or into a shared library used by both platforms).
  2. CFC chart compiled against the wrong target system family (target-system bit set to S7-400 in the block properties while the CPU is an S7-300).
  3. PCS7 master data library binding that re-routes the GET call to an SFB14 wrapper in a PCS7-specific catalog that is not present on a standard STEP 7 CPU 315-2 PN/DP.

2. Hardware and Firmware Context: CPU 315-2 PN/DP

The relevant order numbers of the CPU 315-2 PN/DP family are:

Order Number (MLFB) FW Version PN Interface Notes
6ES7315-2EH14-0AB0 V3.3 2-port switch Most common, with 2-port PN switch
6ES7315-2EH13-0AB0 V3.2 2-port switch Older variant
6ES7315-2FJ14-0AB0 V3.3 2-port switch F-variant (F-CPU)

On every CPU 315-2 PN/DP variant that supports S7 communication over PROFINET, the catalog delivered to STEP 7 contains FB14 "GET" and FB15 "PUT" as loadable function blocks in the S7-300 communication library. The catalog does not contain SFB14 or SFB15. Cross-referencing the CPU's online block folder (target system → BlocksSystem Data) confirms the absence of any SFBxx with a 14/15 index when the S7-300 target is selected.

Field tip: Always verify the catalog by going online (PLC → Accessible Nodes or PLC → Online → Diagnostic) and inspecting Block folder → System Blocks. The list of available system blocks for a 315-2 PN/DP running FW V3.3 is empty of any user-replaceable SFB14/15 entry.

3. Block Selection Rules: SFB vs FB by Platform

Function S7-300 / CPU_31x (loadable) S7-400 / CPU_41x-4H (system)
Read data from partner (GET) FB14 — Standard Library → Communication Blocks → CPU_300 SFB14 — Standard Library → System Function Blocks
Write data to partner (PUT) FB15 — Standard Library → Communication Blocks → CPU_300 SFB15 — Standard Library → System Function Blocks
Interrupt-driven receive (USEND/URCV) FB8 / FB9 (CPU_300) SFB8 / SFB9
Block-related status evaluation STATUS output on FB14/FB15 instance STATUS output on SFB14/15 instance / RET_VAL
Block family (header property) Family = FBs Family = SFBs
Number allocation Local FB number, can be renumbered Fixed system number, cannot be renumbered

For the S7-300 family the FB14/FB15 blocks must be present in the offline project under S7 Program → Blocks so the loader writes them to the CPU at download. The S7-300 firmware has no in-OS image of these blocks; the S7-400 firmware does have an in-OS image. Forgetting to drag FB14/FB15 from the Standard Library into the offline Blocks folder is the most common secondary cause of "block not found" errors at runtime, after the SFB14/FB14 confusion.

4. NetPro Configuration for S7 Connection

NetPro defines the S7 connection that the GET/PUT instance DB references. For two CPU 315-2 PN/DP units talking over the integrated PROFINET port, the procedure is:

  1. Open NetPro from SIMATIC Manager (or open the project, then Options → NetPro).
  2. Right-click the CPU 315-2 PN/DP node → Insert New Connection.
  3. Partner: the second CPU 315-2 PN/DP. Type: S7 connection.
  4. Local ID: the connection ID assigned by NetPro (e.g. 1). This ID must match the ID input of the FB14/FB15 instance.
  5. Confirm the partner IP address, subnet, and rack/slot.
  6. Compile and download NetPro to both CPUs. Connection establishment requires the connection configuration in both directions (active and passive).

The connection ID is critical: a mismatch between the NetPro-assigned ID and the ID wired to the FB instance causes STATUS = W#16#0001 (communication error, ID invalid).

5. CFC-Specific Considerations on S7-300

CFC is a Siemens optional package, order number 6ES7658-1EX08-0YA5 (CFC V8.0) at the time of the reported case. It supports S7-300 targets, but with platform-specific code generation. From the CFC for S7 manual, the target system selection in the block-type properties ("General" tab) drives the SCL back-end:

"In the 'General' tab, specify the block type properties before starting compilation (FB number, symbolic name, name (header), family, author, version) and specify the target system on which the block will be used. This information (S7-300/S7-400) is relevant for the startup blocks, since the SCL compiler needs to generate a different code for each target system."

For the S7-300 path the SCL compiler emits loadable FBs and inserts the corresponding FB14/FB15 instances in the S7 program. For the S7-400 path the compiler emits SFB14/SFB15 calls and expects the system blocks to exist in the CPU's OS image. If the target system setting drifts to S7-400 inside a CFC chart bound to an S7-300 CPU, the catalog mismatch described above occurs.

Engineering rule: Always verify the target-system bit of every CFC block-type instance. Open the chart, right-click the block icon → Object Properties → General → Target System. It must read S7-300 for the CPU 315-2 PN/DP family.

6. PCS7 vs STEP 7 Project Type

The reported case explicitly notes that a PCS7-type project does not communicate over the PN port, while a STEP 7-type project does. The two project types differ in:

Property STEP 7 Project PCS 7 Project
Master data library source Standard STEP 7 catalog PCS 7 APL / FBL catalog
CFC block type lookup CPU_300 / CPU_400 FBs only APL block library bindings
S7 connection ownership Direct NetPro S7 connection Indirect via PCS 7 connection pool
Compile target for SFB calls FB14/FB15 on S7-300 Resolves to APL/FBL wrappers, may emit SFB14 references
PN port usage for S7 comms Direct, works Restricted by PCS 7 plant view

If the project origin is PCS 7, the CFC chart may inherit PCS 7 block bindings that target the S7-400 system block catalog. For a CPU 315-2 PN/DP deployed outside a PCS 7 plant, the cleanest fix is to either (a) create a STEP 7 project, copy the CFC charts in, and re-resolve the block types to the CPU_300 family, or (b) verify the PCS 7 catalog is the correct, licensed one for that specific PCS 7 version and CPU 315-2 PN/DP FW.

7. Step-by-Step Resolution Procedure

7.1 Confirm the CPU and Firmware

  1. Open HW Config. Identify the MLFB and FW of the CPU 315-2 PN/DP. Typical FW V3.x supports S7 communication over PN.
  2. Right-click the CPU → Object Properties → Diagnostic. Confirm the integrated PROFINET interface is configured with an IP address and subnet.

7.2 Replace SFB14/SFB15 References with FB14/FB15

  1. In SIMATIC Manager, open the S7 program → Blocks.
  2. Delete any SFB14, SFB15, SFB8, SFB9 references that exist in the offline program.
  3. Open Standard Library → Communication Blocks → CPU_300.
  4. Drag FB14 GET, FB15 PUT (and FB8 USEND, FB9 URCV if used) into the offline Blocks folder. The blocks must reside in the offline S7 program so the loader can write them to the CPU.
  5. If using multi-instance DBs, allocate a separate instance DB per call (e.g., DB14 for GET, DB15 for PUT). Assign with LAD/STL/FBD → Instance DB.

7.3 Fix CFC Target-System Bit

  1. Open every CFC chart in the S7 program.
  2. Right-click the GET/PUT block instance → Object Properties → General.
  3. Set Target System = S7-300. Apply.
  4. Recompile the chart. The SCL back-end should now emit FB14/FB15 references and an instance DB.

7.4 Bind the NetPro Connection

  1. Open NetPro. Insert a new S7 connection between the two CPU 315-2 PN/DP nodes.
  2. Note the local Connection ID (default 1, may differ).
  3. Wire the ID input of the FB14/FB15 instance to that exact integer.
  4. Compile and download NetPro to both CPUs.

7.5 Compile and Download

  1. In SIMATIC Manager, mark the S7 program → BlocksCompile and Download Objects.
  2. During compile, watch the output window. Any remaining SFBxx not in the OS error is now eliminated.
  3. Download the entire program to the CPU 315-2 PN/DP. The download pushes FB14/FB15, instance DBs, and the NetPro system data blocks (SDB).

8. Verification

  1. Go online with the CPU. Open Blocks → System Blocks in the online view. Confirm FB14 and FB15 are present in the online block folder.
  2. Open the FB14 instance DB in monitor/modify. Force REQ := TRUE. The DONE, ERROR, and STATUS outputs update on the next OB1 cycle.
  3. Decode the STATUS word. Common values for FB14/FB15 on S7-300:
STATUS (hex) Meaning Action
0000 Job completed without error None
0001 Communication job in progress Wait
7000 / 7001 / 7002 Job active, no error Wait
8085 / 80A1 Connection / ID error Re-check NetPro, ID input
80B1 / 80B2 Partner CPU not reachable / not loaded Verify partner IP, FW, and that partner CPU is in RUN
80C3 / 80C4 Resource / temporary resource error on partner Reduce scan time, check partner CPU priority
8183 / 8184 / 8185 IO area / length / write protection error Verify ADDR_1/ADDR_2 area, length, and access rights
8x7F Internal error in SFB/FB, see manual Restart CPU
  1. Use the partner CPU's Monitor/Modify view to confirm the data has been written/read. A successful PUT writes to the partner's specified data area; a successful GET reads from it.
  2. Cycle the partner CPU through STOP/RUN to confirm the S7 connection re-establishes. STATUS should return to 0000 within a few OB1 cycles.

9. Error Matrix and Common Pitfalls

Symptom Likely Cause Fix
Compile error: SFB14/SFB15 not in OS Block placed from S7-400 catalog or PCS 7 catalog Replace with FB14/FB15 from CPU_300 library
Download error: FB14 not found in CPU FB14 not present in offline Blocks folder Drag FB14 from Standard Library → CPU_300 into the offline program
Runtime STATUS = 80A1 Connection ID mismatch between NetPro and FB input Reconcile ID input with NetPro-assigned connection ID
Runtime STATUS = 80B1 Partner CPU not in RUN or PN cable disconnected Check partner CPU state, link LEDs, IP ping from PG
Runtime STATUS = 8183 / 8184 Partner memory area / length invalid Re-verify ADDR_1 / ADDR_2 area pointer, ensure length is byte-aligned and within process image or DB
No SFB14 error but no data transfer NetPro not downloaded to partner CPU Download NetPro system data to both CPUs (active and passive end)
PCS 7 project: charts compile, runtime fails APL/FBL catalog binding to SFB14/15 wrappers Recreate project as STEP 7 type or install the PCS 7 library matching the CPU FW
FB14/FB15 numbered 14/15 conflict with user FBs Default FB numbers clash with user-allocated FBs Renumber user FBs to free numbers, or use different FB slot for GET/PUT (F-number ranges of CPU 315-2 PN/DP allow free selection within user FBs)

10. Alternative Communication Approaches

If the GET/PUT path remains problematic on a CPU 315-2 PN/DP, three officially supported alternatives exist:

  1. S7 Communication via BSEND / BRCV (FB12 / FB13 on S7-300): Block-oriented, larger data volumes, same PN port. Useful for variable-length data.
  2. Open Communication over TCP / ISO-on-TCP (FB63 / FB64 / FB65 / FB66 / FB67 / FB68 on S7-300, TCON, TSEND, TRCV, TDISCON, TUSEND, TURCV): The user manages the connection. Use this if the partner is non-Siemens or non-PROFINET-aware.
  3. PROFINET IO Data Record read/write (RDREC / WRREC, SFB52 / SFB53 on S7-400; FB52 / FB53 on S7-300): Useful for acyclic IO data exchange with PN IO devices.

Each of these blocks also has S7-300 vs S7-400 naming differences. Apply the same rule: the S7-300 catalog uses loadable FBs; the S7-400 catalog uses system SFBs.

11. Diagnostic Tools and Online Monitoring

Beyond STATUS decoding, the following STEP 7 / PCS 7 tools accelerate root-cause identification on the CPU 315-2 PN/DP PN port:

  • PLC → Diagnostics/Setting → Diagnostic Buffer: shows the timestamped event log, including SFB/FB calls that produced an error and the source line.
  • PLC → Accessible Nodes: confirms the CPU 315-2 PN/DP is reachable on the PN subnet.
  • NetPro → Connection Diagnostics: shows S7 connection state (established / not established / aborted) for every configured S7 connection.
  • SIMATIC Manager → Options → Set PG/PC Interface: ensure the PG/PC is on the same subnet as the CPU 315-2 PN/DP. For direct PN attachment, set the PG/PC interface to TCP/IP → Intel(R) ... with the appropriate NIC.
  • Wireshark or Siemens PRONETA for low-level PN frame inspection during commissioning.

12. Field Commissioning Notes

When bringing up S7 communication on the integrated PN port of the CPU 315-2 PN/DP, follow this order to avoid re-work:

  1. Configure both CPUs in HW Config with valid IP addresses on the same subnet.
  2. Download HW Config to both CPUs and cycle power if requested.
  3. Configure the S7 connection in NetPro. Verify the connection appears in the online SDB.
  4. Drag FB14/FB15 from the Standard Library into the offline Blocks folder. Do not use SFB14/SFB15 from the S7-400 catalog.
  5. Create the instance DBs (e.g., DB14 for GET, DB15 for PUT). Wire ID to the NetPro connection ID.
  6. In CFC, set every block instance target system to S7-300 before compile.
  7. Compile, then download the entire Blocks folder. Verify FB14/FB15 are listed in the online block folder.
  8. Set REQ := TRUE on the instance DB and monitor STATUS.
Safety note: When the CPU 315-2 PN/DP is used in a safety-relevant application (F-variant, e.g., 6ES7315-2FJ14-0AB0), the S7 communication over the integrated PN port for safety-relevant data must use the fail-safe blocks (FB14 with safety wrapper) and a safety-program structure. Non-safety S7 communication on a safety CPU must be isolated from the safety program; do not mix standard FB14/FB15 calls inside the safety runtime group.

13. Frequently Asked Questions

Why does STEP 7 report "SFB14 used in the program does not exist in the operating system of the CPU" on a CPU 315-2 PN/DP?

The error is triggered by a call to SFB14, which is an S7-400 system function block. The CPU 315-2 PN/DP firmware only provides FB14 (a loadable function block from Standard Library → Communication Blocks → CPU_300). Replace the SFB14 call with the FB14 from the CPU_300 library, place the FB in the offline Blocks folder, and recompile.

Can CFC be used to program S7 communication on a CPU 315-2 PN/DP?

Yes, with the optional package CFC for S7 (e.g., 6ES7658-1EX08-0YA5 for V8.0). The chart's block-instance target system must be set to S7-300, not S7-400. PCS 7 project type must be re-evaluated: a PCS 7 master data library binding may force the chart to look up SFB14/SFB15, which the CPU 315-2 PN/DP firmware does not contain.

How is the connection ID wired to FB14/FB15 in CFC?

Open the FB14 instance in CFC. Wire the ID input to the integer assigned by NetPro (typically 1, but may differ if multiple S7 connections are configured). The ID must match the local ID of the S7 connection in NetPro exactly. STATUS = 80A1 at runtime indicates an ID mismatch.

Is the integrated PROFINET port of the CPU 315-2 PN/DP usable for S7 communication?

Yes. From FW V2.x onward, the CPU 315-2 PN/DP supports S7 communication over its integrated PN port, with FB14/FB15 from the CPU_300 catalog. The port is a 2-port switch on most variants, so a daisy-chain topology is possible without an external switch. S7 communication and PROFINET IO can coexist on the same PN port.

What is the difference between GET/PUT on S7-300 vs S7-400 in terms of the catalog?

On the S7-300, GET is FB14 and PUT is FB15, both loadable FBs in the CPU_300 library. On the S7-400, the same functions are SFB14 and SFB15, system function blocks stored in the CPU's operating system image. The function is identical at the application interface (REQ, ID, NDR, DONE, ERROR, STATUS, ADDR_1, ADDR_2, RD_1, RD_2, SD_1, SD_2). Mixing the two platform catalogs produces the SFB14-not-in-OS error.

Why does a PCS 7 project fail where a STEP 7 project succeeds on the same CPU 315-2 PN/DP?

PCS 7 master data libraries bind CFC block types to the PCS 7 APL/FBL catalog. When the catalog resolves a GET/PUT call to a wrapper that emits SFB14/SFB15 references, the S7-300 CPU cannot satisfy the call. The fix is to either keep the project as a standard STEP 7 project, or install the PCS 7 library version that matches the CPU 315-2 PN/DP FW and PCS 7 release, and verify the APL block family is bound to FB14/FB15 for the S7-300 target system.

Back to blog