SDG Implementers Guide
SDG Implementers Guide
Page i
Page ii
1) LICENSE. Triangle MicroWorks, Inc. hereby grants to the person (Customer) who is purchasing the enclosed software media to
use the same (the contents of which, together with all modifications and accompanying documentation are referred to herein as the
Software), a limited, non-exclusive license to use the software on the terms and conditions set forth. This license is solely for the use
of the Software by the Customer on a single computer. The Customer may physically transfer the Software to another computer by
having the media read into such computer, provided that the Software may not be used on more than one computer at any given time.
Subject to the foregoing limitation, the Customer is entitled to copy the Software into any machine-readable or printed form for backup
purposes in support of the use of the Software on a single computer by the Customer. The Customer may likewise merge the Software or
incorporate the same into another program provided that such program will, for so long as the Software is included therein, be subject to
all of the terms and conditions of this license. Any copy of the Software permitted by the preceding provision shall include a copyright
notice of Triangle MicroWorks, Inc.
2) TERM OF LICENSE. The license will continue until the Customer physically destroys all copies of the Software and returns the
original program disk and documentation to Triangle MicroWorks, Inc.
3) MAINTENANCE & ENHANCEMENT PLAN. Customer is subscribed in the Maintenance & Enhancement Plan for a period
of one (1) year following the purchase of SCADA Data Gateway. The Plan may be renewed each year on the anniversary of the
purchase date unless cancelled by either party.
This optional Maintenance & Enhancement Plan provides a cost effective method for upgrading to the most recent release
version of the SCADA Data Gateway. It also provides technical support by telephone, fax, or email. The first year of the
Maintenance & Enhancement Plan is free. Renewal price after the first year is 25% of the purchase price; however, future
years may be purchased in advance at 20% of the purchase price.
4) COPYRIGHT. The Software is copyrighted, and all rights therein are reserved by Triangle MicroWorks, Inc.
5) LIMITED WARRANTY. The Customer assumes all responsibility for the selection of the Software as appropriate to achieve the
results intended by the Customer. Triangle MicroWorks, Inc. warrants that the enclosed media medium upon which the Software is
recorded shall be free from defects in material and workmanship under normal use and conditions, and that the Software shall perform
substantially as described in its documentation for a period of sixty (60) days from purchase. EXCEPT FOR THE FOREGOING
LIMITED WARRANTY. THE SOFTWARE IS PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND EITHER
EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE.
5) LIMITATION OF REMEDIES. In the event of the breach of the limited warranty set forth above, the Customer shall be entitled to
return the media to the place of purchase and, at the election of the vendor, to have the purchase price refunded or to receive media
containing the Software which conforms with the above limited warranty. In no event will Triangle MicroWorks, Inc. be liable for any
damages arising out of the Customers use of the Software, including, by way of illustration, lost profits or any incidental or
consequential damages.
6) ACKNOWLEDGMENTS. The Customer acknowledges that the Customer has read this agreement, understands it and agrees to be
bound by its terms and conditions, which agreement will be acknowledged in writing upon the request of Triangle MicroWorks, Inc.
7) GENERAL PROVISIONS. The Customer shall have no right to sublicense any of the rights of this Agreement, for any reason. In
the event of the breach by the Customer of this Agreement, the Customer shall be liable for all damages to Triangle MicroWorks, Inc.,
and this Agreement shall be terminated. This Agreement can only be modified in writing between the Customer and Triangle
MicroWorks, Inc. If any provision of this Agreement shall be deemed to be invalid, illegal or unenforceable, the validity, legality and
enforceability of the remaining portions of this Agreement shall not be affected or impaired thereby. The laws of the State of North
Carolina shall govern this Agreement.
Page iii
Additional References:
SDG Whats New.pdf
SDG Quick Start Guide.pdf
SDG 61850 Quick Start Guide.pdf
Office:
Triangle MicroWorks, Inc
2840 Plaza Place
Suite 205
Raleigh, North Carolina 27612
Phone: 919.870.5101
Fax: 919.870.6692
Email: [email protected]
Website: http://www.trianglemicroworks.com
Page iii
2.
3.
Overview ......................................................................................................................................................... 9
1.1 Purpose of this Manual........................................................................................................................... 9
1.2 Introduction to SDG ............................................................................................................................... 9
1.3 SDG Components ................................................................................................................................. 11
1.3.1 Master Components of the SDG ............................................................................................. 11
1.3.2 Slave Components of the SDG................................................................................................ 11
1.3.3 Master / Slave Data Flow ........................................................................................................ 12
1.3.3.1 Sequence from remote Slave devices to Master Component data collection ............ 12
1.3.3.2 Command Sequence from Remote Master Devices ................................................... 12
1.4 Data Point Addressing.......................................................................................................................... 13
1.4.1 Communication Channels ....................................................................................................... 13
1.4.2 Sessions ................................................................................................................................... 14
1.4.3 Sectors ..................................................................................................................................... 15
1.4.4 External OPC Servers ............................................................................................................. 16
1.4.5 The OPC Alarm and Event Server .......................................................................................... 17
1.5 Modem Pools........................................................................................................................................ 17
Installation and Setup .................................................................................................................................. 19
2.1 System Requirements ........................................................................................................................... 19
2.2 SDG Performance ................................................................................................................................ 20
2.3 Installing the SCADA Data Gateway................................................................................................... 20
2.4 SCADA Data Gateway Licensing ........................................................................................................ 21
2.4.1 Standard License ..................................................................................................................... 21
2.4.2 USB Key License .................................................................................................................... 22
2.4.3 License Manager ..................................................................................................................... 22
2.4.3.1 Requesting a Permanent License ............................................................................... 23
2.4.3.2 Installing/Updating a Permanent License .................................................................. 23
2.4.3.3 Remove an Existing License ...................................................................................... 24
2.4.3.4 Transferring a License ............................................................................................... 24
2.5 Running the SDG as a Service ............................................................................................................. 25
2.5.1 Installation, Removal and Setup.............................................................................................. 25
2.5.2 Service Configuration and Startup .......................................................................................... 25
2.5.3 Service Monitor ....................................................................................................................... 27
2.5.4 Service Events and Status Messages ....................................................................................... 28
User Interface ............................................................................................................................................... 29
3.1 Main Window....................................................................................................................................... 29
3.2 Configuration Window Interface ......................................................................................................... 30
3.2.1 Configuration Toolbar Menus ................................................................................................. 30
3.2.2 Configuration Window Menu Items ....................................................................................... 31
3.2.2.1 File Menu ................................................................................................................... 31
3.2.2.2 Edit Menu ................................................................................................................... 32
3.2.2.3 View Menu ................................................................................................................. 32
3.2.2.4 Window Menu ............................................................................................................ 33
3.2.2.5 Help Menu .................................................................................................................. 33
3.2.3 Context Menus ........................................................................................................................ 34
3.3 Protocol Analyzer ................................................................................................................................. 34
3.3.1 Protocol Analyzer Toolbar Menus .......................................................................................... 35
3.3.2 Protocol Analyzer Menu ......................................................................................................... 35
3.3.2.1 File Menu ................................................................................................................... 35
3.3.2.2 Edit Menu ................................................................................................................... 36
3.3.2.3 View Menu ................................................................................................................. 36
Page iv
3.4
Page v
4.
Page vi
4.6.2
5.
6.
7.
8.
Page vii
Table of Figures
Figure 1: SCADA Data Gateway.......................................................................................................................10
Figure 2: SDG Software Architecture ...............................................................................................................11
Figure 3: Slave to Master Component Data Collection ....................................................................................12
Figure 4: Commands passed thru the SDG .......................................................................................................12
Figure 5: Connection and Identification of Data Points...................................................................................13
Figure 6 Communication Channels ..................................................................................................................14
Figure 7 Sessions ..............................................................................................................................................15
Figure 8 Sectors ................................................................................................................................................16
Figure 9 Install/Update License tab ..................................................................................................................22
Figure 10 Remove License Tab .........................................................................................................................24
Figure 11 Example of Master to Slave and Master to Master Association....................................................110
Figure 12 TMW Simple OPC Client ................................................................................................................125
Figure 13 Event Log Record Format..............................................................................................................151
Page 8
1. Overview
The Triangle MicroWorks SCADA Data Gateway (SDG) application is a communication protocol driver. It
provides the values that the protocol transmits over the wire. It collects data from OPC Server, IEC 60870-5,
DNP3, IEC 61850, or Modbus Slave devices and then supplies this data to other control systems supporting
OPC Client, IEC 60870-5, DNP3, IEC 61850, and/or Modbus communication protocols.
1.1
This manual contains the necessary information required to install and configure the SCADA Data Gateway
(SDG) and provide descriptions of various aspects of configuring and using the SDG.
This manual covers the following topics:
1.2
Introduction to SDG
The SDG is a communication protocol driver, and it provides the values that the protocol transmits over the
wire. For example, it does not perform conversion of normalized and scaled values in IEC 60870-5-101 to
the equivalent floating point representation. However, this conversion can be done in the SDG through an
equation, as described in Section 4.3.5.7 Equation Field.
Page 9
Page 10
Multiple connections to remote master or slave devices can be made with each protocol component.
1.3
SDG Components
Page 11
The OPC Alarm and Event Server reports events to OPC Alarm and Event Clients running on the
same or a different computer.
The OPC Server Component is a specific Slave Component that communicates through the OPC
interface to other Windows software applications running on the same or a different computer.
Page 12
1.4
Points are the most indivisible level of data in the SDG. Master Data Points may be defined automatically for
OPC tags when the data is first received from a remote device. This is accomplished by setting the following
parameters in the tmwgtway.ini file:
Slave Data Points are created and associated with Master Data Points or Equations in the Point Mapping file.
Master Data Points are placeholders for data calculated by equations or collected by Master Components
from Remote Slave Devices. Slave Data Points are placeholders for data in the SDG that are available to
remote Masters. The identity of the sector for each data point specified in the Point-Mapping file (channel,
link Address, ASDU address) must correspond to a sector defined in tmwgtway.ini.
Data points are identified by their physical connection to the SDG and the addressing within the
communication protocol configured for the remote device. The following diagram illustrates how the SDG
connects to and identifies each data point. While this diagram shows a Master Component of the SDG
connected to several remote slave devices, the same point identification scheme is used for Slave
Components communicating with remote Master devices.
Page 13
1.4.2 Sessions
A session is a communication connection between the SDG and a remote device. A session is identified by a
specific link address on a communication channel. If more than one device is attached to a SDG
communication channel (multi-drop topology), the link address is used to select the device or SDG Slave
Component that should receive the message. The session establishes a virtual connection between the SDG
and a remote master or slave device.
IEC60870-5-104 only supports one session per channel; hence the session or link address is not
required for this protocol.
Communication protocol specifications supported by the SDG use the ISO protocol standards for the
Application (7), Data Link (2), and Physical (1) Layers. It should be noted, the term session in this product
and the associated documentation does NOT refer to the defined ISO Session (5) Layer.
Page 14
Figure 7 Sessions
The parameters associated with the session include an index to the communication protocol and most of the
communication protocol related settings. Each session using the same communication channel must have a
unique data link address. Since the IEC60870-5-104 only supports one session per channel, the data link
address is not required. For more information, refer to Session Configuration and subsequent sections in
tmwgtway.ini.
PC COM ports are typically RS-232 interfaces, which only permit connection to a single remote
device. To permit connection to multiple remote devices, as shown in Figure 7, it may be
necessary to use some form of multi-drop interface device such as an RS-232 to RS-485 converter.
1.4.3 Sectors
In IEC 60870-5 protocols, each session may contain more than one sector. Each Sector is a group of data
contained within a single Session. In these protocols, each sector corresponds to a single Common Address
of ASDU. DNP3 does not support sectors and hence does not require a Common Address of ASDU.
Page 15
Figure 8 Sectors
Each sector is identified in tmwgtway.ini by both its session index and sector index. The sector ASDU
Address must be unique within the session. If a remote Slave device or a Slave Component consists of only
one sector, the ASDU address is normally set to the same value as the link address. Refer to the Database
Configuration section of tmwgtway.ini.
In the Point-Mapping file, the following identify the sector:
Communication Channel
Data Link Address
ASDU Address
Page 16
1.5
Modem Pools
The SDG supports the concept of modem pools (a group of modems that can either receive or dial telephone
calls). Multiple modem pools can be configured in the SDG where each pool is a group of modems managed
by the pool. The modem pool acts as a dispatcher for the modems in its pool. For instance, when a Modem
Pool Channel decides it needs to send some data it asks the modem pool for a modem. If a modem is
available, the physical modem is connected to the modem pool channel. The modem pool channel then dials
its configured telephone number and establishes a connection with its peer device. If a modem in the pool
receives a call it will answer the call and establish a connection with the caller, receive the incoming data,
and then determine if the data is destined for any of the session/channels configured in the SDG. However,
this requires that the addressing information of all sessions in the SDG is unique regardless of the channel
that they are associated with. Addresses must be unique because the incoming message is parsed to
determine which session the message is intended for.
Page 17
The following illustration represents a typical set of master channels using 3 modems:
In the illustration above, there are 6 Modem Pool Channels that share 3 physical modems. Each of the
Modem Pool Channels is configured to connect to a single Modem Pool. In addition it is assumed that the
sessions are Master Sessions. The Modem Pool is responsible for managing the 3 Modems. As the modems
become available and requests are made by the Modem Pool Channels, the Modem Pool handles these
requests and provides them to the available modem(s).
To use this type of configuration effectively, the communications load on each Modem Pool Channel must
not be continuous (i.e. The Idle timeout value should be utilized to force a modem to become available when
there are no communications requirements on a Modem Pool Channel). The rate at which requests are made
of the slave device should be greater than the idle timeout. This allows each channel to take turns using the
modems. When the idle timeout occurs, the modem is made available for use by another channel. Each
physical modem should be configured for dial out and be enabled (these are the default settings). Each
Modem Pool Channel should also be configured for dial out with a telephone number specified for its
corresponding slave device.
Page 18
System Requirements
The Triangle MicroWorks SCADA Data Gateway (SDG) is a Windows based application and is supported
under the following operating systems:
Page 19
2.2
SDG Performance
The performance of the SDG depends on a number of factors, including the number of data points; the
number of channels/sessions/sectors; the frequency at which data changes; and the capabilities of the host
PC. Also, the number and types of other applications running on the host PC can also affect overall system
performance. Consequently, it is difficult if not impossible to characterize the performance on various
systems.
Listed below is information on the limitations of the SDG to consider when trying determining system
performance:
The 250 session limit is per SDG. For example, you could have one channel with 250 sessions; or 250
channels with one session per channel; or 50 channels with 5 sessions per channel; etc.
2.3
The SDG application is provided as a self-installing executable file (SDGVmnn.exe where m is the major
release and nn is the minor release). To begin installing the SDG application double-click the SDGVmnn.exe
file and follow the on-screen instructions.
In addition to installing the required files on your system, the installation application performs the following
steps:
1. Creates entries in the StartAll Programs menu for the selected protocols.
2. If running on Windows NT/2000/XP it will run the setupex.exe program found in the installation
directory to install the drivers required by the licensing software.
To run the SDG application, select StartAll Programs->Triangle MicroWorksSCADA Data Gateway
folder from the Start Menu or double-click the tmwgtway.exe file located in the installation directory. Refer
to the Quick Start Guide for information on configuring the SCADA Data.
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 20
To reinstall or remove the SDG application, run the installation process again or select Add/Remove
Programs from the Control Panel.
2.4
The SDG uses a software licensing mechanism, which supports the licensing of individual components of the
SDG product. When the SDG is run for the first time, a demo license will be generated which enables all of
the SDG components for 21 days. To obtain a permanent license specific to the components you have
purchased, please contact Triangle MicroWorks before the end of the evaluation period.
The SDG supports the following, individually licensable, components:
Component
IEC60870-5-101 Master
IEC60870-5-102 Master
IEC60870-5-103 Master
IEC60870-5-104 Master
IEC60870-5-101 Slave
IEC60870-5-102 Slave
IEC60870-5-103 Slave
IEC60870-5-104 Slave
IEC 61850 Client
Distributed Network Protocol Master
Distributed Network Protocol Slave
Modbus Master
Modbus Slave
OLE For Process Control (OPC) Server
OLE For Process Control (OPC) Alarm
and Event Server
OLE For Process Control (OPC) Client
OPC XML Server
OPC XML Client
Symbol
M101
M102
M103
M104
S101
S102
S103
S104
IEC 61850 Client
MDNP
SDNP
MMB
SMB
OPC Server
OPC Alarm and Event
Server
OPC Client
XML Data Access
Server
XML Data Access
Client
Status
Currently Supported
Future
Currently Supported
Currently Supported
Currently Supported
Future
Future
Currently Supported
Currently Supported
Currently Supported
Currently Supported
Currently Supported
Currently Supported
Currently Supported
Currently Supported
Currently Supported
Currently Supported
Future
Page 21
Page 22
Permanent licenses have an Expires date of Never and do not expire. The Expires date is currently
only used for temporary or evaluation licenses. The MP Expires date indicates when the Maintenance
and Enhancement Plan expires. A valid Maintenance and Enhancement Plan entitles you to free product
updates and technical support. You will not be able to install updated versions of the SDG after the MP
Expires date.
2.4.3.1 Requesting a Permanent License
Once you have purchased the desired SDG components, you will need to obtain a permanent license from
Triangle MicroWorks. SDG licenses are machine specific. The following steps will collect the
information needed in order to issue the permanent license for your machine. If the computer is connected
to the Internet and has an email client, the information will be directly mailed to Triangle MicroWorks.
Otherwise, the information will be saved to a file (SDGlicenseRequest.tlr) which you can email to Triangle
MicroWorks ([email protected]) from another computer.
To request a permanent license for the SDG, please follow the instructions below:
1. Start the SCADA Data Gateway
2. Go to the Help menu and select License Quote Request
3. Next, on the provided dialog screen, if you would like to license a USB device, select Yes.
Select No to license to the workstation. (There is an additional cost for licensing a USB Key.
Please contact Triangle MicroWorks for more details.)
4. Complete the information on the License Quote Request dialog screen. Be sure to include the
requestor information as well as applicable components and protocols.
5. If the workstation is connected to the Internet and there is an email client installed on the
workstation, click the Email It button to email the request to Triangle MicroWorks; otherwise,
click the Save As button to email from later or from another workstation.
When requesting a USB key license, please ensure that all other USB devices are disconnected from the
PC during this process. Devices such as USB hard drives and USB network adapters may cause conflicts
with the device you are trying license. After the license has been installed on your USB device, you can
reconnect the other devices back to the PC.
Page 23
2.4.3.3
Remove an Existing License
If required, an existing license may be removed from a machine using the Remove License tab shown
below. Once this operation is complete the SDG will no longer be licensed on that machine. This
process will create a unique confirmation key that can be returned to Triangle MicroWorks to confirm that
the license is no longer in use.
Page 24
2.5
This section describes how to run the SDG as a Windows Service. A Windows Service is a process that runs
in the background. Typically a service starts when the system boots, although this behavior can be modified
through the use of the service management console. Some advantages of running the SDG as a service
include:
No login required
Service can run under a separate user account
Application starts automatically when the computer boots
Casual users can not accidentally stop the application
The SDG can run as a service or as an interactive application, it cannot run as both at the same time. The
interactive application (i.e., GUI SDG) mode is used to configure the SDG communications parameters, point
mapping, etc. This configuration process results in an INI and CSV file that the service version of the SDG
will later use to configure itself when it starts.
The SDG configuration can be created and tested interactively using the GUI version and then, when the
configuration/testing process is complete, the SDG service can be started as a service from the service control
panel as outlined below. To make changes to the configuration the service must be stopped before the GUI
can be started.
2.5.2
In most configurations the service settings INI file will be the same as the paths INI file (which is used for the
GUI SDG application). Use the options dialog box, to specify the INI file for the service. This dialog box is
available from the view menu in the GUI version of the SDG. By default when the SDG GUI shuts down it
can ask if you would like to start the SDG service. This question can be disabled by un-checking the Ask to
Start SDG Service on GUI exit checkbox. To have the SDG service automatically start when you exit the
GUI, check the Automatically Start SDG Service on GUI exit radio button. When the GUI starts, if the
service is running you will get the option to shut the service down. As stated above the service and GUI can
not run at the same time. The following dialog is used to configure these options:
Page 25
To start/stop and configure the SDG service startup up behavior, the service control panel is used. It can be
accessed by selecting All ProgramsTriangle MicroWorksSCADA Data GatewaySDG Service
ConfigurationStart or Stop SDG Service from the Start Menu. The service control panel is shown below:
Page 26
The name of this service is GTWService. Right-clicking on this entry will bring up a context menu that can
be used to Start/Stop and set the properties of the GTWService. When setting the properties the following
dialog appears:
The Startup type is used to specify how the service starts up. Automatic will cause the service to start when
the system boots; Manual is used if you want to manually start the service at a later time. Manual is the
recommended setting during SDG configuration and testing. See the help for the Windows Services Control
panel for explanations of the other configuration features of a service.
Page 27
The Event log along with the protocol analyzer log should be used to troubleshoot problems.
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 28
3. User Interface
3.1
Main Window
The SDG User Interface is a Multiple Document Interface Application, with 2 document types; a
Configuration document and a Protocol Analyzer document. The main window is a container for both of
these document types. Each document type can have multiple views of the same document data, allowing the
user to see the configuration and protocol information in various different ways. The menus are context
sensitive depending on which document type is currently selected. In addition context sensitive help is
provided for certain fields on the configuration dialog boxes. Below is a screenshot of the main SDG
application window with the configuration document/view at the top and the protocol analyzer
document/view on the bottom.
Page 29
3.2
Below is the Configuration window expanded within the SDGs main window:
On the left is a hierarchical view of the current SDG configuration which includes:
(1) Gateway at the root of the hierarchy
The configured devices with the:
o (2) Channel
o (3) Session
o (4) Sector
o (5) Data Type(s)
In the upper right is a list of points (6), which displays their current value, quality, etc (if appropriate). In the
lower right is the Point Mapping view (7), which displays the current mapping of master to slave data points.
The configuration user interface is used to both configure as well as monitor the SDG.
Page 30
(1)
(2)
(3)
Save - Saves the current configuration to the tmwgtway.ini and tmwgtway.csv files.
Exit with Save - Exits the SDG and saves the INI and CSV files.
Exit without Save - Exits the SDG without saving the INI and CSV files.
Page 31
(1)
(2)
(3)
(1)
(2)
(3)
(4)
(5)
Page 32
(1)
(2)
(3)
(4)
(5)
(6)
(1)
(2)
(3)
(4)
(5)
(6)
(7)
(8)
(9)
(10)
(11)
Page 33
3.3
Protocol Analyzer
The protocol analyzer window allows you to monitor communications between the SDG and external
devices. Below is the Protocol Analyzer window expanded within the main SDG window.
Page 34
At the top is the Filter bar (1) which determines the content of the Protocol Analyzer display by selecting
checkboxes to customize the filters.
On the left is the Device Filter (2). This filter allows you to select which channels, sessions, and sectors will
get displayed.
On the right is the Communications Display, Protocol Analyzer log, (3) which shows the communications
between the SDG and external devices.
(1)
(2)
(3)
(4)
(5)
Page 35
(6)
(7)
Exit with Save - Exits the SDG and saves the INI and CSV files.
Exit without Save - Exits the SDG without saving the INI and CSV files.
**
The Protocol Analyzer buffer will then be saved to the specified file, which will also
become the current analyzer file. All subsequent save operations will save the
protocol analyzer log to this file.
(1)
(2)
Copy Copies the selected text in the Protocol Analyzer log to the Windows clipboard.
Find Text Opens a dialog screen for searching the Protocol Analyzer log for a particular text.
(1)
(2)
(3)
(4)
(1)
(2)
Set Buffer Controls the size of the Protocol Analyzer log buffer.
Font Set the font for the Protocol Analyzer display.
Page 36
(1)
(2)
(3)
(4)
(5)
(6)
(1)
(2)
(3)
(4)
(5)
(6)
(7)
(8)
(9)
(10)
Page 37
Filter (1) - contains a checkbox for each of the protocol layers (User, Application, Transport, Data
Link, and Physical, MMI, OPC). Only layers that are checked will be displayed in the Protocol
Analyzer windows. The Errors check box determines whether error messages will be displayed in
the Protocol Analyzer window.
Database (2) - controls whether Static, Cyclic, and Event Header and Data are displayed.
Timestamp (3) - determines whether timestamps will be displayed for all messages in the Protocol
Analyzer window.
Window Controls (4)
o Pause checkbox - when checked, pauses the Protocol Analyzer display. Use caution when
using this option because data can be lost while the display is paused.
o Clear button - clears the Protocol Analyzer display window.
The Clear All and Set All buttons (1) provide a convenient means of selecting or clearing all devices
layers.
The device filter includes the connected devices:
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 38
Channel (2)
Session (3)
Sector (4)
Checking and un-checking an item does not affect the items below it. Thus, it may be necessary to expand
items in order to fully view which items will be displayed. For example, in the above diagram, the MDNP
channel is not checked. However, it is possible that the Session Layer below the MDNP channel is
checked.
Changes made to this box from the Print option will be used for the current print session. Changes made to
this box from the Print Setup item will be used by subsequent Print operations unless the Print dialog box is
used to override them at the time of printing
The Print option from the File menu displays the dialog box shown above. This dialog box can be used to
select a printer, select printer options, and number of copies to print.
Page 39
Option
Percentage of Lines to Remove
When Full
Max Protocol Analyzer Line Count
Enable Save to File
Description
the number of lines that are removed when the buffer becomes full
(in order to make room for new lines)
sets the maximum number of lines in the display window
Determines whether the Protocol Analyzer log is saved to a file
automatically. This option is convenient for saving traces that are
larger than the buffer size. When this block is checked you can
specify the path and name of the file where the log will be saved
Page 40
3.4
Page 41
Property
Use System Clock
Description
If set to true, the date and time will always be read from the Windows
system clock as opposed to an internally maintained clock. The internal
clock is initialized to the Windows system clock at startup but will be
adjusted whenever clock synchronization is received from an external
master. You would generally set UseSystemClock to true if you have an
external clock synchronization mechanism that synchronizes the Windows
system clock outside the SDG. In this case it is advised that
AcceptClockSync be set to false.
If set to true and UseSystemClock is true, the Windows system clock will
be adjusted by a time sync received from an external master device. If set
to false, the time syncs will not adjust the Windows system clock. When
using a simulated clock, this setting has no effect and clock syncs are
always accepted and adjust the simulated clock.
Page 42
Maximum amount of time between saving the INI and CSV application
configuration files. The INI file is only saved if a change has been made.
A value of 0 will disable saves.
Specifies whether the SDG starts minimized normal, or maximized.
- Specifies the source of the time tag for data points which are generated as
the result of an equation. The possible values are Update or Reported
where Update means the time, relative to the SDG system clock, at which
the equation was last calculated, Reported specifies the reported time of
the most recent event that caused the equation's result to change. Reported
time will be relative to the remote slave device's system clock except on
initialization where the SDG's system clock is used until the first event
with time is received. It is important to note that static data polling, or
received events which do not specify a reported time, may cause a specific
data point's value to change without its event time being modified. Based
on system polling rates and other parameters this could result in
discontinuous times being reported, especially in equations that have inputs
from multiple slave devices.
Event Log File Name and Path. See manual for a description of the
available %xxx property keywords.
Event Log record format. See manual for a description of the available
%xxx property keywords.
Maximum amount of time between writing to the event log file before it is
flushed to disk. Set to zero to inhibit explicit flushing. This parameter
may be useful if another application reads the event log file to obtain event
data in real time.
Sequence Of Events Queue File Name and Path. [DEFAULT:
SDG_SOEQueueFile]
If set to true, the SOE Queue will be enabled. Possible values are 0, 1,
'FALSE', or 'TRUE'. [DEFAULT: FALSE]
The interval at which an OPC client requests status information from its
server. If the client does not wish to request status updates set this to 0.
Possible values are from 0 to 30000. [DEFAULT: 1000 ms]
Specifies the source of the time tag for OPC data points. The possible
values are Update or Reported. Update means the time, relative to
the SDG system clock, at which the data point was last updated.
Reported specifies the reported time of the most recent event that caused
the data to change. Reported time will be relative to the remote slave
device's system clock except on initialization where the SDG's system
clock is used until the first event with time is received. Static data polling,
or received events which do not specify a reported time, may cause a
specific data point's value to change without an event being generated;
hence the event time will not change.
Page 43
Specifies the source of the time tag for OPC Alarm and Event data points.
The possible values are Update or Reported. Update means the
time, relative to the SDG system clock, at which the data point was last
updated. Reported specifies the reported time of the event that caused the
data to change. Reported time will be relative to the remote slave device's
system clock except on initialization where the SDG's system clock is used
until the first event with time is received. Static data polling, or received
events which do not specify a reported time, may cause a specific data
point's value to change without an event being generated; hence the event
time will not change.
The log mask is a bitmap of the values. The mask can be applied to the
Event Log File and/or the OPC Alarm and Event Server.
Possible values are:
0x0001 The data is being updated, but the reason for the update is
unknown.
0x0002 The data is being updated because it was requested.
0x0004 The data is being updated by the source of data without direct
request. No change is necessarily indicated.
0x0008 A change in the data is indicated by the source of data.
0x0010 A change in the data is indicated due to a request through
communications.
0x0020 A change in the data is indicated due to action at the device.
0x0040 A control request has been transmitted to a remote device.
0x0080 A control request has been confirmed by a remote device, but is
not yet complete.
0x0100 A 1st pass in a 2-pass control operation has been transmitted to a
remote device.
0x0200 A 1st pass in a 2-pass control operation has been confirmed by a
remote device.
0x0400 A cancel operation has been transmitted to a remote device to
abort a 2-pass control operation between the 1st and 2nd passes.
0x0800 A cancel operation has been confirmed by a remote device.
0x1000 A remote device has responded to indicate an error in a control
operation.
0x8000 Either the data point or the remote device is operating in a test
mode.
Page 44
Diagnostics
Control
Equations
OPC Data Access
Subscription
Description
Each bit enables (1)/disables (0) a reason to log errors, such as changes
in number of link layer checksum failures or in link session online/off-line status, in the event log file. If 0, nothing will be logged.
Each bit enables (1)/disables (0) a reason to log diagnostic data, such
as change to the number of transmitted frames, in the event log file. If
0, no diagnostics data will be logged.
Each bit enables (1)/disables (0) a reason to log control data, such as
changes to pollEnabled or to GeneralInterrogationPeriod, in the event
log file. If 0, nothing will be logged.
Each bit enables (1)/disables (0) a reason to log results of equations. If
0, no equation results will be logged.
Each bit enables (1)/disables (0) a reason that an item subscription
through the SDG OPC Data Access Server should enable OPC Alarm
and Event notifications for the item. This mask overrides all other
masks if enabled. If 0, no OPC Alarm and Event notifications will
occur as a result of an item subscription.
If true, all OPC AE events are reported as simple events. Possible
values are 0, 1, 'FALSE', or 'TRUE'.
The Edit at Runtime checkbox allows you to make changes to the SDG properties
without having to restart the application. If you make changes and this option is not
checked, then you will need to re-start the SDG for the changes to take effect.
Once you have added all the modem pools you require, the SDG configuration window will display these
items under the ModemPools node as shown below:
Page 45
Next, to add a modem to the pool right-click on the desired modem pool element and select Add Modem to
display the Add Modem dialog screen:
Most of the configuration parameters on this dialog screen are the same as those for a serial port. The ones
that are different are described below.
Parameter
Modem Name
Initialization String*
Description
A name used to refer to and identify the modem
Specifies the initialize string that is sent to the modem when the modem is
opened
Page 46
Hangup String*
Dialing Mode
Read Command Timeout
Write Command Timeout
Response Terminator
Character
No Dial Out
Enable
Specifies the hang up string that is sent to the modem when the modem is
closed
Sets the dialing mode of the Modem: 'pulse' - use pulse dialing. 'tone' - use
tone dialing
Specifies the timeout in seconds that the SDG waits for a modem to respond
to a command
Specifies the timeout in seconds that the SDG waits to send a command to a
modem
Sets the character used to terminate a response from the Modem: 'none' don't use a character to terminate the response (assumes the modem is set up
with no command responses (i.e. ATQ1)). 'line feed' - use a 'line feed'
character to terminate the response. 'carriage return' - use a 'carriage return'
character to terminate the response
If TRUE, the modem will be configured for receiving telephone calls only
If set to true, the modem will be Enabled and Available for use. This can be
used to perform maintenance on the modem
* The Initialization String and Hang-up String must be compatible with the Hayes AT
command set.
Attention!
Escape Sequence
Pause
Repeat Sequence
Answer Mode
Select Communication Protocol
Transmission Carrier
Dial Control
Echo
Data Mode Echo
Hook Select
Report Modem Information
Set Speaker Volume
Set Speaker Mode
Automode Selection/Detection
Retrain Selection
Pulse Dialing
Result Codes to DTE
Status Registers
Tone Dialing
Format of Result Code
Extended Result Codes
Result Codes for Call Progress
Long Space Disconnect
Soft Reset and Restore
All modems on the computer system required by the SDG need to be configured in this way. The modems
will have to be available in the Operating System prior to adding them to the SDG.
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 47
Once the modem pool configuration is complete, the SDG configuration window will display these items
under the ModemPools node as shown below:
3.4.4 Channels
Channels have a protocol associated with them, as a result all session associated with a channel will have the
same protocol. In the user interface channels are containers for sessions. A channel can be TCP/IP, Serial
or, a Modem Pool Channel.
Page 48
Parameter
Session Protocol
IP Address / None Name
Mode
IP Port Number
Alias Name
Description
Sets the protocol for the channel. Possible values are 'S101', 'S104',
'M101', 'M103', 'M104', 'MDNP', or 'SDNP'
Sets the Communication Channel. Examples: "192.168.1.25" or "node
name"
Sets the connection mode to use. Possible values are 'server', or 'client'.
Typically Slaves are servers and Masters are clients
Sets the TCP/IP port number to use
Name for communications channel, this must be specified
Parameter
Session Protocol
COM Port
Baud Rate
Parity
Description
Sets the protocol for the channel. Possible values are 'S101', 'S104',
'M101', 'M103', 'M104', 'MDNP', or 'SDNP'
Sets the Communication Channel. Examples: "COM1", COM2,
COM3, etc
Sets the baud rate for corresponding serial port.
Sets the parity for corresponding serial port. Possible values are 'none',
Page 49
Data Bits
Stop Bits
Flow Control
Alias Name
'even', or 'odd'
Sets the number of data bits for corresponding serial port. Possible values
are '7', or '8'
Sets the number of stop bits for corresponding serial port. Possible values
are '1', or '2'
Sets the mode of the serial Channel.
Possible values are:
none - use no flow control.
hardware - use hardware flow control. Hardware flow control is
configured by the SDG as shown in the table below
windows - use flow control and serial parameters (baud rate,
parity, etc.) as specified with the Windows MODE command (For
information on the Windows Mode command, type help mode in a
Windows Command window).
The period at which the sessions on the channel are polled if they are
offline. This parameter only applies to serial DNP and Modbus master
sessions on this channel. A value of zero (0) will disable this feature
Name for communications channel, this must be specified
Parameter
Session Protocol
Dial Out
Description
Sets the protocol for the channel. Possible values are 'S101', 'S104', 'M101',
'M103', 'M104', 'MDNP', or 'SDNP'
Specifies if the channel will dial or not. If the check box is checked the
channel will attempt to dial the telephone number on a modem specified in
Page 50
Modem Pool
Phone Number
Wait For Answer
Redial Attempts
Idle Time
Alias Name
the Modem Pool field. If the check box is not checked the channel will be
configured to only answer telephone calls
The modem pool this channel will use for communications. A free modem
in the modem pool must be available for the channel to attempt dialing
The telephone number of the peer device that this channel will dial when
making a connection
Sets the amount of time in seconds the modem will wait for an answer from
the peer device. If the peer device does not answer in this time period a new
dial attempt will be made
Sets the number of times the channel will attempt to dial the remote device.
If the remote device cannot be reached the channel is disabled, and must be
manually re-enabled. To re-enable the channel the
ChannelRedialLimitControl MDO must be set to false. This internal MDO
indicates true when the redial limit is reached
Sets the number of seconds the modem will stay connected after there is no
more data to send or receive. If more data is sent or received on the modem
the timeout period starts over. This parameter is useful for disconnecting the
modem when there is no communications activity. If this value is set to 0
the idle timeout is disabled (i.e. the modem will not automatically hang up)
Name for communications channel, this must be specified
3.4.5 Sessions
The session dialog boxes are protocol specific, only the configuration parameters required for the selected
protocol on the Channel configuration dialog box are displayed.
For all Session types the following fields are defined here:
Parameter
Absolute Response Timeout
Incremental Response
Timeout
Description
Default application response timeout. This value is the maximum
amount of time (in milliseconds) that will be allowed before a
command is cancelled due to timeout. This time starts when the request
is submitted and ends when the final application level response is
received. This value can generally be overridden for specific data
points by the 'TO' option in the point mapping file
Maximum amount of time (in milliseconds) to allow between messages
from a remote device when a request is pending to that device. The
message need not be a direct response to the pending request. If no
message is received from the remote device within this period it is
assumed the device has terminated processing of the request and the
request is cancelled due to an application level timeout. This timer is
restarted every time a message is received from the remote device
Page 51
IEC 60870-5-101
Parameter
Controlled Station Link Address
Link Mode
Link Max Retries
Description
Data link address of slave component or remote device. Each
Address identifies a unique session, which is a link layer
connection between a Master and a Slave device. Set to 0xffff
(65535) for the session to be a "broadcast session".
Data link transmission mode. Required for each communications
channel. Possible values are 'balanced', or 'unbalanced'
Maximum number of attempts to re-transmit data link-layer
frames that were not confirmed. This parameter does not apply
for link layer connections (sessions) when the GATEWAY is
acting as an unbalanced slave
The maximum amount of time (in milliseconds) to wait for a
confirmation of frame. For an IEC 60870-5-104 session this is
the T1 parameter. This parameter does not apply for link layer
connections (sessions) when the GATEWAY is acting as an
unbalanced slave
Number of octets (bytes) in link Address field. A value of 0 is
only valid for sessions whose link mode is balanced. This
parameter is only used for IEC60870-5-101 master and slave
sessions. Possible values are from 0 to 2
For an unbalanced master communication link, the minimum
delay (in milliseconds) after sending request for class 2 data
when an application layer response is not pending for this
Page 52
Page 53
Originator Address
3.4.5.1.2
IEC 60870-5-103
Parameter
Controlled Station Link
Description
Data link address of slave component or remote device. Each Address
Page 54
Address
Page 55
3.4.5.1.3
IEC 60870-5-104
Parameter
T1 - Link Acknowledge
Timeout
T2 Send Acknowledge
Delay
T3 Test Frame Interval
K Transmitted
W Received
Originator Address
Description
The maximum amount of time (in milliseconds) to wait for a
confirmation of frame
Maximum time (in milliseconds) to wait to send an Acknowledge
frame
Time (in milliseconds) for the Test Frame interval
Maximum number of unacknowledged transmit frames
Maximum number of unacknowledged received frames
Originator address (for 2-octet COT). Possible values are from 0 to
255
Page 56
3.4.5.1.4
Master DNP3
Parameter
Session Name
SDG Local Link Address
Remote Device Link Address
Link Confirm Mode
Description
Optional parameter for setting the Session Name to a custom value
Data link address of the local device
Data link address of the remote device
Request the remote device to send a data link layer confirm of the last
frame sent. This setting is independent of whether the remote device
will require this device to send a data link confirm to frames it receives
Each bit enables (1) or disables (0) an automatic request. This
parameter is only used for master or slave sessions using the DNP3
protocol
Possible values are:
0x001
clear restart upon RESTART IIN
0x002
integrity poll upon RESTART IIN
0x004
integrity poll upon LOCAL IIN on-then-off
0x008
integrity poll upon timeout of previous request
0x010
integrity poll upon BUFFER OVERFLOW IIN
Page 57
0x020
0x040
0x080
0x100
0x200
0x400
Enable Unsolicited Event
Class
Create from Device
Create Tags from XML File
DNP3 Secure Authentication
Parameter
HMAC Algorithm
Reply Timeout (ms)
Key Change Interval (ms)
Description
HMAC algorithm to be used in challenges.
How long to wait for any authentication reply.
For Master: Session key interval. When time since last
key change reaches this value, session keys will be
Page 58
3.4.5.1.5
Modbus Master
Parameter
Controlled Station Slave Address
Description
Data link address of remote device. Each Address identifies a
unique session, which is a link layer connection between a
Master and a Slave device
Page 59
IEC 60870-5-101
Parameter
SDG Link Address
Link Mode
Link Max Retries
Description
Data link address of slave component
Data link transmission mode. Required for each communications
channel. Possible values are 'balanced', or 'unbalanced'
Maximum number of attempts to re-transmit data link-layer frames
that were not confirmed. This parameter does not apply for link layer
connections (sessions) when the GATEWAY is acting as an
unbalanced slave
Maximum time to wait for confirmation of frame. This parameter does
not apply for link layer connections (sessions) when the GATEWAY
is acting as an unbalanced slave
Number of octets (bytes) in link Address field. A value of 0 is only
valid for sessions whose link mode is balanced
Number of octets (bytes) in Common Address of ASDU (sector
address) field
Number of octets (bytes) in Cause Of Transmission (COT) field of
ASDU
Number of octets (bytes) in Information Object Address (point
number) field
Page 60
3.4.5.2.2
IEC 60870-5-104
Parameter
T1 - Link Acknowledge Timeout
T2 Send Acknowledge Delay
T3 Test Frame Interval
K Transmitted
W Received
Description
The maximum amount of time (in milliseconds) to wait for a
confirmation of frame
Maximum time (in milliseconds) to wait to send an Acknowledge
frame
Time (in milliseconds) for the Test Frame interval
Maximum number of unacknowledged transmit frames
Maximum number of unacknowledged received frames
Page 61
3.4.5.2.3
Slave DNP
Parameter
Session Name
SDG Local Link Address
Remote Device Link Address
Link Confirm Mode
Description
Optional parameter for setting the Session Name to a custom value
Data link address of the local device
Data link address of remote device
Request the remote device to send a data link layer confirm of the
last frame sent. This setting is independent of whether the remote
device will require this device to send a data link confirm to frames
it receives
If TRUE, the DNP3 Secure Authentication Settings dialog screen is
displayed.
Page 62
3.4.5.2.4
Modbus Slave
Parameter
Slave Address
Description
Data link address of local device. Each Address identifies a unique session, which
is a link layer connection between a Master and a Slave device
Page 63
3.4.6 Sectors
Parameter
Sector Address
EOI Action Mask
Description
ASDU address of the sector
Each bit enables (1) or disables (0) an automatic request to be sent as a
result of receiving an initialization message from a slave device. This
parameter is only used for IEC 60870-5 master sessions
Possible values are:
0x1
request a general interrogation
0x2
request a clock synchronization
0x4
request a counter interrogation
Each bit enables (1) or disables (0) an automatic request to be sent as a
result of a slave device coming online. This parameter is only used for
IEC 60870-5 master sessions
Possible values are:
0x1
request a general interrogation
0x2
request a clock synchronization
0x4
request a counter interrogation
Each bit enables (1) or disables (0) an automatic request to be sent as a
result of a slave device leaving blocking mode. This parameter is only
used for IEC 60870-5-103 master sessions
Possible values are:
0x1
request a general interrogation
0x2
request a clock synchronization
0x4
request a counter interrogation
Page 64
A Data Type is a container for MDOs or SDOs. After a sector or session (for DNP and Modbus) is specified
a Data Type can be added to it. The list of available types varies depending on the protocol.
When prompted to use a SCL/ICD/CID file for the configuration, click the Yes or No button:
Page 65
Parameter
Name
Connect Timeout (msecs)
Server IP Address
Server IP Port
Server MAC Address
Client IP Address
Client MAC Address
GOOSE Adapter
SCL File
Reconnect Time (msecs)
Reconnect Re-try Count
Use SCL File
Description
The name of the client.
The time to wait for a valid connection.
The TCP/IP address of the server to connect to.
The TCP/IP port number on the server to connect to.
GOOSE parameter to specify the server.
Specifies the IP address of this IEC 61850 Client. This can be useful to
select a different network adapter.
Specifies the MAC address of this IEC 61850 Client.
The adapter to use for GOOSE communications.
The SCL/ICD/CID file used to configure the client from.
How often to attempt re-connection if a connection fails.
How many time to reconnect (0 is forever).
To allow switching between and on-line configuration or an off-line
configuration.
At a minimum, configure the Name and Server IP Address. If the SDG and IEC 61850 server are running
on the same machine, use the default loopback address provided of 127.0.0.1. Click the OK button to
continue to add the client to the configuration.
Page 66
This will display the Add 61850 Report Control Block dialog screen:
Select any one of the Report Control Blocks from the list box on the left side of the Add 61850 Report
Control Block dialog box. The corresponding data set and its contents will be shown in the list box on the
right. Next, click the Add RCB button to add the report control block.
If the Report Control Block is already in use by a client, choose a different report control block or use a
Polled Data Set (right click on the IEC 61850 Client node in the tree again and select Add a 61850 Polled
Data Set)
The Report Control Block is now added and can be viewed by clicking on the 61850Client node:
Page 67
3.4.8.3 Adding an IEC 61850 Data Attribute from the Report Control Block
To add an IEC 61850 Item, right-click on the Report Control Block and select Add IEC 61850 Item:
This will display the Add 61850 Data Attribute dialog screen:
Next, select an item from the list and click the Add Item(s) button. To select multiple items at once, hold
down the control key and click the desired items. To select a range of items, click the first item and hold
down the shift key and click the last item. Use the filters at the bottom of the dialog box to limit the
number of Data Attributes Shown. Click the Done button when all items have been added.
Data Attributes can also be added from the keyboard by using the down arrow key to
scroll through the list and the enter key to activate the Add Item(s) button.
The Data Attributes now appear in the tree under the 61850Client node and in the list view:
Page 68
Note that the Data Attributes are treated in the SDG as any other Master Data Objects (MDOs). So they
can be mapped to other items and are available through the SDGs OPC Server.
This will display the Add an OPC AE Client dialog screen as shown below:
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 69
Next, click Find OPC Server and then select the desired OPC AE Server from the Select OPC AE Server
dialog screen. This dialog displays a list of OPC AE Servers available on the Server Node. Selecting
one of these servers places the value of the Prog ID field and the Node Name or IP address field into
the above dialog box. Click OK to continue.
Page 70
Parameter
Node Name or IP Address
Prod ID
Alias Name
Description
Specifies the Node name of the OPC AE Server to connect to
Specifies the PROG ID of the OPC AE Server to connect to
Optional Name for the OPC AE Server to connect to, if not specified
use the value of OPCAEserverProgID. It is strongly recommended
that this parameter be defined as an external OPC AE client may not
be able to browse for tags in SDG OPC AE server if the OPC AE
server name contains one or more period ('.') characters. To work
around this issue, define this alias name (with no periods for the
external OPC AE server, and reference the server by its alias.
The buffer time, specified in milliseconds, indicates the number of
times the event notifications may be sent to the subscription object.
This parameter is the minimum time spread between two successive
event notifications. The value 0 means that all event notifications
shall be sent immediately from the server. If the parameter MaxSize
is greater than 0, it instructs the server to send event notifications
quicker in order to keep the buffer size within MaxSizeSpecifies the
buffer time for the OPC AE Server subscription.
This parameter is the maximum number of events that may be
specified in a call. The value 0 means no restriction for the number of
events. Please note that if the value MaxSize is greater than 0, then
events can be sent faster from the server than through the BufferTime
parameter. Specifies the max size for the OPC AE Server
Page 71
subscription.
Specifies the reconnect timeout for the OPC AE Server (0 = no
reconnect).
Specifies the reconnect re-try count for the External OPC AE Server
(0 = attempt reconnects for ever)Setting the client refresh MDO will
cause the internal limit counter to be re-set to 0resulting in continued
connection attempts to the OPC AE server.
Page 72
Not all OPC AE servers support an Area Space. As a result, if the Area Space browsing is not supported
event source names will need to be entered manually. If Area Space browsing is supported, then event
source items can be selected in the Area Browser to create OPC AE MDOs.
By default when a source name is selected, a source_name.Event MDO is created. This MDO will receive
events for that source name in the OPC AE Server. The value of this MDO by default will be the message
value of the OPC AE event. Time and quality are always obtained from the OPC AE event.
To browse for an Event Source, click on the nodes to expand the tree and then click Add to add the desired
item:
Page 73
Page 74
To browse for an Event Attribute, click on the nodes to expand the tree and then click Add to add the
desired item.
The event is now displayed in the SDG Configuration window:
OPC AE Client MDOs can be created to represent these attributes. The value of these MDOs will be the
attribute value (i.e. x position or y position) but the quality and time stamp will be obtained from the event.
3.4.9.6 OPC AE MDO Options
To edit the OPC AE MDO options, right-clicking on an MDO and Selecting Edit OPC AE MDO.
Page 75
To view the available options for this item, click on the ellipse () button to display the Options Editor
dialog screen. Select the desired options, including the Value and the Use parameters. These items are
selected by clicking in the appropriate box to change the value. Click OK to continue.
Page 76
Parameter
ALIAS
EVENT_FALSE_MSG
EVENT_TRUE_MSG
EVENT_VALUE
LOGMASK
OPCAE_LOGMASK
OPCAESIMPLEEVENT
OPCAETIMEREPORTED
OPCAETIMEUPDATE
OPCREPORTMODEPOLL
OPCREPORTMODEREPORT
OPCTIMEREPORTED
OPCTIMEUPDATE
Description
used to parse the message string of the event and look for the string
specified if the string is found the MDO value will be set to false
used to parse the message string of the event and look for the string
specified if the string is found the MDO value will be set to true
used to specify/override the default message value for the event. (i.e.
EVENT_VALUE true will cause the MDO value to be true when the
event is received)
*
*
*Click on the ellipse () button to open the LOGMASK dialog screen which displays a
list of additional options for these items.
The following options are related to the OPC AE Client. However, these options are selected in the OPC
DA MDO Options dialog (covered in the next section).
Parameter
AE_INIT_VALUE_MDO
Description
used to specify the OPC AE MDO that will be initialized with the
value, quality and time stamp (VQT) of the Data Access MDO. Once
Page 77
AE_RESET_VALUE_MDO
AE_RESET_VALUE
initialized the VQT will not be applied again unless the OPC AE Client
disconnects from its server
used to specify the OPC AE MDO that will receive a VQT from the
OPC DA MDO if the AE MDO value is different from the DA MDO
value
in association with AE_RESET_VALUE_MDO is used to specify the
value of the OPC DA MDO that will cause the OPC AE MDO to be set
to the VQT of this OPC DA MDO when an OPC DA update is received
for this OPC DA MDO. Valid values for this options argument are
0,false,1,true, numeric value (float or integer) or some string.
If this option is specified the difference comparison in the
AE_RESET_VALUE_MDO option will not be used
This will display the Add an OPC Client dialog screen as shown below:
Page 78
Parameter
Node Name or IP address
Prog ID
Alias Name
Refresh Rate (msecs)
Description
Specifies the Node name of the OPC Server to connect to. This field
is automatically populated when you select a server.
Specifies the PROG ID of the OPC Server to connect to. This field
is automatically populated when you select a server.
Optional Name for the OPC Server to connect to, if not specified the
value of Prog ID is used.
Specifies the rate at which the OPC server that the client is
connected to will refresh the OPC client. This is a requested update
rate and that the server may actually no update the client at the rate
requested.
Specifies the reconnect timeout for the OPC Server (0 = no
reconnect).
Specifies the period at which properties are read (0 = don't read)
Specifies the reconnect re-try count for the External OPC Server (0 =
attempt reconnects for ever)Setting the client refresh MDO will
cause the internal limit counter to be re-set to 0resulting in continued
connection attempts to the OPC server.
Displays the Select OPC Server dialog screen.
Click the Find OPC Server button to display the Select OPC Server dialog screen:
Page 79
This dialog displays a list of available OPC servers on the Server Node. To select an OPC Server,
highlight the server name in the list (4) and then click the OK button to return to the Add an OPC Client
dialog screen. Complete the remaining fields, if required, and then click OK to continue.
To browse the list of available network node names, click the ellipse button (1) to display the Network
Node Names dialog screen:
Select the Node Name from the list and then click OK to return to the previous screen.
To define the server type select an option (1.0, 2.0, or General) under the Available Servers section (2).
Next click the Refresh button (3), if necessary, to refresh the list of available servers.
Page 80
OPC Client items are considered MDOs in the SDG. OPC Client items obtain their value from an external
OPC server. They are updated as the server provides them to the client. These points can be mapped to
other protocols or to another OPC Client.
To add an OPC Client item to your configuration, right-click on the OPC Client and select Add OPC
Client Item:
To add items, navigate the item tree (1) to the desired node and then select a value from the list on the
right. Click Add Item (2) to add the item to the configuration. Once all items have been added, click
Done (3) to return to the SDG main window.
Page 81
To view the properties of the OPC Client tag, click the Item Properties button (4). The Item Properties
dialog screen is explained in more detail below.
The Data Type group box (5) is used to override the SDG data type for the OPC point. If Use native type
is selected, the type is set to the type of the point in the OPC server. This ability to override the data type
can be useful if a server provides data as one type and it is convenient to change the type in the SDG to a
different type.
For example, if a server provides data as R8 (double float) and you want to map this to an IEC T50
(floating point set point command) it is useful to be able to change the type of the OPC client point to R4
(float) to facilitate the mapping.
Mapping the Refresh tag has to be done manually in the CSV file. When changed, this causes the server to
refresh all items in the client.
The following is an example of mapping an equation to the OPC Client Refresh tag in the CSV file:
Description
the equation name
the OPCClient name
the Refresh tag in the OPC client
the equation (myPB is an internal Boolean tag)
the type of Refresh (i.e. bool)
Refer to section 4.3.2 Mapping Points to an External OPC Server for additional information about OPC
Client Items.
Page 82
To add properties, select an item from the list (1) and then click the Add Property button (2).
To display the list of available options, click the ellipse button (3).
To refresh the list of available properties, click the Refresh button (4).
To view the attributes of the selected property, click the Attributes button (5).
Once the property is added to the SDG, it will appear with an underscore (_) appended to the end of the
OPC tag name:
This OPC Property can now be used like any other SDG MDO and can be mapped to other SDG points.
The description of the new MDO will become the description of the OPC property.
OPC properties are updated by setting the INI file configuration parameter
OPCserverReadPropertiesTime. This OPC Client configuration parameter can also be set by right-
Page 83
clicking on the OPC Client node and selecting Edit OPC Client. Next, adjust The Read Properties Time
field. A value of 0 will disable property reads.
A Change in quality or value of the property will cause a propagation of the quality or value to a mapped
SDO.
Page 84
Enter the Point Number (1) for this MDO and click the ellipse button (2) to select any require options for this
MDO.
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 85
The User Tag Name (3) and Description (4) parameters are optional and are used to provide further
description of the MDO.
The MDO is now added and can be viewed, or edited, by clicking the session:
After the point has been mapped, the Slave Data Object Editor is displayed:
Page 86
Enter the Slave Information Object Address (1) and then select any required options (2) for the Slave Point.
Click OK to return to the SDG main window.
The SDO is now added to the Slave Data Type:
Page 87
This will display the Internal Master Data Object Editor dialog screen. This dialog screen allows you to
define the User Tag Name (1), Options (2), and the Type (3) for the MDO. The Description parameter (4) is
optional:
Page 88
One use of Internal MDOs is to facilitate mapping of SDO points to other SDO points. Another use is to
provide a user modifiable source of data in the SDG. To use an Internal MDO to map between two slave
points, first create the Internal MDO of the desired type, then drag and drop the internal MDO onto the
desired command SDO (this will provide a value for the MDO), and then drag and drop the same internal
MDO onto the desired monitor SDO point (this will provide a value for the monitor SDO), see the diagram
below.
The value of a command SDO will be passed on through the Internal MDO to a monitor SDO.
Internal MDOs can be used just like any other MDO type in the SDG. However internal MDOs can accept a
value and provide a value to a mapped point.
To modify the current value and quality of an MDO, click on the Gateway node and then locate the internal
MDO in the item pane on the right. Next, right-click on the MDO and select Edit Internal MDO:
The following dialog boxes are used to manage the value and quality for various data types:
Page 89
To edit an Internal Boolean MDO Value, click the Value checkbox (1) to set the value to TRUE or
uncheck the checkbox to set it to FALSE. Click the Quality button (2) to edit the MDOs quality.
To edit an Internal Analog MDO value, enter a value in the Value textbox (1). Click the Quality button (2)
to edit the MDOs quality.
To edit the quality of an Internal MDO, select the appropriate checkboxes on the Quality Editor Dialog
screen. The quality can be a combination of the check boxes listed above. The numerical value is displayed
in the Value edit box.
Page 90
3.4.14 Equations
Equations are MDOs that obtain their value based on a calculation performed on one or more other points in
the configuration. To add an Equation MDOs to the configuration, right-click on the Gateway node and
select Add Equation:
This will display the Master Data Object Equation Editor dialog screen:
The equation editor makes it easy to create equations using a drag-and-drop approach. Equation operations
and database tags can be dragged and dropped from the Tag List (1) or Operations List (2) into the Equation
field (3). The Validate Equation button (4) can be used to verify the syntax of the equation prior to adding it
to the point list.
Page 91
One use of equations is to convert the raw value reported by the SDG into an IEC Normalized or Scaled
value. For example, to convert the reported value, which has a range of -32768 to 32767 to a Normalized
value, which has the range of -1 to +1-2-15, enter an equation to divide the reported value by 32768.
See section 4.3.5.7 Equation Field for more information on the options and restrictions for equations.
Page 92
The Option column (1) displays the option name. The Value column (2) is used to set the value of the option.
For Boolean options, in order to include the option the Value must be TRUE. The Use column (3) must be
set to Yes for the option to be included. To edit an option, click in the textbox next to the option to change the
value.
Page 93
The retry failed transaction part of this dialog screen is used to configure a retry of a timed out transaction,
the failed transaction will be retried for Count times at an interval of Period (ms). Once the transaction
succeeds again the retry count is reset to 0.
This will display the IEC Action Mask Editor dialog screen:
Page 94
This will display the DNP Action Mask Editor dialog screen:
Page 95
The DNPActionNow has a completion status MDO associated with it DNPActionNowStatus. This MDO is
used to display the current status of the DNPActionNow request. The following describes the meaning of
the values:
Status Value
0 (success)
1 (intermediate)
2 (failure)
3 (mismatch)
4 (statuscode)
5 (iin)
6 (timeout)
7 (canceled)
Description
Indicates the request has completed successfully
Indicates a response was received but the requested command is not yet complete.
This could mean the response is part of a multi-fragment response and did not
have the FINAL bit set. Or this could be a request such as a select operate that
requires multiple requests and responses.
Indicates that the transmission of the request failed
The response to a select or an execute did not echo the request.
The response to a select or an execute echoed the request, except the status code
was different indicating a failure.
The response to the request had IIN bits set indicating the command failed.
This indicates that the request has timed out. This could either be an incremental
timeout indicating we received no link layer frame from the device in the
specified time, or an application response timeout indicating this particular
request did not complete in the specified time.
This indicates either that the user asked that the request be canceled by calling
dnpchnl_cancelFragment or that a second duplicate request has been made and
therefore this first one is canceled.
Typically this can be used to indicate the DNPActionNow has completed and a reason why. This can also
be used to sequence a set of commands/requests on a multi-drop connection.
This will display the Modbus Action Mask Editor dialog screen:
Page 96
All data specified in the database will be read at the period specified by the mask period.
Transactions will be created based on an optimization algorithm and issued to a slave
device.
This dialog box is used to set the appropriate parameters of the slave data point.
Page 97
To map points from the OPC Master Component to other Master Components, drag a monitor MDO to an
OPC client. When the MDO is dropped on the OPC Client the following dialog box is displayed. Use this
dialog box to set the appropriate parameters of the OPC point.
MDOs can also be mapped to internal points (both predefined and user defined). When mapping MDOs to
these internal points they must already be defined. Select the source MDO and then drag it to a Gateway,
Session, Channel, or Sector node in the configuration tree. When the point is dropped on one of these
targets, a Tag Selector dialog will appear:
Page 98
This dialog allows the destination mapped point to be selected. When MDOs are mapped in this way, the
destination point must be writeable.
Once this operation is completed the source MDO will provide a value to the destination MDO.
Page 99
3.4.24 Tags
Tags are added to a data type in the configuration interface. Tags can be MDOs, SDOs, Equations, or OPC
Client items. Slave Data Objects are created indirectly by mapping MDO, Equations, Internal Points, or OPC
Client items to them. See section 4.3.5 Definition of Fields contained in the Point Mapping File for
additional information about the fields on the below dialog boxes.
Page 100
The Auto Refresh Time (1) sets the rate at which the point list in the configuration window is refreshed.
Setting this value to 0 disables the refresh operation. When enabled the values of all the points displayed in
the list are updated from the internal SDG database at the rate specified.
The Paths group is useful to define the location of the SDG INI file and help file. Note that if running as an
OPC server (started by an OPC client), the SDG needs this information to accurately locate the INI file and
help file. When started by an OPC client, the default path if not specified, is dependant on the OPC client
and operating system (this usually defaults to C:\winnt\system32).
The Enable Use of Path setting (2) causes the SDG to look in the specified directory during startup for the
tmwgtway.ini file, if checked. By default during installation these paths are initialized to the location of the
SDG executable file. To change the path of the INI file, click on the ellipse (3) next to the INI File parameter
and select the location of the INI file.
To change the path of the Help file, click on the ellipse (4) next to the Help File parameter and select the
location of the Help file. The path to the INI file that will be used when the SDG is run as a service can be
set by clicking the ellipse (5) next to the INI parameter and then selecting the location.
There are also several parameters available for setting the SDG Service start-up options (6) when the SDG
GUI is exited.
Page 101
4. Configuration Reference
This section discusses the configuration of the SDG. The SDG application configuration is specified in a file,
called tmwgtway.ini.
In addition, the tmwgtway.ini file may specify a second configuration file called a point-mapping file, which
is described in section 4.2.2. The point-mapping file defines the characteristics necessary to identify and
interact with the data associated with a remote Master or Slave device(s).
4.1
As mentioned in the Quick Start guide the SDG must be registered as an OPC server if you wish to connect to
it from an OPC client. Normally this is done by the install.
Registration of the SDG as an OPC server can be done from the Windows Command Shell (DOS window) as
follows:
Open a Windows Command Shell (DOS window) by going to StartRun and typing cmd in
the "Open:" field, and then clicking the OK button.
When the Command shell is opened, you will typically be in your C: drive. If you have installed
the SDG on a hard drive other than the C: drive, then change to that drive by typing the letter for
that drive followed by a colon. For example, if you have installed the SDG on your E drive, then
type the command "E:" to change into the E drive.
Change to the directory where your SDG is installed by typing the command "cd
PATH_TO_SCADA_DATA_GATEWAY", where PATH_TO_SCADA_DATA_GATEWAY is the
directory where you have installed the SDG. For example, if you installed the SDG in the
directory C:\Program Files\TriangleMicroWorks\SDG and you are in the C drive in your DOS
window, then type the command "cd C:\Program Files\TriangleMicroWorks\SDG". Depending
upon how your system is configured, you may have to use the short directory names, such as "cd
C:\Progra~1\Triang~1\SDG".
Next, type the command "tmwgtway.exe -regopcserver" to register the OPC server. This will
register the Alarm and Event as well as the Data Access servers. Once registered, the SDG will
be available to OPC client software under the name TriangleMicroWorks.OPCDA.1 for the
OPC Data server and TriangleMicroWorks.OPCAE.1 for the OPC Alarm and Event server.
Un-registration is as above but use "tmwgtway.exe -unregopcserver".
The SDG service can, and should, also be registered as an OPC server. However, the GUI and service can
not be registered at the same time. Normally this is done automatically when the GUI and/or service are
executed.
In case this process has to be done manually, here are the necessary commands:
Command
GTWService.exe regopcserver
GTWService.exe unregopcserver
Description
Register service as OPC Data access and Alarm and Event server
Un-register service as OPC Data Access and Alarm and EVENT
server
Page 102
4.2
The SDG is configured using a configuration file. By default this file is named tmwgtway.ini. The file
includes comments describing the purpose of each parameter, the range of values, and the default value. The
tmwgtway.ini file must be located in the same directory as the SDG executable, and changes should be made
when the SDG software program is NOT running (closed). Tmwgtway.ini is overwritten with any parameter
changes made during the program execution when the SDG terminates. Comments in tmwgtway.ini should
not be altered, since they will be set back to the original text when the SDG saves the file.
Once you have completed configuring the SDG, Triangle MicroWorks recommends that you make a copy of
the configuration files (tmwgtway.ini and tmwgtway.csv) so you can easily restore your system in the event
that these files are accidentally lost or overwritten.
Configuration information may be read from another initialization file specified on the command line when
invoking the SDG. This initialization file will not be overwritten when the SDG terminates. Comments may
be inserted in this file by preceding the comment text with two slash characters (i.e.: //). For example,
[email protected] could be used where file.xyz is the name of the file being passed into the Gateway.
The following diagram shows how the some of the important configuration parameters in tmwgtway.ini relate
to the point-addressing scheme.
DNP
101
103
104
MB
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
Description
COM port or remote TCP/IP address
COM port baud rate
COM port parity
Number of COM port data bits
Number of COM port stop bits
TCP/IP port number
TCP/IP connection mode
Page 103
X
X
LinkSizeAddress
LinkMode
DbasSectorAddress
ASDUsizeCmnAddr
ASDUsizeCot
ASDUsizeIOA
For a complete listing of all the parameters contained in the tmwgtway.ini configuration file, please see
Error! Reference source not found..
4.2.2 Setting IEC 60870-5-101 and -104 Slave Data Types to use Time Stamps
The SDG does not currently support setting a data type with time stamp (e.g., Type 58 Single Point with
CP56 timestamp) via the GUI interface. However, the default data type can be set via the INI file.
To set the default data type to use a time stamp, select the "base" data type from the GUI (e.g., T1 - Single
Point). Then set the corresponding xxx_timeFormat parameter in the INI file. For example, for Single
Points, modify the following parameter:
MSPNA_timeFormat[*][*]=CP56
//
//
//
//
//
//
//
//
//
For Double Points, use MDPNA_timeFormat, for Step Position use MSTNA_timeFormat, etc.
Page 104
Obj02DfltVariation=2
4.3
//
//
//
//
//
//
//
//
//
//
//
Point-Mapping File
The Point-Mapping file (tmwgtway.csv) identifies how the value for each data point in a Slave Component is
obtained. This could be a direct mapping to a Master Data Point, or an equation, which incorporates multiple
Master Data Points. If the OPC server is the only Slave Component in the target application, it may not be
necessary to create a point-mapping file. Creating a point map file with only the required points will improve
efficiency.
Page 105
4.3.1
By setting GlobalCreateTagAutomatic = TRUE in the INI file, the data points returned from a remote slave
device to the SDG will automatically be shown in an OPC Client Browser that is connected to the SDG OPC
Server. Simply define the remote slave device in the INI file, or by using the Configuration User Interface,
run the SDG, and perform a general interrogation command (see section 4.4.3 Predefined Tag Names for
Monitoring and Control). All data points returned from the remote device will then be shown in the OPC
Client Browser and will not require an entry in the Point-Mapping file.
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 106
Since Command points are not received from the remote device, they will not be shown in an OPC Client
Browser. Command points may be configured in one of two ways:
1. Manually enter a physical tag name in the OPC client for the command point, for example if the
protocol is IEC60870-5-101 the physical tag name might be "COM1.L3.A3.T46.P1142". The value
written to this tag will be converted to a 101 Double point command using the command qualifier
and select mode (whether a select command is sent prior to the execute) specified in the "Command
Qualifiers" section of INI file. This method requires all points of the same type use the same
command qualifier and execute mode settings.
2.
Create a point-mapping file with only Master component entries for each command point (the Slave
component columns are left blank) as outlined later in this section. Use the options field to set the
Qualifier of Command and select mode to a different value for each point if necessary. If the
options field is left blank, the values specified in the "Command Qualifiers" section of the INI file
will be used. Points listed in the point mapping file will appear in the OPC Client Browser followed
by the user name in parenthesis (if one was entered).
#DataType
OPC_PROP_CDT
#Value
OPC_PROP_VALUE
#Quality
#TimeStamp
#AccessRights
OPC_PROP_QUALITY
OPC_PROP_TIME
OPC_PROP_RIGHTS
#Description
OPC_PROP_DESC
Description
Provides the OPC Variant data type of the
Point
Provides the current value of the point (same
as the point it self i.e. without the .Value)
Provides the OPC quality of the point
Provides the update time of the point
Provides the access rights of the point
Provides a description of the Point (if it was
provided)
To use a property add it to the end of the tag name. For instance: if the MDO tag being subscribed to by
an external OPC Client is named MDNP.L4.T30.P0, to obtain its quality use MDNP.L4.T30.P0#Quality.
Simply specifying MDNP.L4.T30.P0 will return the value of this MDO.
Page 107
4.3.2
The OPC Client in the SDG is a master component. It receives data from an external OPC Server and makes
it available to the slave components in the SDG. The SDG Point Mapping file is used to describe this data
flow.
When creating a Point Mapping file for the OPC Client, it is only necessary to define the User Tag Name
and Communication Channel fields. The User Tag Name must be the fully qualified path name to the
data point in the external OPC Server (such as Device1.Group.Tag1). The Communication Channel must
be the OPCserverName from the SDG INI file. If the OPCServerName is not specified in the initialization
file, it defaults to the OPCserverProgID. Refer to Section 1.4.4 for more information about these
parameters.
4.3.3
The Point-Mapping file is stored in Comma Separated Value (CSV) format. It may be derived from existing
data files describing the target application or generated from the SDG configuration editor. The following
table lists the order of the fields in the Point-Mapping file.
Item Component
1
Master
2
Master
Attribute
User Tag Name / OPC Tag Name / IEC 61850 Tag Name / IEC 61850 Data Set
Alias Name
Communication Channel / OPC Server Name/ IEC 61850 Client Name / IEC
61850 Data Set Logical Node Name
Page 108
Master
Master
Master
Master
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
Master
Master
Dataset
Slave/Master
Slave/Master
Slave/Master
Slave/Master
Slave/Master
Slave/Master
Slave/Master
Master
Master
Slave
Master
Mapping
Data Link Address (Not used for IEC 60870-5-104) / IEC 61850 Report Name /
IEC 61850 Data Set Name
ASDU Address (Not used for DNP) / IEC 61850 Quality Name / IEC 61850 Data
Set Element Name
Type ID / OPC type/ IEC 61850 Type / IEC 61850 Data Set Report Control Block
Name
Information Object Address/Information Number/ IEC 61850 Time Name / IEC
61850 Data Set GOOSE Control Block Name
Element Index (Only used for IEC 60870-5-103)
Function Type (Only used for IEC 60870-5-103)
Identifies the dataset present values descriptor element
Communication Channel / mapped OPC server
Data Link Address (Not used for IEC 60870-5-104) / mapped OPC tag name
ASDU Address (Not used for DNP)
Type ID / mapped OPC type
Information Object Address/Information Number
Element Index (Only used for IEC 60870-5-103)
Function Type (Only used for IEC 60870-5-103)
Equation
Options
Options
Description
Mapping mode (optional) the value can be MDNP_PROTOTYPE,
MDNP_PROTO_ELEMENT, MDNP_DESCRIPTOR,
MDNP_DESCP_ELEMENT, MDNP_DESCP_ELEMENT_VALUE,
SDNP_PROTOTYPE, SDNP_PROTO_ELEMENT, SDNP_DESCRIPTOR,
SDNP_DESCP_ELEMENT, SDNP_DESCP_ELEMENT_VALUE,USER,
OPC_USER, MDO_USER, OPC_INTERNAL, MDO_INTERNAL, MDO, SDO,
OPC, I61850_DS or I61850_MDO. If not specified SDO is assumed.
The configuration editor is used to generate the CSV file using a graphical user interface. The editor
provides the tools required to intuitively define the information required in the CSV file. The CSV file is
both written and read by the SDG configuration editor; although it is not recommended a user can choose to
modify the file outside of the configuration tool. For DNP datasets the 1st 3 to 6 fields are overridden with
specific dataset descriptor and prototype meanings (i.e. The mapping modes included for data set descriptors
and prototypes).
Page 109
The data points defined in the Master Components (right-hand columns) are an image of monitored or
controllable data in remote Slave devices. Only the objects in the remote Slave that are mapped to points in
an SDG Slave Component are listed in the Master Component column. There may be data received by the
Master Component which has no Master Point defined. This is not an error condition and the unused data is
simply discarded.
Since the OPC Server Slave Component is able to automatically generate a list of data received from the
remote slave device, these points do not require entries in the Master Component column (i.e. They are
mapped automatically when an OPC client connects to the SDG. For more information on mapping points to
the OPC Server, see section 4.3.1 Mapping points to the Internal OPC Server.
When mapping monitor master points to control/command master points the left hand column represents the
control/command point and the right hand column represents the monitor point. The monitor point receives a
value from an external slave and then causes the mapped master command point to issue a command to its
associated slave.
Page 110
Field
Applies to Protocol
Range of
Values
User Tag
String
Channel / Port
2,10
COM1,
COM2,
127.0.0.1,
PhysComChannel, OPCserverName,
PhysComChnlName, I61850ServerName
Data Link
Address
3,11
Decimal
SessionLinkAddress,
I61850ReportControlBlockName
ASDU
Address
4,12
Decimal
Type ID (101,
103)
5,13
Decimal
6,14
Decimal
Object Group
(DNP)
IOA/INF
Element Index
7,15
103
Decimal
Function Type
8,16
103
Decimal
DNP Dataset
DNP
Equation
17
Any
String
Tag Options
18,19
All
String
Tag
Description
20
All
String
Mapping
Mode
21
All
String
Page 111
Operation
Option Name
Meaning
Log file
Master
OPC Alarm
and Events
Master
Control
LOGMSKxxxx
See Table of Events in the
section following this section.
OPCAE_LOGMSKxxxx
See Table of Events in the
section following this section.
WRITE_PERIOD xxxx
Page 112
Master
Control
2PASS
1PASS
Slave
Control
2PASS
1PASS (!1PASS)
SYNC
ASYNC
Slave
Monitored
Data
GI (!GI)
CYC (!CYC)
OPCTIMEUPDATE
OPCTIMEREPORTED
OPCAETIMEUPDATE
OPCAETIMEREPORTED
Slave
Equations
EQTIMEUPDATE
EQTIMEREPORTED
Page 113
UPDATE_IF_NO_CHANGE
OPC DA/AE
Client
Name
ALIAS xxxx
OPC DA
Client
Write
WRITE_INVERTED
OPC DA
Client
Write
WRITE_TRUE_AS_ONE
OPC AE
Client
Event
EVENT_VALUE
OPC AE
Client
Event
EVENT_TRUE_MSG
OPC AE
Client
Event
EVENT_FALSE_MSG
OPC DA
Client
Event
AE_INIT_VALUE_MDO
OPC DA
Client
Event
AE_RESET_VALUE_MDO
OPC DA
Client
Event
AE_RESET_VALUE
Page 114
FQU
PQU
All
Commands
TO nnn
Page 115
Binary In
Double
Point
(Type ID 3)
Slave
PROVIDE_AS_RAW
Analog In
(Type ID
9,11,13)
Analog In
(Type ID
9,11,13)
DEADBAND value
Step
Command
(Type ID
46)
ALLOW_UP
ALLOW_DOWN
ALLOW_ANY
Double
Command
(Type ID
47)
ALLOW_ON
ALLOW_OFF
ALLOW_ANY
Monitored
Data
Page 116
Binary
Commands
(Type ID 45,
46, 47)
Analog
Commands
(Type ID 48,
49, 50)
IEC 60870-5-103:
General
Command
(Type ID
20)
Binary In
Double
Point
(Type ID
1,2)
Master
Binary Data
(Type ID
1,2)
ALLOW xxxx
1PASS (!1PASS)
ACCEPT_AS_RAW
PROVIDE_AS_RAW
RTZ
Page 117
DNP3:
Master
Binary
Control
(Type ID
12)
LATCH
PULSE
PRIORITY nnn
PULSEWIDTH nnn
PULSEWIDTH_VAR
mdo_name
PAIRED
FCM
PCM
Analog In
(Type ID
30)
DEADBAND value
Analog In
(Type ID
30)
Page 118
Monitored
Points
Binary
Output
(Type ID
12)
Binary
Output
(Type ID
41)
ALLOW
Holding
Register,
Coil
Holding
Register,
Input
Register
PRIORITY nnn
DEADBAND value
Master
Holding
Register,
Input
Register
Master
Coil write
ALLOW_ON
ALLOW_OFF
Modbus:
Master
Page 119
ALLOW_ANY
Master
Coil write
INVERTED_WRITE
Master and
Slave
Holding
Register,
Input
Register
SIGNED
Modbus
Slave
Holding
Register,
Input
Register
FLOAT xxx
For a detailed description of reported vs. update time, see section 4.5.1 Event Time Tags and Database
Update Times
Page 120
4.3.5.4 LOGMSKxxxx and OPCAE_LOGMSKxxxx Events used in the MDO option field
This table defines the kind of event LOGMSK may use for an individual data object as identified in the
above table. These mask values will also be used as defines in the Sequence of Event Log Files and/or
the OPC Alarm and Event Server.
The Types of Log Masks supported by the SDG can be found in the INI file.
Mask Value
Type of Event
0x0001
0x0002
The data is being updated, but the reason for the update is unknown.
The data is being updated because it was requested.
The data is being updated by the source of data without direct request. No change is
necessarily indicated.
A change in the data is indicated by the source of data.
A change in the data is indicated due to a request through communications.
A change in the data is indicated due to action at the device.
A control request has been transmitted to a remote device.
A control request has been confirmed by a remote device, but is not yet complete.
A 1st pass in a 2-pass control operation has been transmitted to a remote device.
A 1st pass in a 2-pass control operation has been confirmed by a remote device.
A cancel operation has been transmitted to a remote device to abort a 2-pass control operation
between the 1st and 2nd passes.
A cancel operation has been confirmed by a remote device.
A remote device has responded to indicate an error in a control operation.
Either the data point or the remote device is operating in a test mode.
0x0004
0x0008
0x0010
0x0020
0x0040
0x0080
0x0100
0x0200
0x0400
0x0800
0x1000
0x8000
Table 3 Types of Events used in the SOE Logger and the OPC Alarm and Event Server
FIELD
PREFIX
EXAMPLE
L3
ASDU Address
A44
T1
Point Address
P231
(none)
F160
When a field is not used in the protocol associated with a point, the field does not appear in the tag name.
Examples of physical tag names are:
Page 121
Tag Name
COM1.L12.A23.T3.P1
COM1.L12.A23.T3.P146.0.F160
COM1.A23.T3.P1
COM1.L3.T1.P0
COM1.L3.T0.P0
Protocol
(101 protocol)
(103 protocol)
(104 protocol)
(DNP protocol)
(Modbus protocol)
Page 122
The equation parser does not support equations in which two operators appear consecutively.
For example, an equation of the form (x * -2) is not supported. Generally, you can work
around this limitation by rewriting the equation. For this example, the equation can be
rewritten as ((0 x) * 2).
When an equation argument is a tag and contains characters normally used as operators for calculations
(i.e. / + * etc), the tag should be enclosed in (single quote) to facilitate parsing of the tag. The (single
quote) operates as an escape character on the tag name.
Certain equation operators require that the value of their arguments be able to be converted to a type
double (R8) if the argument does not natively/internally support this conversion a casting operator should
be used to convert the value to the appropriate type. For example the following will require a cast:
If the tag _intR4 is an internal MDO of type R4;
Then the equation short(_intR4 * 100) will generate a type mismatch error since the multiply (*) operator
requires doubles as its arguments. To get this to work the equation should be written as
short(double(_intR4) * 100). The reason for this is that internal MDOs are strictly typed and only return
values of the type they are declared as.
For example, the following OPC Client Tag:
/SUBESTACAO_P/INPUT/00_00_10/Message_2_3.m11
should be enclosed in (single quotes) as follows:
/SUBESTACAO_P/INPUT/00_00_10/Message_2_3.m11
This allows it to be used as an argument in an equation.
Example:
SUM(/SUBESTACAO_P/INPUT/00_00_10/Message_2_3.m11,2)
Equations are entered using the equation editor. For more information on using equations, please review
section 3.4.14 Equations.
Expression Parameters
Physical Tag Name
User Tag Name
numerical constant
(expression)
expression op expression
function(expression-list)
Definition
Physical Tag Names previously defined in the Point-Mapping
configuration file
User Tag Names previously defined in the Point-Mapping file
Any integer, floating point, or hexadecimal value; (e.g., 23, 14.5e-05, or
0xffa782b respectively)
Any combination of Physical or User Tag Name, and supported operators
enclosed within parenthesis.
Any expression operated with another expression. Only supported
operators may be used (the list of supported operators are listed below)
Where function is a supported function as listed below, and expression-list
is one or more expressions separated by commas.
Page 123
Evaluates to:
Logical and of the expressions on either side of the operator
Logical or of the expressions on either side of the operator
Bit Wise and of the expressions on either side of the operator
Bit Wise or of the expressions on either side of the operator
Arithmetic result of subtracting the expressions on either side of the operator
Arithmetic result of adding the expressions on either side of the operator
Arithmetic result of multiplying the expressions on either side of the operator
Arithmetic result of dividing the expressions on either side of the operator
Compares the left and right side of the == and returns true if they are the same value
Compares the left and right side of the != and returns true if they are not the same
value
Compares the left and right side of the > and returns true if the left side is greater than
the right side
Compares the left and right side of the < and returns true if the right side is greater
than the left side
Compares the left and right side of the >= and returns true if the left side is greater
than or equal to the right side
Compares the left and right side of the <= and returns true if the left side is greater
than or equal to the right side
Used to allow special equation operator characters as part of the name of an MDO that
is used as an argument in the equation. The MDO name must be enclosed in single
quotes.
Page 124
4.4
Data Points
Page 125
4.4.2 Translating data types between different protocols (Master to Slave mapping)
In the Point-Mapping example shown below, the mapping translates the IEC 103 protocol to an IEC 101
protocol (1). The Master TypeID 20 may receive Slave TypeID 45 data in protocol 101.
The following table shows the data types which may be translated from one protocol to another.
Summary of Equivalent Data Types for DNP3, IEC 101, IEC 103, Modbus and OPC
Description
DNP3
Object
IEC
101/104
Type
IEC 103
Type
Modbus
Type
OPC Type
Database Format
Binary Input
1, 2, 10
1, 2, 3, 4,
30, 31
1, 2
1 (discrete
input)
VT_BOOL
Boolean
4 (input
register) *2
VT_UI1,
VT_I1,
VT_I2 or
VT_I4
Short or Unsigned
Long
VT_R4
Short Float
VT_BOOL
Boolean
VT_I2 or
VT_R8
Short or Unsigned
Long
VT_I2 or
VT_I4
Short or Unsigned
Long
VT_R4
Short Float
Analog Input
(Integer)
Analog Input
(Floating
Point)
Binary
Output, Step
Change (101
only)
Counter Input
Analog
Output
(Integer)
Analog
Output
(Floating
Point)
30, 32,
40
9, 10, 11,
12, 34, 35
3, 9
13, 14, 36
12
45, 46, 47
20
20, 21
15, 16, 37
41
48, 49
0 (coil) *1
3 (holding
register) *1,2
50
Page 126
Bitstring
(Unsigned 32
bit)
VT_UI4 or
VT_R8
7, 8, 33
Unsigned Long
Table 4 Summary of Equivalent Data Types for DNP3, IEC 101, IEC 103, and OPC
*1
*2
Double
Range
unsigned char
0 = FALSE, 1 = TRUE
signed 16-bit integer value,
-32,768 to 32,767
unsigned 16-bit integer value,
0 to 65,535
signed 32-bit integer value,
-2,147,483,648 to 2,147,483,647
unsigned 32-bit integer value
0 to 4,294,967,295
Conversion
if value=0 then FALSE
else TRUE
value truncated to types range
if required
value truncated to types range
if required
value truncated to types range
if required
value truncated to types range
if required
STD_QLTY_BLOCKED
SB
STD_QLTY_SUBSTITUTED
NT
IV
OV
EI
-
STD_QLTY_NOT_TOPICAL
STD_QLTY_INVALID
STD_QLTY_OVERFLOW
STD_QLTY_INVALID_TIME
STD_QLTY_REF_ERROR
Quality Symbol
Meaning
Blocked
Substituted (over-ride or
forced)
Not topical (offline/not dated)
Invalid
Overflow/rollover
Elapsed time invalid
Reference error
Mask
Value
0x0010
0x0020
0x0040
0x0080
0x0001
0x0008
0x0100
Page 127
STD_QLTY_IN_TRANSIT
STD_QLTY_UNINITIALIZED
STD_QLTY_TEST
In transit/chatter
Not set since startup
Test mode
0x0200
0x0400
0x0800
If the same data type is mapped between Master and Slave component points, the database storage format is
not used and the native data type will be mapped exactly. The tables below may be used to determine how
values and quality flags are translated when a Slave Component point is mapped to a Master Component
point of a different data type. Simply locate the Master Component data type table below and note how the
values and quality flags are mapped into the SDG Database Storage format. Then locate the Slave
Component data type table below and identify how these values are mapped to the SDG Database Storage
format corresponding to the Master Component Data type.
For example: To determine the value and quality of an OPC Slave Component Boolean point when mapped
to an IEC 870-5-101 Master Component Double Point Information (DPI) with a value of 0 (indeterminate or
intermediate state), first locate the DPI table. The Master Component column shows a DPI value of 0 is
mapped to a SDG Database Storage value of Boolean 0 and STD_QLTY_IN_TRANSIT is set to TRUE.
Then locate the OPC Boolean table. The SDG Database Storage column contains a row with Standard
Quality Flag STD_QLTY_IN_TRANSIT set TRUE and this row in the Slave Component column shows the
OPC Quality Flag will be set to UNCERTAIN. The Boolean value will be set accordingly.
Page 128
To
Slave Component or
Master Component
Single point
command
From
To
SDG Database Storage
Boolean = 0
Boolean = 1
Standard Quality Flags:
BL, SB, NT, IV
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_UNINITIALIZED
is TRUE
STD_QLTY_INTRANSIT is
TRUE
IV set TRUE
IV set TRUE
From
Master Component
To
Slave Component or
Master Component
Double point
command
From
To
SDG Database Storage
0 = indeterminate or
intermediate state
Boolean = 0
STD_QLTY_IN_TRANSIT set
TRUE
Boolean = 0
Boolean = 1
Boolean = 0
STD_QLTY_INVALID set
TRUE
Standard Quality Flags:
BL, SB, NT, IV
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_UNINITIALIZED
is TRUE
Quality Descriptors:
BL, SB, NT
IV set TRUE
IV set TRUE
From
Master Component
Quality Descriptors:
BL, SB, NT
To
Slave Component or
Master Component
Normalized value
command
From
To
SDG Database Storage
From
Master Component
Page 129
short
Standard Quality Flags:
BL, SB, NT, IV, OV
normalized value
Quality Descriptors:
BL, SB, NT, IV, OV
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_INTRANSIT is
TRUE
To
Slave Component or
Master Component
Scaled value
command
From
To
SDG Database Storage
scaled value
Quality Descriptors:
BL, SB, NT, IV,
OV
IV set TRUE
short
Standard Quality Flags:
BL, SB, NT, IV, OV
IV set TRUE
From
Master Component
scaled value
Quality Descriptors:
BL, SB, NT, IV, OV
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_INTRANSIT is
TRUE
To
Slave Component or
Master Component
Float value
command
From
To
SDG Database Storage
short float
Standard Quality Flags:
BL, SB, NT, IV, OV
IV set TRUE
From
Master Component
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_INTRANSIT is
TRUE
To
Slave Component or
Master Component
Bitstring command
From
To
SDG Database Storage
From
Master Component
Page 130
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_INTRANSIT is
TRUE
To
Slave Component
short float value
Quality Descriptors:
BL, SB, NT, IV,
OV
IV set TRUE
IV set TRUE
From
To
SDG Database Storage
short float
Standard Quality Flags:
BL, SB, NT, IV, OV
To
Master Component
Boolean = 0
Boolean = 1
BIN_CTRL_MODE_NONE
BIN_CTRL_MODE_PULSE
BIN_CTRL_MODE_PULSE
QU_LONG_PULSE
BIN_CTRL_MODE_LATCH
QU_PERSISTENT)
Master Component
short float value
Quality Descriptors:
BL, SB, NT, IV, OV
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_INTRANSIT is
TRUE
From
To
Master Component
Boolean = 0
Boolean = 1
BIN_CTRL_MODE_NONE
BIN_CTRL_MODE_PULSE
BIN_CTRL_MODE_PULSE
QU_LONG_PULSE
BIN_CTRL_MODE_LATCH
QU_PERSISTENT
Page 131
Master Component
Boolean = 0
Boolean = 1
BIN_CTRL_MODE_NONE
BIN_CTRL_MODE_PULSE
BIN_CTRL_MODE_PULSE
QU_LONG_PULSE
BIN_CTRL_MODE_LATCH
QU_PERSISTENT
From
Slave Component
normalized value
To
From
SDG Database Storage
To
Master Component
short
normalized value
From
Slave Component
scaled value
To
From
SDG Database Storage
To
Master Component
short
scaled value
From
Slave Component
short float value
To
From
SDG Database Storage
To
Master Component
short float
From
Slave Component
unsigned long value
To
From
SDG Database Storage
To
Master Component
From
Master Component
0 = not used
Boolean = 0
Boolean = 1
2 = determined state ON
Boolean =0
STD_QLTY_INVALID set
TRUE
3 = not used
To
SDG Database Storage
short
From
Master Component
short
To
SDG Database Storage
short float
From
Master Component
short float
Page 132
Command Type ID 20
From
SDG Database Storage
To
Master Component
0 = not used
Boolean = 0
Boolean = 1
2 = determined state ON
3 = not used
4.4.2.5 DNP3
Binary Input, Object Group 1 and 2
To
SDG Database Storage
From
Master Component
State = 0
Boolean = 0
State = 0
State = 1
Boolean = 1
State = 1
Restart = 1
STD_QLTY_UNINITIALIZED
On-Line = 0, Restart = 1
Communication Lost = 1
STD_QLTY_NOT_TOPICAL
Communication Lost = 1
Remote Forced = 1
UPDTRSN_CTRL_BY_COMM
Remote Forced = 1
Local Forced = 1
UPDTRSN_CTRL_AT_DEVICE
Local Forced = 1
Chatter = 1
STD_QLTY_IN_TRANSIT
Chatter = 1
Slave Component or
Master Component
Binary command
Slave Component
State = 0
Boolean = 0
State = 0
State = 1
Boolean = 1
State = 1
Restart = 1
STD_QLTY_UNINITIALIZED
On-Line = 0, Restart = 1
Communication Lost = 1
STD_QLTY_NOT_TOPICAL
Communication Lost = 1
Remote Forced = 1
UPDTRSN_CTRL_BY_COMM
Remote Forced = 1
Local Forced = 1
UPDTRSN_CTRL_AT_DEVICE
Local Forced = 1
Slave Component
Code = NUL
Boolean = 0
BIN_CTRL_MODE_NONE
Boolean = 0
BIN_CTRL_MODE_LATCH
Boolean = 1
BIN_CTRL_MODE_LATCH
Boolean = 0
BIN_CTRL_MODE_PULSE
Boolean = 1
BIN_CTRL_MODE_PULSE
Boolean = 0
BIN_CTRL_MODE_PAIRED
Boolean = 1
BIN_CTRL_MODE_PAIRED
Slave Component or
Master Component
Analog command
Page 133
Long
Short, variation 2, 4
Short Float
Restart = 1
STD_QLTY_UNINITIALIZED
On-Line = 0, Restart = 1
Communication Lost = 1
STD_QLTY_NOT_TOPICAL
Communication Lost = 1
Remote Forced = 1
UPDTRSN_CTRL_BY_COMM
Remote Forced = 1
Local Forced = 1
UPDTRSN_CTRL_AT_DEVICE
Local Forced = 1
Over Range = 1
STD_QLTY_OVERFLOW
Over Range = 1
Reference Check = 1
STD_QLTY_REF_ERROR
Reference Check = 1
Long, variation 1, 3
Slave Component
Boolean = 0
Boolean = 1
Restart = 1
STD_QLTY_UNINITIALIZED
On-Line = 0, Restart = 1
Communication Lost = 1
STD_QLTY_NOT_TOPICAL
Communication Lost = 1
Remote Forced = 1
UPDTRSN_CTRL_BY_COMM
Remote Forced = 1
Local Forced = 1
UPDTRSN_CTRL_AT_DEVICE
Local Forced = 1
Slave Component
Short, variation 2, 4
Long, variation 1, 3
Short Float
Long, variation 1, 3
Short float, variation 5
Slave Component
Long, variation 1, 5
Unsigned Long
Short, variation 2, 6
Restart = 1
STD_QLTY_UNINITIALIZED
On-Line = 0, Restart = 1
Communication Lost = 1
STD_QLTY_NOT_TOPICAL
Communication Lost = 1
Remote Forced = 1
UPDTRSN_CTRL_BY_COMM
Remote Forced = 1
Local Forced = 1
UPDTRSN_CTRL_AT_DEVICE
Local Forced = 1
Over Range = 1
STD_QLTY_OVERFLOW
Roll Over = 1
Long, variation 1, 5
4.4.2.6 Modbus
Coil, Type 0
From
To
From To
Slave Component or
SDG Database Storage
Master Component
Master Component
Coil write
Page 134
To
Slave Component
State = 0
State = 1
Boolean = 0
Boolean = 1
State = 0
State = 1
From
To
SDG Database Storage
Boolean = 0
Boolean = 1
From
Master Component
State = 0
State = 1
From To
From
Slave Component or
SDG Database Storage
Master Component
Holding register
write
value
To
Master Component
Unsigned short
value
To
Slave Component
value
From
To
SDG Database Storage
Unsigned short
From
Master Component
value
Page 135
STD_QLTY_UNINITIALIZED
is TRUE
OPC_QUALITY_OUT_OF_SERVICE
set TRUE
STD_QLTY_BLOCKED is
TRUE
STD_QLTY_INVALID is
TRUE
OPC_QUALITY_SENSOR_CAL set
TRUE
OPC_QUALITY_EGU_EXCEEDED
set TRUE
STD_QLTY_REF_ERROR is
TRUE
STD_QLTY_OVERFLOW is
TRUE
OPC_QUALITY_LAST_USABLE set
TRUE
STD_QLTY_NOT_TOPICAL
is TRUE
OPC_QUALITY_UNCERTAIN set
TRUE
STD_QLTY_IN_TRANSIT is
TRUE
OPC_QUALITY_LOCAL_OVERRIDE
set TRUE
STD_QLTY_SUBSTITUTED
is TRUE
Any of
OPC_QUALITY_NOT_CONNECTED
OPC_QUALITY_CONFIG_ERROR
set TRUE
OPC_QUALITY_OUT_OF_SERVICE
set TRUE
Any of
OPC_QUALITY_BAD
OPC_QUALITY_SUB_NORMAL
set TRUE
OPC_QUALITY_SENSOR_CAL set
TRUE
OPC_QUALITY_EGU_EXCEEDED
set TRUE
Any of
OPC_QUALITY_LAST_USABLE
OPC_QUALITY_LAST_KNOWN
OPC_QUALITY_OUT_OF_SERVICE
OPC_QUALITY_COMM_FAILURE
OPC_QUALITY_SENSOR_FAILURE
OPC_QUALITY_DEVICE_FAILURE
set TRUE
OPC_QUALITY_UNCERTAIN set
TRUE
Any of
OPC_QUALITY_LOCAL_OVERRIDE
set TRUE
To From
To
OPC Server Slave Component
SDG Database Storage
or OPC Client Master
Component
VT_BOOL
Boolean
From
OPC Client Master
Component
VT_BOOL
To From
To
OPC Server Slave Component
SDG Database Storage
or OPC Client Master
Component
VT_I2
Short
From
OPC Client Master
Component
VT_I2
To From
To
OPC Server Slave Component
SDG Database Storage
or OPC Client Master
Component
VT_R4
short float
From
OPC Client Master
Component
VT_R4
Page 136
To From
To
OPC Server Slave Component
SDG Database Storage
or OPC Client Master
Component
VT_R8
From
OPC Client Master
Component
double float
VT_R8
To From
To
OPC Server Slave Component
SDG Database Storage
or OPC Client Master
Component
VT_I4
From
OPC Client Master
Component
long
VT_I4
To From
To
OPC Server Slave Component
SDG Database Storage
or OPC Client Master
Component
VT_UI4, VT_R8
From
OPC Client Master
Component
unsigned long
VT_UI4, VT_R8
From
OPC Server Slave Component
To
From
SDG Database Storage
VT_BOOL
Boolean
To
OPC Client Master
Component
VT_BOOL
From
OPC Server Slave Component
To
From
SDG Database Storage
VT_I2
Short
To
OPC Client Master Component
VT_I2
From
OPC Server Slave Component
To
From
SDG Database Storage
VT_R4
short float
To
OPC Client Master Component
VT_R4
From
OPC Server Slave Component
To
From
SDG Database Storage
VT_R8
double float
To
OPC Client Master Component
VT_R8
From
OPC Server Slave Component
To
From
SDG Database Storage
To
OPC Client Master Component
Page 137
long
VT_I4
From
OPC Server Slave Component
To
From
SDG Database Storage
VT_UI4, VT_R8
unsigned long
To
OPC Client Master Component
VT_UI4, VT_R8
Predefined Tag Names may be read directly in OPC or mapped to other protocols in the PointMapping file by listing them in the Master Component User tagName column and leaving the other
Master Component Point-Mapping file columns blank.
Predefined Tag Names may be either type String (Str), Integer (Int) or Binary (Bin).
Some Predefined Tag Names are specific to a Master or Slave component as shown in the table
below, so each session will not have all Predefined Tag Names.
If a Predefined Tag Name is read/write (R/W), then it may be written to, or read from.
If the Predefined Tag Name is read-only (R/O) its value may be read from, but not written to.
Predefined Tag Names marked Error Count are incremented each time an error is detected. They
may be preset to a specific value by writing the value to it or cleared by simply writing a value of
zero.
Reading an R/W Predefined Tag Name returns the last value written to it.
The meaning of each Predefined Tag Name is explained in the table below. Unless otherwise noted,
all Predefined Tag Names designated R/W Int may be set to any integer value.
The M/S column identifies whether the Predefined Tag is applicable to a Master (M) or Slave (S)
component.
GatewayOnline
M/S
M/S
PROTOCOL
All
TYPE
R/O
Bin
SOECounter
M/S
All
R/W
Int
ChannelsOfflineCounter
M/S
All
R/W
Int
ChannelsOnlineStatus
M/S
All
DataBaseUpdateQSize
M/S
All
R/O
Bin
R/O Int
DESCRIPTION
True (1) whenever the gateway
program is running. Inserts an
event into the event buffer
indicating the SDGs startup time
SOE Update Counter. Counts the
number of entries added to the SOE
event log since last reset
Counts the total number of times all
sessions on all channels have gone
off line
TRUE if all sessions on all
channels are on line
The current number of items in the
data base queue that have not been
processed yet
Page 138
M/S
M/S
PROTOCOL
All
TYPE
R/O
Bin
DbQsizeExceededWarningLimit
M/S
All
R/O
Bin
OPCClient_X.CurrentServerTim
e
OPCClient_X.LastUpdateTime
N/A
N/A
R/O Str
N/A
N/A
R/O Str
OPCClient_X.NumGroups
N/A
N/A
R/O Int
OPCClient_X.PercentBandWidt
h
OPCClient_X.ServerOK
N/A
N/A
R/O Int
N/A
N/A
OPCClient_X.ServerStartTime
OPCClient_X.ServerStatus
N/A
N/A
N/A
N/A
R/O
Bin
R/O Str
R/O Str
OPCClient_X.VendorInfo
COMx.ChannelRedialLimitCont
rol
N/A
M/S
N/A
All
R/O Str
R/W
Bin
COMx.NumChecksumErrors
M/S
All
R/W
Int
COMx.NumConfirmFailures
M/S
All
COMx.NumLengthErrors
M/S
All
R/W
Int
R/W
Int
COMx.NumSyncErrors
M/S
All
R/W
Int
COMx.NumTimeoutErrors
M/S
All
COMx.TotalErrors
M/S
All
COMx.NumPhysCharTimeoutEr
rors
COMx.NumPhysXmitErrors
M/S
All
M/S
All
COMx.NumRxBytes
M/S
All
R/W
Int
R/W
Int
R/W
Int
R/W
Int
R/W
Int
DESCRIPTION
TRUE if the DataBaseUpdateQSize
exceeds the DbQSizeErrorLimit
configuration parameter. If this
limit is exceeded items are not
added to the data base queue until
DataBaseUpdateQSize falls below
this limit. In other words if this
limit is exceeded data is lost.
TRUE if the DataBaseUpdateQSize
exceeds the DbQSizeWarningLimit
configuration parameter
The current time on the OPC Server
that this client is connected to.
The last time the OPC client was
updated by the OPC server.
The number of groups created on
the OPC server.
A performance utilization indicator.
TRUE if the OPC client is
connected to the OPC server.
The time the server was started.
A textual description of the OPC
server status.
The vendor of the OPC Server.
Indicates true when modem re-dial
limit reached, set to false to start
dialing again. This Tag is only
valid for Modem Pool Channels.
Error Count. Checksum errors
detected on the communication
channel
Error Count. Data link confirm
failures on this channel
Error Count. Frame length errors
detected on the communication
channel
Error Count. Frame
synchronization errors detected on
the communication channel
Error Count. Data link timeouts on
this Session
Total number of errors on this
channel
Total number of Character Timeout
Errors on this channel
Total number of Transmit errors on
this channel
Total number of bytes received on
this channel
Page 139
M/S
M/S
PROTOCOL
All
TYPE
R/W
Int
R/W
Int
R/W
Int
R/O
Bin
R/W
Int
COMx.NumTxFrames
M/S
All
COMx.NumRxFrames
M/S
All
COMx.ChannelSessionsOnLineS
tatus
COMx.SessionsOfflineCounter
M/S
All
M/S
All
COMx.T1AckTime
104
R/O Int
COMx.T1MaxAckTime
104
R/W
Int
COMx.NumTxFragments
M/S
DNP
COMx.NumRxFragments
M/S
DNP
COMx.Ly.OnLineStatus *
M/S
All
R/W
Int
R/W
Int
R/O
Bin
COMx.Ly.SessionActiveControl
*
M/S
All
R/W
Bin
COMx.Ly.SessionOfflineCounte
r
COMx.Ly.TotalErrors
M/S
All
M/S
All
COMx.Ly.NumTxASDUs
M/S
All
COMx.Ly.NumRxASDUs
M/S
All
R/W
Int
R/W
Int
R/W
Int
R/W
Int
DESCRIPTION
Total number of bytes transmitted
on this channel
Count of message frames
transmitted
Count of valid message frames
received
TRUE if all sessions on this
channel are on line
Counts the number of times any
session on this channel has gone
offline
The current amount of time elapsed
between sending a frame and
receiving an acknowledge
The maximum amount of time that
has elapsed between sending a
frame and receiving an
acknowledge. This value can be
used to tune the value of T1
(LinkCnfmTimeout).
Number of fragments transmitted
on this channel
Number of fragments received on
this channel
Status bit that reflects the current
online status for this session. A
true(1) value means the session is
currently online and
communicating. A false(0) value
means the session if currently
offline. This will occur at system
startup, when the
SessionActiveControl point is set to
false(0), or when the master does
not receive a data link confirm
within the specified timeout period
for the specified number of retries.
Control flag to force a session
active or inactive. Write true(1) to
this value to attempt to bring the
session active. Write false(0) to
make a session inactive.
Counts the number of times this
session has gone offline
Total number of errors on this
session
Number of fragments transmitted
on this channel
Number of fragments received on
this channel
Page 140
M/S
M
PROTOCOL
All
TYPE
R/W
Bin
COMx.Ly.ColdRestartNow
DNP3
R/W
Bin
COMx.Ly.WarmRestartNow
DNP3
R/W
Bin
COMx.Ly.DNPActionNow
DNP3
COMx.Ly.DNPActionMask0-4
DNP3
COMx.Ly.DNPActionPrd0-4
DNP3
R/W
Int
R/W
Int
R/W
Int
COMx.Ly.Az.IECActionNow
101, 103,
104
R/W
Int
COMx.Ly.Az.IECActionMask0-4
R/W Int
COMx.Ly.Az.IECActionPrd0-4
101, 103,
104
101, 103,
104
COMx.Ly.Az.CreateTagsAuto
101,103,104
R/W
Bin
COMx.Ly.Az.Reset101RemoteNow
*
101, 104
R/W Int
COMx.Ly.Az.Reset103RemoteNow
103
R/W
Bin
COMx.Ly.Az.ClearEventBuffers *
101, 104
COMx.Ly.Az.ResetCountersNow
101, 104
COMx.Ly.Az.FreezeCountersNow
101, 104
R/W
Bin
R/W
Bin
R/W
Bin
R/W Int
DESCRIPTION
Write true (1) to this point to send a
general interrogation to the
connected slave device and create
the data types and tags for this
session. The session has to be
online and a previous general
interrogation cant be pending.
This value will be reset to false (0)
when the operation completes.
Write true(1) to this value to force a
Cold Restart of the corresponding
DNP session.
Write true(1) to this value to force a
Warm Restart of the corresponding
DNP session.
See the description below for a
definition of the bits in this mask.
See the description below for a
definition of the bits in this mask.
Time between actions defined in
the DNPActionMask0-4, specified
in milliseconds.
See the description below for a
definition of the bits in this mask.
See the description below for a
definition of the bits in this mask.
Time between actions defined in the
IECActionMask0-4, specified in
milliseconds.
Write true (1) to this point to send a
general interrogation to the connected
slave device and create the data types
and tags for this sector. The session has
to be online and a previous general
interrogation cant be pending. This
value will be reset to false (0) when the
operation completes.
Write QRP value to send to IEC 608705-101 Slave when issuing application
layer command Type ID 105. Refer to
IEC 60870-5-101 clause 7.2.6.27.
Normally the QRP value will be 1
(reset Slave) or 2 (clear event buffers).
Write true (1) to issue a data link Reset
CU command to an IEC 60870-5-103
Slave.
Write true (1) to clear the sectors event
buffers.
Write true (1) to issue an application
level reset counters command.
Write true (1) to issue an application
level freeze counters command.
Page 141
PROTOCOL
TYPE
DESCRIPTION
COMx.Ly.Az.TestNow
M/S
M
101, 104
R/W
Bin
COMx.Ly.Az.NumMissingResponse
s*
COMx.Ly.Az.TotalEventOverflows
*
R/W Int
101, 103,
104
101, 104
COMx.Ly.Az.Tt.NumEventOverflo
ws *
101, 104
R/W Int
R/W Int
Action
Read Class 1 Change Events
Read Class 2 Change Events
Read Class 3 Change Events
Read Binary Input Change Events
Read Analog Input Change Events
Read Running Counter Change Events
Read Frozen Counter Change Events
Page 142
79
10
11
12
13
14
15
16
17
18 20
21
22
23
24 31
(MSB)
Not Used
Read Class 0 Static Data (See note 1)
Specific flag only request points in the SDG database for the data type(s) selected in bits
12-17 (See notes 2, 4, 6)
Read Binary Inputs (See notes 2, 6)
Read Analog Inputs (See notes 2, 6)
Read Running Counters (See notes 2, 6)
Read Frozen Counters (See notes 2, 6)
Read Binary Output Status (See note 6)
Read Analog Output Status (See note 6)
Not Used
Send a Clock Synchronization Request
Send a Freeze Counters Command
Send a Freeze and Clear Counters Command
Not Used
Notes:
1) The DNP specification states a class 0 (static data) poll should be preceded by a class 1,2,3 (event
data) poll; hence bits 0, 1, and 2 should be set when bit 10 is set.
2) The DNP specification states a read of static data should be preceded by a read of change events. As
an example, if bit 12 is set to read binary inputs, bit 3 should also be set to read the binary input
change events. The same logic should be applied to the rest of the data types.
3) At gateway startup, if the action period has a non-zero value, the actions specified by the bit-mask
will be performed immediately and repeated at an interval specified by the period in milliseconds.
4) It is recommended that the GlobalCreateTagAutomatic INI file parameter be set to FALSE if the
Specific flag is set. Otherwise the SDG will automatically add all data points received from the
remote device to the local data base and hence poll for all the data points on the remote device in a
very inefficient manner.
5) Action mask command bits are not mutually exclusive; multiple bits can be set to cause the execution
of multiple commands. For example if bits 21,0,1,2,10 are set 2 messages will be sent. The first
message will be a clock sync, followed by a read of class 1-2-3-0 in the second message.
6) Normally bits 12-17 will cause a read of variation 0 with qualifier code 06 (all points). If the remote
device supports the range qualifier codes (00 and 01), the specific flag may be set to reduce the
response message size (assuming all the points in the remote device are not defined in the SDG
Database).
2 (failure)
3 (mismatch)
Meaning
Indicates the request has completed successfully
Indicates a response was received but the requested command is not yet complete.
This could mean the response is part of a multi-fragment response and did not
have the FINAL bit set. Or this could be a request such as a select operate that
requires multiple requests and responses.
Indicates that the transmission of the request failed
The response to a select or an execute did not echo the request.
Page 143
4 (statuscode)
5 (iin)
6 (timeout)
7 (canceled)
The response to a select or an execute echoed the request, except the status code
was different indicating a failure.
The response to the request had IIN bits set indicating the command failed.
This indicates that the request has timed out. This could either be an incremental
timeout indicating we received no link layer frame from the device in the
specified time, or an application response timeout indicating this particular
request did not complete in the specified time.
This indicates either that the user asked that the request be canceled by calling
dnpchnl_cancelFragment or that a second duplicate request has been made and
therefore this first one is canceled.
Typically this can be used to indicate the DNPActionNow has completed and a reason why. This can also
be useful to sequence a set of commands/requests on a serial multi-drop connection.
4.4.3.5.3
Specific Points
Page 144
For DNP applications that do not support report by exception, the recommended way to reduce
bandwidth requirements is to use the specific flag. Specific mode only requests data for the current
Master data objects in the gateway of the type specified by the bit-mask.
The following example will read the specific binary points at a frequency of 5 seconds and the
analog points at a frequency of 20 seconds. The corresponding change event bits are not set as the
assumption is that the DNP application does not support change events.
Read specific binary points once every 5 seconds:
DNPActionMask0[*]= 0x1800 // bits 11, 12
DNPActionPrd0[*]= 5000 // 5 seconds * 1000 milliseconds
Read specific analog points once every 20 seconds:
DNPActionMask1[*]= 0x2800 // bits 11, 13
DNPActionPrd1[*]= 20000 // 20 seconds * 1000 milliseconds
Action
Send a clock synchronization request
Send general interrogation request
Send group 1 interrogation request
Send group 2 interrogation request
Send group 3 interrogation request
Send group 4 interrogation request
Send group 5 interrogation request
Send group 6 interrogation request
Send group 7 interrogation request
Send group 8 interrogation request
Send group 9 interrogation request
Send group 10 interrogation request
Send group 11 interrogation request
Send group 12 interrogation request
Send group 13 interrogation request
Send group 14 interrogation request
Send group 15 interrogation request
Send group 16 interrogation request
Send general counter interrogation request
Send counter group 1 interrogation request
Send counter group 2 interrogation request
Send counter group 3 interrogation request
Send counter group 4 interrogation request
Not Used
Notes:
At gateway startup, if the action period has a non zero value, the actions specified by the bit-mask will be
performed and repeated at the interval specified by the period in milliseconds.
1994 - 2009 Triangle MicroWorks, Inc. All rights reserved.
Page 145
Action mask command bits are not mutually exclusive; multiple bits can be set to cause the execution of
multiple commands. For example if bits 0 and 1 are set 2 messages are sent first a clock sync, followed by
a general interrogation request.
Action
Read Coils
Read Holding Registers
Read Discrete Inputs
Read Input Registers
Not Used
Notes:
1. At gateway startup, if the action period has a non zero value, the actions specified by the bit-mask will
be performed and repeated at the interval specified by the period in milliseconds.
2. Action mask command bits are not mutually exclusive; multiple bits can be set to cause the execution
of multiple commands. For example if bits 0 and 1 are set 2 messages are sent first a read coils,
followed by a read holding registers.
4.5
SDG Clock
The UseSystemClock configuration parameter allows you to configure the SDG to use the Windows system
clock or an internal clock maintained within the SDG. If UseSystemClock is set to TRUE the SDG will
always get the current date and time directly from the Windows system clock. This mode is useful if an
external clock synchronization mechanism is being used to synchronize the Windows system clock outside
the SDG. In this mode of operation clock synchronization requests from remote masters are parsed by the
SDG but the results are ignored.
The default mode of operation for the SDG is to use an internal clock managed by the SDG. The SDG will
set its internal clock from the Windows system clock at startup. After initialization the internal clock is a
free running clock that is maintained using a free running millisecond timer. Even though the internal clock
is independent from the Windows system clock the two clocks will initially report the same time since the
internal clock is updated using the same Windows millisecond timer used to maintain the Windows system
clock. The internal clock however will be adjusted by any clock synchronization requests received from any
remote master. After an external clock synchronization request the internal clock will remain at a fixed
offset from the Windows system clock.
Page 146
By default, OPC data values, as well as data points generated by equations, use the Update time as
described above. The reason that this is done is to provide a consistent time base for changes whether or not
the data was received with a time tag, and whether or not the time in the slave devices has been synchronized.
OPC only sees the "current value" of the data points, not an "event sequence", hence the time tag accuracy is
not critical.
The user can choose to override the default and report the Reported time for OPC data values and equations
using the OPCAETimeSource, OPCTimeSource and EquationTimeSource INI file configuration parameters
and/or the OPCTIMEUPDATE, OPCTIMEREPORTED, EQTIMEUPDATE, EQTIMEREPORTED point
mapping file data point options. For more details on configuration parameters see the INI file description.
For more details on data point options see the data options field description in the point configuration file
section.
The SDG slave components and the sequence of events log file report time only if a valid time is reported by
the slave device. Hence, the default time for events to external masters talking to an SDG slave component
or a time recorded in a log file will be the Reported time.
4.6
The Sequence of Event (SOE) Log file contains records describing events reported to, detected by, and/or
generated by the Gateway software. Each record describes one reported, detected, or generated event
associated with a Master Component Point. External software applications may actively use the data within
the log file simultaneously with the Gateway updating the file.
Optionally the SOE Queue can be enabled. When the queue is enabled events are logged to a first in first out
queue and an external application can remove the events from the queue. See the example visual basic
application SOEReader. The following header file (SOEVBInterface.h) describes the functions that are
available through the SOEQueue DLL to support this.
#pragma once
/*
The following ifdef block is the standard way of creating macros which make exporting from a DLL simpler. All
files within this DLL are compiled with the SOEQUEUE_EXPORTS symbol defined on the command line. This
symbol should not be defined on any project that uses this DLL. This way any other project whose source files
include this file see SOEQUEUE_API functions as being imported from a DLL, whereas this DLL sees symbols
defined with this macro as being exported.
*/
#ifdef SOEQUEUE_EXPORTS
#define SOEQUEUE_API __declspec(dllexport)
#else
#define SOEQUEUE_API __declspec(dllimport)
#endif
/*
The following are the definitions for the
VB interface DLL functions to the SOE Queue
These can be cut and pasted into the VB code to access them.
Private Declare Function SOEOpen Lib "<PATH_NAME>\SOEQueue.dll" _
(ByVal name As String) As Long
Page 147
Page 148
The parameters listed in the table below, and further described in subsequent sections of this document,
can be used to configure the event log file and queue capabilities of the Gateway. To set or change
these parameters, edit the INI file prior to execution of the Gateway software; the parameters are
located in the Data Change Event Logging section within the INI file.
Parameter Name
SOEQFileName
EnableSOEQ
MaxSOEQSize
SOEQCleanupRate
EventLogFileName
EventLogRecordFormat
EventLogFileFlushPrd
Errors_logMask
Diagnostics_logMask
GatewayControl_logMask
Equations_logMask
MSPNA_logMask
MDPNA_logMask
MSTNA_logMask
MMENA_logMask
MMENB_logMask
MMENC_logMask
MEINA_logMask
CSCNA_logMask
CDCNA_logMask
CRCNA_logMask
CSENA_logMask
CSENB_logMask
CSENC_logMask
CCSNA_logMask
103_M103Type1_logMask
103_M103Type2_logMask
103_M103Type4_logMask
103_M103Type5_logMask
103_M103Type9_logMask
103_M103Type20_logMask
MDNPType1_logMask
Page 149
Parameter Name
MDNPType10_logMask
MDNPType12_logMask
MDNPType20_logMask
MDNPType21_logMask
MDNPType30_logMask
MDNPType40_logMask
MDNPType41_logMask
Page 150
ry4
rmr
%ry4
2000
rdm
%02rmr
11
rtm
val
qly
%val,
%02rdm %rtm,
11:53:58.216,
on,
30
%qly,
0,
utg
de
s
se cr
e ipt
IF io
N n
_T fo
ab r M
le D
4
d
se igit
e ye
R a
D r
T_
re
Ta
p
o
se r
bl
e
e ted
R
D m
T_ o
Ta nth
bl
re
e
po
se rt
e ed
R d
D a
T_ y
re
Ta
po
bl
hh rt
e
ed
:
m
se m t
e :s im
R s e
D .m
T_ s
va
Ta ec
lu
bl
on e
e
of
/
o
se f t
e f, e he
VF t c M
D
N
O
_T
qu
:
a
al
b
se it
l
e
e y(
VF he
x
u s N_ T v a
er
ab lu
se ta
le e)
e g
IF n
N am
_T e
ab
le
dcr
%utg,
%dcr
com1.L12.A41.T1.P100, Feeder Breaker
sval
qly
sqly
rsn
Event
Property
The current value of a master data point (after the change which generated the
event). The representation of the value depends on the data type of the point.
Value
Some values may be represented as character strings (e.g., on, off), while
others may be represented with integer or floating-point values.
The current value of a slave data point. The representation of the value
depends on the data type of the point. Some values may be represented as
Value
character strings (e.g., on, off), while others may be represented with integer
or floating-point values.
A hexadecimal number indicating the quality of the current value of the master
Quality
data point. The quality can indicate a combination of the following bits:
A hexadecimal number indicating the quality of the current value of the slave
data point. The quality can indicate a combination of the following bits:
0x0000
Successful no fault or other conditions
0x0001
Overflow or Rollover
0x0008
Elapsed Time Invalid
0x0010
Blocked
Substituted (over-ride or forced)
Quality 0x0020
0x0040
Off-line (not topical or not dated)
0x0080
Invalid
0x0100
Reference error
0x0200
In transit
0x0400
Un-initialized (not set since startup)
0x0800
Test mode
Update Indicates the reason the event was reported, detected, or generated.
Reason Possible values are:
Page 151
Field
Name
Event
Property
0x0002
0x0004
0x0008
0x0010
0x0020
0x0040
0x0080
0x0100
0x0200
0x0400
0x0800
0x1000
0x8000
Page 152
Field Name
udt
utm
uy2
uy4
umr
ume
udm
udw
uhr
umn
usc
ums
Event Property
Update Date
Utq
Field
Name
Event Property
rdt
Reported Date
rtm
Reported Time
ry2
ry4
rmr
Reported
2-digit Year
Reported
4-digit Year
Reported Month
Page 153
rme
rdm
rdw
rhr
rmn
rsc
rms
Rtq
Reported
Month Name
Reported
Day of Month
Reported
Day of Week
Reported Hour
Reported Minute
Reported Second
Reported
Milliseconds
Reported
Time Quality
Page 154
Field
Name
dcr
Event Property
Description
ptg
Physical
Tag Name
utg
User
Tag Name
prt
Communication Channel
Name
Link Address
lnk
app
Application
Address
ioa
typ
pcl
Information Object
Address
Data Type
Protocol
eli
Element Index
ftp
Function Type
Page 155
Escape sequence
\a
\b
\f
\n
\r
\t
\v
\0mm
\1mm
\2mm
\3mm
\xhh
Type of Event
The data is being updated, but the reason for the update is unknown.
The data is being updated because it was requested.
The data is being updated by the source of data without direct request. No change is
necessarily indicated.
A change in the data is indicated by the source of data.
A change in the data is indicated due to a request through communications.
A change in the data is indicated due to action at the device.
A control request has been transmitted to a remote device.
A control request has been confirmed by a remote device, but is not yet complete.
A 1st pass in a 2-pass control operation has been transmitted to a remote device.
A 1st pass in a 2-pass control operation has been confirmed by a remote device.
A cancel operation has been transmitted to a remote device to abort a 2-pass control
operation between the 1st and 2nd passes.
A cancel operation has been confirmed by a remote device.
Page 156
0x1000
0x8000
4.7
DNP3 Datasets
It is highly recommended that the user be familiar with the document DNP Technical Bulletin TB2004-004e
Data Sets prior to using this feature of the SDG. This document will provide the required background to
effectively use and configure data sets in the SDG.
4.7.1 Background
DNP3 Datasets are collections of data treated as a unit. They can be read and written through the SDG GUI.
Typically there is a 1 to 1 relationship between a dataset descriptor and its present values unless a dataset
prototype is referenced in a descriptor. When this is the case the prototype elements are expanded into the
present value. A descriptor needs to exist on the master and slave before the present values can be
transferred. The descriptors and prototypes are used to define the type information of the present values.
Descriptor and prototype definitions can be transferred between slave and master devices.
4.7.2 Prototypes
Prototypes can be thought of as a formal registered definition for the structure of a group of related data that
can be referenced by a descriptor. When a descriptor references a prototype it inherits the definition of the
elements in a prototype. As a result the elements in a prototype will be expanded into the data set present
value. In the descriptor the prototype is just shown as referenced. A prototype has a unique identifier called
a UUID which should be registered with a standards body. The UUID is also used to reference a prototype
from a descriptor.
To add a prototype to your configuration, a DNP3 session must already exist. Right-click on the DNP3
session, select Add Data Type and then select a T85 (Data Set Prototypes).
Next, right-click on the T85 data type and select Add DNP Prototype:
Page 157
Complete the necessary fields and then click OK to add the new prototype to the T85 data type as shown in
the following screenshot:
To add an element to a prototype, right-click on the prototype (i.e. C0) and then select Add DataSet
Element to Prototype:
Page 158
Upon completing the definition of a prototype the SDG configuration window will look similar to this.
Page 159
To edit a prototype or an element, right-click on the item and select Edit DNP Prototype, for prototypes, or
Edit DNP Dataset Element, for elements.
4.7.3 Descriptors
Descriptors are used to specify the actual definition for the elements in the dataset present value. The
definition can consist of individual elements and/or references to prototypes.
To add a descriptor to your configuration, a DNP3 session must already exist. Right-click on the DNP3
session, select Add Data Type and then select a T86 (Data Set Descriptors):
This will add the T86 and T87 data type to the configuration (see section 4.7.4 Dataset Preset Values for
more information on the T87 data type). Next, right-click on the T86 data type and select Add DNP
Descriptor:
Page 160
Complete the necessary fields and then click OK to add the new descriptor to the configuration as shown in
the following screenshot:
To add an element to a descriptor, right-click on the descriptor (i.e. S1) and then select Add DataSet
Element to Descriptor:
Page 161
Upon completing the definition of a descriptor the SDG configuration window will look similar to the
configuration shown below (in this example, a prototype was referenced in the descriptor):
Because a prototype was referenced in the descriptor, the present values are expanded to show the elements
of the prototype as shown below:
Page 162
Next, use the dropdown box (1) to select the data set present value element that should have its value
supplied by this MDO. If you want to supply the data set present value element with the status value of the
MDO, click the ellipse button (2) to display the Options Editor dialog screen and then enable the
MAP_MDO_SATAUS option.
Page 163
Data set present value MDOs can also be mapped to other SDOs in the SDG by dragging them
to the other SDOs.
Page 164
Page 165
6. Troubleshooting
The following information is provided to assist you with common problems encountered when setting up and
configuring the SDG.
6.1
With Vista, when you install the SCADA Data Gateway you must first save the file locally and then rightclick on it and select "Run as Administrator." Next, right-click on the SDG shortcut icon and then select the
Compatibility tab. Select "Run this program as an Administrator" then click OK; after that, starting the
SCADA Data Gateway from the shortcut should run it as an Administrator.
6.2
The evaluation versions of the SCADA Data Gateway will not run in a Virtual Machine (VM). Only a fully
licensed copy can run in a VM, but this requires a USB flash drive license. Use the following link for more
information on using the SDG on a VM:
http://www.trianglemicroworks.com/VirtualMachines.aspx
6.3
These error messages are most likely related to errors discovered in the Point Mapping (CSV) file during
startup. Since the file could not be completely read on startup, the SDG will not overwrite it on exit in order
to ensure there is no loss of data.
To get more information related to these errors, ensure that you have Errors checked in the protocol
analyzer log filter and then restart the SCADA Data Gateway. You will most likely get an error message
stating that there are errors in the CSV file. However, the errors are now listed in the Protocol Analyzer
along with a line number that corresponds to the line in the CSV file where the error occurred.
These errors may be resolved by:
1. Exiting TMWgtway.exe
2. Editing either the Point Mapping file (CSV) or the INI file
3. Restarting TMWgtway.exe
6.4
6.5
Page 166
6.5.2 Configuration
Verify the configuration of both the SDG and your remote device:
For a serial connection, verify the baud rate, parity, and number of stop bits are configured the same
for both devices.
For a TCP connection, verify the TCP and port address, as well as the client/server settings.
For either type of connection, verify that the link address and common address of ASDU (sector
address) match the addresses set in the remote device.
6.6
Page 167
The "Timeout waiting for application layer response fragment or restart." message is normal behavior after a
warm restart command is sent.
If you are seeing this error at other times, it may indicate that the device with which you are communicating
is either slow or has not established a connection at all.
If you always receive this message, it probably indicates that the connection has not been established. In this
case, you should check your configuration. For a serial connection, verify the baud rate, parity, and number
of stop bits configured. For a TCP connection, verify the TCP and port address, as well as the client/server
settings. For either type of connection, you should verify the link addresses.
If the connection is established but you occasionally receive this message, then the device you are connected
to is probably slow to respond. You might try changing the ApplResponseTimeout parameter in the INI file.
6.7
6.8
If you are experiencing issues when trying to run the SDG as a service, the localization DLL may be corrupt
or missing. To correct this, you will need to download and install the Microsoft Visual C++ 2005 SP1
Redistributable Package using the following URL:
http://www.microsoft.com/downloads/details.aspx?familyid=200b2fd9-ae1a-4a14-984d-389c36f85647&displaylang=en
If you will be running the Service Monitor, then your computer must have the Microsoft .NET
2.0 redistributable installed. If it is not installed, the SDG installer will warn you. You can
download and install the redistributables from the Microsoft web site:
http://www.microsoft.com/downloads/details.aspx?FamilyID=0856eacb-4362-4b0d-8eddaab15c5e04f5&displaylang=en
6.9
The SDG is compatible with any RS-232/RS-485 converter using Send Data (SD) control. If you experience
communication problems when using the SDG with an RS-232/RS-485 converter, make sure that your
converter is configured for Send Data control.
If your converter does not support Send Data control, you will need to acquire a different converter
before using the SDG in your project.
Page 168
Triangle MicroWorks has tested the SDG using the 485SD9TB Port Powered RS-232 to RS-485
Converter from B&B Electronics:
http://www.bb-elec.com/product.asp?sku=485SD9TB&dept_id=171
6.10 Setting Command and Control Modes for Binary Outputs in DNP3 Master
Sessions
The SDG supports several parameters in the INI file that are used to set the command and control modes for
binary output points in Master DNP3 sessions.
The OBJ12_use2pass parameter is used to set the control mode. If this parameter is set to TRUE, then
two-pass control operations will be used for all initiated "Binary Output" controls. If this parameter is set to
FALSE, then single-pass control operations will be used for all initiated "Binary Output" controls.
The OBJ12_forceDflt parameter is used to determine if the control mode specified by the
OBJ12_use2pass parameter will be used or if the control mode will be taken from upstream devices. If this
parameter is set to TRUE, then the default control code will always be used instead of any control codes
for Binary Output controls received from upstream devices. If this parameter is set to FALSE, then the
control code for Binary Output controls received from upstream devices will be used if possible.
The OBJ12_dfltCmdMode parameter is used to set the command mode. Possible values for this parameter
are LATCH, PULSE, and PAIRED. The default is LATCH.
The PulseLength parameter is used to set the length (in milliseconds) of the pulse used for all initiated
Binary Output controls. Pulse Length is used when a pulse, trip or close control code is specified. The
default value is 100 (milliseconds).
The values specified for these parameters in the SDG initialization file apply to all points and
devices configured for use with the SDG.
For certain points and/or devices that require different control and command modes from those specified in
the initialization file, these default values can be overridden using the point mapping file. See Section 4.3.5.3
Table of Control Options and the Meaning on page 112 for more information.
6.11 After installing Windows XP Service Pack 2, OPC Communications via DCOM
no longer work
Installing Windows XP Service Pack 2 with the default configuration will inhibit OPC communications via
DCOM. The OPC Foundation has prepared the following white paper with instructions for configuring
Service Pack 2 for use with OPC/DCOM communications:
http://www.opcfoundation.org/WebUI/DownloadFile.aspx?CM=1&RI=161
Page 169
7. Glossary of Terms
Term
APCI (Application
Protocol Control
Information)
APDU (Application
Protocol Data Unit)
Application Layer
ASDU
ASDU (Application
Service Data Unit)
Description
The transport interface is a stream-oriented interface, which does not define
any start or stop mechanism for the ASDUs of IEC 60870-5-101. In order to
detect the start and end of the ASDUs, each APCI includes delimiting
elements (i.e., a start char, specific length of the ASDU, and control field).
Contains an APCI and an ASDU. The 1st octet, which is subsequently the 1st
octet of the APCI, contains the length of the APDU (max 253).
Layer 7 of the ISO model and one of the layers used in the EPA model. The
application layer contains a number of application functions that involve the
transmission of ASDUs between source and destination.
Data Unit ID Data Unit Type
The application user layer contains a
number of Application Functions that
involve the transmission of ASDUs
between source and destination. The
Information
ASDU is composed of a Data unit
Information
Object ID
Object
identifier and one or more information
objects
Time Tags
Information
baseband
DNP or DNP3
A type of digital data transmission in which each medium (wire) carries only
one signal, or channel, at a time. In contrast, broadband transmission enables
a single wire to carry multiple signals simultaneously.
A device that receives data on a communication link. Also referred to as
Master or SCADA node.
A file format in which each object in the file is separated by a comma. When
an object is to be omitted then two commas are side by side with no space in
between.
These may be physically discrete ports, or logically discrete ports that share a
physical connection, such as multiple TCP/IP serial pipes, each of which is
a separate logical port, even though they may share a single physical 10BaseT
interface.
The direction of transmission from the controlling station to a controlled
station.
Distributed Network Protocol
EPA (Enhanced
Performance
Architecture)
A protocol reference model that provides (compared to the 7 layer ISO model
architecture) a three-layer architecture for obtaining faster response times for
the critical information but with service limitation.
Client
Comma Separated File
(CSV)
Communication Channels
control direction
Ethernet
F-Code
Page 170
FUN
Function type
Function Type
IED
The 1st octet of the information object identifier/data unit identifier defines the
function of protection equipment.
The IEC is a worldwide organization for standardization comprising all
national electrotechnical committees. The object of the IEC is to promote
international co-operation on all questions concerning standardization in the
electrical and electronic fields.
Intelligent Electronic Device
IEC 101
Information Object
IEC (International
Electrotechnical
Commission)
OPC
Point
RTU
SCADA (Supervisory
Control and Data
Acquisition)
SDG
Page 171
TCP/IP (Transmission
Control Protocol/Internet
Protocol)
Type ID
10 Base T
100 Base T
A protocol developed for the Internet to get data from one network device to
another; "TCP uses a retransmission strategy to insure that data will not be
lost in transmission".
Is a code, which unambiguously identifies the ASDUs type within the
collection of all possible types, for a system or a profile. The Type ID enables
the receiving application service to send each data unit to the correct
application process for handling the indicated type of data unit. It also
enables the receiving application process to see what type of data is contained
in the data unit and to determine its structure from a local table.
The User Tag Name is a user-supplied text label that identifies the Master
Component Point. The User Tag Name should not contain spaces. Also
beware of using characters in tag names that may have special meaning to
OPC clients.
One of several adaptations of the Ethernet (IEEE 802.3) standard for Local
Area Networks (LANs). The 10Base-T standard (also called Twisted Pair
Ethernet) uses a twisted-pair cable with maximum lengths of 100 meters. The
cable is thinner and more flexible than the coaxial cable used for the 10Base-2
or 10Base-5 standards.
Cables in the 10Base-T system connect with RJ-45 connectors. A star
topology is common with 12 or more computers connected directly to a hub or
concentrator. The 10Base-T system operates at 10 Mbps and uses baseband
transmission methods.
A networking standard that supports data transfer rates up to 100 Mbps (100
megabits per second). 100Base-T is based on the older standard.
Page 172
Page 173
Page 174
Page 175
Page 176
Page 177
Page 178
Page 179
Page 180
Page 181
Page 182
Page 183
Page 184
Page 185
Page 186
Page 187
Page 188
Page 189
Page 190
Page 191
Page 192
Page 193
Page 194
Page 195
Page 196
Page 197
Page 198
Page 199
Page 200
Page 201
Page 202
Page 203
Page 204
Page 205
Page 206
Page 207
Page 208
Page 209
Page 210
Page 211
Page 212
Page 213
Page 214
Page 215
Page 216
Page 217
Page 218
Page 219
Page 220
Page 221
Page 222
Page 223
Page 224
Page 225
Page 226
Page 227
Page 228
Page 229
Page 230
Page 231
Page 232
Page 233
Page 234
Page 235
Page 236
Page 237
Page 238
Page 239
Page 240
Page 241
Page 242
Page 243
Page 244
Page 245
Page 246
Page 247
Page 248
Page 249
Page 250
Page 251
Page 252
Page 253
Page 254
Page 255
Page 256
Page 257
Page 258