S7-1500 Analog Value Status: Channel Diagnostics in TIA Portal

David Krause12 min read
SiemensTIA PortalTutorial / How-to
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

Overview

The Value Status function in the SIMATIC S7-1500 analog modules adds a quality bit for every channel directly inside the process image of the inputs. Instead of issuing an RDREC call, polling channel-LED status, or wiring discrete diagnostic inputs, the CPU appends one extra byte (or bytes) to the module's input address range, and each individual bit inside that byte reports whether the corresponding channel is good (bit = 1) or faulted (bit = 0). The mapping is channel-ordered: bit 0 of the value-status byte = channel 0, bit 1 = channel 1, and so on. This makes per-channel analog diagnostics trivial to evaluate in ladder, FBD, or SCL.

Value Status is supported on the S7-1500 and on the ET 200MP / ET 200SP / ET 200AL distributed I/O families. The S7-1200 family does not expose this property; on S7-1200 the same diagnostic data must be read via record 0 or record 192 with RDREC. The same diagnostic philosophy applies to the SIMATIC ET 200AL analog modules, as described in the TIA Portal cloud documentation on analog diagnostics.

Prerequisites

  • SIMATIC S7-1500 CPU (any firmware variant that supports the analog module) or ET 200MP / ET 200SP / ET 200AL interface module with PROFINET connection back to the CPU.
  • STEP 7 (TIA Portal) V15.1 or later; V16 / V17 / V18 are recommended for full Value-Status support on newer analog modules such as the AI 8xU/I/RTD/TC ST (6ES7531-7KF00-0AB0) and AI 8xU/I/RTD HF (6ES7531-7PF00-0AB0).
  • Analog input module with the Value status property exposed in the module parameters. The capability is standard on:
Module family Typical catalog number Value Status available
S7-1500 AI 8xU/I/RTD/TC ST 6ES7531-7KF00-0AB0 Yes
S7-1500 AI 8xU/I/RTD HF 6ES7531-7PF00-0AB0 Yes
S7-1500 AQ 4xU/I ST 6ES7532-5HD00-0AB0 Yes
ET 200MP AI 4xU/I/RTD/TC ST 6ES7531-7QD00-0AB0 Yes
ET 200SP AI 4xU/I 2-/4-wire ST 6ES7131-6GD00-0BA0 Yes
ET 200SP AI 8xRTD/TC 2-wire HF 6ES7131-6PF00-0AA0 Yes
ET 200AL AI 4xU/I 4-wire 6ES7534-4HA00-0AA0 (ET 200AL) Yes
S7-1200 AI 4xRTD (the unit discussed in the source thread) 6ES7231-5PF32-0XB0 No — use RDREC

Enabling Value Status in TIA Portal

  1. Open the project and switch to Device View of the S7-1500 station (or the ET 200MP / ET 200SP head module).
  2. Click the analog module. In the inspector window select Properties > Module parameters.
  3. Navigate to AIx > Inputs > Channel n (for the specific channel) and expand Diagnostics.
  4. Select Value status in the module-level configuration (or in the channel-level group "Configuration"). The exact path label in the inspector reads Value status in the field labeled "xx Configuration".
  5. Compile the hardware configuration and download it to the CPU. After the download, the module reserves one additional byte in the input process image.
Note: Enabling Value Status does not change the analog measurement result. It only adds a 1-bit-per-channel quality stamp to the input address range. Wire-break, overflow, underflow, and short-circuit diagnostics are still configured per channel under the Diagnostics group.

Address Mapping and Bit Structure

Once Value Status is enabled, the module's I-address footprint grows. For an 8-channel analog input with a starting input address of I32, the input area is normally 16 contiguous bytes (2 bytes per channel). After enabling Value Status, an additional byte is appended after the channel data. The byte order is little-endian on the S7-1500.

Address Content Notes
IW32 ... IW47 Channel 0 .. Channel 7 analog values 16-bit signed integer per channel
IB48 Value Status byte 0 Bit 0 = channel 0, bit 7 = channel 7
I48.0 Channel 0 quality 1 = good, 0 = fault
I48.1 Channel 1 quality 1 = good, 0 = fault
I48.7 Channel 7 quality 1 = good, 0 = fault

Reading Diagnostic Bits in the User Program

The Value-Status bit is updated every PLC scan by the module firmware. It is valid for the analog value delivered in the same process-image update. Three practical patterns follow.

Pattern 1 — Ladder bit test (FBD/ LAD)

// Channel 0 good?
A I 48.0
= M 100.0   // "AI0_OK"

// Channel 4 good?
A I 48.4
= M 100.4   // "AI4_OK"

Pattern 2 — Word extract in SCL

