# 12.2 DNP 3.0 Master Default group and variation sets are used to send commands. If slave devices support different groups and variations, they can be adjusted in Excel configuration. For more information check section Excel configuration. #### Configuring datapoints To use DNP3 Master in WCC Lite, it has to be configured via an Excel configuration. This configuration contains two Excel sheets where parameters have to be filled in ­Devices and Signals. ##### DNP3 Master parameters for Devices tab
**Parameter** **Type** **Description** **Required **Default value** (when not specified) **Range**
Min Max
namestring User-friendly device nameYes
descriptionstringDescription of a deviceNo
device\_aliasstringAlphanumeric string to identify a deviceYes
enablebooleanEnabling/disabling of a deviceNo101
protocolstringProtocol to be used (”dnp3 serial”/”dnp3 tcp” (case insensitive))Yes
modestringChoosing between TCP, TLS and SERIAL modes . If protocol provided DNP3 TCP mode defaults to tcp and if DNP3 serial is provided mode defaults to serialNoTCP or SERIALTCP, SERIAL
ipstringIP address of TCP slave deviceYes (for TCP).
bind\_address stringIP address of network adapter used to connect to slave deviceNo (for TCP)0.0.0.0
portintegerTCP communication portNo (for TCP)20000
deviceintegerCommunication port (”PORT1” or ”PORT2”)Yes (for SERIAL)
baudrateintegerCommunication speed, bauds/sNo (for SERIAL)9600300, 600, 1200, 2400, 4800, 9600, 19200, 38400, 57600,115200
databitsintegerData bit count for communicationNo (for SERIAL)869
stopbitsintegerStop bit count for communicationNo (for SERIAL)102
paritystringCommunication parity optionNo (for SERIAL)nonenone, even, odd
flowcontrolstringCommunication device flow control option. No (for SERIAL)nonenone
tlsbooleanEnable/disable use of TLS Yes (for TLS)001
tls\_local\_certificatestringLocal certificate for TLS connectionYes (for TLS)
tls\_peer\_certificatestringCertificate authority file for TLS connectionNo (for TLS)
tls\_private\_keystringFile consisting of private key for TLS connectionNo (for TLS)
max\_rx\_frag\_sizeintegerMaximum size of a received fragment.No204802048
destination\_addressintegerAddress of a master stationNo1065535
source\_addressintegerAddress of a slave (local) station.No1065535
unsol\_disableboolDisables unsolicited messages on startup. Overrides **unsol\_classes** parameter. No001
unsol\_classesstringDefines which classes will have unsolicited actions on startup. Can be overriden with **unsol\_disable**. (Example: "1,3,2")Nono class13
groups\_scan\_maskintegerBitmask for enabling separate group scans with x06 qualifier (all objects): 0 -­ Binary, 1 ­- Double­bit Binary, 2 ­- Binary Output Status, 3 ­- Counter, 4 ­- Frozen Counter, 5 ­- Analog, 6 ­- Analog Output Status, 7 ­- Octet StringNo007
groups\_scan\_intervalinteger, string Time between separate groups scans intervals in seconds. Set to 0 to disable.No00
exception\_scan\_intervalinteger, string Time between exception scan (classes 1,2,3) intervals in seconds. Set to 0 to disable.No00
integrity\_scan\_intervalinteger, string Time between integrity scan (classes 0,1,2,3) intervals in seconds (general interrogation). Set to 0 to disable.No00
timesync\_modestringWill override masters default setting for choosing timesync procedureNoNON-LAN(for Serial) LAN (for tcp) LAN, NON-LAN
time\_sync\_interval\_sec integer, string Periodic time sync interval in seconds. If 0 < ­- time syncs are forced and periodic. If = 0 ­- time syncs react to IIN bits from slave. If < 0 -­ time syncs are disabled. No00
select\_msintegerSelect command timeout. Valid for all signals.No10000
timeout\_msintegerResponse timeout in millisecondsNo 2000
keep\_alive\_timeoutintegerTime interval for sending a keep alive packet in milliseconds.No60
##### DNP3 Master parameters for Signals tab
**Parameter** **Type** **Description** **Required **Default value** (when not specified) **Range**
Min Max
signal\_namestringUser-friendly signal nameYes
device\_aliasstringDevice alias from a Devices tabYes
signal\_alias Unique alphanumeric name of the signal to be usedYes
enablebooleanEnabling/disabling a deviceNo101
indexintegerIndex of a signal.Yes 065535
logbooleanEnable logging in the event logNo00
signal\_typestringDNP3 signal type. (case insensitive) Yes ”BINARY”, ”ANALOG”, ”DOUBLEBITBINARY” ”BINARYOUTPUTSTATUS”, ”COUNTER”, ”FROZENCOUNTER”, ”ANALOGOUTPUTSTATUS, ”OCTETSTRING”, ”TIMEANDINTERVAL”, ”BINARYOUTPUTCOMMAND”, ”ANALOGOUTPUTCOMMAND”
command\_variationintegerDNP3 command variation. *Supported variations depend on signal type and are provided in the table below* No004
static\_variationintegerDNP3 command variation (). Supported variations depend on signal type and are provided in the table below.No 0, 1, 2, 3, 4, 5, 6, 9, 10
event\_variationintegerDNP3 command variation. Supported variations depend on signal type and are provided in the table below.No 08
control\_codeintegerDNP3 control model code of CROB signal. TripClose and Pulse control model requires **PulseOn/off** times to be set No LATCH, PULSE, TRIPCLOSE
pulse\_on\_time\_msintegerPulse ON time in milliseconds, when using Pulse or TripClose control models must be setNo
pulse\_off\_time\_msintegerPulse OFF time in milliseconds, when using Pulse or TripClose control models must be setNo
class\_numintegerClass assignment of this signal.No003
operate\_typeinteger No1-11
job\_todostringThe device status signal can be configured by providing one of the given values. No COMMUNICATION\_STATUS, DEVICE\_RUNNING, DEVICE\_ERROR, UNKNOWN\_ERROR
#### Debugging the DNP3 Master service If configuration for DNP3 devices is set up, handler for protocol will start automatically. If configuration is missing or contains errors, protocol will not start. It is done intentionally decrease unnecessary memory usage. DNP3 protocol runs a service called **dnp3-­master**. If DNP3 does not work properly (e.g. no communication between devices, data is corrupted, etc.), a user can launch a debug session from command line interface and find out why link is not functioning properly. To launch a debugging session, a user should stop **dnp3-­master** process and run **dnp3-m­aster** command with respective flags as in the table given below. Procedure for DNP3 Master protocol service debugging: - **Step 1**: Service must be stopped by entering the following command into the wcclite: **/etc/init.d/dnp3-­master stop** - **Step 2**: After service is stopped it must be started with the preferred configuration file (JSON files found in /etc/ folder) and a debug level 7: **dnp3­-master ­-c /etc/dnp3-­master/dnp3­master.json ­-d7**Additional output forming options described in the table below. - **Step 3**: Once the problem is diagnosed normal operations can be resumed with the following command: **/etc/init.d/dnp3-­master start** dnp3­-master command line debugging options
Option Description
­-h \[ –help \] Display help information
­-V \[ –version \] Show version
-p \[ –port \]­Show output for one port only
­-d <debug level>Set debugging level
-­c \[ –config \] Config path
-­a \[ –app \]Show application layer data
–l \[ –link \] Show link layer data
–t \[ –transport \] Show transport layer data
-­r \[ –redis \] Show Redis messages
-­R \[ –readyfile \] Ready notification file