ISaGRAF Target 5 Technical Reference
ISaGRAF Target 5 Technical Reference
Technical Reference
2 SCADAPack E Target 5 Technical Reference
Table of Contents
3
4 SCADAPack E Target 5 Technical Reference
1 Technical Support
Support related to any part of this documentation can be directed to one of the following
support centers.
2 Safety Information
Read these instructions carefully, and look at the equipment to become familiar with the
device before trying to install, operate, or maintain it. The following special messages may
appear throughout this documentation or on the equipment to warn of potential hazards or to
call attention to information that clarifies or simplifies a procedure.
DANGER
DANGER indicates an imminently hazardous situation which, if not avoided, will
result in death or serious injury.
6 SCADAPack E Target 5 Technical Reference
WARNING
WARNING indicates a potentially hazardous situation which, if not avoided, can
result in death or serious injury.
CAUTION
CAUTION indicates a potentially hazardous situation which, if not avoided, can
result in minor or moderate injury.
CAUTION
CAUTION used without the safety alert symbol, indicates a potentially hazardous
situation which, if not avoided, can result in equipment damage..
PLEASE NOTE
Electrical equipment should be installed, operated, serviced, and maintained only by qualified
personnel. No responsibility is assumed by Schneider Electric for any consequences arising
out of the use of this material.
A qualified person is one who has skills and knowledge related to the construction and
operation of electrical equipment and the installation, and has received safety training to
recognize and avoid the hazards involved.
WARNING
UNINTENDED EQUIPMENT OPERATION
Do not control safety-critical systems with SCADAPack Workbench and
SCADAPack E Smart RTU.
Failure to follow these instructions can result in death, serious injury or
equipment damage.
Do not use this product on machinery lacking effective point-of-operation guarding. Lack of
effective point-of-operation guarding on a machine can result in serious injury to the operator
SCADAPack E Target 5 Technical Reference 7
of that machine.
CAUTION
EQUIPMENT OPERATION HAZARD
Verify that all installation and set up procedures have been completed.
Before operational tests are performed, remove all blocks or other temporary
holding means used for shipment from all component devices.
Remove tools, meters, and debris from equipment.
Follow all start-up tests recommended in the equipment documentation. Store all equipment
documentation for future references.
Software testing must be done in both simulated and real environments.
Verify that the completed system is free from all short circuits and grounds, except those
grounds installed according to local regulations (according to the National Electrical Code in
the U.S.A, for instance). If high-potential voltage testing is necessary, follow
recommendations in equipment documentation to prevent accidental equipment damage.
Before energizing equipment:
Remove tools, meters, and debris from equipment.
Close the equipment enclosure door.
Remove ground from incoming power lines.
Perform all start-up tests recommended by the manufacturer.
3 Preface
Purpose
The purpose of this document is to describe in detail the interface between the SCADAPack E Smart
RTU and the SCADAPack Workbench software.
It is assumed that the reader is familiar with the SCADAPack Workbench software. For more
information about the Workbench program environment, see the Workbench Help documentation.
Additional programming options specific to the SCADAPack E Smart RTU can be found in the
SCADAPack E Target 5 Function Blocks Reference manual.
The Workbench Help documentation is not dedicated to any particular target and describes general
concepts. The material covered in this manual together with the SCADAPack E Target 5 Function
Blocks Reference manual therefore supplements the Workbench Help manuals for it deals exclusively
with the implementation of the IEC 61131-3 Target software on a Schneider Electric SCADAPack E
Smart RTU.
Assumed Knowledge
Familiarity with the SCADAPack Workbench is strongly recommended.
Target Audience
Systems Engineers
Commissioning Engineers
Maintenance Technicians
References
Workbench Help
SCADAPack E Target 5 Help
ISaGRAF provides IEC61131-3 international standard PLC programming capability to the SCADAPack E
Smart RTU.
The IEC 61131-3 target Virtual Machines (VM's) execute on the SCADAPack E Smart RTU and are built
in to the operating system firmware.
transferring and debugging through connection to the target by serial or network communications.
The SCADAPack E Smart RTU provides two IEC 61131-3 target types, Target 3 and Target 5. This
document covers Target 5 and SCADAPack Workbench.
Highlights
By way of summary, the following facilities are notable Workbench facilities, or are provided in addition
to the standard Workbench facilities when used on SCADAPack E Smart RTU:
Load applications to RTU via SCADAPack Workbench, via File Transfer, remotely via DNP3, remotely
via IEC60870-5-101 & -104 protocol
Remote debugging of IEC 61131-3 applications via serial or TCP/IP connections
Dual IEC 61131-3 target Virtual Machines (VM's) for executing 2 separate application resources
simultaneously
Download IEC 61131-3 application project source to the RTU, for later upload
Permits Online Changes to running application resources
Scan control prioritization for improved performance or high accuracy scan intervals
Interaction between IEC 61131-3 applications and RTU operating system facilities
Interaction between IEC 61131-3 applications and RTU point database attributes
IEC 61131-3 application interaction with RTU database floating point numeric and string data types
IEC 61131-3 application application control over data exchange with peer RTU nodes
IEC 61131-3 application control over trend sampling
IEC 61131-3 application file management
IEC 61131-3 application custom communication protocol management
IEC 61131-3 application interface to common PLC and peripheral device protocols
Terminology
The SCADAPack E Smart RTU provides two IEC 61131-3 target types, called Target 3 and Target 5.
Target 3 is used with 16-bit ISaGRAF Workbench (not covered by this document) and Target 5 with
SCADAPack Workbench (covered by this document).
A IEC 61131-3 application is called a Solution in Workbench.
A Solution for a IEC 61131-3 application contains a Project.
A Project contains a Device, which a SCADAPack E Smart RTU. The example above shows a
SCADAPack 300E RTU.
A Device can contain one or two Resources. Resources are independent parts of the application.
Resources can be stopped, downloaded, uploaded, and started independently. A Resource contains IEC
61131-3 programs (also called Program Organization Units or POU), I/O devices, functions, function
blocks, and variables. Resources can exchange information through variable binding. These are
explained in the sections that follow.
10 SCADAPack E Target 5 Technical Reference
This solution structure is used for SCADAPack Workbench applications. Although it's possible to
structure the solution in other ways, they are not supported by the SCADAPack E Smart RTU.
The two Resources are independent, but can exchange data through variable binding.
The type of connection used by the Workbench is a function of the project configuration. The
SCADAPack Workbench software offers pre-configured Proj ect Templates 12 for either Serial or TCP/IP
connections.
Only one active connection is used to communicate with either running VM.
The Target Remote Access 80 section describes the various connection options that are available
between the SCADAPack Workbench and SCADAPack E RTU's.
The hierarchy of a SCADAPack Workbench IEC61131-3 Solution is shown in the diagram below.
SCADAPack E Target 5 Technical Reference 11
The SCADAPack E RTU firmware supports the simultaneous execution of up to two IEC 61131-3 target
VM's (Virtual Machines) on the same RTU. This allows up to two independent applications resources to
execute simultaneously on the same RTU. The two IEC 61131-3 targets within the RTU have a fixed
Workbench Resource Number of 1 and 2 respectively. Both IEC 61131-3 target VM's are activated by
default, i.e. there is no additional configuration required to activate the second VM.
The status (running or halted) of an IEC 61131-3 resource on each VM can be obtained from the
SCADAPack E Configurator 12 software or via separate Application Halted system binary points
50100 and 50101. These binary points are part of the system points dedicated to providing the status of
the RTU. For more information see the SCADAPack E Operational Reference Manual.
The SCADAPack E target device type is selected from one of several project templates selected from
the Workbench New Proj ect window. There are currently two templates for SCADAPack 300E models
and two for SCADAPack ES/ER models, depending on the the default method of communication
between the SCADAPack Workbench and the IEC 61131-3 target on the RTU.
SCADAPack E Target 5 Technical Reference 13
For an existing project, the current target type can be found by opening the Properties window on the
project Device in the Solution Explorer window.
The Workbench Resource Embedded Symbol Table property is not required to be enabled for the
SCADAPack E RTU.
The Device Properties window allows the Target to be changed to SIMULATOR. Do not change the
target setting. Rather, select Simulator from the debugging toolbar to run the solution on a simulator.
The SIMULATOR target type is present only to allow the Simulator to function, and should not be
selected from the Properties window.
14 SCADAPack E Target 5 Technical Reference
Each Workbench Resource has automatically-defined System variables that hold the values relating to
cycle count, timing, kernel bindings, and resource information. You can view System variables from the
Global Variables dictionary instance for each resource. For example, __SYSVA_TCYCURRENT is a
global TIME variable which holds the value of the current cycle time. These values are normally read with
the Workbench debugger running and connected to the target. However, the variables can be also be
used within an application program.
SCADAPack E Target 5 Technical Reference 15
The IEC 61131-3 target executing on an SCADAPack E RTU can be configured to scan in various ways:
Real Time Scanning 16
This mode can be temporarily overridden from within the SCADAPack Workbench debugger. The
debugger can be used to change to Cycle Time Scanning 18 by writing a new value to the
__SYSVA_TCYCYCTIME 18 resource global TIME variable.
WARNING
UNINTENDED EQUIPMENT OPERATION
Evaluate the operational state of the equipment monitored and controlled
by the RTU before debugging. Hazardous situations can occur if system
state is not confirmed prior to debugging.
Failure to follow these instructions can result in death, serious injury or
equipment damage.
If the IEC 61131-3 application or the SCADAPack E RTU is restarted, a temporary cycle timing setting
is lost. The cycle time will revert to the Resource properties’ Execution Mode and Cycle Time settings.
SCADAPack E Target 5 Technical Reference 17
It is recommended that, where possible, IEC 61131-3 applications use continuous scanning mode and
be designed to take into account variations in the timing of the scan rate.
18 SCADAPack E Target 5 Technical Reference
The Workbench Debugger will increment the __SYSVA_TCYOVERFLOW System variable value if the
time taken to perform an individual scan is higher than the fixed (allowed) time. In this case the fixed
Cycle Time should be increased.
The following sections describe methods for permanently or temporarily setting Cycle Timing scanning
for an IEC 61131-3 resource. This mode can also be changed from within a user application.
SCADAPack E Target 5 Technical Reference 19
To change the IEC 61131-3 scanning mode from cycle timing back to Continuous scanning, set the
Trigger Cycles property to False, rebuild and download the application resource.
20 SCADAPack E Target 5 Technical Reference
WARNING
UNINTENDED EQUIPMENT OPERATION
Evaluate the operational state of the equipment monitored and controlled
by the RTU before downloading. Hazardous situations can occur if
system state is not confirmed prior to downloading.
Failure to follow these instructions can result in death, serious injury or
equipment damage.
WARNING
UNINTENDED EQUIPMENT OPERATION
Evaluate the operational state of the equipment monitored and controlled
by the RTU before debugging. Hazardous situations can occur if system
state is not confirmed prior to debugging.
Failure to follow these instructions can result in death, serious injury or
equipment damage.
The cycle time can also be set by in the debugger by writing to the __SYSVA_TCYCYCTIME 18
Resource Global Variable. The value entered uses the format of a TIME expression, e.g. T#200ms.
Information on the Time Data type is available in the Workbench Help documentation.
To change the application scanning mode from cycle timing back to continuous scanning, set the Cycle
Timing (ms) entry field back to zero or the __SYSVA_TCYCYCTIME variable value to "T#0s".
If the IEC 61131-3 application or the SCADAPack E RTU is restarted, a temporary cycle timing setting
is lost. The cycle time will revert to the Resource properties’ Execution Mode and Cycle Time settings.
SCADAPack E Target 5 Technical Reference 21
High priority scanning sets the target VM task to run at a higher priority than routine RTU operating
system tasks. This is useful where highly accurate execution rates are required.
An IEC 61131-3 VM task executing with standard priority and Cycle Time Scanning will still achieve
relatively accurate execution timing, suitable for typical applications. Schneider Electric recommends
that High Priority Scanning only be used where absolutely necessary for the application as it can
adversely affect the RTU's capacity to perform other tasks.
If multiple IEC 61131-3 resources are executing on the same RTU, it is not recommended for more
than one of the Resources to operate in high priority scanning mode.
Where high priority scanning is required, it is suggested that user IEC 61131-3 applications be split into
a high priority and low priority component. This is to minimize the amount of application code that runs
at high priority and the otherwise resultant impact on other RTU operations, such as communication.
Two IEC 61131-3 target resources could be used to separately execute the low and high priority
components. One of the resources could then use the RTUPARAM function block to increase its
priority.
For more information on the RTUPARAM function block see the SCADAPack E Target 5 Function Block
Reference manual.
22 SCADAPack E Target 5 Technical Reference
Output Updates 24
Language Types 25
Data Types 26
Operators 28
I/O Locking 29
Retained Variables 32
Array Variables 34
Analog Inputs
The update of analog input values to an IEC 61131-3 application is similar to binary inputs. The updates
are synchronized with the scanning of the IEC 61131-3 application. The SCADAPack E RTU's database
supports 16-bit Signed Integer, 32-bit Signed Integer as well as 32-bit Floating-Point data points. Analog
variables in Workbench are represented as 16-bit Signed IEC INT, 32-bit Signed IEC DINT or 32-bit
Floating Point IEC REAL within the application resource. The RTU supports data conversion between
the 16-bit and 32-bit analog data types.
24 SCADAPack E Target 5 Technical Reference
Analog Outputs
The analog output data is updated at the end of a Resource scan similar to Binary Outputs. The RTU
supports 16-bit Signed Integer, 32-bit Signed Integer and Floating Point data objects. Analog variables
are represented as16-bit Signed IEC INT, 32-bit Signed IEC DINT or 32-bit Floating Point IEC REAL
within the Workbench environment. The RTU also supports data conversion between the 16-bit and 32-
bit analog data types.
By default an executing IEC 61131-3 application, with analog points on Output I/O Devices, has control
of those Physical RTU Analog Outputs and Derived RTU points, unless a “Remote Interlock” is active for
individual analog points. See Remote Control Interlock 64 for more information.
See Stopping an IEC 61131-3 Application 52 for a description of the effect on Analog Outputs when
the application resource is stopped.
SCADAPack E Target 5 Technical Reference 25
INT Signed, short integer GETPNTSS, Analog point, 16-bit Integer value (RAW
(16-bit) SETPNTSS function
blocks
DINT Signed, long integer RTU_RAW_ I/O Analog point, 32-bit Integer value (RAW
(32-bit) Devices, GETPNTSL,
SETPNTSL function
blocks
UINT Unsigned, short GETPNTUS, Analog point, 16-bit Integer value (RAW
integer (16-bit) SETPNTUS function )
blocks
REAL Floating point 32-bit RTU_ENG_ I/O Analog point, 32-bit floating point
IEEE-754 devices, GETPNTF, Engineering value (ENG)
SETPNTF function
blocks
The target on the SCADAPack E RTU supports elementary IEC 61131-3 data types, with the exception
of the SAFEBOOL type. See the Workbench Help documentation for more information on the IEC
61131-3 data types.
SCADAPack E Target 5 Technical Reference 27
Workbench has a wide range of built-in Data Conversion operators such as ANY_TO_DINT,
ANY_TO_TIME, etc.
IEC 61131-3 integer variables can correspond to RTU analog point Integer (RAW) values when connected
through I/O Devices or function blocks. REAL IEC61131-3 variables correspond to RTU analog point
Engineering (ENG) values when connected through I/O Devices or Function Blocks.
IEC 61131-3 Integer constant data types, such as DINT, INT, UDINT, etc. may be expressed with one of
the following Bases. Integer constants begin with a Prefix that identifies the Bases used:
The underscore character ('_') may be used to separate groups of digits. It has no particular significance
other than to improve literal expression readability.
28 SCADAPack E Target 5 Technical Reference
6.5 Operators
SCADAPack Workbench application software supports a comprehensive array of built-in operators
including functions for:
maths ABS, ACOS, ASIN, ATAN, COS, EXPT, LOG, POW, SIN,
SQRT, TAN, TRUNC
string management ASCII, DELETE, FIND, INSERT, LEFT, MID, MLEN, REPLACE,
RIGHT
See the Workbench Help documentation sections on Operators, Functions & Function Blocks for more
information.
SCADAPack E Target 5 Technical Reference 29
WARNING
UNEXPECTED EQUIPMENT OPERATION
Evaluate the operational state of the equipment monitored and controlled by the
SCADAPack E RTU prior to initializing the SCADAPack E RTU.
SCADAPack 300E RTU's "FORCE" LED indicates that an application resource has at least one I/O
variable in a LOCK state. When no variables remain locked, the FORCE LED will turn off.
I/O variables on the target can be locked and unlocked individually through the SCADAPack Workbench
when connected online with the Workbench debugger to the SCADAPack E RTU's target resource. This
can be done through the resource's Dictionary dialog (shown below) or from the I/O Device Window.
When an I/O variable is locked, the Workbench indicates the Logical Value used by the IEC 61131-3
Resource and the Physical Value associated with the I/O Device connection.
For an input variable (Direction VarInput), the Logical Value field can be modified to override the
variable value used by the Resource. The Physical Value indicates the actual value coming from the I/
O Device even though it is not being used by the Resource.
For an output variable (Direction VarOutput), the Physical Value can be modified to override the value
output to the I/O Device. The Logical Value indicates the variable value coming from the Resource
even though it is not being sent to the I/O Device.
Clear the Lock indication to release the override on the variable. The Physical Value and Logical Value
should return to indicate the same value.
The Workbench debugger also provides another mechanism to view or unlock locked variables. When in
30 SCADAPack E Target 5 Technical Reference
Debug mode, use the Lock Variables Viewer (shown below). This can be activated from the menu
Debug > Locked Variables Viewer or from the lock icon on the Target Execution Toolbar.
WARNING
Online firmware update will NOT preserve the RTU operational state prior
to the upgrade, including output states, application state information, I/O
Lock states, etc.
Consider the impact on operating equipment when upgrading firmware.
The diagram below shows how inputs and outputs are isolated from the IEC 61131-3 variable database
and Workbench debugger when locked.
SCADAPack E Target 5 Technical Reference 31
It is recommended that the user perform their own bounds checking on the message value if it is
required to handle numbers above 2^31. For example, use ANY_TO_LINT and then check the value.
32 SCADAPack E Target 5 Technical Reference
BOOL 1 byte
TIME 4 bytes
The amount of memory allocated to each variable type is automatically allocated by the SCADAPack E
RTU depending on the application requirements and the number of active applications in the RTU. The
SCADAPack Workbench resource Memory For Retain property is not required for the SCADAPack E to
use retained variables. Non-volatile memory storage for retained variables is allocated at a fixed memory
segment within the RTU. The total retained memory space requirements of a resource needs to be less
than 4KB or a Resource startup status code will be set (Code 4004).
The Memory Usage (Retain Space) property of each resource shows the memory (in bytes) requirement
for the application.
SCADAPack E Target 5 Technical Reference 33
The SCADAPack E RTU clears retained variable values when an IEC 61131-3 application or RTU NV-
RAM is cleared.
E.g. when a Cold Boot factory-defaults initialization occurs, if RTU firmware is changed through a local,
manual firmware upgrade, or when using the command line "CLEAR ISaGRAF" command.
The SCADAPack E IEC 61131-3 targets in the RTU automatically clear retained variables for the
appropriate target kernel task when a new IEC 61131-3 application is loaded.
34 SCADAPack E Target 5 Technical Reference
Array names can have up to 128 characters and can begin with letters or single underscores followed by
letters, digits, and single underscores. Array variables are declared in a Resource’s Global Variables
window or in a Program’s Local Variables window.
Examples:
1. One-dimensional array:
FOR i := 1 TO 10 DO
END_FOR;
2. Two-dimensional array:
FOR I := 1 TO 10 DO
FOR J := 1 TO 3 DO
END_FOR;
SCADAPack E Target 5 Technical Reference 35
END_FOR;
CAUTION
Like many other Programming Languages, access of an IEC 61131-3 array
variable in a program using an index number beyond the configured
dimension can lead to serious unpredictable results including overwriting of
data, reset of the RTU, etc.
The Resource Compiler Options property, Check Array Index can be enabled to check the bounds on
array accesses at run-time (see below). If an out-of-bounds access is found, System Error 4033, "Kernel
TIC: Boundary check error" is set and the offending Resource is stopped.
CAUTION
Enabling the Check Array Index Compiler Option should not be relied upon
to detect all array access errors. If enabled, this option is likely to have a
performance impact on the application's cycle time.
Once an array is defined in a resource's Local or Global Variables Window, the IEC notation ArrayName
[ index ] may be used in any program or I/O Device connection.
The Retained property applies to the whole array. It's not possible to retain just individual elements.
Dynamic Arrays
The SCADAPack Workbench allows up to 16 arrays of DINT values to be created dynamically (per-
resource) using the ARCREATE Function. This feature may be useful in user functions where the
bounds of an array is determined by a parameter where the value is not known at compile time.
The dynamic array is created with a single call to the ARCREATE function, passing in an array ID value
between 0 and 15. This ID value is used in subsequent calls to the ARREAD (read from array) and
ARWRITE (write to array).
Dynamic arrays are cleared when the application resource is stopped or the RTU is restarted. The array
element values cannot be retained in dynamic arrays.
See the SCADAPack E Target 5 Function Blocks Reference manual for further details.
SCADAPack E Target 5 Technical Reference 37
SCADAPack Workbench also supports the concept of custom Array Data Types. The user can create
their own named array type and then add variables of this type in the Resource's Global Variables or
Program's Local Variables window.
Array Data Types are declared in the Resource's Lib\DataTypes Window as shown below.
In order to use a custom Data Type, add variables of that type using the Resource Global Variables
window or Program Local Variables window.
Example 1:
The user creates an Array Data Type called MyArrayType, which is an array of 10 BOOL. Its dimension
is defined as follows: [1..10].
38 SCADAPack E Target 5 Technical Reference
In the Resource's Local Variables dictionary, the array MyVar is created, which is of type MyArrayType.
The MyVar array can then be used as a normal array in a program as follows:
Ok := MyVar [4];
In this example, the MyVar variable is an instance of the MyArrayType Data Type.
Example 2:
In the Resource's Local Variables dictionary, the array MyVar2 is created, which is an array of type
MyArrayType (as per the previous example). This effectively creates a two-dimension array, which could
be initialized as follows:
FOR I := 1 TO 3 DO
FOR J := 1 TO 10 DO
END_FOR;
END_FOR;
Structure Data Types are declared in the Resource's Lib\DataTypes Window as shown below.
SCADAPack E Target 5 Technical Reference 39
In order to use a Structured Data Type, add variables of that type using the Resource Global Variables
window or Program Local Variables window.
Example:
In the Data Types Structure tab, the user creates MyStruct1, which is composed as follows:
In the Resource's Local Variables dictionary, the array MyVar is created, which is of type MyStruct2. The
following Structured Text example shows how the MyVar variable could be used in an IEC 61131-3
program:
Structure fields can be initialized individually in the Workbench Dictionary. Or, write initial values in a
startup program.
The Retained property applies to the whole structure. It's not possible to retain just individual fields.
Functions and Function Blocks cannot have parameters of structure type, but can have an element of
the exact field, if it's an elementary IEC 61131-3 type ( e.g. using 'dot' notation MyVar.Field1 ).
The SCADAPack Workbench Resource Numbers are configured as “1” and “2” to represent the RTU’s
first and second target resources, respectively.
SCADAPack E Target 5 Technical Reference 41
When such an equivalence is defined, its identifier is available anywhere in an ST program to replace the
attached expression. The following ST programming example uses defined words:
If OK Then
angle := PI / 2.0;
isdone := YES;
End_if;
When the same identifier is defined twice with different ST equivalencies, the last defined expression is
used:
Define:
OPEN is FALSE
OPEN is TRUE
means:
OPEN is TRUE
Names of defined words can have up to 32 characters and begin with a letter followed by letters, digits,
and single underscore characters. The last character can be either a letter or a digit.
The definition of a defined word is expressed using variables or literals; these cannot use defined words
or expressions.
Defined Words are declared in the SCADAPack Workbench Resource's Lib\DataTypes Window as
shown below.
42 SCADAPack E Target 5 Technical Reference
The 'greyed-out' Defined Words shown in the above diagram are target-specific. They are defined by the
SCADAPack Workbench and can't be removed. However, user-specific Defined Words can be added to
the list.
The list of Defined Words can be alphabetically and numerically sorted with the grid column headers.
SCADAPack E Target 5 Technical Reference 43
7 Application Management
The following sections describes facilities provided by SCADAPack Workbench for application
management
On-line Changes 44
Application Storage 47
WARNING
Online changes should be used with care. The IEC 61131-3 target may not detect
all possible conflicts generated by user-defined operations as a result of these
online changes.
An Online Change does not restart the resource. Variable values are preserved. When performing online
changes you cannot modify application parameters, add or remove I/O Devices, modify I/O Device
connections or modify I/O Device parameters.
The following application modifications are permitted when performing Online Changes:
Internal When renaming or changing the data type of internal variables, the Workbench
Variables creates new variables. Therefore, variables are initialized.
Adding and removing elements in arrays for internal variables. For multi-dimensional
arrays, you can only add elements to the first dimension. The Workbench initializes
these new elements. Adding elements to other dimensions causes the Workbench to
initialize a new array.
Programs Adding, deleting, renaming, and reordering (for execution within the programs section)
programs. When renaming programs, the Workbench detects a CRC mismatch and
updates the code on the target for the program and reinitialize's local variables. When
renaming SFC programs, instance data and local variables are not preserved, i.e,
elements are reset to their initial state.
When planning to add programs (other than SFC) using online changes, you need to
allocate a sufficient number of maximum extra POUs.
When planning to add SFC programs using online changes, you need to allocate
sufficient memory space for SFC programs.
Adding, deleting, renaming steps and transitions as well as modifying the initial step or
the flow between elements. When modifying SFC programs, instance data and local
variables is preserved, i.e., elements are not reset to their initial state.
Adding, deleting, and moving action blocks within steps of SFC programs. Action
blocks within steps are executed in the order of appearance. You can also change the
qualifier of an action block.
Functions and Adding, deleting, and moving function blocks. Adding and deleting function block
Function Blocks instances.
Renaming and modifying user-defined functions and function blocks.
SCADAPack E Target 5 Technical Reference 45
Adding, removing, and modifying the parameters of user-defined functions and function
blocks. When modifying the parameters, instance data is not preserved. You need to
recompile modified functions and function blocks called by other POUs as well as the
calling POUs.
I/O Devices New I/O variables may be created and attached to an existing I/O Device.
Existing I/O variables may be moved from channel to channel on the same I/O Device.
Existing I/O variables may be moved from one I/O Device to another.
Parameters may be modified on an existing I/O Device except for the following:
Parameters cannot be swapped between I/O devices. This is because the validation
checks are done one device at a time; the first device to be checked will detect a
duplicate and refuse the change (because the other device hasn't been changed
yet).
The 'Port' parameter cannot be changed online unless it's a TCP port number.
If an I/O output device has channels connected to local physical outputs and the
‘First_Point_Number’ parameter is changed online, the device will follow the state of
the 'Hold_On_Stop' parameter (if applicable). If the 'Hold_On_Stop' parameter is False
(default), the I/O device will zero the current value or state of any points that have been
disconnected from output channels as a result of the online change. See the Hold On
Stop 64 section.
The following actions require a full application download:
Adding a new I/O Device
Removing an existing I/O Device
Modifying the number of channels on an existing I/O Device
WARNING
UNCONTROLLED OUTPUT VARIABLES
Online changes to output I/O devices should be done with care. If output variables
are moved between channels or devices, the vacated channels will remain in their
previous state or value, unless replaced with another variable.
Failure to follow these instructions can result in death, serious injury or
equipment damage.
You can perform online changes after building a project. Online changes are unavailable after cleaning a
project.
Modifying a running application with the Online Change feature consists of the following operations:
Modify the application source code in the Workbench
Build the current application program
Download the new application using the Online Change command. From the Workbench Solution
Explorer, right-click the project for which to perform the Online Change, then choose Online Change or
46 SCADAPack E Target 5 Technical Reference
WARNING
UNINTENDED EQUIPMENT OPERATION
Evaluate the operational state of the equipment monitored and controlled by the
RTU before downloading. Hazardous situations can occur if system state is not
confirmed prior to downloading.
The user will be informed if the change cannot be made online, and the change will not proceed.
SCADAPack E Target 5 Technical Reference 47
The application upload facility is supported through the following SCADAPack E IEC 61131-3 interfaces:
via an RTU serial port configured as ISaGRAF
via Ethernet when RTU has ISaGRAF/TCP service enabled (see SCADAPack E Configurator TCP/IP
page)
IEC 61131-3 project Upload facilities are not supported via DNP3 communications using SCADAPack E
Configurator.
The user can choose to embed source for just the selected Resource or for the whole Proj ect (i.e. both
project resources).
When the application is next built by the Workbench and downloaded to the RTU, it will store the project
on the RTU for later retrieval by Uploading 49 .
In the Workbench Solution Explorer window, right click the desired resource to upload. It shows the
dialog in the following figure:
Select Upload and wait while the data is uploaded from the target. When this is complete, an Import
dialog will be shown as follows:
50 SCADAPack E Target 5 Technical Reference
8 I/O Interfaces
The diagram below shows the relationship between the IEC 61131-3 application and other elements that
it interacts with in the SCADAPack E RTU firmware. The IEC 61131-3 application connects to the RTU
point database via I/O Devices and Function Blocks. In turn, the point database segregates the I/O
(physical & derived), the protocol drivers and the IEC 61131-3 application.
SCADAPack Workbench provides several interfaces for associating RTU data with IEC 61131-3
variables. The following sections describe the methods that can be used.
Physical I/O 52
Derived Data 54
SCADAPack E RTU_xxx_WRITE I/O devices export data from a IEC 61131-3 Resource to the RTU
database. This data is then available to the SCADA master system or other peer RTUs. Similarly,
RTU_xxx_READ I/O devices used for derived points import data from the RTU database into a IEC
61131-3 Resource. Control data from a SCADA master, or peer RTU for example is then available to
the IEC 61131-3 Resource.
IEC 61131-3 Resource derived outputs = SCADA master inputs, Peer RTU input data
IEC 61131-3 Resource derived inputs = SCADA master outputs, Peer RTU output data
IEC 61131-3 input variables attached to RTU derived database point (via I/O Device channels) may be
initialized to a predefined state via the appropriate SETPNTxx Function Block. The figure below shows
an example of the Workbench I/O Device interface, with inputs attached to the currently selected device
(RTU_RAW_READ) displayed on the right.
RTU_BIN_WRITE BOOL 100 Physical Output, Derived & System Binary Objects
VarOutput
variables
RTU_BIN_READ_OUT BOOL 100 Physical Output, Derived & System Binary Objects
PUT VarInput with Status
variables
RTU_ENG_READ REAL 100 Physical Input & Derived Floating Point Objects
VarInput
variables
RTU_ENG_WRITE REAL 100 Physical Output &, Derived Floating Point Objects
VarOutput
variables
RTU_RAW_READ_O DINT 100 Physical Output &, Derived Integer Object with Status
UTPUT VarInput
variables
RTU_ENG_READ_OU REAL 100 Physical Output &, Derived Floating Point Object with
TPUT VarInput Status
variables
56 SCADAPack E Target 5 Technical Reference
These I/O devices are only supported on SCADAPack ER RTUs. Resources referencing these I/O
Devices will not start on RTUs other than SCADAPack ER RTU. These I/O Devices are only available in
the Workbench I/O Device Selector window if a SCADAPack ES/ER Template 12 was chosen for the
project.
ER_BIN_IN BOOL 32
VarInput variables
ER_BIN_OUT BOOL 16
VarOutput variables
ER_ENG_IN REAL 16
VarInput variables
ER_ENG_OUT REAL 4
60 SCADAPack E Target 5 Technical Reference
VarOutput variables
ER_RAW_IN DINT 16
VarInput variables
ER_RAW_OUT DINT 4
VarOutput variables
The SCADAPack ER I/O Devices reference the respective physical I/O cards by specifying a
Slot_Number field. The Slot_Number field is set via user configuration through the I/O device parameters.
These are set in the Workbench Resource's I/O Device window.
The required fields are described as follows:
A valid I/O card configuration needs to be loaded into the SCADAPack ER RTU prior to loading an IEC
61131-3 application that references SCADAPack ER I/O devices, otherwise the I/O device will not be
opened and the IEC 61131-3 application WILL NOT START. This is done using SCADAPack E
Configurator by assigning an I/O card and writing the Configurator file changes onto the RTU. A RTU
restart is required after these configuration details have been written to the RTU. See SCADAPack E
Configurator User Manual for details.
SCADAPack E Target 5 Technical Reference 61
Unlike the ER_BIN_OUT I/O device, there needs to be point database configuration points associated
with the physical channels referenced by the ER_BIN_IN I/O device's Slot_Number fields for proper
operation.
Where a IEC 61131-3 Resource connects a BOOL VarInput variable to a ER_BIN_IN I/O device, the
Current State Property of the digital point will be read into the IEC 61131-3 variable. The ER_BIN_IN I/O
device may be successfully opened if there is a valid I/O card configuration loaded into the SCADAPack
ER , and there is at least 1 physical binary input configuration point associated with the given I/O card.
62 SCADAPack E Target 5 Technical Reference
ER_RAW_OUT
The ER_RAW_OUT I/O Device references a physical analog output card by specifying a Slot_Number
field (the slot number that the card is installed on a SCADAPack ER RTU rack). The Channel number in
the Workbench Resource's I/O Device window corresponds to the physical channel number on the
SCADAPack ER I/O card.
Where an IEC 61131-3 Resource attaches an DINT VarOutput variable to an ER_RAW_OUT output
device, the Current Integer Value property of the associated analog point will be controlled from the IEC
61131-3 variable. If there is a physical analog output configuration point associated with this physical
channel, the Current Integer Value and Engineering Value of this configuration point will be updated after
the successful control of the relay output.
The ER_RAW_OUT output device may be successfully opened if there is valid I/O card configuration
loaded into the SCADAPack ER RTU. Unlike standard RTU point output devices (e.g.
RTU_RAW_WRITE), it is NOT necessary that there are physical analog output configurations points
associated with the physical channels referenced by the ER_RAW_OUT output device.
Both DINT and REAL IEC 61131-3 analog variables cannot be mixed on the same output I/O Device.
Use the ANY_TO_DINT or ANY_TO_REAL conversion functions if this is required.
ER_ENG_OUT
The ER_ENG_OUT I/O device references a physical analog output card by specifying a Slot_Number
field (the slot number that the card is installed on a SCADAPack ER RTU rack). The Channel number in
the Workbench Resource's I/O Device window corresponds to the physical channel number on the
SCADAPack ER I/O card.
Where an IEC 61131-3 Resource attaches a REAL VarOutput variable to an ER_ENG_OUT output
device, the Current Eng Value property of the associated analog point will be controlled from the IEC
61131-3 variable. If there is a physical analog output configuration point associated with this physical
channel, the Current Eng Value and Current Integer Value of this configuration point will be updated after
the successful control of the analog output.
The ER_ENG_OUT output device may be successfully opened if there is valid I/O card configuration
loaded into the SCADAPack ER RTU. Unlike standard RTU point output devices (e.g.
RTU_ENG_WRITE), it is NOT necessary that there are physical analog output configurations points
associated with the physical channels referenced by the ER_ENG_OUT output device.
Both DINT and REAL IEC 61131-3 analog variables cannot be mixed on the same output I/O Device.
Use the ANY_TO_DINT or ANY_TO_REAL conversion functions if this is required.
the physical channels referenced by the ER_RAW_IN input device for proper operation.
Where an IEC 61131-3 Resource attaches a DINT VarInput analog variable to an ER_RAW_IN input
device, the Current Integer Value property of the associated analog point will be read into the ISaGRAF
variable.
The ER_RAW_IN input device may be successfully opened if there is a valid I/O card configuration
loaded into the SCADAPack ER RTU, and there is at least 1 physical analog input configuration point
associated with the given I/O card.
Both DINT and REAL IEC 61131-3 analog variables cannot be mixed on the same input I/O Device. Use
the ANY_TO_DINT or ANY_TO_REAL conversion functions if this is required.
ER_ENG_IN
The ER_ENG_IN I/O Device references a physical analog input card by specifying a Slot_Number field
(the slot number that the card is installed on a SCADAPack ER RTU rack). The Channel number in the
Workbench Resource's I/O Device window corresponds to the physical channel number on the
SCADAPack ER I/O card.
Unlike the ER_ENG_OUT output device, there needs to be point database configuration points
associated with the physical channels referenced by the ER_ENG_IN I/O Device for proper operation.
Where an IEC 61131-3 Resource attaches a REAL (floating point) VarInput analog variable to an
ER_ENG_IN input device, the Current Eng Value property of the associated analog point will be read into
the ISaGRAF variable.
The ER_ENG_IN input device may be successfully opened if there is a valid I/O card configuration
loaded into the SCADAPack ER RTU, and there is at least 1 physical analog input configuration point
associated with the given I/O card
Both DINT and REAL IEC 61131-3 analog variables cannot be mixed on the same input I/O Device. Use
the ANY_TO_DINT or ANY_TO_REAL conversion functions if this is required.
64 SCADAPack E Target 5 Technical Reference
Hold On Stop
The SCADAPack Workbench Output I/O Devices support a hold_on_stop parameter.
This BOOL parameter allows the user to identify how outputs are processed on a shutdown (or restart) of
the IEC 61131-3 application.
This applies for local RTU physical output points on the SCADAPack ES/ER RTUs.
The hold on stop parameter is not used on the SCADAPack 300E RTUs even if it is available on a
Workbench I/O device.
See Stopping an IEC 61131-3 Resource 52 for a description of the effect of stopping an IEC 61131-3
application.
This Hold On Stop Output I/O device parameter defaults to false (meaning outputs will be reset off or
reset to 0 when the application stops).
When set to true, the local physical outputs of SCADAPack ES/ER RTUs are held at their current
values until the database point is updated to some other value (e.g. by a new application, DNP3 /
IEC60870-5-101 / Modbus control, etc).
SCADAPack E Target 5 Technical Reference 65
When an IEC 61131-3 application Resource starts, particularly if there is a large number of
PLC Device I/O devices, or if a PLC is not responding, the Workbench debugger may not
TIP:
connect to the SCADAPack E target immediately. In this case please wait a little while for the
application to work through the PLC device updates before attempting to re-establish a
66 SCADAPack E Target 5 Technical Reference
debugger connection.
Different PLC Device I/O Devices are provided for different types of PLC data.
For example: read PLC value registers (analog input device), write PLC coils (boolean output device),
read PLC accumulated data (analog input device). The different types of I/O devices available and
ranges of PLC data that can be accessed depend on the individual PLC driver. The following section
details a summary of the SCADAPack E RTU’s MODBUS PLC driver. For detailed information on
Modbus and other drivers, see the relevant SCADAPack E PLC Device Interface manual.
ISaGRAF PLC Device I/O devices access data in the following way:
a READ PLC I/O Device normally corresponds to a read access to PLC data
a WRITE PLC I/O Device corresponds to a write-only access to PLC data
Serial communication with external devices, such as PLCs, is made through the SCADAPack E
RTU port(s) configured as PLC Device.
IEC 61131-3 function blocks: MBUSCTRL, MTCPCTRL & DF1CTRL can be used to control read &
write communications to the PLC device whose communication is defined by I/O devices. Disabling
read operations affects PLC device Input data. Disabling write operations affects PLC device Output
data.
Up to a total of 200 PLC I/O Devices can be defined in total for PLC Device communication ports
and IEC 61131-3 Resources. Multiple PLC Device serial ports, as well as TCP/IP channels for
some PLC devices, can be used for PLC peripheral communication.
SCADAPack E Target 5 Technical Reference 67
PLC I/O input devices typically require user configuration through the I/O device parameters. These are
set as part of the Workbench application and are entered into the I/O device parameter fields within the
Workbench Resource's I/O Device Window.
The SCADAPack E RTU can communicate with Allen Bradley DF1 PLC's, Modbus PLC peripheral
devices via the serial ‘MODBUS RTU’, Open Modbus/TCP or Modbus RTU in TCP protocols.
Port: This parameter is only available on certain PLC I/O device drivers. Where present, it defines which
of multiple RTU PLC Device ports will be used to communicate with the PLC or peripheral device. PLC I/
O Devices not including this parameter can only be used when a single PLC Device port is configured on
the SCADAPack E RTU.
PLC I/O output devices require user configuration through the I/O device parameters. These are set as
part of the Workbench application and are entered into the I/O device parameter fields within the
Workbench Resource's I/O Device Window.
The SCADAPack E RTU can communicate with Allen Bradley DF1 PLC's, Modbus PLC peripheral
devices via the serial ‘MODBUS RTU’, Open Modbus/TCP or Modbus RTU in TCP protocols.
The SCADAPack E RTU checks for data being written to the PLC by an IEC 61131-3 I/O device driver,
before the PLC I/O Input Device data is retrieved.
Communication requests made by the SCADAPack E RTU to the PLC are asynchronous to the
scanning of the IEC 61131-3 Resource, but data within the resource remains consistent duration of a
scan cycle.
To assist with debugging of PLC I/O Device communication, the SCADAPack E RTU provides two types
of analog system points which provide useful information:
1. PLC Communication Status
Status available for the first 60 PLC I/O Devices used by IEC 61131-3 Resource Number 1 and the first
14 PLC I/O Devices used by Resource Number 2.
2. Cache Time (seconds)
for PLC I/O Input Devices, these system points represents the age of the data since the last update
these system points are not updated for PLC I/O Output Devices (0).
SCADAPack E RTU analog system points 53300 to 53419 are set aside for the PLC Device
communication status information for up to 60 PLC I/O Devices in IEC 61131-3 Resource Number 1.
Points 53422 to 53449 are set aside for the PLC Device communication status information for up to 14
PLC I/O Devices in Resource Number 2. A pair of consecutive points represent the PLC
Communication status (‘COMMS_STATUS’) and the age of the data (‘UPDATE_TIME’) for each PLC I/O
Device (refer to table below). Non ‘PLC’ I/O devices (i.e. "RTU" devices), are not included in the
consecutive count.
This data is accessible externally to the RTU (via a communications protocol accessing these points) or
from an IEC 61131-3 resource, using RTU_RAW_READ I/O devices. These points are only accessible if
PLC Device functionality is enabled.
‘Comms Status’ & ‘Cache Time’ System Point Numbers for IEC 61131-3 Resource Number 1
1 53300 53301
2 53302 53303
3 53304 53305
4 53306 53307
5 53308 53309
6 53310 53311
7 53312 53313
8 53314 53315
9 53316 53317
10 53318 53319
SCADAPack E Target 5 Technical Reference 71
11 53320 53321
12 53322 53323
13 53324 53325
14 53326 53327
15 53328 53329
16 53330 53331
17 53332 53333
18 53334 53335
19 53336 53337
20 53338 53339
21 53340 53341
22 53342 53343
23 53344 53345
24 53346 53347
25 53348 53349
26 53350 53351
27 53352 53353
28 53354 53355
29 53356 53357
30 53358 53359
31 53360 53361
32 53362 53363
33 53364 53365
34 53366 53367
35 53368 53369
36 53370 53371
37 53372 53373
38 53374 53375
39 53376 53377
72 SCADAPack E Target 5 Technical Reference
40 53378 53379
41 53380 53381
42 53382 53383
43 53384 53385
44 53386 53387
45 53388 53389
46 53390 53391
47 53392 53393
48 53394 53395
49 53396 53397
50 53398 53399
51 53400 53401
52 53402 53403
53 53404 53405
54 53406 53407
55 53408 53409
56 53410 53411
57 53412 53413
58 53414 53415
59 53416 53417
60 53418 53419
‘Comms Status’ & ‘Cache Time’ System Point Numbers for IEC 61131-3 Resource Number 2
1 53422 53423
2 53424 53425
SCADAPack E Target 5 Technical Reference 73
3 53426 53427
4 53428 53429
5 53430 53431
6 53432 53433
7 53434 53435
8 53436 53437
9 53438 53439
10 53440 53441
11 53442 53443
12 53444 53445
13 53446 53447
14 53448 53449
These system points are only accessible if PLC Device functionality is enabled through a PLC Device
port setting or Modbus/IP (Client) setting.
PLC Input I/O Device data is updated by the SCADAPack E RTU when it communicates with the PLC
device. The PLC communication status is updated if there is a status code returned from the PLC or no
response from the PLC after a data request by the RTU. Status codes are presented in the Table 73
above. The value in each status register is cleared by the RTU upon successful communication
sessions. Variables within an IEC 61131-3 resource can be used to log transient status codes.
PLC Output I/O Device data is written to the PLC when an IEC 61131-3 resource changes the value of a
variable attached to the I/O device Channel. In addition, output data is written to the PLC under the
following conditions:
When the IEC 61131-3 resource starts, output data is written
If the PLC does not respond to a control, it is resent until it is responded
I/O devices with a data_update_rate parameter output data at this rate
74 SCADAPack E Target 5 Technical Reference
The RDREC_x function blocks provide IEC 61131-3 resources with a set of commonly used attribute
and property fields for points in the RTU database
IEC 61131-3 Arrays can be useful when using the above Functions and Function Blocks. For more
information see Array Variables 34 .
Details of these, and other SCADAPack Workbench functions blocks are described in the SCADAPack
E Target 5 Function Block Reference manual.
SCADAPack E Target 5 Technical Reference 75
Building the solution, or a part of it, generates defined words from directly represented
variable variables that are wired to RTU point database I/O devices. See I/O Devices
Checked by the Pre-Processor 77 for a list of I/O devices used to generate defined words.
Defined words generated by previous builds are deleted first. The build deletes defined words
that begin with POINT_ including manually defined words.
Should the variable name break any of the rules outlined below, the Output window and Error
List window will report the reason. The build will be unsuccessful. Correct the variable names
and build the solution again.
A defined word has three parts: Name, Equivalent and Comment.
Name
The name identifies the resource, program, and variable name of the variable. In general the
name takes the form
POINT_VariableName_ProgramName_ResourceName
Equivalent (Value)
The Equivalent (value) is the variable’s point number. The point number is determined from I/
O device’s First_Point_Number parameter and the index of the channel. For example, if the
First_Point_Number is 100 and the index of the channel is 2, the Equivalent (value) is 102.
Comment
The comment is "Automatically generated by the RTU Point Pre-Processor”
Examples
Some pre-processor naming examples are below.
Example 1
With these variables
Resource1 contains global variable varRes1
Resource2 contains global variable varRes2
These defined words are created
POINT_varRes1_Resource1
POINT_varRes2_Resource2
Example 2
With these variables
Resource1 contains global variable var1
Resource2 contains global variable var1
These defined words are created
POINT_var1_Resource1
POINT_var1_Resource2
Example 3
With these variables
Resource1 contains Program1 with var1
Resource1 contains Program2 with _var1
These defined words are created
SCADAPack E Target 5 Technical Reference 77
POINT_var1_Program1_Resource1
Example 4
With these variables
Resource1 contains SFC Program1 with child SFC program Program1A that contains var1
Resource1 contains SFC Program1 with child SFC program Program1B that contains var1
These defined words are created
POINT_var1_Program1A_Program1_Resource1
POINT_var1_Program1B_Program1_Resource1
The pre-processor generates Defined Words for variables wired to these I/O devices.
RTU_BIN_READ
RTU_BIN_READ_OUTPUT
RTU_BIN_WRITE
RTU_COUNTER_READ
RTU_ENG_READ
RTU_ENG_READ_OUTPUT
RTU_ENG_WRITE
RTU_RAW_READ
RTU_RAW_READ_OUTPUT
RTU_RAW_WRITE
RTU_STRING_WRITE
RTU_BIN_WRITE_INPUT
RTU_RAW_WRITE_INPUT
RTU_ENG_WRITE_INPUT
RTU_COUNTER_WRITE_INPUT
78 SCADAPack E Target 5 Technical Reference
Defined Words created by the pre-processor are useful with these function blocks.
RDFLD_I
RDFLD_R
RDREC
RDREC_AN
RDREC_CN
RDREC_DG
RDSTRING
SETATR_I
SETATR_R
Defined Words created by the pre-processor can be used to access point data with these
functions.
GETPNTB
GETPNTC
GETPNTF
GETPNTSL
GETPNTSS
GETPNTUS
SETPNTB
SETPNTF
SETPNTSL
SETPNTSS
SETPNTUS
A few differences with the pre-processor exist between ISaGRAF 3 Workbench and
SCADAPack Workbench.
SCADAPack E Target 5 Technical Reference 79
Prefix Configuration
Since the defined word name length is increased to 128 characters, there is no need to have
a configurable prefix value. The prefix value used by the pre-processor is hard-coded to
POINT_. There is no option to configure the pre-processor to use a suffix rather than a prefix.
Array Variables
Array variables cannot be wired to I/O devices. The pre-processor does not generate Defined
Words for array variables.
In this example, two variables are wired to the RTU_BIN_WRITE I/O device at device index 8.
This I/O device is part of a resource named MyResource.
The Pre-Processor generates these Defined Words linking the DNP point to the I/O device.
80 SCADAPack E Target 5 Technical Reference
POINT_oVar1_Prog1_MyResource = 100
POINT_oVar2_Prog1_MyResource = 101
TCP/IP Communications 83
Application File Transfer 86
SCADAPack E Target 5 Technical Reference 81
A maximum of one RTU serial port may be configured as ISaGRAF for local connection to a
TIP: SCADAPack Workbench debugger. If a second Workbench connection is desired, use
ISaGRAF via Ethernet (ETCP).
An IEC 61131-3 resource previously loaded into the RTU (via Workbench or File Transfer) will execute on
the RTU regardless of whether an ISaGRAF port is configured.
The SCADAPack Workbench project requires local configuration in order to communicate with a
SCADAPack E RTU over a serial line.
Select the Workbench Deployment View window from the View -> Deployment View menu, or from the
Solution Explorer window as shown below.
The available serial port configuration fields are described below. These settings should match the
ISaGRAF serial port configuration on the SCADAPack E RTU target.
Port The Workbench local communication port. The default value is COM1.
Baud Rate The baud data transfer rate. The default value is 9600.
Parity The type of parity used. Possible values are N for none, E for even, and O for
odd;
The default value is N.
Stop Bit The number of stop bits used to indicate the end of a transmission. Possible
values are 1 or 2;
The default value is 1.
HardwareFlowControl The control of the flow of data transmission between the network hardware.
Possible values are True or False;
* Use the default value of False for SCADAPack E Smart RTU.
Make a copy of the settings file (this can be used to restore the settings a mistake is made)
Open the settings file with a text editor or XML editor
This parameter adjusts the timeout. Edit the text highlighted below.
<!--Time-out in milliseconds to declare connection failure-->
<ConnectNoResponseTimeOut>10000</ConnectNoResponseTimeOut>
This parameter adjusts the multiplier. Edit the text highlighted below.
<!--IXL Tx (10 sec.), Rx (4 sec.) time-out multiplication factor-->
<IxlTimeoutMultiFactor>3</IxlTimeoutMultiFactor>
From the Deployment View window, select the Network connection (shown above as circled). The
Properties window should then show the available Workbench network settings (see below).
This requires the RTU has ISaGRAF/TCP service enabled (see SCADAPack E Configurator TCP/IP
page) as shown below.
SCADAPack E Configurator
Enabled TCP/IP Services
86 SCADAPack E Target 5 Technical Reference
Use the icon on SCADAPack E Configurator Toolbar and follow the dialog to select the appropriate
*.I5P file. The SCADAPack E Configurator will transfer the selected package file to the RTU and
activates the IEC 61131-3 Resources automatically.
WARNING
UNINTENDED EQUIPMENT OPERATION
Evaluate the operational state of the equipment monitored and controlled by the
RTU before downloading. Hazardous situations can occur if system state is not
confirmed prior to downloading.
Failure to follow these instructions can result in death, serious injury or
equipment damage.
The syntax of the RESTART ISAGRAF command is shown in the following table.
Command Action
RESTART ISaGRAF Restart Resource 1 and Resource 2 from the
existing C:\ISAGRAF5\ folder for Target 5.
RESTART ISaGRAF filename Unpack project from the .I5P file into the "C:
\ISAGRAF5" directory, and restart Resource 1 and
Resource 2.
If a Resource is missing from the package, it
removes that resource.
If filename is not found or the format is invalid, it
generates a status code and returns.
'1' and '2' are invalid project filenames.
The subsequent state of the IEC 61131-3 Resources can then be confirmed using the SCADAPack E
Configurator's Logic -> IEC61131-3 page or from the "Status" command-line command.
88 SCADAPack E Target 5 Technical Reference
4005 0x2202:0005 ISaGRAF 5 Retain bad Do not use workbench retain memory
memory description description for SCADAPack E RTU
4007 0x2202:0007 ISaGRAF 5 Read retain Check file system is not full, Reload IEC
variables from backup 61131-3 application
unsuccessful
SCADAPack E Target 5 Technical Reference 89
4025 0x2202:0019 ISaGRAF 5 Device write Contact Schneider Electric technical support
internal was unsuccessful
4026 0x2202:001A ISaGRAF 5 Device I/O Contact Schneider Electric technical support
control internal was
unsuccessful
4027 0x2202:001B ISaGRAF 5 I/O driver Contact Schneider Electric technical support
initialize was
unsuccessful
4028 0x2202:001C ISaGRAF 5 I/O device Review SCADAPack E point configuration and
open unsuccessful IEC 61131-3 application I/O device settings
4033 0x2202:0021 ISaGRAF 5 TIC boundary Review the IEC 61131-3 application
check (Array access out
of range)
4034 0x1202:0022 ISaGRAF 5 SINT variable Review the IEC 61131-3 application
divided by zero
4035 0x1202:0023 ISaGRAF 5 DINT variable Review the IEC 61131-3 application
divided by zero
SCADAPack E Target 5 Technical Reference 91
4037 0x2202:0025 ISaGRAF 5 Dynamic SFC Review incorrect IEC 61131-3 application
behaviour processing implementation
unsuccessful
4038 0x2202:0026 ISaGRAF 5 Cannot Put Contact Schneider Electric technical support
action of specified SFC
step in list of actions to
execute
4039* 0x1202:0027 ISaGRAF 5 Cycle Time Increase the cycle time in the IEC 61131-3
Overflow application
4048 0x1202:0030 ISaGRAF 5 LINT variable Review the IEC 61131-3 application
divided by zero
4050 0x1202:0032 ISaGRAF 5 UINT variable Review the IEC 61131-3 application
divided by zero
* These status codes will NOT generate an RTU System Status in system analog point 50020. Other
listed IEC 61131-3 status codes DO update the RTU System Status.
92 SCADAPack E Target 5 Technical Reference
Detailed IEC 61131-3 target status codes are also visible in the SCADAPack Workbench using the
System Event log. When the workbench is connected to the target in Debug mode, press the yellow
lightning-bolt icon on the debug tool bar to start the system event logger (as shown below).
11 Target Upgrade
A firmware upgrade on the SCADAPack E Smart RTU may add new functionality. If new firmware has
additional I/O device definitions, function blocks and capabilities the Target Definition must be updated in
existing projects, or the resources will not start when downloaded.
SCADAPack Workbench can import the I/O device definitions, function blocks and capabilities of a
target device from a Target Definition file (".tdb"). If new capabilities or features are added to the
SCADAPack E firmware, a new set of .tdb files will be published and released as part of an updated
SCADAPack Workbench release. New Workbench projects that are created from a Proj ect Template
12 will not require a Target Definition file to be imported.
There are Two Target Definition files maintained for the SCADAPack Workbench. The files are named
as follows:
"SP_300E_Target_*.tdb" for the SCADAPack 300E RTU models, where * is the firmware version
"SP_ES_Target_*.tdb" for the SCADAPack ES/ER RTU models, where * is the firmware version
To import a Target Definition file into an existing project:
1. From the SCADAPack Workbench Solution Explorer window, right-click the project and choose
Import, then Import Target Definitions from the contextual menu (as shown below).
2. In the Open window, browse to locate the appropriate target definitions (*.tdb) file for your target to
import into the project, then click Open. These files can be found in the workstation’s SCADAPack
Workbench "C:\Program Files\Schneider Electric\SCADAPack Workbench\SCADAPack
Workbench\TargetDefinitions" directory tree.
When the importation process is completed, the features from the target definition are available for use in
the project.
12 Unsupported Features
ISaGRAF 6.1 Unsupported Features
This section outlines the features that are documented in the ISaGRAF 6.1 Workbench User's Guide or
ISaGRAF Target User's Guide that are not currently implemented in the SCADAPack E RTU Target.
Most other major ISaGRAF 6.1 features are implemented.
A target error will usually be produced if an IEC 61131-3 application or SCADAPack Workbench
accesses an unimplemented feature. The unsupported features are as follows:
Producer/Consumer Bindings between devices
Interrupts feature
Wiring on complex variable members
User System Variables
Scientific Apparatus Makers Association (SAMA) diagram language
IEC 61499 language
Failover Mechanism
I/O Device Conversion, Gain, Offest
SAFEBOOL variable types