// ValueStatusByte is the byte appended after the analog channels
#VS_Byte := "AI_8CH".ValueStatus;
FOR #i := 0 TO 7 DO
    IF (#VS_Byte.%X#i) THEN
        // bit i = 1 → channel i healthy
    ELSE
        // bit i = 0 → channel i faulted
    END_IF;
END_FOR;

Pattern 3 — Map to a status word for the HMI

// Pack all 8 channel-good bits into one INT for the HMI status screen
"HMI_AI_Status" := "AI_8CH".ValueStatus;

ET 200MP Distributed I/O

The same feature is available on ET 200MP analog modules plugged into the distributed rack. The Value-Status byte still appears immediately after the channel data in the PROFINET slot, and the mapping (bit = channel) is preserved. Two practical points to keep in mind on a distributed rack:

  • If the ET 200MP interface module drops out of PROFINET, the Value-Status byte substitutes the value 16#00 for all channels (all bad). This is identical to the substitute-value behavior of the analog data and is the correct way to detect a station failure without waiting for the I/O fault OB.
  • The diagnostic bit clears automatically once the channel returns to a valid range. There is no acknowledge or edge required.

Wire-Break Detection on RTD / TC Channels

For RTD and thermocouple modules, enable Wire break per channel under Diagnostics in addition to Value Status. With both enabled, the diagnostic bit drops to 0 within one PROFINET update cycle (~1 ms) of a broken sensor lead, and the analog value is forced to the configured substitute value (default 0 or 7FFFh overflow). This combination is the standard pattern for an S7-1500 / ET 200MP 8-channel RTD card.

Note on the source-thread S7-1200 RTD: The module referenced in the discussion, 6ES7 231-5PF32-0XB0, is an S7-1200 SM 231 RTD module. It does not support the S7-1500 "Value Status" property. On the S7-1200 the engineer must call RDREC with record 0 or record 192 to obtain the channel-diagnostic payload. The diagnostic interpretation (wire break vs. out-of-range vs. short circuit) is encoded in the data record's channel status bit, not in a process-image bit.

S7-1200 Alternative Using RDREC

On S7-1200 with the SM 231 RTD 8x (6ES7231-5PF32-0XB0) the equivalent function is achieved through the RDREC instruction. The relevant data records are summarized below.

Data record Length Purpose Notes
DS0 4 bytes per channel Channel diagnostic — first 16 bits per channel map the standard PROFINET channel-diagnosis bits (short circuit, wire break, overflow, underflow, parameter error, etc.) Read with RDREC; the MLEN input must be sized to the full record (typically 32 bytes for an 8-channel module).
DS1 Variable Module/type identification Generally not used at runtime.
DS192 34 bytes Module diagnostic — header + per-channel status, used when the module signals "module fault". Read only when the diagnostic interrupt fires.

Typical SCL skeleton for the S7-1200 RTD card:

// Trigger: rising edge of diagnostic interrupt OB82 or a 1-Hz cyclic task
#RDREC_REQ := TRUE;
#RDREC_ID   := 50;                 // HW identifier of the SM 231
#RDREC_INDEX := 0;                 // Data record 0 (channel diagnostic)
#RDREC_MLEN  := 34;                // Full record size for 8 channels
#RDREC_RECORD := #AI_Diag_Buffer;  // P#DB100.DBX0.0 BYTE 34

// On done:
IF #RDREC_VALID THEN
    // Bytes 0..1 = channel 0 status (bit 0 wire break, bit 1 short circuit, ...)
    // Bytes 4..5 = channel 1 status
    // etc.
END_IF;

Because the S7-1200 RTD module does not push channel quality into the process image, the engineer should build a small "status word" DB that the HMI can poll in parallel with the analog values.

Distinguishing Fault Types in Data Record 0

For the S7-1500 / ET 200MP analog modules, the data-record-based diagnostics give the same fault detail that the simple Value-Status bit does not. Use it when the application must log which fault occurred. The standard PROFINET channel-diagnosis bit assignments inside each 16-bit channel entry are:

Bit Meaning Typical cause on AI module
0 Short circuit Sensor wires shorted (current loop / RTD short)
1 Underflow Measured value below the configured measuring range
2 Overflow Measured value above the configured measuring range
3 Wire break Open sensor lead or open current loop
4 Reserved —
5 Parameter assignment error Channel configured but not wired, or wrong measurement type
6 Missing supply voltage Sensor supply L+ missing on the module terminals
7 Measuring range violation (lower) Sensor output below 4 mA / below 0 V
8 Measuring range violation (upper) Sensor output above 20 mA / above 10 V
11..15 Vendor-specific / extended status Refer to the module manual

The ET 200AL analog modules share the same channel-diagnosis model, as documented in the SIMATIC ET 200AL function manual — Diagnostics.

Step-by-Step Commissioning Procedure

  1. Wire and configure the channel — Choose the measurement type (0..10 V, 4..20 mA, Pt100, TC type K, etc.) and the smoothing settings in the module parameters.
  2. Enable per-channel diagnostics — Under Channel n > Diagnostics enable only the fault types you care about (typically wire break and overflow). Enabling all diagnostics can produce nuisance faults during commissioning.
  3. Enable Value Status — In the module-level Configuration group tick Value status. Compile the hardware.
  4. Note the address — Read the start address of the value-status byte from Device View > Module > I/O addresses > "Address to".
  5. Create a Watch Table — Monitor the analog value and the matching value-status bit. Pull a sensor wire and confirm the bit clears.
  6. Wire the bit into the application — Use a normally-closed contact (AN I 48.0) on the value-status bit to set a "channel bad" flag, or a normally-open contact to set a "channel good" flag.
  7. Mirror the status to the HMI — Pack all value-status bits into one word and expose it on the HMI so the operator can see at a glance which channel is faulted.

Verification

Validate the configuration with a forced fault:

  1. Add the analog value and the value-status byte to a Watch Table with monitor ON.
  2. With the sensor connected, the bit is 1 and the analog value matches the process variable.
  3. Pull one wire from the sensor. Within one PROFINET update the bit drops to 0, the analog value goes to substitute value, and the module's channel error LED turns on (if present on the module variant).
  4. Reconnect the wire. The bit returns to 1 automatically, the LED clears, and the analog value resumes normal reading.

For the S7-1200 RDREC path, validate by reading the data record on a 1-Hz task and decoding bytes 0..1 — the wire-break bit (bit 3) must be 1 when the wire is off and 0 when the wire is on.

Troubleshooting Matrix

Symptom Likely cause Remedy
Value-status byte not visible in the process image "Value status" not enabled in the module configuration Re-open module properties, enable Value status, recompile and download
Value-status byte present but all bits are 0 Channel diagnostics not enabled per channel Enable at least one diagnostic type (e.g. wire break) per channel under Channel n > Diagnostics
All bits of value-status byte drop to 0 simultaneously PROFINET station failure or module pulled from the rack Check the interface module diagnostics in TIA Portal > Online > Diagnostics
Bit 0 is 0 but the analog value is plausible Diagnostics for a fault that is not present are also triggered; e.g. overflow configured but sensor output is in range Review the enabled diagnostic types — disable nuisance types
Bit does not clear after reconnecting the wire Module is in substitute-value mode and the substitute is being held Check substitute-value configuration; on wire break, the bit should clear automatically when the next valid conversion is read
Source-thread behavior: pulling wire on channel 0 zeros the entire byte (S7-1200 RTD card) On S7-1200, no Value Status exists; the behavior reported in the source thread is in fact the RDREC path returning 16#00 because the module is in a module-fault state Switch to RDREC with DS0; the per-channel bits inside DS0 give correct per-channel status
Channel fault LED on the module is on but the value-status bit is 1 Diagnostic type enabled in the module that is not propagated to the value-status byte Refer to the module manual; some legacy AI modules do not push every diagnostic event to Value Status

Field-Proven Caveats

  • The value-status byte is updated by the module, not by the CPU. It is therefore valid even when OB1 is not running (e.g. CPU in STOP with configured I/O update). Use it for safe-state evaluation.
  • Value Status only carries a 1-bit per-channel summary. To know which fault occurred, read data record 0 with RDREC or use the standard PROFINET channel-diagnosis alarm (OB82) for full detail.
  • On 2-wire RTD modules, the wire-break detection requires the diagnostic type to be enabled on the matching channel pair, because the module checks the current injection on both leads. Enabling it on only one channel of a 2-wire pair can produce false negatives.
  • On thermocouple channels, enable "Open thermocouple" (wire break) for each channel; the value-status bit will also drop on a missing cold-junction compensation, but the channel-diagnosis record will tell the difference.

FAQ

Does the S7-1500 Value Status byte appear before or after the analog data in the process image?

The Value-Status byte is appended after the channel data. For an 8-channel module starting at I32, the analog data occupies IW32..IW47, and the value-status byte is at IB48. The exact start address is shown in the device configuration under I/O addresses > "Address to".

How do I read analog channel diagnostics on an S7-1200 RTD card such as 6ES7 231-5PF32-0XB0?

Use the RDREC instruction with the HW identifier of the SM and data record 0. Each channel occupies 4 bytes in the returned buffer; the first 16 bits of each channel entry encode the standard PROFINET channel-diagnosis bits (bit 0 short circuit, bit 3 wire break, etc.).

Why does pulling the wire on channel 0 zero the entire value-status byte on my S7-1200 RTD card?

The S7-1200 SM 231 RTD does not support the S7-1500 Value-Status property. What looks like a value-status byte is in fact the RDREC diagnostic buffer that is being refreshed in module-fault state; a single open wire on one channel can place the module in a degraded condition that flags the whole module. Switch to per-channel RDREC decoding of DS0 to get a correct per-channel status.

Can I use the Value-Status bit to detect a missing PROFINET connection to the ET 200MP?

Yes. When the ET 200MP interface module loses the PROFINET connection, the Value-Status byte is forced to 16#00 for all channels, exactly like the analog values are forced to substitute value. Reading the byte is the fastest application-level indicator of a station dropout.

Does enabling Value Status slow down the analog input scan time?

No. The Value-Status bit is generated by the module firmware in parallel with the analog conversion; it is appended to the PROFINET payload with no measurable effect on the channel conversion time. The only cost is one extra byte in the input process image.

Back to blog