IEC 61850 Driver: IEC61850 Device Config Tab
IEC 61850 Driver: IEC61850 Device Config Tab
Filename IEC61850.dll
Manufacturer
Devices Servers (IEDs) compatible with IEC 61850 Standard (ED1
and ED2)
Protocol IEC 61850 MMS over Ethernet TCP/IP
Version 3.0.17
Introduction
The IEC 61850 Driver communicates with protection relays and other devices using the IEC61850 protocol over Ethernet
TCP/IP (MMS). This Driver allows:
Please check the next documents, provided with this manual, for more information about this Driver's functionality:
Configuration
The [P] configuration parameters of this Driver are not used. All settings are performed on the dialog box of this Driver's
configurations. The configuration tabs are described on the next topics.
The available options on this tab are described on the next table.
OPTION DESCRIPTION
Browse SCL Files Tags from relays can be created online, that is, when users
can communicate with relays, or offline by importing SCL
files. This option opens a window to select ICD or SCD files
to import. After selecting a file, for each description of
relay found, an identification is created on the list of
servers, and a file with the description of Logical Devices
(LD) and Logical Nodes (LN) of a relay is also created,
which can be imported to an application by using the Tag
Browser window. In case there are no SCL files, users can
configure each relay directly by using the Add, Update,
and Delete options
Server Informs the name of a device. Used only to identify a
device for this Driver, mapping it to an IP address
IP Informs an IP address of a device. Optionally, users can
inform a TCP/IP port, if it is not the default port of MMS
protocol, using the format X.X.X.X:X, such as
192.168.0.10:102
Backup IP Informs a backup IP address of a device, if available. Use
the same syntax of the IP option
PSel (Presentation Selector) Selection value for the device used by the OSI presentation
layer (ISO/IEC 8823). It must be checked, if fixed, or
informed in the device's configuration. Its value is usually 1
(one)
TSel (Transport Selector) Selection value for the device used by the OSI transport
layer (ISO/IEC 8073). It must be checked, if fixed, or
informed in the device's configuration. Its value is usually 1
(one)
Rem AP ID (Remote Application Process Identification) Identifier used by the OSI link layer OSI (ISO/OSI 8650), in
ASN.1 (Abstract Syntax Notation 1) format. Indicates the
format of data adopted by the AARQ (Association Request)
function. Its value is usually 1,1,999,1,1 (iso.1.999.1.1)
Rem AE Qual (Remote Application Entity Qualifier) Identifier used by the communication layer as a formatter.
It must be checked, if fixed, or informed in the device's
configuration. Its value is usually 12
Disable Disables this device. Therefore, when starting this Driver,
there is no communication with this device
Use Backup IP Informs whether the backup IP address is used
XMPP Function not available on this version
NOTE
The topic Limitations of this Driver contains information about the maximum number of IEDs supported by this Driver.
The available options on this tab are described on the next table.
OPTION DESCRIPTION
Transport Layer In this version, the transport layer is fixed with the value
MMS (IEC 61850-8-1). In later versions, the XMPP (IEC
61850-8-2) options is also available
App Category To send commands, this Driver uses information from this
option to fill the OrCat (Origin Category) property, which
specifies the type of application sending a command, for
security reasons or for solving conflicts of commands. The
available options are Bay, Station, Remote, or
Maintenance
Msg Timeout (ms) Time to wait for a response of a command or a full
message, which can be formed by several intermediate
messages. The time to wait for each byte or intermediate
message is defined on the Setup tab. For more
information, please check topic Documentation of I/O
Interfaces
Status Check (ms) Time interval to send status messages, which must be
answered by an IED. If there is no response, connection
health can be checked, forcing an IED's disconnection and
reconnection. The value of this option must be greater than
the value of the Msg Timeout (ms) option and less than
the disconnection interval configured on the Setup tab. For
more information, please check topic Documentation of
I/O Interfaces
Local S Selector Selection value for this Driver, used by the OSI session
layer (ISO/IEC 8327)
Local T Selector Selection value for this Driver, used by the OSI
transportation layer (ISO/IEC 8073)
Local App ID Local Application Process Identification Identifier used by the OSI link layer (ISO/OSI 8650), in
ASN.1 (Abstract Syntax Notation 1) format. Indicates a data
format adopted by the AARQ (Association Request)
function. Its value is usually 1,1,999,1,1 (iso.1.999.1.1)
LD File Path Default directory where this Driver stores descriptive files
for each Logical Device found, to improve the initialization
process. In the next initialization, if a file is found on the
specified directory, whose name is given by the format
SERVER_LDNAME.LD, where SERVER is the name of the
device and LDNAME is the name of the Logical Device,
then this LD is described based on this file. This Driver
provides several ways to detect changes on IED database,
to update these files
Check Nameplate Mismatches Enables checking identification parameters of an IED
(nameplate) when starting communication, to compare
whether there were any changes. If true, a cache update
(rebuilding LD files) is performed
Invert stVal BitString Interpretation of bitstrings with two or more bits can be
changed by this option, by changing the meaning of Open
or Closed statuses in an application. Default behavior is
reached by deselecting this option
Full Log Details Enables inserting in this Driver's log, enabled on the Setup
tab, detailed information about the notification of events
for any Tag. For more information, please check topic
Documentation of I/O Interfaces
Apply Local Offset to Timestamps Timestamps adopted by the IEC 61850 standard always
refer to UTC (Universal Time Coordinate) standard. By using
this options, users indicate that this Driver must apply a
local offset (timezone and daylight saving time) to the
timestamp sent by a device
No LD Database Scan Informs that no Logical Device or Logical Node request
must be processed for IEDs. This option can be used when
this Driver is used only to transfer files
Block LD Cache Delete In cases where the initialization process is incomplete, or
when any inconsistency is detected between cache files (LD)
and IED's or Server's current database. This Driver deletes
and updates cache files. Enable this option to block file
removal
Local AE Qual - Local Application Entity Qualifier Identifier used by the link layer as a formatter. Its value is
usually 12
RFC 1006 Source TSAP This Driver uses RFC 1006 specification as a way to
transport ISO packets over TCP. To do so, users must
inform the TSAP (Transport Service Access Point) used to
Proposed MMS PDU Size When the Transport Layer option is configured as MMS,
this option defines the size of the PDU negotiated with the
server. Default value is 65000 bytes
Reports Tab
Reports tab
The available options on this tab are described on the next table.
OPTION DESCRIPTION
Prefer Buffered Report Control Blocks (uses Unbuffered IEC 61850 protocol uses Report objects to notify client
if not available) applications about changes on data. Reported data are
defined by users in a DataSet. Each Report can only be
linked to a single DataSet and a device can have several
Reports and DataSets. Please check section Prefer
Buffered Report Control Blocks for more information
about this option
Poll Tags not Found in any Report When a Tag is not found in any Report, this option allows
performing a cyclical reading (polling) of this Tag
according to its scan rate. Remember that this method is
not the most indicated nor the most efficient, because it
may be subject to slow data updates and loss of fast
events
Force Tag Polling Individually using N1 Parameter A polling request for specific variables can be defined with
a value different from 0 (zero) in the N1 parameter if this
Wait for Gtw Ref on Startup Enables the automatic Report EntryID for Gateway
Applications. Please check the topic Gateway
Configuration.
Copy All Values Before Reporting If the DataSet linked to a Report contains objects with
quality and timestamp after the corresponding properties,
this option can be selected to avoid a notification of value
to an application happens without the correct update of
quality and timestamp
Auto Integrity Rpt (s) If the informed value is different from 0 (zero), this Driver
informs this value when enabling a Report as the interval
that an unsolicited general interrogation (GI) message is
generated by the device
Use Exclusive URCBs Defines if, when enabling an Unbuffered Report (URCB),
this Driver is set to exclusive mode (the Reserved property
configured to one) or not (the Reserved property
configured to zero). A URCB enabled in exclusive mode
cannot be used by other clients
Use Quality Change Trigger Indicates an option of trigger by change of quality that
must be used by default, when users are not using a fixed
list of Reports or if the TrgOps option was not informed
Reports can have two types, Buffered and Unbuffered. Buffered means that all changes on the DataSet elements during
a disconnection are stored on buffers, so that a client application receives a notification about all those changes, as long
as there is sufficient space in memory on the device and the settings are correct. This type of Report is used mainly for
SOE (Sequencing of Events) data types. Unbuffered Reports, on the other hand, only store the last value. Both Reports
can be configured to send events spontaneously, at cyclical intervals or wait for a client application to explicitly request, by
polling or general interrogation (GI), data from that Report. However, users must notice the following situations:
· If two client application, such as two E3 or Elipse Power applications, are connected to a device, only one of those
applications can connect to each Buffered Report. This is due to the fact that, when sending data, it is deleted from
the Report's internal buffer.
· Two or more client applications can connect to the same Unbuffered Report, in case they are not using the exclusive
usage option.
This way, the Prefer Buffered Report Control Blocks option instructs this Driver, whenever a Tag enters a communication
process (enter in advise or in scan), to search among all Buffered Reports of a device if the specified Tag belongs to the
respective DataSet of each Report.
If not found, then the Report is enabled by this Driver, if not yet, and starts receiving change notifications. Otherwise, this
Driver starts to repeat the same search process, now on Unbuffered Reports for the same Tag. If found, the Report is
enabled, if not yet. If the answer is negative again, the Tag can communicate in polling mode if the Poll Tags not found
in any Report is enabled.
If the Prefer Buffered Report Control Blocks option is disabled, this Driver repeats the previous procedure, but directly
searching for Unbuffered Reports and discarding the search for Buffered Reports.
· TagName: UserReportList
· Device: ServerName
· Item: UserDefinedReportList
Sub DRV_61850_AfterStart()
'The next script creates an array
'containing the configuration of a Logical Device and its corresponding Report,
'which are activated when writing to the UserReportList Tag.
'Notice that this is a two-position array.
'If users need to activate more Reports,
'configure the size of that array
Dim arr(1)
arr(0) = Array("LogicalDeviceName", "LLN0$BR$brcbEV101")
arr(1) = Array("LogicalDeviceName", "LLN0$BR$brcbEV102")
Set Cmd = Application.GetObject("DriverName.IEDName.UserReportList")
Cmd.WriteEx(arr)
End Sub
NOTE
When selecting the User Defined Report List option, this Driver only finishes the initialization process after receiving a
writing to the UserReportList Tag.
PARAMETER DESCRIPTION
Number_Of_LogicalDevices Total number of Logical Devices in this file
LogicalDeviceN;Number_Of_Reports For each Logical Device, insert a name and how many
Reports are used
ReportName Right after the name of each Logical Device, follows a list
with the Reports used and optional fields
ReportOption;ReportValue The table Optional fields contains optional fields allowed
in an RPT file
Optional fields
FIELD DESCRIPTION
DatSet:DataSetName Name of a DataSet that must be linked to the Report
TrgOps:Options Trigger options for the Report. The Options value
corresponds to a mask of six bits with the values 0: Not
used, 1: DataChange, 2: Quality Change, 3: Data Update, 4:
Integrity, and 5: GI (General Interrogation)
User-Defined Datasets
· TagName: DeclareDSList
· Device: ServerName
· Item: DeclareClientDSList
Users must inform an array of descriptors, each descriptor containing an array with three elements, the name of the
Logical Device, the name of the DataSet (add an @ character at the beginning of this name if volatile) and a unique index
for each DataSet.
Dim arr
arr = Array("LogicalDeviceName", "DataSetName", 1)
Set Cmd = Application.GetObject("DriverName.IEDName.DeclareDSList")
Cmd.WriteEx(arr)
· TagName: PopulateDSList
· Device: ServerName
· Item: PopulateClientDSList
Commands Tab
Commands tab
The available options on this tab are described on the next table.
OPTION DESCRIPTION
Asynchronous Write Allows request commands to return success immediately,
without waiting for an answer, as long as its sending was
successful, such as when there is an active connection. This
behavior aims to facilitate operations involving sending a
large number of commands, to increase general speed.
However, it does not check for failures during the
processing of that command on the device
Use Single Tag Command Alias Instructs this Driver to create during the Tag Browsing
process (please check the next note) a single Tag to send
commands. If this option is not selected, then uses a Block
Tag with five Elements. For more information, please check
topic I/O Tags
Use Cmd Tag N1 as Check Condition In case of using a simple Tag to send commands, this
option informs whether the N1 parameter of this Tag is
used to indicate a security check parameter of a command.
The N1 parameter, in this case, must be a number between
0 (zero) and 3 (three), as the result of a logic OR between
bits 0: INTERLOCKING and 1: SYNCHROCHECK
NOTE
If users are using E3 or Elipse Power as an OPC server, the command Tag can have its reading enabled, that is, the
AllowRead property configured to True. This allows this Tag to receive the initial value of the CtlVal property of the
referred command object, so that an OPC client previously knows the data type. After sending a command, this Driver
returns an automatic reading for the same Tag, with the value written in case the operation is successful. This way, the
WriteFeedBackMode parameter of this Driver, which indicates how a Tag receives a confirmation of the operation by
keeping the written value, can be configured in 0: WaitNextRead, preferably.
Files tab
The available options on this tab are described on the next table.
OPTION DESCRIPTION
Save Comtrade Files Indicates whether this Driver must perform a search for COMTRADE files,
saving them on the directory indicated in the Comtrade Path option
will be defined per IED and not globally for the whole driver.
The individual definition can be done through writing the driver internal
parameters via IOKIT, as explained at the item "Dynamic Configuration".
Delete Files After Upload Instructs this Driver to delete a device's file after successfully finishing the
transfer
Browse Root Folder Only Some relays insert COMTRADE files on a COMTRADE folder from the root
folder, and other relays insert these files on the root folder, indicating as
part of the file name that folder, such as "\COMTRADE\File.cfg". Select this
option for devices with that last behavior
Comtrade Upload Interval (s) In case of transferring more than one file, this Driver waits the time defined
in this option to perform each transfer, to separate a specific time window
for this activity. However, receiving events and sending commands are not
interrupted while transferring a file
Comtrade Path Indicates a directory where this Driver saves COMTRADE files
Fixed Comtrade Path on Device Indicates that a Driver must ignore a search for the COMTRADE folder on
the device, assuming a fixed folder informed in the corresponding field
PRP Tab
Through this tab it is possible to configure PRP (Parallel Redundancy Protocol).
PRP Tab
OPTION DESCRIPTION
Enable PRP Indicates if this driver shall use the PRP Service. If other IEC 61850 drivers exist at the
same system, it is possible to let this option set in all of them, or only at the first one.
Nevertheless, PRP statistical information will only be available to the first driver to
start execution.
Virtual Adapter Select which adapter will be used as Virtual Adapter.
LAN A Select which adapter will be used for LAN A.
LAN B Select which adapter will be used for LAN B.
PRP Service Path Select the folder which the file ElipsePRPSvc.exe was copied. This file is supplied
together with the IEC61850.dll driver.
Status UDP Port Inform an available local TCP/IP port, which will be used by IEC 61850 driver to receive
statistics and logs from the ElipsePRPSvc.exe service. Remember that PRP Statistics will
only be available for the first driver to start execution.
Run Service Upon clicking this button, the driver will generate a initialization file "ElipsePRPSvc.ini"
at the same folder defined for the service, and in sequence it will try to start the
service. A message box will show the result.
Stop Service When clicking this button, the driver will try to stop the service, if it is running. A
message box will show the result.
Check Svc Status When clicking this button, the driver will show a message box with current service
status (Stopped, Running, Pausing, etc..)
Tag Browser
Click Tag Browser on this Driver's toolbar in E3 or Elipse Power to open the Tag Browser window, which allows listing
and dragging to this Driver the Tags identified in a device, according to the next figure.
· IOKit: Contains standard Tags from Elipse Software's IOKit library, allowing to read or write general connection
parameters and status, among others
· Online: Displays Servers declared on the IEC61850 Device Config tab. When clicking a Server, this Driver tries to
communicate with the device, creating a new child folder for each Logical Device (LD) found in the device. Click an LD
to retrieve all respective Tags
· Offline: Displays all Servers and LDs, but clicking an LD displays Tags from LD files created in the import directory,
whether from importing SCL files or by executing an application
To use these Tags in an application, drag them from the list Tags available from driver to the list Tags from current
project.
NOTE
This Driver inserts in each Logical Device a DataSets folder, where users can find all DataSets of that Logical Device
referenced by a Report.
· Logical Devices (LD): These are mapped logical devices that correspond to a real device, such as a Bay, mapped
inside a relay. A Logical Device is always mapped to a single IED (Intelligent Electronic Device), because Logical Devices
are not distributed
· Logical Nodes (LN): These are functions from a real device mapped to a Logical Device. For example, a virtual
representation of a switch (Circuit Breaker) in a Bay is a Logical Node, which contains a standard class name defined
as XCBR. Usually a Logical Device is formed by several Logical Nodes
· Data Objects (DO) and Data Attributes (DA): Information inside a Logical Node is organized in sets of specific data
(Data Objects) and the properties inside each set are Data Attributes. The set of all Data Attributes from a Data
Object is called CDC (Common Data Class)
· Functional Constraint (FC): These are specific services that can be used in each Data Attribute. FCs may also be part
of a variable's path, depending on the configuration of a device
The format used by this Driver for all Tags representing Data Objects or Data Attributes is the following:
Tag Reference
This section contains information about the configuration of I/O Tags and Internal Tags.
I/O Tags
The N parameters of I/O Tags are not used. Tags are addressed only using the Device and Item parameters.
ELEMENT DESCRIPTION
Operation Must receive the operation to perform in Text format.
Possible values are OPERATE, SELECT,
SELECTWITHVALUE, or CANCEL
Value Value to send, depending on the type of object, in the
CtlVal property
Time Time instant, in Visual Basic standard in days since 1900,
for use in a SELECT command by time and filling the T
property
Test Indicates whether a command is a test operation (value
equal to one) or not (value equal to zero)
Check Type of check performed before performing a command.
It must be a number between 0 (zero) and 3 (three) as the
result of a logic OR between bits 0: INTERLOCKING and 1:
SYNCHROCHECK
STATUS STATUSTEXT
0 Terminated OK
2 Select Accepted
3 Select With Value Accepted
4 Cancel Accepted
5 Operate Accepted
50 Terminate Fail
100 AppError:Unknown
101 AppError:NotSupported
102 AppError:BlockedBySwitchingHierarchy
103 AppError:SelectFailed
104 AppError:InvalidPosition
105 AppError:PositionReached
106 AppError:ParameterChangeInExecution
107 AppError:StepLimit
108 AppError:BlockedByMode
109 AppError:BlockedByProcess
112 AppError:CommandAlreadyInExecution
113 AppError:BlockedByHealth
114 AppError:1_Of_N_Control
115 AppError:AbortionByCancel
116 AppError:TimeLimitOver
117 AppError:AbortionByTrip
118 AppError:ObjectNotSelected
200 WriteError:Object_invalidated
201 WriteError:Hardware_fault
202 WriteError:Temporarily_unavailable
203 WriteError:Object_access_denied
204 WriteError:Object_undefined
205 WriteError:Invalid_address
206 WriteError:Type_unsupported
207 WriteError:Type_inconsistent
208 WriteError:Object_attribute_inconsistent
209 WriteError:Object_access_unsupported
210 WriteError:Object_non_existent
211 WriteError:Object_value_invalid
212 WriteError:Error_unknown
213 WriteError:Timeout
214 WriteError:OutOfMemory
215 WriteError:DecodeError
216 WriteError:WrongParameters
217 WriteError:CmdnotSupported
· The Check property has a fixed value of 3 (three, INTERLOCKING and SYNCHROCHECK), except when the N1
parameter is enabled in the option Use Cmd Tag N1 as Check Condition
The Tag for the TimeActivatedOperate operation, with a TimeActOper suffix, is available when the LN contains the
OpertTm property. This operation occurs in a way similar to the Operate command, except that the Tag's timestamp is
used as the operation's time and a scheduled operation can be canceled using the Cancel Tag.
Internal Tags
D ITEM OPERATION MEANING
E
V
I
C
E
S ServerStatus Read Returns the internal status of this Driver. If the Device parameter is
e only equal to ServerName, then this status is relative to the device as
r a whole. Possible values are 0: Starting, 1: Reading LD files, 2:
v Retrieving directory (GetServerDirectory), 3: Processing a single LD
e (Tag Browsing), 4: Retrieving a directory of files, 5: Processing LDs, 6:
r Finishing, 7: Finished OK, 8: Finishing with error, 9: Finished with error,
N 10: Reconnecting, or 11: Finished (waiting)
a
m
e
S ServerStatus Read If the Device parameter is equal to ServerName:LDName, then status
e is relative to the Logical Device. Possible values are 0: Waiting, 1:
r Reading LD file, 2: Retrieving LD directory, 3: Retrieving LN directory,
v 4: Retrieving data definition, 5: Creating a cache of Tags, 6:
e Discovering Reports, 7: Retrieving DataSets, 8: Retrieving the content
r of DataSets, 9: Retrieving Nameplates, 10: Retrieving versions of
N Reports, 11: Checking versions, 12: Programming Reports, 13:
a Operation (runtime), 14: Finishing, or 15: Finishing with error
m
e
:
L
D
N
a
m
e
S ComtradeTransferStatus Read Returns the activity status of file transfers via COMTRADE. Possible
e values are 0: Not connected, 1: Connected, 4: Waiting to list files, 5:
r Retrieving a list of files, 6: Files transferred (synced), 7: Waiting to
v transfer files, 8: Transferring file, 101: Empty list of files in the relay,
e 102: Format errors in the reading command, 103: Error when saving
r COMTRADE file, or 104: Error when transferring file
N
a
m
e
S LastComtradeFileName Read Informs the name of the last transferred COMTRADE file
e
r
S LastComtradeFileTime Read and write Indicates the date of the last collected COMTRADE file. When starting
e an application and avoid files already collected to be retrieved again,
r this Tag must receive a writing with the date of the last existing file.
v So, It is recommended that an application stores the value of this
e Tag when quitting and write back this value when starting
r
N
a
m
e
S ComtradeInfo Read Returns a Block Tag with three Elements with COMTRADE properties.
e Values for Elements are 0: ComtradeTransferStatus, 1:
r LastComtradeFileTime, and 2: LastComtradeFileName
v
e
r
N
a
m
e
S IPSelect Read Informs which IP address is in operation, in cases of using main and
e backup IP addresses
r
v
e
r
N
a
m
e
S IOKitEvent Read Returns IOKit events for the specified IED especificado, according to
e the Read Driver Events Tag available on topic Documentation of
r I/O Interfaces
v
e
r
N
a
m
e
S GetFileDirectory Read Informs a list of existing files in the IED after a GetFileDirectory
e (write) request. If there is no previous request or if there is no data
S FinishedWriteTimeOfEntr Write Please check topic Reports Tab for more information
e y
r
v
e
r
N
a
m
e
S FinishedWriteEntryID Write Please check topic Using EntryID for more information
e
r
v
e
r
N
a
m
e
S IPSwitch Write Requests a switch from the main IP address to the backup address
e or vice versa
r
v
e
r
N
a
m
e
S DeclareClientDSList Write Declares a list of DataSets defined in the client. Please check topic
e Reports Tab for more information
r
v
e
r
N
a
m
e
ServerInitialBuild Item
In the next example, supposing there is an IniBuild Tag with its Item parameter equal to ServerInitialBuild, an IED with
index 0 (zero) is enabled and the TSel parameter is changed.
Dim CommArr(1)
CommArr(0) = Array("IEC61850.Device[0].Disable", 0)
CommArr(1) = Array("IEC61850.Device[0].TSel", 1)
Write -1, 0, 0, 3, CommArr
Item("IniBuild").WriteEx(1)
Redundancy
The ways this Driver avoids receiving duplicated events during start up are the following:
· By defining the last EntryID with automatic generation of a file with an .eid extension
Using EntryID
When selecting the Check BRCB EntryID option on the Reports tab without the automatic files (.EID) option, an
application must perform the next procedures to work properly:
1. Create in the application, or import via Tag Browser, the EntryID Tags available in each Buffered Report and in use
by this Driver. This Tag's value is a Text-type and represents a sequence of bytes.
2. If users do not know whether a Buffered Report is in use, please check the list of BRCBs, as described on topic
Reports Tab.
3. Create in the application an Internal Tag for each EntryID to sync. This Internal Tag must have its Retentive property
configured to True. NOTE: Starting with version 3.2 of E3, users can also perform this procedure using XObject
Properties, which can have their Retentive property enabled directly.
4. Each Internal Tag, or XObject Property, must receive value changes from the corresponding EntryID via script or Link.
5. When starting this application, there must be a script that writes the value of each EntryID according to the value of
the corresponding Internal Tag, which must be updated according to the value sent by the redundant station. At the
end of this process, a special Tag must be written indicating that the process of writing EntryID properties ended and
this Driver can resume initialization. This Tag must be configured with the next properties.
· Name: FinishedWriteEntryID
· Item: FinishedWriteEntryID
NOTE
If the EntryID check option is configured, this Driver only resumes initialization after writing that Tag.
During this Driver's initialization, the application waits for the availability of this file to proceed, to retrieve the values of the
processed EntryIDs until this operation is interrupted. In a redundant system, a user-created application must be
responsible for syncing this file between main and Standby machines.
The next example, which must be executed cyclically, copies EntryID files among redundant servers. As this Driver is
loaded by the IOServer module, which executes on the System account, the example code uses the psExec (SysInternals)
application to elevate privileges of a Windows user, by executing a batch (.bat) file that specifies a user and a password.
NOTE
For more information about the psExec application, please check article PsExec v2.2 on Microsoft Developer Network.
Sub MyTimer_OnPreset()
Set objWScript = CreateObject("WScript.Network")
strServer = objWScript.ComputerName
Set sw = CreateObject("WSCript.shell")
Set fso = CreateObject("Scripting.FileSystemObject")
Set folder = fso.GetFolder("C:\MyAppDir\MyEntryIdDir")
'Loads .eid files
For Each file In folder.Files
GetAnExtension = fso.GetExtensionName(file.path)
If GetAnExtension = "EID" then
'Copies files
fso.CopyFile file.path, "C:\MyAppDir\MyEntryIdDir\EID\"
End If
Next
If strServer = "Server2" Then
sw.run "C:\MyAppDir\Bat\psExec.exe -i 0 -u UserAccount -p Domain@password cmd /c C:
\MyAppDir\Bat\toServer1.bat", 0
End If
If strServer = "Server1" Then
sw.run "C:\MyAppDir\Bat\psExec.exe -i 0 -u UserAccount -p Domain@password cmd /c C:
\MyAppDir\Bat\toServer2.bat", 0
End If
End Sub
In a PRP architecture there must be two parallel networks (LAN_A and LAN_B), with the preferable and totally redundant
adherent devices called DANs (Dual Attached Nodes), i.e. they have 2 interfaces, one on each LAN. Devices with a single
interface (called SAN - Single Attached Nodes) can also take part of the architecture, but don´t benefit from redundancy,
as well as other devices that do not directly support PRP (called VDANs - Virtual Dual Attached Nodes) which can be
connected through a RedBox (Redundancy Box).
Elipse IEC 61850 driver behaves as a DAN, considering that the computer shall have 2 physical network adapters and one
virtual network adapter, installed and configured correctly.
In order to perform packet capture and injection to/from the adapters it is necessary to install a traffic sniffer library,
which can be one of the following options:
2 - Winpcap10: Update of Winpcap for Windows 10, and Windows Server 2016/2019. http://www.win10pcap.org/
3 - NPCAP: Actually installed with Wireshark. But in order to work correctly with this driver, it is necessary to be installed
with WinPcap API Compatibiity mode. https://nmap.org/npcap/
Virtual Adapter
The virtual adapter is a non-physical network adapter installed on Windows, with the objective to provide a single
interface for the IEC 61850 driver (or even other protocols) independent of which physical network (A, B or both) is/are
active.
Install
The simplest way to install a virtual adapter is explained below (example for Windows 10):
1 - On search bar, besides the windows Icon, type "Device Manager", selecting this program.
3: At the "Add Hardware" window, click at "Install the hardware that I manually select from a list (Advanced)" and after that
click on Next.
5: Select “Microsoft” at left panel. Next, choose Microsoft KM-TEST Loopback and hit Next until finish.
Configuration
- Enable at the adapter the usage of the sniffer library (npcap ou winpcap adapter)
- Define a fixed IP Address
To do it, go to Control Panel - Network and Internet - Network Connections, where all connections are exhibited. Select
the Virtual Adapter properties.
At the adapter properties window, enable the mininum number of options, in order to decrease the network traffic to the
IED network. The main options to enable shall be Npcap Packet Driver ou Win10Pcap Driver, and TCP/IPv4.
Select TCP/IP properties and inform a valid and fixed IP Address to access the IED network.
In order to assure that 61850 MMS messages will be directed only to the virtual adapter and not for other adapters, it is
necessary to select this interface for the driver.
To do it, open driver configuration, and at Setup tab define Physical Layer as "Ethernet".
Finally, return to the Setup tab and put back the Physical Layer to "None". Click on OK and Save the driver.
To perform this configuration, go to Control Panel - Network and Internet - Network Connections, where all adapters are
shown. Select the properties of the Ethernet Adapter that will receive network A and disable all network protocols,
including TCP/IP, leaving enabled only the sniffer library (at the example below, Win10pcap Packet capture driver). Click
on OK.
After that, open again the adapter properties and click at the Configure button. Select the tab Advanced, and at the option
"Network Address" define the desired MAC Address, at the 12 hex digits format.
NOTE: Since both adapters shall have the same MAC, this can be obtained defining the MAC Address of the first adapter
at the second or vice-versa, or even defining a new MAC for both.
In order to know the actual MAC Address of your network adapter, open a new command session (cmd.exe) and type the
command "ipconfig /all".
PRP Service
Together with the IEC61850.DLL driver, starting from version 3.0.8, it is provided at the same .ZIP file the program
ElipsePRPSvc.exe, that shall be copied in a folder of your choice, in order to allow PRP communications. The folder can
be the same used for the IEC61850.dll or a different one.
This file is a windows service, that needs an initialization file ElipsePRPSvc.ini to start. This file is generated by the driver
configuration window (PRP Tab).
When clicking at the "Run Service" button, the driver will generate the initialization file at the same folder of the service,
and will try to start the service. This procedure shall be executed only once, because after the ElipsePRPSvc.ini is
generated, the service will be started automatically by the the first IEC61850 driver with the PRP option enabled.
Another option is to configure the service to start automatically when windows starts. For this, at the search bar type
"Services", select Elipse PRP Service at the list - select Properties and define the initialization type as "Automatic".
After startup, the service starts to send other logs and statistics to an UDP port, informed at the configuration window,
which is received by the IEC 61850 driver.
The log messages are redirected to the driver log, with the prefix "PRPService: XXXXXXXX".
Status information are available through 6 tags, that can be created at the driver. Remember that such information is only
available for the first 61850 driver to enter operation, if other drivers with PRP option enabled exist at the same
application.
They are:
Define a reasonable scan interval for these tags, in order to avoid driver log pollution. As suggestion, the scan can be
between 5000 and 10000 ms (5 and 10 seconds).
Gateway Configuration
In gateway applications, where it's necessary to send data from this 61850 driver to other protocols (like DNP 3.0 or IEC
104), it is possible to find situations of event loss or duplication, especially at application startup or gateway switch-over
(hot standby).
This may happen when an event is received by 61850 driver and forwarded, but it not received yet by a remote master in
another protocol. Example:
Aba Reports
The image above show events being transferred and pending of transmission in several gateway components (61850
Server, 61850 Client, DNP Slave and DNP Master). This event queue size can change depending on the protocol driver
configuration and network architecture, between other factors.
When a switch-over from Gateway A to Gateway B happens, for example, the pending events can be lost or duplicated,
depending on the application configuration. This behavior can be controlled by programming the EntryID field of the
61850 buffered reports. The EntryID is a unique identifier for each report message sent.
When enabling the Gateway feature by the option "Wait for Gtw Ref on Startup", the driver will wait for E3 application to
inform a string text which represents each 61850 tag inside another driver (ex: DNP or IEC 104 Slave). When this other
driver receives the confirmation the event was delivered to Control Center, it can inform back 61850 driver about this
event, so it's possible to position EntryID values forward and save the EntryID File. If a new swtichover happens, the driver
will enable the reports starting from this point - avoiding the event loss or repetition.
EntryID Management
1 - Enable the options "Check BRCB Entry ID", "R/W Entry ID File (.EID)", "Wait for Gtw Ref on Startup". Further, if the
IED uses the same reports for both gateways, you should evaluate using a fixed report list - "User Defined Report List",
avoiding the redundant application to enable unexpected reports.
2 - At 61850 driver, create the tag "FinishedGtwRef", and the blocks "GatewayRef" and "GatewayEventOK" as below. These
3 tags are described at the topic Referência de Tags - Tags Internos.
3 - Taking DNP Slave driver as example, a block with N2=-22 shall be created. It receives at the OnRead script a list with
master confirmed events. Please consult DNP Slave driver documentation for more details.
5 - Upon startup, the application shall initialize the external references, passing a string text which represents the
DNP Address for each 61850 tag which needs the EntryID management. This write operation, however, can only be
performed from the moment the driver has the Logical Devices created, otherwise the write will fail. To solve this
problem, the exemple below shows an internal tag script which tries to send the configuration every 5 seconds. If
the operation is successful, the event is not fired anymore. At the process end, the tag "FinishedGtwRef" is
written.
Also in this example, the reference string is obtained through the union of DNP object/variation and the index. At
the DNP Slave driver these values are available at N3 and N4 parameters.
Initial Value of the tag InitGateway: TRUE (Boolean)
6 - When "EventOK" Block is read at DNP Slave driver, it means a new event was received and confirmed by DNP Master.
The script below gets the event information and forwards to 61850 driver. At the DNP Slave specific case, this block
returns object and variation, index, class, value, valid timestamp and timestamp. The script sends all these parameters to
61850 (except DNP class, which is not relevant) using the block GatewayEventOK.
Sub EventOK_OnRead()
Set IECBlock = Application.GetObject("IEC61850.GatewayEventOK")
IECBlock.Item("Ref").Value = CStr(Item("ObjVar").Value) + ";" + CStr(Item("Index").Value)
IECBlock.Item("Value").Value = Item("Value").Value
IECBlock.Item("TSValid").Value = Item("TSValid").Value
IECBlock.Item("Time").Value = Item("Time").Value
IECBlock.Write 2 'async
End Sub
7 - At this moment the driver will position the EntryIDs at the next pending event. To synchronize the EntryIDs with the
redundant computer, it is necessary to follow the steps indicated at the section Redundancy - Using EID Files.
- When a new 61850 report is received, it checks if any dataset object with a gateway reference has changed
quality or value. If positive, a new event is added to an internal individual list per 61850 object.
- When an event is confirmed by external driver and informed at the block "GatewayEventOK", the internal list is
compared with the informed event:
- If timestamp is not valid (DNP/IEC104 Slave tag is not using timestamp), all events are removed from the
list;
- If timestamp is valid, all events are removed if they are equal or happened before the informed event.
In order to avoid unnecessary processing, it is recommended to only add gateway references to tags that can´t have
event loss or duplication, typically digital and simple/double state tags. It is also recommended in this case, to separate
report Datasets by tag types. By configuring digital and analog tags in different datasets, you can avoid receiving useless
old analog values if the digital reports have to roll back in time.
Configuration parameters
IP IEC61850.Device[%u].IP STRING
Backup IP IEC61850.Device[%u].IPBackup STRING
PSEL IEC61850.Device[%u].PSel DWORD
SSEL IEC61850.Device[%u].SSel DWORD
TSEL IEC61850.Device[%u].TSel DWORD
Rem AE Qual IEC61850.Device[%u].AEQualifier DWORD
Rem AP ID IEC61850.Device[%u].AppID STRING
Disable IEC61850.Device[%u].Disable BYTE
Use Backup IP IEC61850.Device[%u].UseIPBackup BYTE
Save Comtrade (Per Device) IEC61850.Device[%u].SaveComtrade BYTE
Delete Comtrade Files (Per Device) IEC61850.Device[%u].DeleteComtrade BYTE
Browse Root Folder Only (Per IEC61850.Device[% BYTE
Device) u].BrowseRootFolderOnly
· IEC61850.dll: Allows communication with up to 25 relays (IEDs), to ensure communication performance. For more
relays, use a new instance of this Driver
· Power_IEC61850.dll: Allows communication with a single relay (IED), using a standard license that allows replacement
by another power system Driver. For a full list of Drivers sharing this license, please check with Elipse Software
Driver Configuration
I/O Interface configuration is performed on a Driver's configuration dialog box. To access the configuration of this dialog
box in E3 (version 1.0), follow these steps:
In E3 version 2.0 or later, click Configure driver on a Driver's toolbar. In Elipse SCADA, follow these steps:
Currently, an I/O Interface allows opening only one connection for each Driver. This means that, if users want to access
two serial ports, they must add two Drivers to an application and then configure each Driver for each serial port.
Setup Tab
The Setup tab contains Driver's general configurations. This tab is divided into the following groups:
· General configurations: Configurations of Driver's physical layer, time-out, and initialization mode
· Connection management: Configurations on how the I/O Interface keeps a connection and which recovery policy is
used on failure
OPTION DESCRIPTION
Physical Layer Select the physical layer on a list. Available options are
Serial, Ethernet, Modem, and RAS. The selected interface
must be configured on its specific tab
Timeout Configure a time-out, in milliseconds, for the physical layer.
This is the amount of time an I/O interface waits to receive
any byte from reception's buffer
Start driver OFFLINE Select this option so that the Driver starts in Offline mode
or stopped. This means that the I/O interface is not created
until this Driver is configured to Online mode by using a
Tag in an application. This mode enables a dynamic
configuration of an I/O interface at run time
OPTION DESCRIPTION
Mode Selects a management mode of a connection. Selecting the
Automatic option allows a Driver to manage the
connection automatically, as specified in the next options.
Selecting the Manual option allows an application to fully
manage a connection. Please check topic Driver Statuses
for more details
Retry failed connection every ... seconds Select this option to enable a Driver's connection retry in a
certain interval, in seconds. If the Give up after failed
retries option is not selected, the Driver keeps retrying
Give up after ... failed retries Enable this option to define a maximum number of
connection retries. When the specified number of
consecutive connection retries is reached, the Driver goes
to the Offline mode, assuming that a hardware problem
was detected. If a Driver establishes a successful
connection, the number of unsuccessful retries is cleared. If
this new connection is lost, then the retry counter starts at
zero
Disconnect if non-responsive for ... seconds Enable this option to force a Driver to disconnect if no byte
was received by the I/O interface during the specified time-
out, in seconds. This time-out must be greater than the
time-out configured in the Timeout option
OPTION DESCRIPTION
Log to File Enable this option and configure the name of a file to write
a log. Log files can be large, so use this option for short
periods of time, only for testing and debugging purposes.
If the %PROCESS% macro is used in the log file name, it is
replaced by the ID of the current process. This option is
particularly useful when using several instances of the same
Driver in E3, thus allowing each instance to generate a
separate log file. For example, when configuring this
option as c:\e3logs\drivers\sim_%PROCESS%.log, a file
named c:\e3logs\drivers\sim_00000FDA.log is generated
for process 0FDAh.
Users can also use the %DATE% macro in the file name. In
this case a log file is generated every day (in the format
aaaa_mm_dd). For example, when configuring this option
as c:\e3logs\drivers\sim_%DATE%.log, a file named c:
\e3logs\drivers\sim_2005_12_31.log is generated in
12/31/2005 and a file named c:
\e3logs\drivers\sim_2006_01_01.log is generated in
01/01/2006
Ethernet Tab
Use this tab to configure parameters of an Ethernet Interface. These parameters, except port configurations, must also
be configured for use in the RAS.
OPTION DESCRIPTION
Transport Select TCP/IP for a TCP socket (stream). Select UDP/IP to
use a UDP socket (connectionless datagram)
Listen for connections on port Use this option to wait for new connections in a specific IP
port, common in Slave Drivers. If this option remains
unselected, the Driver connects to the address and port
specified in the Connect to option
Share listen port with other processes Select this option to share the listen port with other Drivers
and processes
Interface Select the local network interface, identified by its IP
address, that is used by the Driver to establish and receive
connections, or select the (All Interfaces) item to use any
local network interface
Use IPv6 Check this option to force the Driver to use IPv6 addresses
on all Ethernet connections. If this option is unchecked the
Driver will work with IPv4 addresses
Enable 'ECHO' suppression Enable this option to remove the echo from received data.
An echo is a copy of sent data, which can be returned
before a reply message
IP Filter List of restricted or allowed IP addresses from where a
Driver accepts connections (Firewall). Please check the
IO.Ethernet.IPFilter property for more details
PING before connecting Enable this option to execute a ping command, that is,
check whether a device can be reached on a network, for a
device before trying a socket connection. This is a quick way
of determining a successful connection before trying to
OPTION DESCRIPTION
Main IP Type the IP address of the remote device. Users can use an
IP address separated by dots, as well as a URL. In case of
a URL, the Driver uses the available DNS service to map
that URL to an IP address, such as "192.168.0.13" or
"Server1"
Port Type the IP port of the remote device, between 0 (zero)
and 65535
Local port Select this option to use a fixed local IP port when
connecting to a remote device
Backup IP 1, 2, and 3 Indicate here the IP address, the IP port, and the fixed local
IP port of up to 3 (three) backup addresses of a remote
device
General Configurations
This section contains information about the configuration of general I/O Tags and Properties of I/O Interfaces.
I/O Tags
General I/O Interfaces Tags (N2/B2 = 0)
The Tags described next are provided for all supported I/O Interfaces.
This Block returns Driver events generated by several sources in I/O Interfaces. The TimeStamp property of this Block
represents the moment this event occurred. The Block Elements are the following:
· Element 1: Source of event. Possible values are 0: Driver (specific of a Driver), -1: IOKit (generic events of I/O
Interfaces), -2: Serial Interface, -3: Modem Interface, -4: Ethernet Interface, or -5: RAS Interface
NOTE
A Driver keeps a maximum number of 100 events internally. If additional events are reported, older events are
discarded.
IO.PhysicalLayerStatus
This Tag indicates the status of a physical layer. Its possible values are the following:
· 0: Physical layer stopped, that is, the Driver is in Offline mode, the physical layer failed when initializing, or exceeded
the maximum number of reconnection attempts
· 1: Physical layer started but not connected, that is, the Driver is in Online mode but the physical layer is not
connected. If the Connection management option is configured as Automatic, the physical layer can be connecting,
· 2: Physical layer connected, that is, the physical layer is ready for use. This DOES NOT mean the device is connected,
only the access layer is working
IO.SetConfigurationParameters
B2 Parameter 0 (zero)
B3 Parameter 0 (zero)
B4 Parameter 3 (three)
Size Property 2 (two)
ParamItem Property IO.SetConfigurationParameters
Use this Tag to change any property of a Driver's configuration dialog box at run time.
This Tag works only while a Driver is in Offline mode. To start a Driver in Offline mode, select the Start driver OFFLINE
option on the Driver's configuration dialog box. Users can write to a PLC Tag or to a Block Tag containing the parameters
to change. Writing individual Block Elements is not supported, the whole Block must be written at once.
In Elipse SCADA, users must use a Block Tag. Every parameter to configure uses two Block Elements. For example, if users
want to configure three parameters, then the size of the Block must be 6 (3 × 2). The first Element is the property's name,
as a String, and the second Element is the property's value, according to the next example.
// 'Block' must be a Block Tag with automatic reading,
// scan reading, and automatic writing disabled.
// Configure all parameters
Block.element001 = "IO.Type" // Parameter 1
Block.element002 = "Serial"
Block.element003 = "IO.Serial.Port" // Parameter 2
Block.element004 = 1
Block.element005 = "IO.Serial.BaudRate" // Parameter 3
Block.element006 = 19200
// Writes the whole Block
Block.Write()
When using E3, the ability to create arrays at run time allows using an I/O Tag as well as a Block Tag. Users can use
Driver's Write method to send all parameters to the Driver, without creating a Tag, according to the next example.
Dim arr(6)
' Configure all array elements
arr(1) = "IO.Type"
arr(2) = "Serial"
arr(3) = "IO.Serial.Port"
arr(4) = 1
arr(5) = "IO.Serial.BaudRate"
arr(6) = 19200
' There are two methods to send parameters
' Method 1: Using an I/O Tag
tag.WriteEx arr
' Method 2: Without using a Tag
Driver.Write -1, 0, 0, 3, arr
A Driver does not validate parameter names or passed values, therefore be careful when writing parameters and values.
The Write method fails if the configuration array is incorrectly created. Users can check Driver's log or use the writeStatus
parameter of the WriteEx method to find out the exact cause of the error.
Dim arr(10), strError
arr(1) = Array("IO.Type", "Serial")
arr(2) = Array("IO.Serial.Port", 1)
arr(3) = Array("IO.Serial.BaudRate", 19200)
If Not Driver.WriteEx -1, 0, 0, 3, arr, , , strError Then
MsgBox "Failed configuring Driver parameters: " + strError
End If
IO.WorkOnline
This Tag informs the current status of a Driver and allows starting or stopping the physical layer. Possible values are the
following:
· 0 - Driver Offline: Physical layer is closed or stopped. This mode allows a dynamic configuration of a Driver's
parameters using the IO.SetConfigurationParameters Tag
· 1 - Driver Online: Physical layer is open or executing. While in Online mode, the physical layer can be connected or
disconnected and its current status can be checked on the IO.PhysicalLayerStatus Tag
In the next example, using E3, a Driver is configured to Offline mode, its COM port is changed, and then configured to
Online mode again.
'Configure to Offline mode
Driver.Write -1, 0, 0, 4, 0
'Change port to COM2
Driver.Write -1, 0, 0, 3, Array("IO.Serial.Port", 2)
'Configure to Online mode
Driver.Write -1, 0, 0, 4, 1
The Write method can fail when configuring a Driver to Online mode, that is, writing the value 1 (one). In this case, the
Driver remains in Offline mode. The cause of failure can be:
· Type of physical layer incorrectly configured, probably an invalid value was configured in the IO.Type property
· Physical layer probably did not create its working thread. Search the log file for a message "Failed to create physical
layer thread!"
· Physical layer could not start. The cause of failure depends on the type of physical layer. It can be an invalid serial
port number, a failure when starting Windows Sockets, or a failure when starting TAPI (modem), among others. This
cause is recorded on the log file
IMPORTANT
Even if the configuration of a Driver to Online mode is successful, this does not necessarily mean the physical layer is
ready to use, that is, ready to execute input and output operations with an external device. The IO.PhysicalLayerStatus
Tag must be checked to ensure the physical layer is connected and ready for communication.
Properties
These are general properties of all supported I/O Interfaces.
IO.ConnectionMode
Controls the management mode of a Connection. Possible values are 0: Automatic mode, where a Driver manages the
connection or 1: Manual mode, where an application manages the connection.
IO.GiveUpEnable
When configured to True, defines a maximum number of reconnection attempts. If all reconnection attempts fail, the
Driver enters the Offline mode. When configured to False, the Driver tries until a reconnection is successful.
IO.GiveUpTries
Number of reconnection attempts before this one is aborted. For example, if the value of this property is equal to 1
(one), a Driver tries only one reconnection when the reconnection is lost. If this one fails, a Driver enters the Offline mode.
IO.InactivityEnable
Configure to True to enable and to False to disable inactivity detection. The physical layer is disconnected if inactive for
a certain period of time. The physical layer is considered inactive only if it is capable of sending data but not capable of
receiving it back.
IO.InactivityPeriodSec
Number of seconds to check for inactivity. If the physical layer is inactive for this period of time, it is disconnected.
IO.RecoverEnable
Configure to True to enable a Driver to recover lost connections and to False to leave a Driver in Offline mode when a
connection is lost.
IO.RecoverPeriodSec
Delay time between two connection attempts, in seconds.
IO.StartOffline
Configure to True to start a Driver in Offline mode and to False to start a Driver in Online mode.
NOTE
It is pointless to change this property at run time, as it can only be changed when a Driver is already in Offline mode. To
configure a Driver in Online mode at run time, write the value 1 (one) to the IO.WorkOnline Tag.
IO.TimeoutMs
Defines a time-out for the physical layer, in milliseconds. One second is equal to 1000 milliseconds.
IO.Type
Defines the type of physical interface used by a Driver. Possible values are the following:
· N or None: Does not use a physical interface, that is, a Driver must provide a customized interface
· M or Modem: Uses a local modem, internal or external, accessed via TAPI (Telephony Application Programming
Interface)
· R or RAS: Uses a RAS (Remote Access Server) Interface. A Driver connects to a RAS device using the Ethernet Interface
and then sends an AT (dial) command
Statistical Configuration
This section contains information about the configuration of I/O Tags and Properties of I/O Interfaces statistics.
I/O Tags
Tags of I/O Interface statistics (N2/B2 = 0)
The Tags described next display statistics for all I/O Interfaces.
IO.Stats.Partial.BytesRecv
IO.Stats.Partial.BytesSent
N2 Parameter 0 (zero)
N3 Parameter 0 (zero)
N4 Parameter 1100
Configuration by String IO.Stats.Partial.BytesSent
This Tag returns the number of bytes sent through the current connection.
IO.Stats.Partial.TimeConnectedSeconds
This Tag returns the number of seconds a Driver is connected in the current connection or 0 (zero) if a Driver is
disconnected.
IO.Stats.Partial.TimeDisconnectedSeconds
This Tag returns the number of seconds a Driver is disconnected since the last connection ended or 0 (zero) if a Driver is
connected.
This Tag returns the number of bytes received since a Driver was loaded.
IO.Stats.Total.BytesSent
This Tag returns the number of bytes sent since a Driver was loaded.
IO.Stats.Total.ConnectionCount
This Tag returns the number of connections a Driver already established, successfully, since it was loaded.
This Tag returns the number of seconds a Driver remained connected since it was loaded.
IO.Stats.Total.TimeDisconnectedSeconds
This Tag returns the number of seconds a Driver remained disconnected since it was loaded.
Properties
Currently, there are no properties defined specifically to display I/O Interface statistics at run time.
I/O Tags
Tags of an Ethernet Interface (N2/B2 = 4)
The Tags described next allow controlling and identifying an Ethernet Interface at run time and they are also valid when
the RAS Interface is selected.
IMPORTANT
These Tags are available ONLY while a Driver is in Online mode.
Indicates the active IP address. Possible values are 0: The main IP address is selected, 1: The first alternative or backup IP
address is selected, 2: The second alternative or backup IP address is selected, or 3: The third alternative or backup IP
address is selected.
If the Ethernet or RAS Interface is connected, this Tag indicates which one of the four configured IP addresses is in use. If
the Interface is disconnected, this Tag indicates which IP address is used first on the next connection attempt.
During the connection process, if the active IP address is not available, the I/O Interface tries to connect using the next
alternative IP address. If the connection with the alternative IP address works, it is configured as the active IP address
(automatic switchover).
To force a manual switchover, write values from 0 (zero) to 3 (three) to this Tag. This forces a reconnection with the
specified IP address (0: Main IP address or 1, 2, 3: Alternative IP address) if the Driver is currently connected. If the Driver
is disconnected, this Tag configures the active IP address for the next connection attempt.
IO.Ethernet.IPSwitch
Any value written to this Tag forces a manual switchover. If the main IP address is active, then the Driver tries to connect to
each one of the alternative or backup IP addresses and back to the main IP address until a connection is established.
If the Driver is disconnected, this Tag configures the active IP address for the next connection attempt.
Properties
These properties control the configuration of an Ethernet Interface.
IO.Ethernet.AcceptConnection
Configure to False if the Driver must not accept external connections, that is the Driver behaves as a master, or
configure to True to enable the reception of connections, that is, the Driver behaves as a slave.
IO.Ethernet.BackupEnable[2,3]
Configure to True to enable an alternative or backup IP address. If the reconnection attempt with the main IP address
fails, the Driver tries to use an alternative IP address. Configure to False to disable its usage.
IO.Ethernet.BackupLocalPort[2,3]
Local port number to be used when connecting to an alternative IP address of a remote device. Used only if
IO.Ethernet.BackupLocalPortEnable is equal to True.
IO.Ethernet.BackupLocalPortEnable[2,3]
Configure to True to force the use of a specific local port when connecting to an alternative or backup IP address of a
remote device or configure to False to use any available local port.
IO.Ethernet.BackupIP[2,3]
Alternative or backup IP address of a remote device. Users can use a numerical address, as well as a device's host
name, such as "192.168.0.7" or "SERVER2".
IO.Ethernet.BackupPort[2,3]
Port number of an alternative or backup IP address of a remote device, used with the IO.Ethernet.BackupIP property.
IO.Ethernet.IPFilter
List with a comma-separated IPv4 or IPv6 addresses, which defines from which addresses a Driver accepts or blocks
connections. Users can use asterisks, such as "192.168.*.*", or intervals, such as "192.168.0.41-50", in any part of IP
addresses. To block an IP address or a range of IP addresses, use the tilde ("~") character at the beginning of the
address. Examples:
· 192.168.0.10, 192.168.0.15, 192.168.0.20: Accepts connections from IPv4 addresses 192.168.0.10, 192.168.0.15, and
192.168.0.20
· ~192.168.0.95, 192.168.0.*: Accepts connections from IPv4 addresses from 192.168.0.0 to 192.168.0.255, except the
IPv4 address 192.168.0.95
· If the last element on the list is an authorization, such as "192.168.0.24", then all IP addresses not found on the list are
blocked
· If the last element on the list is a block, such as "~192.168.0.24", then all IP addresses not found on the list are
authorized
If an IP address appears on more than one filter on the list, the leftmost filter has precedence. For example, in case of
"~192.168.0.95, 192.168.0.*", the IP address 192.168.0.95 fits both rules, but the rule that wins is the leftmost one,
"~192.168.0.95", and therefore this IP address is blocked.
When IOKit blocks a connection, it logs a message "Blocked incoming socket connection from {IP}!".
In case of UDP connections in broadcast listen mode, where a Driver can receive packets from different IP addresses,
blocks or permissions are performed at each packet received. If a packet is received from a blocked IP address, it logs a
message "Blocked incoming packet from {IP} (discarding {N} bytes)!".
IO.Ethernet.ListenIP
IP address of the local network interface that a Driver uses to establish and receive connections. Leave this property
empty to use any local network interface.
IO.Ethernet.ListenPort
Number of the IP port used by a Driver to listen to connections.
IO.Ethernet.MainIP
IP address of a remote device. Users can use a numerical address, as well as a device's host name, such as
"192.168.0.7" or "SERVER2".
IO.Ethernet.MainLocalPort
Local port number to use when connecting to the main IP address of a remote device. This value is only used if the
IO.Ethernet.MainLocalPortEnable property is equal to True.
IO.Ethernet.MainLocalPortEnable
Configure to True to force the use of a specific local port when connecting to the main IP address of a remote device or
configure to False to use any available local port.
IO.Ethernet.MainPort
Number of the IP port of a remote device, used with the IO.Ethernet.MainIP property.
IO.Ethernet.PingEnable
Configure to True to enable sending a ping command to the IP address of a remote device, before trying to connect to
the socket. This socket's connection time-out cannot be controlled, therefore sending a ping command before connecting
is a fast way to detect if the connection is going to fail. Configure to False to disable a ping command.
IO.Ethernet.PingTries
Maximum number of attempts of a ping command. Minimum value is 1 (one), including the first ping command.
IO.Ethernet.ShareListenPort
Configure to True to share a listening port with other Drivers and processes or False to open a listening port in
exclusive mode. To successfully share a listening port, all Drivers and processes that use that port must open it in shared
mode. When a listening port is shared, each incoming connection is distributed to one of the processes listening. This
way, if a Slave Driver only supports one connection at a time, users can use several instances of this Driver listening on the
same port, therefore simulating a Driver with support for multiple connections.
IO.Ethernet.SupressEcho
Configure to True to eliminate echoes in communication. An echo is the unwanted reception of an exact copy of all data
packets a Driver sends to a device.
IO.Ethernet.Transport
Defines a transport protocol. Possible values are T or TCP: Uses the TCP/IP protocol or U or UDP: Uses the UDP/IP
protocol.
IO.Ethernet.UseIPv6
Configure to True to use IPv6 addresses on all Ethernet connections or configure to False to use IPv4 addresses
(default).
Revision History
VERSÃO DATA AUTOR COMMENTS
3.0.17 21/12/2020 M. Salvador · Adicionado a suporte a
gateway
· Arquivos de horario do
último comtrade
3.0.9 11/12/2019 M. Salvador · PRP Support
www.elipse.com.br
kb.elipse.com.br
forum.elipse.com.br
www.youtube.com/elipsesoftware
[email protected]