Restoring SIMATIC Safety Matrix Viewer in WinCC Runtime: Missing .cem Files, Internal Tags, and Transfer Workflow

Restoring SIMATIC Safety Matrix Viewer in WinCC Runtime: Missing .cem Files, Internal Tags, and Transfer Workflow

When migrating a SIMATIC PCS 7 project with Safety Matrix to V8.1, clicking a matrix block icon that opens an empty faceplate displaying 'Waiting for matrix file...' indicates that the Safety Matrix transfer step was omitted prior to OS compilation. The Safety Matrix Viewer relies on binary configuration files (.cem) and internal WinCC tags (*#MatrixFile, *#ServerPath, Cause/Effect raw tags) generated strictly during the Matrix Transfer workflow. Running a Full OS Compile without transferring the matrix purges unreferenced tags. To resolve this, open each matrix in the Safety Matrix Engineering Tool, execute 'Matrix -> Transfer' with OS generation enabled, compile CFC, and execute an OS Compilation.

Table of Contents

Safety Matrix Engineering and Runtime Architecture Pipeline

SIMATIC Safety Matrix is the certified Cause and Effect methodology used in SIMATIC PCS 7 for safety-instrumented systems (SIS / ESD). The engineering lifecycle spans two distinct software domains: the safety controller (F-CPU execution) and the operator station (Safety Matrix Viewer in WinCC Runtime).

The Safety Matrix Viewer faceplate (@PG_F_MATCTL.pdl) is an active ActiveX/OCX control. Rather than querying thousands of individual discrete tags across the network, the Viewer reads a compiled matrix description file (<MatrixName>.cem) stored locally in the WinCC project directory, while reading real-time cause/effect states via high-speed raw data tags (*#CauseRaw, *#EffectRaw).

Why the OS Compiler Purges Safety Matrix Internal Tags and .cem Files

During a major PCS 7 version upgrade (e.g. from V7.1 SP1 to V8.1), engineers frequently perform an OS Compilation with the option 'Entire OS' and 'With tags and create server data'. If the project was migrated without first re-running the Safety Matrix transfer tool:

  1. Missing Transfer Descriptors: The OS Compiler relies on temporary interchange files generated by the Safety Matrix tool. If no transfer was executed on the new ES, the compiler assumes the matrix associations are obsolete.
  2. Internal Tag Cleanup: The OS Compiler automatically deletes unreferenced internal tags. Tags such as <Matrix>#MatrixFile, <Matrix>#ServerPath, and raw communication channels are stripped from WinCC Tag Management.
  3. Missing File Repository: The compiler fails to create or populate the <OS_Project_Dir>\SafetyMatrix\ directory, leaving the .cem file missing. When an operator clicks the block icon, the Viewer opens, searches for the missing .cem file, and stalls indefinitely displaying 'Waiting for matrix file...'.

The Three-Phase Safety Matrix Workflow (Engineering, Transfer, OS Compile)

Restoring full functionality requires executing the complete three-phase pipeline in strict order:

  • Phase 1: Engineering & Consistency Check: In the Safety Matrix Tool, open the matrix, verify causes, effects, and intersections, and run Matrix -> Check to validate safety logic consistency.
  • Phase 2: Matrix Transfer: Execute Matrix -> Transfer. This critical step generates the F-CFC safety charts (F_SC_C, F_SC_E, F_MATCTL), assigns safety signatures, and exports the binary .cem runtime layout into the WinCC project hierarchy.
  • Phase 3: CFC and OS Compilation: Compile CFC charts (safety program generation), followed by an OS Compilation. The OS compiler detects the exported .cem file and generates the complete WinCC internal tag structure.

Re-establishing Internal Tags and WinCC SafetyMatrix Subfolders

When the Transfer and OS Compile complete successfully, verify that the WinCC environment reflects the required assets:

  • File System: Inside <Project_OS_Path>\SafetyMatrix\, the file <MatrixName>.cem must be present with an updated timestamp.
  • Tag Management: Under Internal Tags -> Safety Matrix, the following tag structures must exist:
  • <MatrixName>#MatrixFile (Text tag 8-bit containing filename)
  • <MatrixName>#ServerPath (Text tag 8-bit containing server directory path)
  • <MatrixName>#CauseRaw (Raw data tag for dynamic cause states)
  • <MatrixName>#EffectRaw (Raw data tag for dynamic effect states)
  • Server Packages: If operating a distributed OS architecture, update and load server data packages onto all OS Clients.

Diagnostic Matrix: Safety Matrix Viewer Runtime Faults

The following table summarizes common Safety Matrix Viewer faults and their engineering remedies:

Runtime SymptomRoot CauseDefinitive Corrective Action'Waiting for matrix file...'.cem file missing; internal tags purged by OS compileRun Matrix -> Transfer in Safety Matrix Tool; recompile OSMatrix faceplate opens completely blankSafety Matrix Viewer OCX not registeredRun regsvr32 on SafetyMatrixViewer.ocx on OS stationMatrix layout shows; dynamic values staleRaw data communication tags disconnectedCheck S7 connection status; verify *#CauseRaw tag in WinCCBypass / Reset buttons disabledMissing Safety Matrix operator authorizationIn WinCC User Administrator, assign authorization level for Safety MatrixTransfer error: F-signature mismatchMatrix edited without safety passwordEnter safety engineering password; verify F-runtime groups in CFC

Step-by-Step Restoration Procedure in PCS 7 V8.1

Follow this exact sequence to restore the Safety Matrix Viewer in PCS 7 V8.1:

  1. In SIMATIC Manager, open the Safety Matrix folder in Component View.
  2. Double-click the target Safety Matrix to open the Safety Matrix Engineering Tool V6.2 SP1.
  3. Select Matrix -> Check to verify error-free logic.
  4. Select Matrix -> Transfer. In the transfer dialog, ensure the checkboxes for Generate F-Blocks and Transfer OS Data are checked. Click OK.
  5. Open SIMATIC Manager and compile CFC charts (Charts -> Compile -> Changes Only).
  6. Compile the OS project (Right-click OS -> Compile -> Entire OS / With Tags).
  7. In WinCC Explorer, verify that <OS_Dir>\SafetyMatrix\<MatrixName>.cem exists.
  8. Launch WinCC Runtime, click the matrix block icon, and confirm instant faceplate rendering.

Verification

Confirm that the Safety Matrix Viewer operates correctly in runtime:

  1. In WinCC Runtime, click the Safety Matrix block icon (@F_MATCTL/1).
  2. Verify that the faceplate opens within 1 second, displaying the full cause-and-effect grid with live colored status tiles.
  3. In the Safety Matrix Engineering Tool, turn on Online Mode; confirm that online cell states in engineering match WinCC Runtime identically.
  4. Verify that operator bypass, maintenance override, and reset functions operate according to configured user authorizations.

Limitations and Operational Precautions

Adhere to the following safety precautions:

  • Safety Program Re-Compilation: Executing Matrix -> Transfer regenerates F-CFC charts and may alter the safety program collective signature (F-Signature). Verify safety signatures in the Safety Program dialog prior to downloading to redundant F-CPUs.
  • Client Licensing: Dedicated OS Clients viewing Safety Matrix faceplates require the SIMATIC Safety Matrix Viewer runtime license.
  • Version Alignment: Ensure that the installed Safety Matrix Engineering Tool and Safety Matrix Viewer versions match identically across Engineering Stations and OS Servers.

Engineer FAQ

Does executing 'Matrix -> Transfer' modify the safety program signature?

Yes. If causes, effects, or intersection logic were modified, transferring the matrix regenerates the underlying F-blocks in CFC, which updates the collective safety signature.

Can I copy the .cem file manually into the WinCC project folder?

Copying the .cem file manually restores the visual grid layout, but without running the transfer and OS compile, dynamic raw data tags will be missing and live states will not update.

What license is required to view Safety Matrix faceplates on OS Clients?

Each OS Client displaying the matrix faceplate requires the 'SIMATIC Safety Matrix Viewer' license in Automation License Manager.

Technical References

Related Articles

Related Tags

  • Safety Matrix
  • Waiting for Matrix File
  • Matrix Transfer
  • Safety Matrix Viewer
  • F-Systems
  • WinCC Runtime Faceplate
6 respuestas