Resolving Value Discrepancies Between APL MonAnL Online CFC Blocks and WinCC OS Faceplates

Resolving Value Discrepancies Between APL MonAnL Online CFC Blocks and WinCC OS Faceplates

When a process value displayed on a WinCC OS faceplate (e.g., 0.62) does not match the live PV_Out value observed online in the CFC chart on an APL MonAnL block (e.g., 1.0), the root cause is an asynchronous tag database caused by uncompiled or undownloaded chart modifications. When block parameters, scales (Scale.High/Low), units, or chart structures are modified in the ES without subsequently executing an OS Compile and OS Download, the WinCC Tag Management database continues referencing outdated raw data tags or obsolete address offsets. To resolve this discrepancy, perform a complete CFC compilation with 'Generate module drivers', execute an OS Compile with 'Tags and screen objects' selected, and download the updated OS project to the target WinCC runtime station.

Table of Contents

Executive Summary

In SIMATIC PCS 7, the Advanced Process Library (APL) block MonAnL (FB1845) is the standard technological block utilized for monitoring continuous analog process measurements, executing limit checks, generating alarms, and delivering standardized data to WinCC operator faceplates. During commissioning, troubleshooting, or control strategy tuning, plant engineers sometimes discover that the process value (PV), engineering unit, or alarm threshold displayed in the WinCC runtime faceplate differs significantly from the value observed online inside the CFC chart.

Because WinCC does not poll individual CFC block pins dynamically via direct memory addresses, it relies on structured AS-OS tag mappings generated during the OS compilation process. If chart connections, scaling ranges, or block instances are updated in the engineering station without propagating those changes through an OS Compile and OS Download, the operator station continues to read from obsolete internal tags or outdated communication structures. This guide examines the fundamental AS-OS communication architecture of APL blocks, explains why value divergence occurs, provides a systematic diagnosis and resolution procedure, and details verification checks to ensure absolute runtime data integrity.

Architecture and Fundamental Mechanics

