Interpreting FbAnIn Mode Byte 16#1 and Discrepancies with PV_ST in SIMATIC PCS 7 APL

Interpreting FbAnIn Mode Byte 16#1 and Discrepancies with PV_ST in SIMATIC PCS 7 APL

In SIMATIC PCS 7 Advanced Process Library (APL), an analog fieldbus channel driver (FbAnIn) asserts an invalid signal status (QBAD = 1) when the Mode parameter indicates 16#000001, even if the process value quality input (PV_ST) reports 16#80 (Good). The Mode input structure uses Byte 3 (lowest byte) to define hardware validity (16#80 = valid, 16#00 = invalid). A Mode value ending in 16#01 represents an invalid 4-20 mA measurement from an uncommunicative or defective PROFIBUS PA / FOUNDATION Fieldbus device. Resolving this discrepancy requires inspecting upstream diagnostic drivers, addressing fieldbus physical faults, and clearing channel diagnostics.

Table of Contents

Architecture of the FbAnIn Driver Block in PCS 7

In SIMATIC PCS 7, the FbAnIn block (FB1813) serves as the specialized Advanced Process Library (APL) channel driver for fieldbus devices connected across PROFIBUS PA or FOUNDATION Fieldbus:

  • Cyclic Peripheral Mapping: FbAnIn connects to the input process image of the fieldbus device, cyclically reading a 5-byte data structure conforming to the PA Profile: 4 bytes for the floating-point process value (REAL) and 1 byte for the fieldbus status byte (PV_ST).
  • Hardware Diagnostic Interface (Mode): Simultaneously, FbAnIn receives hardware and channel health metadata from the upstream system diagnostic blocks (MOD_D1, MOD_PA, OB_DIAG) via the 32-bit parameter Mode.
  • Output Processing: The block evaluates both inputs. If either the fieldbus telegram status or the hardware Mode indicates failure, FbAnIn asserts QBAD = 1 and outputs substitute or hold values to downstream technological blocks (PIDConL, MonAnL).

Anatomy of the 3-Byte Mode Input Parameter

