DNP: Major Improvements from MODBUS
About five years ago, I started working a lot more with Distributed Network Protocol (DNP3). I was used to working exclusively with MODBUS. There are so many advantages of DNP over MODBUS. Here are a few things I can think of that are improvements. Before going over the improvements, I want to expand on some terminology differences.
- Register Type such as Holding Registers, Coil Registers, and Input Registers are treated very different in DNP. Instead of two register types, there are many. I will expand on these later, but know they are grouped by what they do, such as Binary Input, Binary Output, Analog Input, Analog Output, and others. The register type as one would think of it in MODBUS is referred to as the Object Type in DNP.
- Variation in DNP is a concept that is not necessarily present in MODBUS. Variation is what specifies the data type you are after. For instance, you can specify if you are wanting a 16-bit integer from the device or a 32-bit integer. In MODBUS, there are ways to have your data acquisition software treat two registers (holding or input) as a 32-bit integer, but in DNP you specify or use whatever the device defaults to. In MODBUS, input and holding registers are 16-bit integers and coil registers are booleans. That’s the extent of capibility unless your software doing the acquisition allows you to treat the data differently.
- The register number or index in MODBUS is simply called the index in DNP.
Now that some terminology is cleared up, here are some improvements in comparison to MODBUS.
- Master and slave unit have an address
- Two masters can be on the same serial bus and can relay information between each other
- Timestamps for each index
- Quality for each index
- Quality can indicate more than good or bad quality
- Counters and Frozen Counters as a separate object
- Ability to specify data type desired on a per-index basis
- Floating point and double precision floating point is available as a data type if master and slave devices support it
- Integrity polling separate from event polling
- Unsolicited Event Notification instead of Polling
- File Transfer Capability
- Timestamp Object Type
- Time syncing Capability
- Ability to Segregate Polling Into Classes
- Group Indexes Assigned to Class
- Poll Each Class at Different Rate
- Class 0 is Integrity Poll
- Class 1, 2, and 3 are configurable from what I’ve observed
- Events Can Be Reported as Current State or Sequence of Events
- Internal Indicators (IIN in DNP terminology)
- Can be used to indicate thing such as device rebooted, device needs to sync time, class data available, event buffer overflow, and others
- Binary outputs have more than one type of operation
- Output points can be set to require a selection of the index prior to setting a value
- Newer DNP implementations can require user authentication
I hope, in the future, to create a series to expand on each of these items. If you want more information, I found a presentation from Eaton on DNP that looks pretty thorough. Refer to it or the DNP Protocol Primer direct from the horses mouth.