CT STG sg2 PDF
CT STG sg2 PDF
CT STG sg2 PDF
How can I …
accelerate the engineering workflow?
Disclaimer
This document is not comprehensive for any systems using the given architecture
and does not absolve users of their duty to uphold the safety requirements for the
equipment used in their systems or compliance with both national or international
safety laws and regulations.
Readers are considered to already know how to use the products described in this
document.
3
The STG Collection
System Technical Guides (STG) are designed to help project engineers and Alliance
System Integrators during the development of a project. The STGs support users
during the architecture selection and the project execution (design, configuration,
implementation and operation) phases with an introduction to the system operating
modes.
• Technical documentation
• Application examples
• Object libraries
Each STG addresses one or several customer challenges within the proposed
solution using the offer from Schneider Electric.
All explanations and applications have been developed by both Schneider Electric
experts and System Integrators in our solution labs. The contribution from the system
integrators helps the kit’s contents meet the expectations of our users.
All STGs are illustrated with industry-specific applications to give more concrete
examples of the methodology.
It is not intended that the STGs be used as substitutes for the technical
documentation related to the individual components, but rather used to compliment
these materials and training.
Development Environment
Each STG has been developed in one of our solution platform labs using a typical
PlantStruxure architecture.
4
Table of Contents
1. Introduction...........................................................................7
2. Selection..............................................................................15
3. Design..................................................................................37
4. Configuration ......................................................................75
5
4.4. ODBC (Open DataBase Connectivity) Configuration ............................................................................... 84
5. Implementation ...................................................................85
6. Operation...........................................................................143
6
1-Introduction
1. Introduction
1.1. Purpose
The recommendations and guidelines provided in the following chapters of this STG
are generic and are targeted at process applications such as mining, cement, oil and
gas, and so on. However, we use the specific example of a wastewater plant with an
automation project based on a PlantStruxure Control System to illustrate a process
application developed with sg². Starting from the process analysis, a Bottom-up
approach is used to develop the project.
Finally, the single used database facilitates the data handling between SCADA and
PAC systems in terms of processing, storage, and redundancy.
For customers in industries that require the type of application mentioned above, the
challenges are:
These challenges acted as a guide during the solution development. This guide
suggests best practices to address these challenges and highlight specific areas
including how to:
7
1-Introduction
1.3. Prerequisites
• Unity Pro
• Vijeo Citect
• OFS
This STG explains the project methodology and includes the following phases:
Selection, Design, Configuration, Implementation, and Operation. The document
provides a step-by-step methodology to create an application with SoCollaborative
Engineering used as a system engineering tool. Here is an overview of this method:
• Selection. The P&ID (Piping and Instrumentation Diagram) of the plant process is
used as the starting point for this analysis. This phase includes the following
seven topics to help you select the most appropriate solution for your application:
3. P&ID: Lean how to finalize your P&ID, applying the previously defined
naming rules.
8
1-Introduction
• Design. This phase includes three topics to help you build the core application:
3. Vijeo Citect Navigation: Customize the sg² project to meet the project
constraints and requirements.
• Configuration. This phase explains the different elements that you have to set up:
4. Unity Pro project: this section explains how to develop with SGStudio
Workbench in order to generate the Unity Pro application.
5. OFS: learn how to configure OFS to allow the communication with the
unlocated variables of the Unity Pro application.
6. Vijeo Citect: This section explains how to develop with sg² Framework
in order to generate the Vijeo Citect application.
• Operation. This phase summarizes what the operator can do with the final
SCADA application:
2. Alarms
3. Trends
9
1-Introduction
Architecture
10
1-Introduction
The pre-treatment of a wastewater plant, the mechanical treatment steps, include the
following:
• Lifting,
• Screening,
• Primary clarifier.
The following picture illustrates a wastewater installation plant. The project considers
the mechanical cleaning section only, which is highlighted:
Lifting
Screening
Grease&Sand
Primary Clarifier
11
1-Introduction
In the following paragraphs, you find a short description of each functional unit of the
project.
1) Lifting. The aim of this unit is to lift effluents toward the next unit (screening). It
includes two elements:
2) Screening. In this unit, the effluents go through a metallic screen, a sifter, in order
to catch the more voluminous wastes. It includes two main elements:
12
1-Introduction
3) Grease & Sand Removal. This unit allows sand to deposit at the bottom of a tank
and also gathers greases. The plant includes a Grease & Sand removal tank.
4) Primary clarifier. The aim of this unit is to clarify the water before biological
treatment. It includes a clarifier in the shape of a cyclone. The plant has only one
Clarifier basin. Two main elements compose this unit:
13
1-Introduction
14
2-Selection
2. Selection
This chapter describes how to perform, from the P&ID (Piping and Instrumentation
Diagram) of the wastewater plant, the functional analysis of the process. It proposes
a methodology for:
• analyzing the plant process and highlighting the characteristics of all equipment
used in this process.
• defining the requirements of selecting the object library in the next phase.
15
2-Selection
To follow this methodology, you must gather information from different sources:
• functional specifications
• operator requirements
• company standards
This information is used to either choose the most appropriate components in the
current process libraries or to build new components required to handle the project’s
process.
16
2-Selection
An industrial process can be described with a P&ID diagram. Our project is the pre-
treatment for a wastewater plant, that is, the mechanical cleaning parts.
The following P&ID without any tag is used in this step to analyze the process:
17
2-Selection
2.2.1. Introduction
From the plant analysis, the functional analysis can be performed using the ISA-S88
international standard. A bottom up approach is applied to analyze the process and
then to design the automation application. The functional analysis leads to the choice
of the required components in the software libraries.
• Lifting,
• Screening,
• Primary clarifier.
The following paragraphs describe the process philosophy of each functional unit,
and what we consider as a common functioning.
18
2-Selection
2.2.2. Lifting
The aim of this unit is to lift effluents toward the next unit (screening). Two tanks
compose this unit: wastewater and rainwater tanks.
Wastewater Tank
Note: Two of the pumps (see pump management paragraph) are managed by a split
range function that enables their control with only one signal, here the regulation loop
output. The split range parameters can be accessed on the supervision as well.
3
A level switch indicates a very low level in the tank. Two flowmeters (gauged in m /h)
measure the input and output flows of the basin. Each flowmeter has a totalizer
function.
19
2-Selection
• Pump Management
A parameter (xxh, in hour) makes each pump change its role periodically. The
following flowchart explains the functioning of the three pumps:
Note: The user can adjust the xxh parameter on the supervision.
• Security Management:
The very low level switch is wired directly to the power circuit of the pumps. Note that
this signal is also wired on the PAC.
The high level switch in the downstream unit (Screening) and an adjustable high
threshold of the level transmitter included in the wastewater tank condition the
interlock of the wastewater tank’s pumps.
20
2-Selection
Rainwater Tank
• Pump Management
The primary pump attends the complementary water needs for the wastewater tank.
The rescue pump replaces the primary pump in the event of maintenance or a
detected fault.
A parameter (xxh, in hour) makes each pump change its role periodically.
Note: the user can adjust the xxh parameter on the supervision.
• Security Management
The very low level switch is wired directly to the power circuit of the pumps. Note that
this signal is also wired on the PAC.
An adjustable high threshold of the level transmitter included in the wastewater and
the low level switch of the rainwater tank condition the interlock of the rainwater tank’s
pumps.
21
2-Selection
2.2.3. Screening
Note: the duration time between two startups (here, 5 seconds) cannot be set by a
supervision parameter. You must instead adjust the duration time in its program
according to the application requirements.
Finally, the basin includes two digital switches that indicate high and low levels (see
security management), as well as an emptying valve.
• Security Management
The low level switch of the basin included in the screening unit conditions the
interlock of the three motors.
The high level switch of the basin included in the downstream unit (Grease & Sand
Removal) or the high level switch of the primary clarifier condition the interlock of the
basin output valve that is included in the screening unit.
22
2-Selection
A measure of the high sand level (by a high level switch) makes a by-pass valve open
and the starts two aspiration pumps. If the high level is lost, the secondary pump
stops and the primary keeps pumping for a hysteresis (30 s.) from the high level and
then stops.
Note: the duration of the hysteresis cannot be set by a supervision parameter. You
must instead adjust the duration in its program according to the application
requirements.
• Security Management
The feedback of the by-pass valve conditions the interlock of the secondary aspiration
pump.
The low level switch conditions the interlock of this unit’s motors, pumps and valves.
23
2-Selection
• Pump Management
The primary pump empties the wastes into a unit specialized in biological treatment.
The rescue pump replaces the primary pump in the event of maintenance or a
detected fault.
A parameter (xxh, in hour) makes each pump change its role periodically.
• Security Management
The low level switch conditions the interlock of this unit’s motors, pumps and valves.
24
2-Selection
• Turning on
The power contactors, upstream of the pumps, are closed in a cascade way when the
PAC shifts in RUN mode.
Each actuator and sensor can be manually controlled from the supervision.
• Parameters
All the parameters (setpoints, thresholds…) can be set from the supervision.
An alarm page displays the current alarms; another page is dedicated to the historical
ones.
The operator controls the startup of the pre-treatment process from the supervision. A
unique startup command is necessary to start the whole installation.
Note: the management system of the sequential adheres to the ISA-S88 standard.
25
2-Selection
Each project is unique, and each customer has uniquely defined standards. It is
important to listen to customer expectations in terms of engineering design to define
appropriate naming rules. For this project, we defined our own rules.
The following table shows the structure used for the object identification:
Aa 1 Aa(aa) A (optional) 1
Unit Unit Index Control Module Sub Index Control Module Index
Analog Sensors
26
2-Selection
From the description of the process and the analysis of the plant, we define the final
P&ID as follows:
27
2-Selection
The functional analysis allows to highlight the automation requirements. From the
final P&ID, we define the PlantStruxure architecture to perform the wastewater
process. It is an Ethernet-based architecture with a unique M340 PAC and a Vijeo
Citect SCADA client/server.
28
2-Selection
• ATV 61: they are connected directly to Ethernet. Monitoring functions and control
are allowed. An embedded web server can be used for maintenance.
• ATS 48: a Transparent Ready gateway ETG100 is used to connect this device to
the Ethernet architecture.
Note: all the five previous devices can be configured by Powersuite software..
• Contactor: the selected solution is directly wired to the contactors of the Advantys
STB I/O module. The STB islands are directly connected on Ethernet.
Note: the STB islands can be configured by Advantys configuration tool, included as
part of SoCollaborative Engineering.
29
2-Selection
Now, you can list the required equipment thanks to the P&ID and the system
architecture topology previously defined.
The following table summarizes the required equipment for the project:
Analog & Lf1LsllR1 Very low level of the rainwater tank on Advantys STB
30
2-Selection
31
2-Selection
32
2-Selection
33
2-Selection
Alarms
× × ×
acknowledgement
Changes of the
× × ×
operator parameters
Commands linked to
× × ×
the sequences
Enable/ Disable
× × ×
First-level Alarms
Change of owner
× ×
(Operator/ Program)
Changes of the
×
parameters
Enable/ Disable
×
Second-level Alarms
Interlock Bypassing ×
Enable/ Disable
×
the simulation mode
34
2-Selection
The motor management of the plant defines specific operating modes. The objective
is to propose operating modes that allow the installation management in the remote
mode with a PAC, or in the local mode with buttons or a local panel.
• Remote mode
In the Remote Mode, either the PAC (Auto Mode) or the SCADA/HMI operator
(Manual Mode) controls the motor. When both a SCADA and a local HMI are able to
control switching between Auto and Manual modes, the first station switching to the
Manual Mode controls the actuator. Only this station can switch the motor control
back to the Auto Mode.
• Local mode
35
2-Selection
36
3-Design
3. Design
After analyzing the process requirement and constraints, you can start the project
design by:
• Selecting the sg² components from the sg² library documentation and thus
building the project process library,
• Creating the user components required to finalize the building of the project
process library,
For this project sg² is used to optimize the realization, reduce the engineering time,
and facilitate the deployment of future similar projects.
sg² includes many tools. You can find a short description in the following paragraphs:
37
3-Design
• Resources that are ready to be used for the development of automation systems:
sg² Resources.
SGStudio Workbench is the configuration environment for sg² objects. It creates the
instances of all the application I/Os (motors, valves, sensors and so on) and
generates the control application in Unity Pro.
38
3-Design
sg² Framework is the environment from which the engineering tasks are performed.
sg² Framework makes it possible to integrate control Projects in Unity with a
monitoring Project developed with Vijeo Citect.
The following main engineering tasks can be carried out from sg² Framework:
• Managing sg² projects, including managing the main Vijeo Citect project
Databases.
Libraries).
• Platform Tools:
3) OFS: OPC Server.sg² Framework allows to create links between Unity Pro and
Vijeo Citect projects. It creates the Vijeo Citect start application (cluster, included
project) and also generates the tags linked to the parameterized Unity application in
terms of I/Os, alarms, trends and so on. A resource tab allows for the customization
of the actual generation such as components, tags, and the application.
39
3-Design
3.1.3. SGBuilder
SGBuilder is the sg2 application that allows reusable control element libraries to be
built (and subsequently instantiated with SGS Workbench). Each one of the control
templates called SGU Component can contain different resources for a Unity Pro
application: Program sections, animation tables, operator screens, variables, and
data types (DDTs and DFBs). The tool for defining control components is the Unity
Pro programming environment itself, so that every component is generated from a
different Unity project (.stu extension) that contains all the resources associated with
a specific control strategy. The SGBuilder tool processes each one of the component
Unity files, validates the information in each one of them, and generates a series of
folders and XML files that make up the resulting library. This way, the control strategy
that has been defined and validated in a component can be included in a library and
then be reused as many times as necessary with SGStudio Workbench.
SGS Guardian automates the synchronization process for Tags, Alarm Tags, and
Trend Tags that are necessary to monitor Unity projects from Vijeo Citect. The
configuration information entered into the control projects programmed in Unity (Tag
names, descriptions, addresses, etc.) is automatically moved to the required fields in
the Vijeo Citect configuration Databases.
40
3-Design
For the first step of the Design phase, we recommend you to select the sg²
components from the sg² library documentation and then build the project process
library. The functional analysis identifies the requirements in terms of equipment to be
controlled and automation devices to be managed. sg² components are selected from
these requirements. 5 sg² libraries are available:
• Diagnosis
• Communication
• Device
• Process
• User
The sg² components can now be selected from the P&ID and the automation system
architecture topology.
41
3-Design
This library gathers information from the PAC, in terms of Cycle Time, Watch Dog,
Clock and so on. The following table presents its functionalities:
CPU information M340 PAC M340 Diagnosis/ General Status/ This component
recovery allows you to
CPUDIAG
quickly diagnose
the CPU state via
Vijeo Citect
without going
through Unity Pro
This object has been selected for the wastewater project to allow a quick diagnosis of
the PAC CPU without using Unity Pro.
The following screenshots show what the component looks like during runtime:
42
3-Design
This library includes devices that attend the data exchanges. The project requires two
types of communications: Ethernet and Modbus serial via a Modbus serial Gateway
(ETG100). Consequently, Ethernet Port M340 and Ethernet Modbus serial Gateway
(ETG100) need to be instantiated in the project, after which it is possible to implement
Modbus serial devices (ATS48 for example), which is connected to the ETG100
instance. For more information about instantiation, please refer to the Instantiation
section of the implementation chapter.
The following table summarizes the required functions with their corresponding
components:
43
3-Design
We mix the two libraries in the same paragraph to group the instances that are linked
to the same hardware element.
The following paragraphs list the components by functional unit, with the
corresponding P&ID and automation system architecture topology representations:
Lifting
44
3-Design
Rainwater Tank
Process\ On-Off
Digital Pumps Motors\ With This component automatically
Basin pumping with pump Lf1PmpR1
piloted by Interlocks, Failures, associates the motor with the
cycle management Lf1PmpR2
ATS48 Maintenance and device.
Device
45
3-Design
Wastewater Tank
Digital Safety Digital Low Low Process \ Digital Inputs The Digital Input component is
Lf1LsllD1
Sensor Level Sensor \ Digital Input adapted to manage the digital level.
Flow in \ out
Analog Flow sensor Lf1ftD1 The Analog Input with Calculation
Process \ Analog Inputs
Measure in
4-20mA \ With Calculations meets the need to measure the flow.
Lf1ftD2
the basin
Lf1PmpD1
The I\O scanning service of the NOE
Devices \ Devices in
ATV61 Ethernet Lf1PmpD2 Ethernet module enables to
Ethernet \ ATV61 Drive
communicate with the equipment.
Lf1PmpD3
46
3-Design
Screening
47
3-Design
Sc1Mot1
Digital Motor Process \ ON-OFF Motors \ With This component
piloted by Sc1Mot2 Interlocks, Failures, Maintenance and automatically associates the
TeSys U Device motor with the device.
Sc1Mot3
48
3-Design
49
3-Design
50
3-Design
Digital Air
This component
Compressor Process \ ON-OFF Motors \ With
Gs1Mot3 Interlocks, Failures, Maintenance automatically associates
piloted by and Device
the motor with the device.
TeSys T
Analog
The Analog Input
Oxygen Process \ Analog Inputs \ Analog
Gs1Ot1 component is adapted to
Sensor Input
manage the digital level.
4-20 mA
Manual Valve
Evacuation valve of the with Process \ Hand Valves \ Valves This component meets the
Gs1Vlv3
basin open/close With 1 or 2 limit switches needs.
feedback
51
3-Design
Primary Clarifier
52
3-Design
This component
Programmed in automatically manages the
ClarifierSludge Component to be created
the PAC pump cycle (Normal\
Rescue).
Process Control
53
3-Design
Once the library is chosen, you can begin the second step of the Design phase: the
component creation.
sg² allows you to create your own components. The following three steps
chronologically compose the process: Unity, sg² and Vijeo Citect.
A visual representation of the process is below, with the creation steps on the left and
the corresponding software on the right:
The section on sg² components selection highlights the need for an additional
component, which attends to the pump cycle management. We choose to call this
component PCYCLE.
For more information about this cycle, see the pump management paragraph in the
functional analysis included in the Selection chapter.
54
3-Design
in Unity Pro
The component must be created with Unity Pro. Refer to sg² documentation for
details. Before compiling the component with SGBuilder, some essential rules must
be respected in regards to naming rules and parameter utilization notably. Thus, the
paragraphs below describe the recommended practices for the creation of a ‘user’
component.
General Rules
• The name of the Unity Pro station and the .stu file must have the same name, as
follows:
55
3-Design
• Create the component program in a unique section. The section name must use
IEC language (_Language), and it is recommended that you indicate the
component name, PCYCLE_FBD for example.
56
3-Design
• You must name the used parameters for the instantiation in SGStudio Workbench
as follows : X__Par_name__X
The following screenshots show how the parameters named in Unity Pro appear
when the corresponding ‘user’ component is instantiated in SGStudio Workbench:
57
3-Design
The following screenshot shows this setting in Unity Pro Variable Editor:
58
3-Design
This DDT is used to ease the creation of the resources components with SGCU
Editor, which allows to automatically generate the Vijeo Citect tags.
• Do not enter parameters in the animation table; only variables such as EDT and
DDT are authorized. Note that the naming of the animation table does not have
such restrictions.
• Do not enter parameters in the operator screens; only variables such as EDT and
DDT are authorized. Note that the naming of the operator screens does not have
such restrictions, but that the objects in the screen must be grouped. This group
must be placed at the coordinates (0,0) as shown below:
• Y
o
u
m
u
s
Name the instances of the DFB or DDT as follows: X__Var_name__X.
Note: It is recommended that you create this DDT, which eases the Resources
Components creation with sg² Framework. Resources Components allows generating
Vijeo Citect tags automatically.
59
3-Design
• You must surround the program with a commentary block of coordinates (0,0),
Note that there are no restrictions with the naming of such blocks.
Overview
Here is an overview of the component both during the development phase with Unity
Pro, and then after its instantiation\ generation with SGStudio Workbench:
Development:
60
3-Design
in SGBuilder
Once the component is created in Unity Pro, the next phase in sg² is the generation of
components resources. From these resources, the automatic tag generation can be
done in Vijeo Citect. The sg² phase includes three steps with SGBuilder, SGStudio
Workbench and SGCU Editor. These steps are described below.
61
3-Design
The goal of this phase is, from a .stu Unity Pro file, to generate source files of the
‘user’ component (library + component itself). Proceed as follows:
Step Action
1 Start SGBuilder.
3 Select the path to recover the component .stu file, and then click OK. If the path is correct, the
following window appears:
Fill in the Name and Version text boxes. Click Accept and then Yes to validate.
62
3-Design
Once the processing completes, the Results window displays. The Created with error field
must display 0.
Click OK, then Yes. SGBuilder presents the component and its library as follows:
63
3-Design
For example, you can double click on Default Group to rename and change the icon:
6 Finalize the component and its associated library, by clicking on Write library. Once the
process completes, the Process ended window displays:
64
3-Design
in SGStudio Workbench
SGStudio Workbench allows you to import the component and the library previously
created with SGBuilder.
65
3-Design
Step Action
2 Click on Libraries of SGU Components and then choose Import from the drop down
menu.
3 Select the new library previously created by SGBuilder, and then click OK
66
3-Design
In SGCU Editor
Now you can begin the second phase, the creation of the component for the
automatic generation of the Vijeo Citect tags.
SGCU Editor, included in sg² Framework, allows you to define SGCU components
that extract data from the instantiated Unity Pro objects (DDT or DFB).
For more information about the creation of a new component, refer to the SGCU
Editor User Manual.
67
3-Design
The following table provides methods and recommended practices for creating the
mandatory resources that allow sg² to automatically generate the components tags
for a Vijeo Citect application.
Step Action
2 Create a new component by clicking on the sg² Resources tab, and then right click on SGCU
Components and then New, as is shown below:
3 As previously indicated in the Unity Pro section of this chapter, it is recommended that you
create a DDT in the Unity Pro project.
The SGCU Editor works as follows: if an Unity Pro object’s instance (DFB and\ or DDT) for
the new ‘user” component previously defined is detected in the corresponding Unity Project,
then SGCU Editor automatically generates the required tags (that is Variable, Advanced
Alarms, Digital Alarm and\ or Trends) for Vijeo Citect.
68
3-Design
Fill in the Type and Syntax properties. SGCU Editor uses this information as a filter to detect
the match component instance in the .stu file (see step 3). Here, the data Type is DDT, and the
Syntax is _PCCYLE_DDT.
Define the tags to be created in Vijeo Citect, as shown in the following screenshot:
Note: Marks are available to customize the tags. For more details, refer to SGCU Editor
documentation.
69
3-Design
The following screenshot illustrates the created tag in Vijeo Citect from an instance called
WasteTank in sg²:
70
3-Design
in Vijeo Citect
The third step of the component creation is to create Genie and Super Genie, which
control and command the previously defined component. The following examples
illustrate the Genie/Super Genie for the 2 and 3 pumps cycle management
respectively.
Genie
The Genie for the 2 pumps cycle management displays one state:
The Genie for the 3 pumps cycle management displays two states:
71
3-Design
Super Genie
The following screenshot illustrates the Super Genie for the 2 pumps cycle
management:
The following screenshot illustrates the Super Genie for the 3 pumps cycle
management:
It includes the same previous information, but for two principal pumps.
72
3-Design
Once the component creation is done, define your navigation rules to complete the
Design phase.
The pretreatment process is divided into four units: Lifting, Screening, Grease&Sand
Removal and Primary Clarifier. You can access a detailed view of the actuators, such
as motors and digital inputs, by clicking on a unit. Clicking on the equipment leads to
its commands and diagnosis options. On each view, a banner displays the current
alarms. A button enables access to the historical alarms.
73
3-Design
74
4-Configuration
4. Configuration
Here is a sum up of the project‘s progress:
Note: A sg² project can contain several PACs. In the current project, only one
Modicon M340 is configured.
Note: The instantiation of some sg² components is available if a controller has been
previously defined only.
Before configuring anything, you must consider the project hypothesis regarding the
hardware configuration.
CPU P342020
75
4-Configuration
The first step is to define the hardware configuration in Unity Pro, if it does not exist in
the sg² libraries.
The hardware configuration of the wastewater plant includes a Modicon M340 and a
NOE Ethernet module. This hardware configuration is not included in the sg² library.
• Pick up a new PAC configuration from the sg² template list. In this case, the Unity
project starts from scratch.
• Create a new PAC configuration from a customized sg² template. This template
comes from a Unity Pro .xef file. The template import is done from the SGStudio
Workbench menu, then Destination Template and Import.
• Start directly from a .stu or a .xef file, then add more features or update it with sg²
without modify the original code.
76
4-Configuration
The following table shows how to import a hardware configuration from Unity Pro to
sg²:
Step Action
1 Create the material configuration according to the application requirements. Here, the
topology is based on Ethernet, so a NOE module must be implemented to get the I/O
Scanning and Address Server services.
2 Create the network configuration. Validate the I\O Scanning and the Address Server
services of the Ethernet NOE module.
77
4-Configuration
5 Import this template in SGStudio Workbench by clicking Destination Template -> Import.
The template is now available, and you can access the configuration of the M340 + NOE
module through SGStudio Workbench.
78
4-Configuration
The second step, after loading the hardware template in SGStudio Workbench,
consists of the Vijeo Citect server’s configuration.
Step Action
2 Right click on sg2 Systems, and then select Create sg2 System.
Note: you can also link and update an existing Vijeo Citect project by clicking on the Link sg2
system choice. Once linked, this one is managed from sg² Framework.
79
4-Configuration
3 Name the project, and then select the sg2_blank2.ctz as the sg² Template, which is automatically
created during sg² installation.
The sg2_blank2 template includes the SGC_Include2 project with the following features:
->sg² Symbols
->sg² Genies
->sg² Pages
->sg² Cicode
->sgc_devices.dbf file: texts and formats management of the sg² devices screens (ATV, ATS, TeSys U
and so on)
4 You can see the project previously created by clicking on the Vijeo Citect Explorer button:
80
4-Configuration
81
4-Configuration
The final configuration step involves adjusting and establishing the communication
between the PAC and the SCADA system.
The OFS server (OPC Factory Server) is used to make Vijeo Citect communicates
with the M340 PAC, according the following diagram:
The .XVM file establishes the link between the non-located variables of the next Unity
Pro program and Vijeo Citect.
We recommend to use the .XVM file as the symbol file, by this way:
• It is not mandatory to have Unity Pro installed on the machine running OFS,
Unity Pro allows you to generate and consequently update the .XVM file during a
program download (PC to PLC) or Build Changes. Click the Project autosaving on
download in the Unity Pro Project Settings, as follows:
82
4-Configuration
Step Action
1 Start the OFS configuration tool. In the sg² Framework toolbar, click on the quick launch
button for OFS:
You must use the same alias name (here, M340) for the definition of the supervision channel
in sg² Framework. Please refer to the implementation chapter, sg² Framework paragraph.
The .XVM file path is specified in the implementation phase when the new Unity Pro
application is generated.
3 Save the configuration and then quit the OFS configuration tool.
83
4-Configuration
An ODBC installation must be configured to establish the link between Vijeo Citect
and the parameters.mdb sg² file. This file is in the Vijeo Citect folder of the Water
application.
Create a new ODBC link, in Microsoft Access Drive type, following this path:
84
5-Implementation
5. Implementation
The Unity Pro and Vijeo Citect projects have been created during the configuration
phase. The wastewater project must be finalized with the generation and the
completion of all the applications. Consequently, this chapter describes the final
adjustments to finalize the project application in terms of:
• Finalization with OFS to allow the communication with the unlocated variable of
the Unity Pro application,
• Developments with sg² Framework leading to the generation of the Vijeo Citect
tags,
85
5-Implementation
The first step in the implementation is to generate the Unity application with SGStudio
Workbench.
86
5-Implementation
SGStudio Workbench can be launched either from the Windows start menu or from
sg2 Framework. This option offers you to interact with others software programs
(Vijeo Citect) and management system (OFS). Consequently, we recommend this
way.
This section describes how to create a project with SGStudio Workbench, which
leads to the Unity application creation.
Launch sg² Workbench, and then create the water project project.
You can select different sg² libraries used in our project such as Diagnosis,
Communication, Device & Process, as well as the user library (creation of PCYCLE
component for pumping management).
87
5-Implementation
In SGStudio Workbench, click New from the Controllers tab, and then select the
template previously defined (CPUM340+NOE110):
Note: since the NOE module was successfully added in the Unity hardware
configuration, the sg² Ethernet devices are available. Otherwise, they appear in
grayed out, as follows:
Before the controller was added After the controller was added
88
5-Implementation
5.1.3. Instantiation
Note: the multiple instantiation option allows for faster instances creation.
Note: we recommend to use the same names between the devices and the process
instances, such as the drives and motors for example. This automatically places
these two objects in the same program section. Then, sg² creates the unique object’s
variables for each element.
89
5-Implementation
Simple Instantiation
We recommend to use the simple instantiation when the component appears once in
the project.
The following table shows the instantiation of the CVALVE component (unique in the
project) for the analogical valve Gs1Vlv2:
Step Action
1 Select the CVALVE component in the Process library, and then double click.
2 The General Options pop-up window appears. Name your corresponding instance, here
Gs1Vlv2, and then click OK.
90
5-Implementation
3 The ASPECT Control Window appears. In the Properties tab, adjust your object’s
parameters. The example below shows 0-32000 as the value for the configuration of the
Advantys STB:
Note: The user can also modify other properties, such as ranges, alarm time, engineering
units, time watch, thresholds, format and so on.
91
5-Implementation
• The difference between the instance’s names of this component is only the final
index.
The following table shows the instantiation of the Ethernet ATV61 Drive component
for the pumps Lf1PmpDX (three occurrences in the project):
Step Action
1 Select the Ethernet ATV61 Drive component in the Devices library, and then double
click.
2 The General Options pop-up window appears. Fill in the Object Names box with the
selected name, here Lf1PmpD. Then choose the instance number (Quantity box), the
start index (Start box) and the index form (Minimum Width box), and then click OK.
92
5-Implementation
3 The Aspect CONTROL window displays. In the Properties tab, add the character %n to
the Ethernet.REFRESH_IO_, which corresponds to the ATV position in the I\O scanning
configuration included in the CONTROLLER.
4 Click OK to complete the object creation. The three objects appear as follows:
Note: The user can customize the objects properties, or just refine one of them.
93
5-Implementation
We recommend to use this kind of multiple instantiation if the same component needs
to be deployed in the project. You can then configure the digital inputs and customize
them before the import.
Note: this method allows the user to directly edit its .csv files from a spreadsheet,
without sg² being installed on the PC.
This method consists of creating the first component’s instance and then exporting it
to the .csv file. You can then edit the .csv file to add modifications and import it in sg²
to include new instances.
The following table explains how to make the multiple instantiation, using the
Lf1PmpD1 motor as the instance’s source:
Step Action
1 Select the Speed Drive Motors\ With Interlocks, Failures, Maintenances, & Devices
(variable speed) component in the process library, then double click.
2 The General Options pop-up window appears. Fill in the Object Names box as desired.
94
5-Implementation
3 The Aspect CONTROL window appears. As previously discussed, you can customize your
object with the Properties tab.
95
5-Implementation
4 In the Interfaces tab, check the connection, here with the speed drive. Then click OK to complete
the object creation.
5 Export the object. Right click on the motor’s instance, and then Export Object/s.
6 Save the .csv file and then select Generate and Open Files to edit. In the following example of
edits, 2 motors (Lf1PmpD2 and L1PmpD3) are added.
2) Modify the instance’s name (Object column), object’s name for Vijeo Citect (VC- Control column)
and associated speed drive’s name (DEWS column) fields, thus change the others properties
individually.
96
5-Implementation
7 Import the .csv file. In SGStudio Workbench Project window, click on the Objects tab. Right click
on the main project node, select Import object\s, and then open the .csv file.
A popup message displays to notify you that the Lf1PmpD1 already exists. If you did not modify the
Lf1PmpD1 object in the .csv file, click on Skip. Note that you can avoid this message by deleting
the line of the Lf1PmpD1 object in the .csv file.
9 The motors (associated to their own drives) are not created. A report of the import is shown below,
and all the objects of .csv files are in the SGStudio Workbench Project.
97
5-Implementation
From the components list defined in the Design chapter, the following screenshot
shows all the instantiated components of the application:
98
5-Implementation
sg² generates Unity Pro sections. Consequently, you can easily organize the project
sections by dragging & dropping. Click on the Controller tab, and then on the
Programs sub-tab to view the sections structure.
Note: sg² can automatically sort components according rules. For more information,
please refer to the sg² Documentation.
1: This case shows an automatic organization. The three components have the same
name, ‘Gs1Mot1’, so sg² automatically sorts them together.
2: This case shows a manual organization. The two components dedicated to the
Modbus serial communication are placed together by a drag and drop action. The
section is renamed regarding the common feature of the components, thus
ModbusGateway.
99
5-Implementation
From the Controller tab and the Tables sub-tab, you can see the animation tables as
they will be organized during the Unity Pro project generation.
As for all the sections, you can customize the organization of the future animation
tables for the Unity Pro application by using a drag and drop action.
From the Controller tab and the Screens sub-tab, you can see the operator screens
as they will be organized during the Unity Pro project generation.
As for all the sections, you can customize the organization of the future operator
screens for the Unity Pro application by using a drag & drop action.
Once you organize the future Unity Pro sections, you can generate the Unity Pro
project from SGStudio Workbench. From the Controllers tab, click on Generate
Unity:
You can now open the project from SGStudio Workbench. In the Controllers tab,
click on the Open button:
Note: Clicking on the Open button generates the Unity Pro project, if it is not already
done.
100
5-Implementation
Note: To finalize the Unity Pro project in terms of sequential, gateway, messages and
so on, please refer to Unity Pro and Vijeo Citect Finalization section of this current
chapter.
ETG100
The ETG 100 instance of the Ethernet Modbus Gateway component and the EPortM
instance of the Ethernet Port M340 component are manually put in the same section
from SGStudio Workbench. (see section paragraph of this current chapter)
• Sections
Note: an EPortM_EWorkMemory DDT variable is on the two DFBs. This is the link
between the two DFBs.
101
5-Implementation
• Animation Tables
• Operator Screens
102
5-Implementation
ATV61
The LfPmpD1 instance of the Ethernet ATV61 component (Speed Drive Motors With
Interlocks Failures, Maintenance and Device).
These two objects are automatically put in the same section due to the same
instances names. Refer to instantiation paragraph of this chapter for more details.
Note: The whole content of the section is not shown in this manual.
• Section
The following screenshot shows what is generated by SGStudio Workbench for the
Ethernet ATV61 LfPmpD1 component:
103
5-Implementation
And the following is what is generated by SGStudio Workbench for the whole
Lf1PmpD1 motor control:
Detected
Failures
Maintenance
Motor
Interlocks
You can see the additional components surrounding the motor: Interlocks, Failures,
Maintenance.
104
5-Implementation
If you focus specifically on the Motor component, the automatic generated links with
Ethernet ATV61 are highlighted:
105
5-Implementation
• Animation table
The following screenshots show the animation tables, motor and ATV61 respectively:
106
5-Implementation
• Operator Screen
107
5-Implementation
Before transferring the application to the PAC, the compilation (Unity Pro build) is
required.
We proceed as follows:
Step Action
108
5-Implementation
2 Define the I/O Scanning of the NOE module to communicate with the Ethernet equipment.
Below is the occupation memory table of the equipment in the I/O scanning of the NOE
module:
Note: The sg² components linked to the Modbus serial via the ETG100 are not mapped in
the I/O scanning. Only the peripherals listed above are present.
109
5-Implementation
Thanks to the previously defined table, we define the I/O scanning in Unity Pro. Each line
corresponds to a device.
Note: The repetitive rate (ms) duration corresponds to the Unity Pro Mast task periodic
duration.
Note: In order to be able to link the sg² objects with the Ethernet network, you need to map
one line per device. Therefore and due to the topology, some IP addresses are scanned
many times.
Note: When Unity Pro is about to transfer the program in the PAC, it generates the .XVM.
This file allows to parameterize OFS.
110
5-Implementation
5.2. OFS
You can now begin the second step of the implementation phase, which is related to
the communication.
As defined in the previous paragraph, the .XVM file allows to parameterize OFS. This
file is mandatory for Vijeo Citect to communicate with the non-located variables
included in the Unity Pro application.
Step Action
1 Start the OFS configuration tool by clicking on the OFS quick launch button in the sg² Framework
window, as shown:
111
5-Implementation
2 Indicate the path of the previously defined .XVM in the Symbol table file:
3 You can adjust the communication parameters to optimize the communication between Vijeo Citect
and the PAC:
112
5-Implementation
sg² Framework is at the core of the third step in the implementation phase.
The .stu file is generated by SGStudio Workbench. (Please refer to Unity Generation
section of this chapter). To generate the Vijeo Citect tags, you must configure an I/O
device in sg² Framework, following this method:
Step Action
Fill in the mandatory boxes (marked with *), and then save the modifications.
The Unity Project parameter must point to the previously generated .STU file. sg² Framework uses
the .STU file as a source file to automatically create the Vijeo Citect tags.
113
5-Implementation
Fill in the mandatory boxes (marked with *), and then save the modifications.
We recommend keeping the default values and then saving the modifications.
Note: The OPC Alias corresponds to the equipment name in OFS. This name must be identical in
Vijeo Citect and in OFS so that Vijeo Citect knows which equipment to request in OFS.
Deploy Supervision Services tree, right click on I/O Devices then New,
114
5-Implementation
Fill in the mandatory boxes (marked with *), and then save the modifications.
Note: The Supervision Channel box corresponds to the previously created equipment.
4 sg² Framework can now generate Tags of the Vijeo Citect configuration.
115
5-Implementation
sg² Framework generates the Vijeo Citect tags for one PAC at a time.
To do this generation, you must specify the Unity Pro project source by following the
method described in this table:
Step Action
Right click on the M340 PAC (included in the Controllers section) in the sg² Framework
configuration screen, and then click Activate:
116
5-Implementation
2 Synchronize Unity Pro and Vijeo Citect. You can use one of the following two ways:
Or click on the Manual Generation button from the sg² toolbar, which you can access from
the System Tray icon of the taskbar.
117
5-Implementation
3 Customize the tags and the messages associated with the data.
sg² generates the database of the tags and messages, and displays it in a spreadsheet for
potential modifications.
The Generate states can be modified, and the modifications are taken into account in the
next generation.
The UIM tab displays the Interlocks and detected faults (associated to sg² Components)
messages. These messages can be defined directly in the UIM tab and/or in Unity Pro during
the finalization phase. Nevertheless, the message’s modifications done in Unity Pro have
priority.
Note: To avoid the loss of data in the message modifications, it is recommended not to blend
the two previous ways, that is, make your desired modifications either with Unity Pro or with
the UIM tab.
118
5-Implementation
4 Proceed to the final generation of the messages and tags for Vijeo Citect.
Note: All the tags generated by sg² Framework are in the ‘Linked’ type in Vijeo Citect. A
Linked tag indicates a link with an external data source. Consequently, it cannot be modified
in Vijeo Citect, only by sg².
When sg² generates a database, it always replaces the earlier one to create a new .dbf file.
That is, if a component is deleted in the Unity Project, it is not included in the external
database generated by sg² Framework, and therefore the Vijeo Citect database is
automatically updated and reloaded.
119
5-Implementation
• OFS is configured to manage the communication between Vijeo Citect and the
M340 PAC,
• The messages and tags are generated in the Vijeo Citect project.
You can now begin the fourth implementation step, the finalization of the Unity Pro
and Vijeo Citect applications.
In Unity Pro:
In Vijeo Citect:
120
5-Implementation
Before working on Unity Pro and Vijeo Citect, you must update the Vijeo Citect
database with SGS Guardian, following this methodology:
Step Action
1 You must activate the project and thus launch the Unity Pro application from sg²
Framework
Note: In the System Tray, the icon displays the Activated/Deactivated state of SGS
Guardian as blue or red.
3 Once SGS Guardian is activated, the Vijeo Citect database is updated with the
modifications in the Unity Pro project.
121
5-Implementation
The following paragraphs explain the final developments in Unity Pro, in terms of:
gateway, sequential, interlocks and user variables.
Note: As discussed earlier in the chapter, in order for SGS Guardian to update the
Vijeo Citect Database according to the Unity Pro modifications, you must launch the
Unity Pro project from sg² Framework by clicking on the Active Project button.
Gateway
To communicate with the Modbus serial equipment via Ethernet, an ETG100 gateway
is required. The IP address of this gateway must be configured in Unity Pro as follows:
Note: The IP address syntax only applies to a NOE module on a M340 PAC. Refer to
the documentation of the sg² component Modbus serial-Ethernet Gateway for the
different syntaxes regarding the PAC configuration.
122
5-Implementation
Sequential
Step Action
1 Type the step description for the display in the Sequential Control component:
3 Type the parameter text of the sequential in the Comment textbox of the following variables:
« STATION_SEQPAR05_ST.IP04 » : “Free”
« STATION_SEQPAR05_ST.IP05 » : “Free”
123
5-Implementation
Messages
sg² uses the Vijeo Citect supervision to display the default and interlock conditions of
the different actuators. You must therefore first instantiate these elements with a
default management (CONDSUM) and/or interlocks (CONDSUM1).
Step Action
Lf1PmpD1 is shown in the below screenshot as an example. Edit the DFB instance
Lf1PmpD1_FC_CONDSUM.
We recommend to type the comment text regarding the default connected in the DFB input.
Note: for the messages on the Interlock conditions, apply the same rule.
124
5-Implementation
2 Before the build, verify that SGS Guardian is activated, as this automatically generates the
messages in Vijeo Citect.
3 Once the build completes, SGS Guardian automatically steps in to generate the export of the
Unity Pro variables. The following popup appears once the export completes:
Click See Changes to display the table describing all the created, modified and deleted
messages and tags. If necessary, make any desired modifications.
Note: You do not need to stop/restart the Vijeo Citect application to account for these
new messages.
User Variables
SGS guardian not only generates the sg² component variables modified, but also the
variables that you created in Unity Pro. The following table shows an example of a
Boolean (HMI_CLEAR_FAULT).; we use this variable to do the acquaintance of the
detected defaults.
Step Action
Click Generate.
Note: sg² stores the Generate states, so you do not need to define this variable again before future
generations.
125
5-Implementation
The following paragraphs explain the final developments in Vijeo Citect, in terms of
access level and flowchart.
Access Level
Before creating the access level, you must consider the following privileges. The sg²
column indicates the levels with which the component button are created in sg². As
defined in the selection chapter, the crosses indicate the choices.
Alarms
× × × 1
acknowledgement
Enable/ Disable
× × × 3
First-level Alarms
Change of owner
× × 4
(Operator/ Program)
Changes of the
× 5
parameters
Enable/ Disable
× 5
Second-level Alarms
Interlock Bypassing × 5
Enable/ Disable
× 5
the simulation mode
126
5-Implementation
The following table explains you how to create the users profiles:
Step Action
The following screenshot shows the Operator profile, with the fields for levels 1 to 3
completed:
127
5-Implementation
128
5-Implementation
Control Views
Home
• General view
Lifting
Screening
Grease&Sand
Clarifier
• Network
• Electric
The home view is the start page of the Water Vijeo Citect application, which is
configured in the following path: tools -> project editor -> tools -> computer setup
wizard.
129
5-Implementation
Step Action
1 Create a new graphic page from the sg²_style template through the following path: file->new-
> template. Name it lifting.
3 Instantiate the sg² Genies. The libraries of the sg² Genies are marked with a sgc_ prefix.
130
5-Implementation
Illustrated here are the Lf1PmpD1 pump, the associated drive, and the corresponding object that is
dedicated to pump cycle management.
1) Press F11, and then select the sgc_rcpump_10 Genie (Speed Driven Centrifuge Pump) of the
sgc_sddevctl library.
Genie parameters:
Use the menu to specify the Control Module name, here Lf1PmpD1.
Note: Due to the sg² filter, only the corresponding instances display.
Set the Area: specify the zone number, here 1, for the object. You must type a zone number >0 and
<255.
131
5-Implementation
132
5-Implementation
3) You can now add the component of the pump cycle management.
Parameter component:
133
5-Implementation
Complete the instantiation of all the necessary components on the graphic view, as follows:
This button sets the HMI_CLEAR_.FAULT bit previously created (Input tab). The PAC performs the bit
reset.
134
5-Implementation
Entering 1 as a privilege level forces the operator to be connected to acquaint the current alarms.
1) Text
All the instantiated sg² Genies of the Lifting view have an associated text marking them.
The call function PageGetInt() is completed on the Appearance properties tab. This function reads a
135
5-Implementation
Refer to the sg² documentation for more information about the PageGetInt () function.
A shortcut to the PageDown key, linked to a script, exists on the Lifting Properties page to allow you to
change the value of the Page-Based Variable.
Refer to the sg² documentation to have more information about the PageSetInt () function.
136
5-Implementation
2) Devices
Select the 5 instances of the Lifting view (2ATS and 3ATV), and the group them.
This functioning mode is common to the 4 views (Lifting, Screening, Grease&Sand and Clarifier).
137
5-Implementation
Parameters
To access to the parameters from Vijeo Citect, the sg² Genie sgc_parameter_30 of
the sgc_param library is located on the project’s GeneralView view.
3
• Minimum inlet Flow to start Lifting Pump (m /h) – Min Max [0…100]
3
• MinFlow_Lf1PmpR for Minimum inlet Flow to start Lifting Pump (m /h)
• Winter parameters
• Summer parameters
To implement these parameters, edit the C:\Schneider Application\ Vijeo Citect\ User\
WaterProject\ parameters.mdb file with Microsoft Access.
• Definitions
• Enums
• ParametersList
Note: The Enums table is used to implement the predefined parameters values via a
menu.
138
5-Implementation
The incremental management of the project is the final step of the implementation
phase. The goal of the incremental implementation is to update the whole project.
• You must add new components in the project. In this case, the incremental
implementation is done trough three steps: SGStudio Workbench, OFS and sg²
Framework.
• The components you want to add already exist. In this case, you can duplicate
them using a copy/paste method.
139
5-Implementation
SGStudio Workbench
Using SGStudio Workbench is the first step to adding new components in the Unity
Pro sections of the project. Follow the method below:
Step Action
2 Select the .stu file of the WaterProject to be updated by clicking Add, and then open.
4 These steps are the same as for a newly created project. See the first paragraph of this
chapter.
OFS
In OFS, you must point to the new project, as follows: modify the path of the symbol
file that must point to the XVM file of the new Unity Pro project generated by the
following new sg² project STG_WATER_M340_V1_1.
If the XVM file is not already created, do an export of variables of the new Unity Pro
project.
140
5-Implementation
Sg² Framework
To generate the Vijeo Citect tags with sg² Framework, modify the .stu source file. This
file must point to the new sg² project, that is, STG_WATER_M340_V1_1, as follows:
Note: We recommend you to do a backup of the Vijeo Citect project before this
generation.
141
5-Implementation
If the component type already exists, you can directly add a new component to a
Unity Pro program without going through an incremental implementation, as follows:
Step Action
3 Launch the generation from sg² Framework to create the new tags in Vijeo Citect.
142
6-Operation
6. Operation
This chapter provides a methodology for operating application. It presents the content
in terms of navigation rules, alarms management, and trends performing.
6.1.1. Home
Once the application is launched, the system opens a home page, which situates the
project in a whole water treatment plant:
A simple click on the home page leads to the general view, which displays the project
and its four pretreatment units:
A navigation toolbar is located on the top of the screen, and a display dedicated to the
alarms is located on the bottom. The current date and time are displayed on the
bottom right corner.
143
6-Operation
6.1.2. Navigation
The navigation takes place through a graphic environment. Once the system runs, a
screen displays the complete installation. You can click on the four following main
units: Lifting, Screening, Grease & Sand Removal and Primary Clarifier. The mouse
pointer highlights them with a square. Clicking on the desired unit displays the
equipment included in the unit and then each control module related to the equipment.
The goal is to make the navigation intuitive: unit-> element-> equipment-> control
module…The following screenshots shows the navigation sequence for accessing the
control panel of the linked Super Genies that manage the Lf1PmpD2 pump in the
Lifting. unit:
144
6-Operation
145
6-Operation
146
6-Operation
For more information about their utilization, please refer to sg² documentation.
6.1.4. Alarms
The bottom of the home page is dedicated to the standard alarms display. At the
center, a screen displays the current alarms. On the left corner, five icons allow you to
manage the alarms display with a simple click:
147
6-Operation
6.1.5. Trends
The trends menu is available on the main navigation toolbar. It permits you to
represent the trends of values through a graphic tool. You can access this graphic
trend tool by directly clicking on the Trends button.
This tool has two tool panels: data and graphic management.
the data as a .dbf file. to show a panel that enables navigation through
the graphic representation.
148
Schneider Electric Industries SAS
Head Office Due to evolution of standards and equipment, characteristics indicated in texts and images
89, bd Franklin Roosvelt in this document are binding only after confirmation by our departments.
92506 Rueil-Malmaison Cedex
FRANCE
Print:
www.schneider-electric.com