The Mode input parameter is a 32-bit DWORD (typically formatted as three active bytes, 16#00yyzz or 16#xxyyzz):

  • Byte 1 & 2 (Signal Type / Measurement Range): Encodes the technological sensor configuration:
  • 16#0001: Standard analog input / current 4-20 mA or PA floating-point profile.
  • Byte 3 (Quality / Validity Status): Encodes the operating state of the I/O channel:
  • 16#80: Valid Signal (Hardware channel healthy, cyclic communication active).
  • 16#00: Invalid Signal (Channel defect, wire break, station failure, or diagnostic trip).

When Mode displays 16#000001 (or 16#1):
* Byte 1 & 2 indicate standard fieldbus analog mode (0001).
* Byte 3 is 00 (shifted), representing Invalid Signal / Channel Failure.
* Consequently, the driver generator and block operating system interpret the channel as bad.

Why PV_ST = 16#80 Conflicts with Mode = 16#01

Engineers are often confused when observing PV_ST = 16#80 (Good) while QBAD = 1 and WinCC displays a red maintenance wrench icon:

  • PV_ST is the Fieldbus Status Byte: The value 16#80 at PV_ST is the internal default value or the last static value held in the CPU memory image. If communication with the physical PA slave fails or if the PA coupler loses backplane sync, the CPU input image may continue to show the last read 16#80 byte.
  • Mode is the Controller Diagnostic Verdict: System diagnostic blocks monitoring OB82 (diagnostic interrupt) and OB86 (rack failure) detect that the physical fieldbus device is disconnected or reporting an internal sensor failure. The diagnostic driver immediately sets Mode.Byte3 = 16#00.
  • APL Safety Principle: Hardware diagnostics always override static data image inputs. If Mode reports invalid (16#00), FbAnIn immediately forces QBAD = 1 and marks the technological output PV_Out.ST = 16#00 (Bad), triggering the faceplate maintenance alert.
+-------------------------------------------------------------------+
|               FbAnIn Quality Evaluation Hierarchy                 |
+-------------------------------------------------------------------+
|  Fieldbus Device (PROFIBUS PA / FF)                               |
|     - Cyclic Process Image: PV (REAL) + PV_ST (16#80 = Good)      |
|                                                                   |
|  Hardware Diagnostics (OB82 / OB86 / MOD_PA Driver)               |
|     - Channel State: Wire break / Comm failure -> Mode = 16#0001  |
|                                                                   |
|  FbAnIn Channel Driver Block Evaluation                           |
|     - Mode Byte 3 == 00 (Invalid) OVERRIDES PV_ST == 16#80        |
|                                                                   |
|  Block Outputs:                                                   |
|     - QBAD = 1 (Signal Fault Active)                              |
|     - PV_Out.ST = 16#00 (Bad)                                     |
|     - WinCC Renders Red Wrench / Fault Icon                       |
+-------------------------------------------------------------------+

Step-by-Step Diagnostic and Resolution Procedure

Follow these steps to clear the invalid Mode fault:

Step 1: Trace Hardware Diagnostic Alarms in STEP 7

  1. Open SIMATIC Manager.
  2. Select the CPU and press Ctrl + D to open the Diagnostic Buffer.
  3. Check for events referencing PROFIBUS DP/PA coupler failures or slave dropouts (e.g., Event ID 16#38C4 or 16#39B3).
  4. Identify the specific DP master system, DP address, and PA slave address.

Step 2: Inspect Fieldbus Coupler and Segment Health

  1. Locate the physical DP/PA Coupler (e.g., FDC 157-0 or standard coupler).
  2. Inspect front panel LEDs:
    * DP: Steady green (active communication).
    * PA: Steady green or flashing (bus traffic).
    * FAULT / SF: Red indicates open circuit, shorted spur, or missing bus terminator.
  3. Verify bus termination: Ensure the passive or active PA bus terminator at the far end of the segment is properly installed and energized.

Step 3: Re-Generate Module Drivers in CFC

  1. In SIMATIC Manager, open any CFC chart.
  2. Select Charts -> Compile -> Chart as Program....
  3. Check Generate module drivers and select Scope: Changes only.
  4. Compiling module drivers ensures that interconnections between MOD_PA, OB_DIAG, and FbAnIn.Mode are synchronized with current HW Config addressing.
  5. Download changes to the controller.

Verification

Confirm proper restoration of channel validity:

  1. CFC Online Monitoring:
    * Open the CFC chart containing FbAnIn in Test Mode.
    * Observe parameter Mode: Confirm that Mode changes to 16#00800001 or that Byte 3 reads 16#80.
    * Verify that QBAD transitions from 1 to 0.
    * Confirm that PV_Out.ST displays 16#80 (Good) and matches live process values.
  2. WinCC Faceplate Verification:
    * Open the associated analog monitoring faceplate in WinCC Runtime.
    * Confirm that the red wrench and fault alarm indicators clear automatically.

Limitations and Operational Precautions

  • Substitute Value Activation: If SubsPV_En = 1, FbAnIn outputs the substitute value SubsPV while QBAD = 1. Verify that downstream logic behaves safely under substitute values.
  • Never Force Mode Constants: Never manually hard-code constants onto the Mode pin in CFC; doing so breaks automatic hardware failure detection, masking real field wiring breaks and risking silent process failures.
  • PA Coupler Baud Rate: PROFIBUS PA operates at 31.25 kbit/s. Ensure fieldbus couplers and barrier repeaters are configured for the correct transmission rate.

Engineer FAQ

  • What does Mode input 16#1 mean on an FbAnIn block?
    It indicates that Byte 3 of the Mode structure is 16#00 (invalid signal/channel fault) while Bytes 1 and 2 indicate standard fieldbus analog mode (0001).
  • Why does QBAD remain 1 when PV_ST reads 16#80 (Good)?
    Hardware diagnostics (via the Mode parameter) detect that the physical channel or fieldbus device is faulted, which overrides the static PV_ST value.
  • Which block generates the Mode value connected to FbAnIn?
    The PCS 7 driver generator automatically interconnects Mode from the system diagnostic block (e.g., MOD_PA or MOD_D1).
  • What does Mode Byte 3 equal when a channel is healthy?
    In a healthy operational state, Byte 3 of the Mode parameter is 16#80 (Valid).
  • What visual symbol appears on the WinCC faceplate when Mode is invalid?
    A yellow or red maintenance wrench icon appears on the block icon and faceplate, indicating a field device or driver fault.
  • Can an incorrect PROFIBUS PA bus terminator cause Mode to become invalid?
    Yes, missing or shorted termination causes signal reflection, dropping the PA slave from cyclic communication and triggering OB82/OB86 faults.
  • What is the purpose of the FbAnIn block in PCS 7?
    FbAnIn is the standard APL channel driver for acquiring analog process values from PROFIBUS PA and FOUNDATION Fieldbus field instruments.
  • How do I configure a substitute value for sensor failure in FbAnIn?
    Set SubsPV_En = 1 and enter the desired safety value at parameter SubsPV.
  • Does FbAnIn support NAMUR NE 107 diagnostic states?
    Yes, FbAnIn evaluates fieldbus device diagnostics and maps them to standard NAMUR NE 107 status categories.
  • Does changing Mode parameters require recompiling the WinCC OS?
    No, Mode is an internal automation station diagnostic signal evaluated by the AS channel driver; WinCC compilation is not required.

Technical References

  • Siemens Industry Online Support (SIOS) Portal: How are the inputs MODE and PV_ST evaluated in the PCS 7 Advanced Process Library? (Entry ID: 23073740).
  • SIMATIC PCS 7 Advanced Process Library (APL) Function Manual, Siemens AG.
  • PROFIBUS PA Profile for Process Control Devices (Version 3.02), PI International.

Related Articles

Related Tags

PCS 7, APL, FbAnIn, Mode, PV_ST, PROFIBUS PA, Channel Drivers, Diagnostics

20 respuestas