Automation Glossary • PROFIBUS DP Diagnostics

PROFIBUS DP Diagnostics and Extended Diagnosis

Merobix Engineering • • 7 min read

PROFIBUS DP does not need a separate poll to tell you a slave is unhappy - the slave raises a flag inside its normal cyclic reply, and the master then reads a detailed diagnosis block. Knowing how that mechanism works turns a vague slave fault into a specific, located problem. This page explains DP standard and extended diagnostics and how they surface.

Back to Blog

PROFIBUS DP Diagnostics in one line: PROFIBUS DP diagnostics work by the slave setting a diagnostic flag in its cyclic response, which prompts the master to request the slave's diagnosis block. That block carries standard status - station not ready, configuration fault, and similar - plus a device-specific extended diagnosis (Ext_Diag) area where the vendor encodes the actual fault, such as a channel error, so the master learns both that and what went wrong.

The Slave Raises a Flag, the Master Reads the Detail

The clever part of DP diagnostics is that it costs almost nothing until something is wrong. During normal cyclic exchange the slave simply reports its I/O. When it has a problem, it sets a diagnostic indication in its response - a signal to the master that a diagnosis is waiting - without yet sending the detail. The master notices the flag and issues a diagnosis request to that slave, which returns the full diagnosis block. This keeps the routine cyclic traffic lean while still delivering rich fault detail on demand, much like PROFINET separates cyclic data from event alarms.

The standard part of the diagnosis block carries defined status bits: station not ready, station not existent, configuration fault, parameter fault, and the like. These tell the master about the health of the relationship itself - whether the slave came up correctly, whether its configuration matches, whether it is even answering. For a great many problems, these standard bits alone point you at the cause: a configuration fault means the module layout does not match, a parameter fault means the parameterization was rejected.

Extended Diagnosis Carries the Device-Specific Fault

Beyond the standard status, the diagnosis block includes an extended diagnosis area, Ext_Diag, where the device vendor encodes fault detail specific to that device: which channel has a wire break, which measurement is out of range, an internal fault code. The meaning of the extended bytes is defined by the device and documented in its manual and GSD file, so reading them usually means consulting that documentation to decode what a particular byte pattern signifies. This is where DP tells you not just that a slave is faulted but which terminal or function is the problem.

There is also a diagnostic overflow indication for when a device has more diagnostic information than fits in one block, so the master knows to fetch more. In practice, engineers map the important diagnosis bits into the PLC so the HMI can show a meaningful fault rather than a bare slave-fault flag, similar to surfacing a watchdog or link fault as an operator message. The decoded result is what a historian or SCADA layer such as Merobix then trends and alarms on; Merobix records the controller's diagnosis tags rather than requesting DP diagnosis blocks itself. Understanding the standard-plus-extended structure is what lets you trace a SCADA fault back to the exact DP diagnosis that raised it.

The Three Ext_Diag Formats

Extended diagnosis is not one undifferentiated blob; the specification structures it into three formats, each with a header identifying its type and length. Identifier-related diagnosis is a bitmap flagging which module slots have something to report - it narrows the search to a module. Channel-related diagnosis goes further: it names the module, the channel, and a coded error type from a standard list - wire break, short circuit, overrange, underrange - which makes it nearly self-describing. Device-related diagnosis is the free-form vendor area, and only the device documentation can decode it.

In practice you read them in that order of preference. A channel-related entry hands you the faulted terminal directly; identifier-related tells you which module to inspect; device-related sends you to the manual. The engineering tool can often translate vendor-specific entries into plain text, but only when the GSD file it holds matches the device firmware on the wire, which is one more reason a GSD file version check belongs in commissioning.

A Walkthrough From Flag to Fix

Suppose the slave at address N raises its diagnostic flag. A repeatable sequence keeps the investigation short:

  1. Fetch the diagnosis block through the engineering tool or the controller's diagnosis function.
  2. Read the standard bits first - a configuration or parameter fault ends the search immediately, because the problem is the setup, not the hardware.
  3. If the standard bits are clean, parse the Ext_Diag headers to find the format: identifier, channel, or device-related.
  4. For channel diagnosis, map the module and channel to the wired terminal and inspect that circuit.
  5. For device-related bytes, decode against the manual's diagnosis table.
  6. After the fix, confirm the diagnostic indication has cleared from the cyclic reply, not just from the tool.

One habit worth adopting: record the raw diagnosis bytes before power-cycling anything. Diagnosis often clears on restart, and a fault that vanishes along with its evidence will be back on the night shift.

Surfacing Diagnosis Without Flooding the Operator

Mapping every diagnosis byte to its own alarm buries operators; mapping only a bare slave-fault bit starves them. A workable middle course is a summary alarm per slave plus a coded diagnosis word the display can decode, with momentary diagnoses latched until acknowledged so a fault that flickers during the night still gets seen. The severity policy is an engineering decision: a channel warning on a spare input does not deserve the same treatment as a configuration fault on a shutdown node.

Bus-wide upsets deserve their own thought. When a segment power dip or a broken termination hits, dozens of slaves flag diagnosis at once, and an alarm list that presents them alphabetically hides the cause. Grouping alarms by physical segment makes the pattern visible - one segment lighting up together points at cable, power, or termination, not at any individual device.

Frequently Asked Questions

How does a PROFIBUS DP slave report a fault?

The slave sets a diagnostic flag in its normal cyclic response rather than sending detail unprompted. The master sees the flag and issues a diagnosis request, and the slave returns its diagnosis block with standard status bits plus a device-specific extended diagnosis. This keeps routine cyclic traffic lean while still delivering full fault detail on demand.

What is Ext_Diag in PROFIBUS?

Ext_Diag is the extended diagnosis area of the DP diagnosis block, where the device vendor encodes fault detail specific to that device - a channel wire break, an out-of-range measurement, an internal fault code. Its meaning is defined by the device and documented in its manual and GSD file, so decoding the extended bytes usually means consulting that documentation.

What do the standard DP diagnosis bits tell me?

They report the health of the relationship: station not ready, station not existent, configuration fault, parameter fault, and similar. These often pinpoint a cause on their own - a configuration fault means the module layout does not match the plan, a parameter fault means parameterization was rejected. The extended diagnosis then adds the device-specific channel or function detail.

Why does a slave show a diagnosis while its I/O keeps updating?

Because diagnosis does not automatically stop data exchange. Many diagnoses are warnings scoped to one channel or function - a wire break on a single input, say - while the rest of the device runs normally. Whether a given diagnosis should stop the process, raise an alarm, or merely log is a policy the engineer sets when mapping diagnosis into the controller, not something the protocol decides.

Does fetching diagnosis interfere with cyclic traffic?

No - the mechanism is built so the detail travels only when a slave has flagged it, and the master schedules the diagnosis request alongside its normal cycle. The routine exchange stays lean because the flag is a single indication inside the reply the slave was sending anyway, with the block transfer happening on demand rather than continuously.

More in Industrial Protocols
Modbus Function Code 08 Diagnostics  •  PROFINET Diagnostics Model  •  PROFINET LLDP Diagnosis  •  PROFIBUS DP Master Class  •  PROFIBUS Address and HSA  •  All Industrial Protocols →
Free SCADA operator training
Merobix University - 70 video lessons & 261 quiz questions, from first login to compliance reporting. No demo call required.
Start free →