The data link between an AS-based APL block and a WinCC OS runtime faceplate operates through structured communication mechanisms established during OS compilation:
1. OCM Attribute and Block Instances: When MonAnL is instantiated in a CFC chart, its inputs and outputs flagged with the S7_m_c = true (Operator Control and Monitoring) attribute are earmarked for export to the WinCC Tag Management database.
2. Structure Tag Generation: During the OS Compile step, the WinCC compiler queries the CFC database and generates a corresponding WinCC Structure Tag Type (e.g., @MonAnL) and an instantiated structure tag matching the plant hierarchy path (e.g., Plant/Area/FIC_101).
3. Cyclical Tag Communication: WinCC communicates with the AS controller using S7 named connections or S7 fault-tolerant connections. It reads dynamic values (such as PV_Out.Value, PV_Out.ST, and status dwords Status1, Status2) using high-speed cyclical tag read requests or cyclic raw data services.
4. Root Causes of Discrepancy:
* Missing OS Compile/Download: If an engineer changes the raw input channel, adjusts the measuring range in Pcs7AnIn (e.g., changing scale from 0–100 to 0–500), or reconnects PV_In on MonAnL, but fails to compile and download the OS, WinCC reads cached data or outdated tag addresses.
* AS Program Download Inconsistency: If the OS was compiled against an updated offline CFC chart, but the user program was NOT downloaded to the AS controller, WinCC expects new tag structures that the running AS controller has not yet initialized, leading to stale or invalid data displays.
* Faceplate Tag Prefix Mismatch: If an unmanaged or manually copied block icon has an incorrect tag or tagprefix property, clicking it opens a faceplate linked to a completely different block instance.
* Format / Unit / Scale Caching: Faceplates calculate display percentages and scale bars using internal WinCC auxiliary tags (#Scale.High, #Scale.Low). If these tags were not refreshed by an OS compile, the faceplate applies obsolete scaling mathematics to the live process value.

Step-by-Step Implementation Procedure

Step 1: Verify Online Values and Tag Addressing in CFC

  1. Open the target CFC chart in the engineering station and enter Test Mode (Debug > Test Mode).
  2. Locate the MonAnL block (FB1845) in question.
  3. Add PV_In, PV_Out, and Scale to the watch list or monitor them directly on the block pins.
  4. Verify the exact values: record the current PV_Out.Value (e.g., 1.0) and the signal status byte PV_Out.ST (e.g., 16#80 for Good).
  5. Check the Scale parameter: confirm Scale.High and Scale.Low values.

Step 2: Inspect WinCC Tag Management and Tag Prefix

  1. Open WinCC Explorer on the ES (or target OS server).
  2. Navigate to Tag Management > SIMATIC S7 Protocol Suite > Named Connections (or Industrial Ethernet).
  3. Locate the tag group corresponding to the AS controller and find the structure tag for your MonAnL block.
  4. Open the WinCC runtime faceplate in Graphics Designer or in active Runtime.
  5. If testing in Runtime, check the block icon properties in Graphics Designer: ensure the Tag attribute matches the exact hierarchy path of the CFC block without typos.

Step 3: Perform Full Compilation of CFC and Module Drivers

  1. In SIMATIC Manager, select the Charts folder in the S7 Program.
  2. Select Chart > Compile > Changes only (or Entire program if inconsistencies exist).
  3. Ensure Generate module drivers is CHECKED.
  4. Complete the compilation and download changes to the AS controller (Target System > Download > Changes).

Step 4: Execute OS Compilation (AS-OS Engineering)

  1. In SIMATIC Manager, select the OS station object, right-click, and select Compile.
  2. In the OS Compile wizard:
    * Select the target S7 Program and the corresponding WinCC connection.
    * Ensure the compile scope includes 'Tags and screen objects'.
    * Select 'Changes only' (or select 'Entire project' with memory reset if major structural changes occurred).
  3. Click Next and initiate the compile.
  4. Confirm that the compile finishes with zero errors.

Step 5: Download the OS and Verify Runtime Synchronization

  1. In SIMATIC Manager, right-click the OS station and select Target System > Download.
  2. Select 'Changes only' if WinCC Runtime is active, or download the full project during a planned maintenance window.
  3. On the OS runtime station, verify that the faceplate refreshes.

Verification

  1. In WinCC Runtime, locate the block icon on the process picture and click it to open the MonAnL standard faceplate.
  2. Compare the digital process value display in the faceplate against the live PV_Out.Value monitored in the CFC chart.
  3. Confirm that both values match exactly (e.g., both display 1.0).
  4. Modify the input signal on the AS controller (or toggle test input values) and confirm that changes in CFC are instantly reflected in the WinCC faceplate within the configured update cycle (typically 500 ms to 1 s).
  5. Verify that high/low alarm limits and engineering units (Unit parameter) displayed in the faceplate match the CFC block inputs.

Limitations and Operational Precautions

  1. Performing an OS compile with 'Entire project' and memory reset requires stopping WinCC Runtime or briefly interrupting process visualization on single-station setups.
  2. If the faceplate was customized with hardcoded C-scripts or modified VBS actions, updating standard APL libraries will not repair customized script errors.
  3. Modifying block input parameters marked with S7_m_c = true offline will not impact WinCC until both AS download and OS compile/download are completed.
  4. Ensure network communication between ES, OS, and AS is stable; communication bottlenecks or high packet loss on the plant bus can cause delayed tag updates.

Engineer FAQ

Why didn't my CFC parameter changes appear in WinCC automatically?

PCS 7 requires a two-step synchronization workflow: changes made in CFC charts must be downloaded to the AS controller and compiled into the WinCC Tag Management database via an OS Compile.

What does PV_Out.ST represent on an APL block?

It represents the Signal Status byte conforming to IEC 61158. A value of 16#80 indicates valid ('Good') data; values such as 16#00 or 16#28 indicate bad or uncertain signal quality.

Can I update only a single block tag in WinCC without compiling the whole OS?

No. PCS 7 enforces central data management. Tag structures are created and updated exclusively by the OS compiler to prevent database divergence and tag naming errors.

Why does the faceplate show 0.62 when the block output is 1.0?

The faceplate may be reading an outdated structure tag from a previous block instantiation, or the faceplate scaling parameters (Scale.High/Scale.Low) were changed in CFC without an OS compile, causing the faceplate script to scale the value incorrectly.

Do I need to restart WinCC Runtime after an OS Changes download?

No. Downloading 'Changes only' to an OS Server or Single Station applies updated tag mappings and modified picture screens dynamically without requiring a WinCC runtime shutdown.

Technical References

Related Articles

Related Tags

  • MonAnL
  • APL
  • OS Compile
  • WinCC Faceplates
  • Tag Management
20 respuestas