Resolving MonAnL Remaining in Simulation Mode After Resetting SimOn on Pcs7AnIn

Resolving MonAnL Remaining in Simulation Mode After Resetting SimOn on Pcs7AnIn

In SIMATIC PCS 7 Advanced Process Library (APL), an analog monitoring block (MonAnL) will continue to display simulation status even after resetting the simulation flag (SimOn = 0) on the upstream channel driver (Pcs7AnIn) if simulation was also enabled locally on MonAnL or if quality code status tracking remains active. Technological blocks possess independent simulation inputs (SimOn) and quality status evaluators. If MonAnL was put into simulation via its WinCC faceplate or if the process value input (PV) continues to receive a simulated quality code (16#60), MonAnL maintains its simulation indication until both driver and technological simulation states are reset.

Table of Contents

APL Simulation Architecture: Driver Simulation vs Technological Block Simulation

In the SIMATIC PCS 7 Advanced Process Library (APL), simulation capabilities are implemented at two distinct hierarchical tiers:

  1. Channel Driver Tier (Pcs7AnIn / FbAnIn):
    * Simulates the physical hardware interface.
    * When Pcs7AnIn.SimOn = 1, the driver disconnects from the physical peripheral I/O image (PV_In) and outputs the simulated value (SimPV_In) to its output pin PV_Out.
    * The driver sets the output quality code to Simulated Value (PV_Out.ST = 16#60).
  2. Technological Block Tier (MonAnL / PIDConL):
    * Simulates process behavior at the control or monitoring level.
    * MonAnL possesses its own internal simulation subsystem (SimOn, SimPV).
    * When simulation is activated on MonAnL (either via CFC parameterization or by an operator via the WinCC faceplate), the block ignores the interconnected input PV and evaluates the internal simulation setpoint SimPV.
+-------------------------------------------------------------------+
|               APL Dual-Tier Simulation Architecture               |
+-------------------------------------------------------------------+
|  Tier 1: Channel Driver (Pcs7AnIn)                                |
|     - SimOn = 1 -> Evaluates SimPV_In                             |
|     - Outputs: PV_Out.Value = SimValue, PV_Out.ST = 16#60 (Sim)   |
|                             |                                     |
|                             v (Interconnection in CFC)            |
|  Tier 2: Technological Block (MonAnL)                             |
|     - Input: PV.Value, PV.ST                                      |
|     - Independent Simulation: MonAnL.SimOn                        |
|                                                                   |
|  Simulation Display Trigger:                                      |
|     - MonAnL displays "SIMULATION" if MonAnL.SimOn == 1           |
|       OR if PV.ST == 16#60 (Propagated Driver Simulation)         |
+-------------------------------------------------------------------+

Signal Quality Propagation and Status Code 16#60

Under NAMUR NE 107 and APL rules, signal quality propagates down the execution chain:

  • When Pcs7AnIn is in simulation, it tags the signal with status code 16#60 (Uncertain - Simulated Value).
  • When MonAnL receives PV.ST = 16#60, it automatically asserts its internal status bit SimAct = 1 and flags the process value as simulated, illuminating the simulation icon (hand symbol with blue background or "SIM" badge) on the WinCC block icon.
  • Even if MonAnL.SimOn is 0, the block truthfully reports that the process variable arriving from the field channel is simulated.

Root Causes of Persistent Simulation States on MonAnL

When an engineer toggles SimOn = 0 on Pcs7AnIn in S7-PLCSIM or online CFC, but MonAnL remains stuck in simulation:

  1. Independent Technological Simulation Active: During commissioning or testing, an engineer also enabled simulation directly on MonAnL (e.g., via the faceplate button). Resetting the driver does not reset MonAnL.SimOn.
  2. Incomplete PLCSIM Quality Update: In S7-PLCSIM, if the peripheral address is unbuffered or if the simulated driver does not receive a valid physical input cycle, Pcs7AnIn may not update PV_Out.ST back to 16#80 (Good), leaving stale 16#60 bytes in the chart buffer.
  3. Feature Bit Latching: Certain APL feature bits control whether simulation states require operator reset or tracking.

Step-by-Step Procedure to Clear Stuck Simulation States

Follow this diagnostic sequence in Continuous Function Chart (CFC):

Step 1: Inspect MonAnL Simulation Input Pins

  1. Open the CFC chart containing MonAnL.
  2. Toggle to Test Mode (Debug -> Test Mode).
  3. Inspect MonAnL.SimOn:
    * If SimOn = 1, right-click the pin and set value to 0 (or open the faceplate in WinCC and click Deactivate Simulation).
    * Confirm that SimAct resets to 0.

Step 2: Inspect Upstream Driver Output Quality

  1. In the same chart, inspect the connected Pcs7AnIn.PV_Out structure:
    * Verify Pcs7AnIn.SimOn: Must be 0.
    * Inspect Pcs7AnIn.PV_Out.ST: Must be 16#80 (Good) or 16#00 (Bad), not 16#60.
  2. If PV_Out.ST remains 16#60 while SimOn = 0:
    * The driver has not executed a complete processing cycle against real hardware inputs.
    * In PLCSIM, ensure the physical input address (PEW / PIW) is forced to a valid non-zero integer.
    * Cycle the controller from RUN to STOP and back to RUN in PLCSIM if execution buffers are locked.

Step 3: Verify Technological Interconnections

  1. Ensure the interconnection between Pcs7AnIn.PV_Out and MonAnL.PV is intact.
  2. Confirm that no secondary logic blocks (e.g., multiplexers or selector blocks) are overwriting the quality status structure.

Verification

Confirm that simulation mode is completely cleared:

  1. CFC Block Output Status:
    * Monitor MonAnL online in CFC.
    * Confirm that MonAnL.SimAct = 0.
    * Confirm that MonAnL.PV_Out.ST = 16#80 (Good).
  2. WinCC Runtime Block Icon and Faceplate:
    * Open the WinCC process graphic.
    * Verify that the simulation hand/wrench badge disappears from the MonAnL block icon.
    * Open the faceplate; confirm that the simulation indication reads inactive and that the process value reflects live measurement.

Limitations and Operational Precautions

  • Safety Interlock Hazard: Leaving technological blocks in simulation mode prevents them from responding to actual process excursions, presenting severe plant safety risks.
  • Production Audit Compliance: Most industrial standards (FDA, IEC 61511) strictly mandate logging and alarming when simulation mode is active. PCS 7 generates high-priority audit events whenever SimOn is asserted.
  • Total Download Reset Myth: It is never necessary to execute a full memory reset or complete program download simply to clear simulation states; resetting SimOn pins online immediately restores process tracking.

Engineer FAQ

  • Why does MonAnL show simulation when Pcs7AnIn.SimOn is set to 0?
    Either simulation was enabled directly on MonAnL via its faceplate (MonAnL.SimOn = 1), or Pcs7AnIn continues to output quality code 16#60 (Simulated).
  • What quality code indicates a simulated process value in APL?
    Quality code 16#60 (Uncertain - Simulated value).
  • Does MonAnL display simulation if the input quality code is 16#60?
    Yes, MonAnL evaluates the incoming signal status; if PV.ST = 16#60, it asserts SimAct = 1 to warn operators that the incoming measurement is simulated.
  • How do operators disable simulation from the WinCC faceplate?
    In the APL faceplate, switch to the Parameter view with Level 5/6 authorization and click the 'Deactivate Simulation' button.
  • Can simulation be disabled globally across all blocks in a plant?
    There is no single global master switch; simulation must be disabled on the respective driver or technological blocks where it was activated.
  • What is the function of the SimAct output pin on MonAnL?
    SimAct (Simulation Active) is a boolean output flag that indicates whether the block is currently processing simulated values.
  • Why does S7-PLCSIM sometimes keep Pcs7AnIn in simulation quality?
    If PLCSIM does not update the peripheral input address (PIW), the driver cannot calculate a fresh hardware status and holds the last simulated status.
  • Does setting SimOn = 1 on Pcs7AnIn require an AS stop?
    No, SimOn can be toggled dynamically online in CFC or via faceplates without interrupting controller execution.
  • Can simulated values be recorded in WinCC Tag Logging?
    Yes, WinCC logs simulated values, but the associated tag quality flag indicates that the value was recorded during simulation.
  • What is the difference between SimPV_In on Pcs7AnIn and SimPV on MonAnL?
    SimPV_In simulates raw channel input on the driver, while SimPV simulates the scaled technological process value directly on MonAnL.

Technical References

  • Siemens Industry Online Support (SIOS) Portal: How is the simulation function handled in the PCS 7 Advanced Process Library? (Entry ID: 109760968).
  • SIMATIC PCS 7 Advanced Process Library (APL) Function Manual, Siemens AG.
  • NAMUR Recommendation NE 107: Field Device Quality Codes.

Related Articles

Related Tags

PCS 7, APL, MonAnL, Pcs7AnIn, Simulation, SimOn, Quality Code, S7-PLCSIM

20 respuestas