Automation Glossary • DNP3 Application Layer

What Is the DNP3 Application Layer?

Merobix Engineering • • 6 min read

The top of the DNP3 stack is where bytes finally become meaning. The application layer is the part an integrator spends the most time with, because it holds function codes, object data, and the internal indication status that a master reacts to. This page explains what the DNP3 application layer contains, how a fragment is structured, and how the pieces fit together with the layers below it.

Back to Blog

DNP3 Application Layer in one line: The DNP3 application layer is the top layer that carries the actual meaning of a message: a function code that says what to do (read, write, operate, restart), followed by object headers that name the data being carried. A request or response is packaged as an application fragment starting with an application control byte and sequence number, and every outstation response also returns a two-byte internal indication status field.

The Application Fragment Structure

An application-layer message is called a fragment. It begins with an application control byte - carrying FIR/FIN bits for multi-fragment responses, a confirm-requested bit, and an application sequence number - followed by a function code. In a response, a two-byte internal indication field comes next. After that come one or more object headers, each naming an object group, a variation, and a range of points, followed by the point data itself.

That structure is why the same conceptual response can be encoded many ways. The object headers pull directly from the DNP3 object groups and variations model, so the group and variation you choose determine whether a value arrives with a timestamp and flags or as a bare number. Point numbering inside a group follows the DNP3 point index scheme.

Function Codes and Internal Indications

The function code is the verb of a DNP3 message. A master sends read, write, direct operate, select, operate, cold restart, and more; an outstation replies with response or unsolicited response. These verbs are covered in their own right by the DNP3 function code concept, and they are how one page distinguishes a poll from a command from a restart request.

Every outstation response also carries the DNP3 internal indication (IIN) field, two bytes of status bits that ride along with the answer. Those bits tell the master about buffer overflow, a device restart, a need for time, and other conditions - so a master reads not only the data it asked for but a health report on every reply. The application layer is therefore where both the data and the device state surface together.

Fragments, Segments, and Frames: Who Splits What

DNP3 splits a large message more than once on the way down the stack, and the vocabulary keeps the layers straight. The application layer produces fragments, each one a parseable unit with its own control byte and headers. The DNP3 transport function then chops a fragment into segments small enough to fit link frames, and the data link layer wraps each segment in a frame with source and destination addresses plus CRC protection. Reassembly runs the same path in reverse at the receiver, and only a completed fragment reaches the application parser.

The practical consequence is that one "message" in a protocol analyzer is often many frames, and trouble at different layers looks different. CRC failures point at the physical channel - noise, wiring, a marginal radio path. A fragment that starts arriving but never completes points at transport reassembly or at a mismatch in the maximum fragment size configured on each end. Since an integrity poll of a large outstation routinely spans several fragments flagged with FIR and FIN bits, a size mismatch tends to surface on exactly the polls that matter most.

Confirms, Retries, and Sequence Numbers

The application control byte carries a CON bit that requests an application-layer acknowledgement. An outstation typically sets it on responses that carry event data: the master must reply with a confirm before the outstation will clear those events from its buffer. If confirms go missing, events are retransmitted or the buffer creeps toward overflow, so a link that seems healthy on static data can still be quietly failing its event traffic. The mechanics and the failure symptoms are covered in the DNP3 application confirm page.

Application sequence numbers let each side pair confirms with the fragments they acknowledge and discard duplicates after a retry. Keep the application confirm distinct from the link-layer confirm, which acknowledges individual frames one layer down: running both on the same channel doubles the acknowledgement traffic for little benefit, and the usual engineering choice is application confirms for event data with link confirms left off. Whichever combination a channel uses, both ends must be configured to match, and that decision belongs to whoever engineers the channel as a whole.

Reading a Poll in a Protocol Capture

A worked symbolic example ties the structure together. A master's class poll is a request fragment with the read function code and an object header naming group 60 - variation 1 requests class 0 static data, and variations 2, 3, and 4 request event classes 1, 2, and 3. The request carries no point data at all, because it only names what it wants. The outstation's response fragment answers with concrete headers: perhaps a binary-input event group in a time-tagged variation, then an analog group, each header stating group, variation, qualifier, and range, followed by the points themselves.

A decode order that keeps you oriented in a capture:

  1. Find the function code to learn the verb: read, write, select, operate, or response.
  2. Read the application control byte for FIR, FIN, CON, and the sequence number.
  3. On responses, decode the two IIN bytes before anything else - they flag restarts, buffer trouble, and time-sync needs.
  4. Walk the object headers in order: group, variation, qualifier, range.
  5. Only then interpret point values, using the variation to know the encoding.
Practicing on live traffic is the fastest way to internalize this, and capturing DNP3 traffic in Wireshark shows how to get a clean capture to work with.

Frequently Asked Questions

What is a DNP3 application fragment?

A fragment is one complete application-layer message: an application control byte and sequence number, a function code, an internal indication field on responses, and the object headers and data. Large responses can span multiple fragments marked by FIR and FIN bits.

Does every DNP3 response carry status?

Yes. Every outstation response includes a two-byte internal indication field after the function code, so the master always receives device-state flags along with the requested data, even on a routine poll.

Where do object groups fit at the application layer?

Object headers inside the application fragment name an object group, a variation, and a point range. They tell the receiver what kind of data follows and how it is encoded, which is what makes a DNP3 message self-describing.

What is the difference between an application confirm and a link confirm?

They acknowledge different things at different layers. An application confirm acknowledges a whole fragment, and outstations use it to know event data was delivered before clearing their buffers. A link confirm acknowledges a single frame one layer down. Most channels run application confirms for event traffic and leave link confirms disabled, but both ends must be configured the same way.

How big can a DNP3 fragment be?

The maximum fragment size is a configured parameter that master and outstation must agree on, and responses larger than it are split across multiple fragments marked with the FIR and FIN bits. What matters to an integrator is the agreement itself: a mismatch shows up as truncated or never-completing responses, usually first on large integrity polls.

Sources and verification

This page references the protocol specifications published by the organizations below. Editions, product capabilities, and documentation change over time - confirm current requirements and specifications directly with the source.

Merobix is not affiliated with, endorsed by, or sponsored by these organizations; their names are used only to identify the standards and products discussed.

More in Industrial Protocols
DNP3 application confirm  •  PROFINET AR and CR  •  Sparkplug Primary Host Application  •  Application Instance Certificate  •  DNP3 Data-Link Layer  •  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 →