EcoStruxure Control Expert V15.1 Guide
EcoStruxure Control Expert V15.1 Guide
EcoStruxure Control
Expert
V15.1 - BASIC CONFIGURATION - 1
MARIANA GOMEZ
Internal
Content
Introduction. 12
Objectives ................................................................................................................................................. 12
Generalitys ......................................................................................................................................... 12
What is EcoStruxure Control Expert?. 12
Overview of EcoStruxure Control Expert. 12
Four different sizes. 13
What is EcoStruxure Control Expert?. 14
Supported drivers. 15
Modicon M340. 15
Modicon M580 and M580 Safety. 16
Modicon Premium. 17
Modicon Quantum. 17
Modicon Momentum. 17
Bus architectures. 19
Licensingo ........................................................................................................................................ 20
Easy and secure licensing systemo ............................................................................................ 20
License activation methods. 20
How does floating licensing work?? ...................................................................................... 20
EcoStruxure Control Expert References. 21
How to register the software?. 21
Standard programming languages. 22
Standard IEC Languages. 22
Effective Supervision of the Plant. 22
EcoStruxure Control Expert Functions. 22
Use of EcoStruxure Control Expert. 23
Forget about the Hardware while you develop.. 23
Simulations. 23
EcoStruxure Control Expert Interface. 24
Graphical User Interface. 24
How to start EcoStruxure Control Expert. 25
Methods of using the interface. 25
Exercise– Examine the user interface. 26
Internal
Summary. 29
Questions. 29
Driver programming. 30
Objectives ................................................................................................................................................. 30
Standardized programming of controllers. 31
The programming languages of IEC 61131-3. 31
Exercise– See examples of programs.... 32
Creation of new projects. 35
Overview of the project for the workshop.. 35
First step in the configuration. 36
How to create a new project. 36
Exercise– Create a new project.. 37
Language editors. 39
Common tools. 39
Palette. 39
Context menu. 39
Unlimited quantity and extent of comments. 40
Data input functions. 40
Standard editing functions. 40
Bookmarks. 40
Tareas...................................................................................................................................................... 41
Types of taskss.................................................................................................................................... 41
Master. 41
Fast. 42
Auxiliary. 42
I/O and Timer Eventss ...................................................................................................................... 42
Sections. 43
Organization of Programs. 43
Autonomous Entitiess......................................................................................................................... 43
Subroutines. 44
Exercise– Create a section. 45
Elementary functions. 46
Included functionss ............................................................................................................................. 46
Internal
AND Function. 47
Function OR.......................................................................................................................................... 47
More basic functions. 47
Exercise– Use a function block. 48
Variables. 51
Localized variables. 51
Localized variables (cont.). 52
Variables not locateds ...................................................................................................................... 52
Variable Naming Conventionss ............................................................................................ 52
Data Types I/O ................................................................................................................................ 53
Data types of Device (DDT). 53
Exercise– Variables. 54
Exercise– link functions. 56
Summary. 57
Questions. 57
Test a projecto ..................................................................................................................................... 58
Objectives ................................................................................................................................................. 58
Analyze and Generate a project. 58
Analysis. 58
How to analyze a projecto ................................................................................................................. 58
Exit window. 58
Generate a project. 59
How to generate a projecto ................................................................................................................. 59
Internal
Probar la lógica de un programa......................................................................................................... 64
Working with animation tablesn....................................................................................................... 64
Exercise– Create an Animation Table. 65
Exercise– Working with animation tables. 66
Resumen ................................................................................................................................................. 68
Questions. 68
Project managements .................................................................................................................................. 69
Objectives ................................................................................................................................................. 69
Project File Types. 69
File types. 69
Documents .STU. 69
Documents .STA. 69
Documents .XEF. 70
Documents .ZEF. 70
Exported project components. 70
Exported project components– Extensions. 70
Export of projects. 71
Useful for scaling............................................................................................................................. 71
Content of the fileo ......................................................................................................................... 71
How to export a project. 71
Exercise– Export a project. 72
Import projects ................................................................................................................................. 73
Scale projects. 73
Import protected elements.. 73
Import Operator Screens. 73
How to import a project. 73
Exercise– Import projects. 74
Archive projects .................................................................................................................................. 75
Save the compiled project. 75
Properties of a Fileo ................................................................................................................. 75
How to create a file. 75
Exercise– Archiving projects with EcoStruxure Control Expert. 76
Project Explorer. 78
Internal
Deploy the contents of a project. 78
Structural view. 78
Project directory. 78
How to rename the project directory. 78
Exercise– The project tree. 79
Functional view. 80
Functional module. 80
How to switch between views. 80
Exercise– Change views. 81
Resumen ................................................................................................................................................. 82
Questions. 82
Ladder Language. 83
Objectives ................................................................................................................................................. 83
Ladder Diagram Language. 83
Introduction. 83
Ladder Diagram Links. 84
Priorities when defining the flow of the ladder diagram.... 84
Programming Window. 85
Properties of the LD window. 85
LD Tool Palette. 85
Ladder Diagram Contacts. 86
Scales Diagram Coilsa .......................................................................................................... 87
Functions of the Ladder Editor. 88
Flexible column width. 88
Adjustable font sizess ............................................................................................................ 88
Copy, paste, and delete columns and rowss ........................................................................................... 88
Copy and paste variables. 88
Mnemonic LD. 89
Insert functions. 89
Quick access to standard features. 90
Customization of LD color. 90
Exercise– Create a new Ladder section.. 91
Summary. 98
Internal
Questions. 98
Function Block Languagen ................................................................................................................. 99
Objective. 99
Function Block Diagram Language. 100
Introduction. 100
Programming window. 101
Properties of the FBD window. 101
FBD tool palette. 101
Exerciseo............................................................................................................................................. 102
Comments. 103
Why use comments?. 103
How to add a comment. 104
How to show/hide comments ................................................................................................. 104
Exercise - Comments. 105
Execution sequence. 106
Adjustable font sizess .......................................................................................................... 106
Add favorite functionss ................................................................................................................ 106
Show and hide comments. 107
Color customization of FBDs. 107
Exercise– Execution sequence.................................................................................................... 108
Exercise– Connect the functions. 111
Exercise– Complete the FBD.. 112
Summary. 114
Questions .............................................................................................................................................. 114
Function Blocks. 115
Objectives ............................................................................................................................................... 115
Bloques de Función Elemental.............................................................................................................. 115
Internal States. 115
Representation of an EFB. 116
Failure Processing and Counters................................................................................................. 117
Why use fault processing?. 117
Current status of the program. 117
Manejo de Excepciones .................................................................................................................... 117
Internal
Logical design. 117
Exercise - Fault Processing. 118
Derived Function Blocks (DFB) .................................................................................................... 120
Function blocks used as templates. 120
Structure. 120
Advantages of DFBs ......................................................................................................................... 121
Exercise– Create a derived function block.. 122
Exercise– Use the DFB Liquid Pump block.. 126
Exercise– Test and detail the DFB ................................................................................................... 127
Exercise– Renumber the Piness ........................................................................................................ 128
User Derived Data Types and Function Blocksn .................................................................. 129
Derived Data Types (DDT))......................................................................................................... 129
EcoStruxure Control Expert EFB Toolkit. 129
Summary. 130
Questions. 130
Structured Text Languageo ............................................................................................................... 131
Objectives ............................................................................................................................................... 131
Structured Text Language. 132
Introduction to Structured Text. 132
Texto estructurado............................................................................................................................ 133
Blank spaceso ............................................................................................................................ 134
Equal signs. 135
Expressions. 136
Text operatorso ......................................................................................................................... 137
Programming Window. 138
Window properties. 138
Tool palette. 138
ST Expressions. 139
ST operators. 139
Operands ST.................................................................................................................................... 140
ST Instructions. 140
Exercise– Create a new Section ST............................................................................................. 141
Summary. 143
Internal
Questions. 143
Instruction List Language. 144
Objectives ............................................................................................................................................... 144
Instruction List Language. 145
List of Instructions. 145
Scheduling Window. 147
Properties of the window. 147
Instruction palette. 147
Instructions IL. 148
IL Operators. 148
Operands IL ..................................................................................................................................... 148
IL Modifiers. 149
Exercise– Create a new section IL .................................................................................................. 150
Summary. 151
Questions. 151
Operator screens. 152
Objectives ............................................................................................................................................... 152
Dynamically Monitor Processes. 152
Provide a set of information.. 152
Online modea ................................................................................................................................... 153
Graphic Screena..................................................................................................................................... 153
Operator Screens. 153
Toolbars. 153
Design Operator Screens. 154
Standard Graphic Techniques. 154
How to Create an Operator Screen. 154
Exercise– Create an Operated Screenr...................................................................................... 154
Exercise– Add Text as Labels. 155
Exercise– Push Button Controls. 157
Exercise– Add Failure Tests ................................................................................................... 160
Exercise– Display Text in the Runtime. 161
Exercise– Test the logic of the pump.. 163
Resumen ............................................................................................................................................... 164
Internal
Questions. 164
Sequential function diagram. 165
Objectives ............................................................................................................................................... 165
SFC Sections. 165
Size of the sections. 165
Exercise - SFC Sections. 166
SF EditorC ......................................................................................................................................... 170
Components. 170
Test Sequences. 170
Toolbars. 170
Structure of an SF SectionC.......................................................................................................... 171
Exercise– Create the first step.. 172
Times of Steps. 172
Times of Steps. 172
Minimum Supervision Time. 173
Maximum supervision time........................................................................................................ 173
Delay Time. 173
Exercise– Step times. 174
Actions ................................................................................................................................................ 175
Instruction Game. 175
Descriptors ...................................................................................................................................... 175
Exercise– Actions. 176
Exercise– Comments. 178
Transitions. 180
Verify the condition.... 180
Exercise– Transitions ..................................................................................................................... 181
Ejercicio – Add steps to the transitions.. 182
Exercise– Add a jump. 186
Exercise– Animation in SFC language. 188
Summary. 191
Questions. 191
Communication to the controller. 192
Objectives ............................................................................................................................................... 192
10
Internal
Communication drivers. 192
Installation Page - Communication Driversn .............................................................................. 192
Connection Mode. 193
Switch to Standard Mode. 193
Configure a USB port. 193
Exercise– Configure the USB port.. 194
Ethernet Networks. 196
Ethernet Configurationt..................................................................................................................... 196
Embedded Ethernet M580. 196
Ethernet Configuration M580– Directions IP ................................................................................ 197
Ethernet configuration of other controllerss ............................................................................... 198
Map the module. 198
Create a Link in a named network. 198
Configure a Link. 199
Add the link. 201
Exercise– Ethernet Port Configuration M580. 201
Cybersecurity with EcoStruxure Control Expert. 202
Introduction to Cybersecurity– What is Cybersecurity?. 202
Cybersecurity and EcoStruxure Control Expert. 202
Cybersecurity with M580................................................................................................................. 202
Security services. 203
Cybersecurity Audits (Event Storage) .......................................................... 204
Event Storage Functionality. 204
Syslog with EcoStruxure Control Expert. 205
Syslog Originators. 205
Enable the Syslo clientg .................................................................................................................. 205
Summary. 206
Questions. 206
11
Internal
Introduction
Objectives
By the end of this chapter you will be able to:
Generalities
What is EcoStruxure Control Expert?
EcoStruxure Control Expert (formerly Unity Pro) is a common programming platform for seven
specialized hardware: Modicon M340, M580, Atrium, Momentum, Premium, and Quantum.
12
Internal
• EcoStruxure Control Expert Safety Addon (offer to extend an existing XL version)
EcoStruxure Control Expert provides all the tools required for the complete life cycle of
your systems: Design, Commissioning, Operation, and Maintenance.
The software is available for different numbers of users ranging from a single user to everyone.
the employees of a site.
The main difference between editions is the supported references of families and models of
drivers.
The following table is used to determine which version of EcoStruxure Control Expert is required.
13
Internal
What is EcoStruxure Control Expert?
EcoStruxure Control Expert is the common software for programming, commissioning, and operation for
the families of PAC Modicon M340, M580, Momentum, Premium, and Quantum.
Tip:
Support for Modicon M580 and Momentum was added in UnityPro version 8.0.
The support for BME NOC was added in UnityPro version 8.1
IPsec support, CCOTF event storage for local racks and timestamping of variables
internal was added in version 10.0
14
Internal
Supported drivers
Modicon M340
The Modicon M340 is a mid-range controller for industrial processes and infrastructure, which
enables performance with simplicity and integrated features.
With its compact shape, the M340 offers flexibility and services in a small box.
high-end controller. At the heart of the application, it provides easy integration with other devices
from Schneider Electric.
Applications
All-in-one CPU
• 7K inst/ms
• Multitasking system for guaranteed response time
• USB port for programming and HMI
• 2 additional ports as required: Ethernet, CANopen, Modbus
Memory foam
Specific applications
• No batteries required
• Extended temperature (-25°C to 70°C)
• Intellectual property protection of SI and OEMs using SD Card technology
15
Internal
Modicon M580 and M580 Safety
The ePAC Modicon M580 (Ethernet Programmable Automation Controller) is the first controller
based on Ethernet technology and is the significantly improved version of the already present and known in
the PAC Modicon M340 market
The Modicon M580 combines existing controller functions with innovative technologies to
deliver Schneider Electric's first completely Ethernet-based PAC, and offers:
16
Internal
Modicon Premium
The Modicon Premium is a modular controller primarily used for specialized functions and
high-speed manufacturing processes. Premium offers unmatched performance, reducing the
cycle times and avoiding the need for optimization, thanks to the integration of more diagnostics.
Applications
Modicon Quantum
The Modicon Quantum range is designed for a high number of I/Os and complex control of
processes with optional Hot-Standby operation to provide reliability in the processes.
Applications
Modicon Momentum
The Modicon Momentum family is a simple controller that helps increase capacity and
efficiency of old Modicon applications.
This controller can replace an old Modicon controller with minimal wiring work.
programming or can serve as a standalone controller in a distributed network as in a
application of a conveyor or a remote RTU.
The functions of the common core of the new Modicon Momentum Unity family are:
17
Internal
• Embedded real-time clock
• Distributed I/O for 32 slaves
• Improved LEDs
There are 3 different CPUs. The most widespread is the Unity M1E Global Data CPU.
18
Internal
Bus Architectures
For Unity class hardware, a number of communication systems are supported. The following diagram
illustrates the correlation between the families of controllers and the possible communication systems.
Interbus*
Fipio
Unitelway
Client/
Field Bus Serial
Server
19
Internal
Licensing
Easy and secure licensing system
A software license is a document that provides legality using guidelines for use and distribution.
of the software. Software licenses typically grant users the right to one or more copies.
of the software without violating copyright.
Schneider Electric has an easy and secure way to license the software. Using the software License
Manager, it is possible to activate, update, return, and repair licenses for all products. Licenses
blocked by easy-to-use nodes, such as:
• Ability to view and manage all licenses from an account in the Licensing Portal
of Software (SLP). It allows the user to see all active licenses, remaining activations and
who carried them out, etc.…
• Update licenses – upgrade software from one version to a more recent one
• Return licenses - send back a license of a software product to activate it in
otro Servidor de Licencias.
• Repair licenses - restore a software license for later use after this.
being damaged, for example, due to the replacement of hardware components.
• By phone
Or if you only have a phone available and wish to speak with an operator
• Via web
If the PC with the software product to activate has internet access
• Through the web portal
If the PC with the software product to activate does not have internet access.
Requires another PC with internet access to connect to the Licensing Web Portal.
from Software, where you will receive a response XML file
• Via e-mail
or does not require the transaction to be completed immediately. This request may
take some time
20
Internal
Floating Licenses are extremely flexible and customizable:
• The license can be activated on a Local Server, using the same mechanism as a license
Node Locked using the Floating License Manager
• Licenses are used when they are needed from various PCs connected to the corporate server.
of licenses using the License Manager
• Disassociated licenses can be taken offline, for example, for the computer of
maintenance for the selected duration. It simply behaves like a
license blocked by node.
The registered software will have an account in the Licensing Portal (SLP) where the user
you can benefit from viewing all your current licenses, remaining activations, active licenses and
many other functions. Having the ability to increase the number of authorized transfers of
licenses between PCs or to repair them.
21
Internal
Standard programming languages
Standard IEC Languages
EcoStruxure Control Expert incluye, como estándar, 5 lenguajes IEC (International Electrotechnical
Commission) that comply with the IEC 61131-3 standard. Depending on the requirements, the
the application can use any mix of these different languages.
Tip:
EcoStruxure Control Expert also includes support for LL984 language. This allows for the editing of
LL984 logics and it is one of the modernization tools available that enable customers to
migrate from old platforms to more modern controllers.
22
Internal
Use of EcoStruxure Control Expert
With EcoStruxure Control Expert, it is possible:
• Reuse and share all or part of an application using the import/export function.
what includes an assistant to name and relocate sections of programs and variables
• Optimize memory usage by changing the settings for data distribution and
programs
• Determine through simple graphs the amount of data and program memory used by
an application
• Determine the energy usage by the hardware configured in each rack, again with
simple graphs to read
• Develop animated runtime graphics for maintenance operators, without the need for
program. These fully integrated HMI screens reduce downtime.
• Embedded hyperlinks in user comments provide direct access to the tools and
documents required by the maintenance technician.
• The implementation of I/Os Réflex (Special smart coprocessor modules) when
they require response times of less than one millisecond.
Simulations
EcoStruxure Control Expert is capable of simulating the operation of the selected controller by
it is possible to run preliminary tests of the programs without the need to be connected to a
controller. In addition, the PLC simulator allows users to test failure conditions without
need to cause failures in the equipment.
23
Internal
EcoStruxure Control Expert Interface
Graphical User Interface
EcoStruxure Control Expert uses a graphical interface. Many of the functions of this interface allow you
They will be familiar to users who have used other Windows programs.
24
Internal
How to start EcoStruxure Control Expert
Select the EcoStruxure Control Expert item from the Windows start menu:
Home >> Programs >> Schneider Electric >> EcoStruxure Control Expert
25
Internal
Exercise - Examine the user interface
Expected results
By the end of this exercise, you will be able to:
b. When installing EcoStruxure Control Expert, three example projects are installed. These
they can be found by clicking the Open button and navigating to the location
next (this is the default location for installations in Microsoft
Windows
C:\Users\Public\Public Documents\Schneider Electric\ EcoStruxure Control Expert
26
Internal
2. Navigate the project tree
a. Open the three sections by clicking on the (+) symbol. Navigate to Variables and
FB instances
b. Double click on the item Basic variables. This opens the Data Editor that displays
all the variables defined in this project
27
Internal
3. Examine the objects in the example project
a. Expand the operator screens block
[Link] a sample operator screen:
[Link] the Project Browser and the toolbar will change back to the bar
navigation original
28
Internal
Summary
In this chapter, the topics were addressed
Questions
The following questions are to check the understanding of the topics addressed in the chapter:
29
Internal
Driver programming
During a period of ten to fifteen years, the programming languages for drivers became
developed independently of each other. The control applications were developed in
their own proprietary languages based on Ladder programming, C, BASIC, and many others. Given
that all these languages were different, the people who needed to use them had to have
a long time to learn each one.
During the early 1990s, the International Electrotechnical Commission (IEC) developed a standard for
all controllers called IEC 61131. In 1993, IEC 61131-3 (part 3) was developed. This part of the
standard has to do with programming languages for drivers.
EcoStruxure Control Expert is capable of using the five standard IEC languages. These are Diagram of
función secuencialy cuatro leguajes interoperables:Lista de instrucciones (IL), Diagrama de Escalera
(LD), Function Block Diagram (FBD) and Structured Text (ST).
Objectives
Al concluir este capítulo podrás:
30
Internal
Standardized controller programming
The programming languages of IEC 61131-3
The International Electrotechnical Commission (IEC) has defined the IEC 61131 standard for controllers.
programmable devices and their peripherals.
The third part of this standard, IEC 61131-3, defines the programming languages in controllers.
programmable (PLC/PAC). Five programming languages have been defined. This means that their syntax
and semantics have been defined in such a way that each vendor uses the same languages. Once that
these languages have been learned it is possible to use a wide variety of systems based on this
standard.
The languages consist of three graphical tools and two text tools:
Graphs:
Texto:
31
Internal
Exercise - See examples of programs
Expected results
By completing this exercise you will be able to:
32
Internal
c. Many sections with different languages will be displayed. Double-click on
Transportation_Belt. This will open the Function Block Diagram in the panel.
right.
Note:
The icon indicates that this is a Function Block Diagram. A blue mark on
An icon indicates that the code section has been modified since the last compilation.
from the project file.
d. Examine the toolbars. Note that when the FBD window is selected
the toolbar under the main bar changes to the FBD Editor
33
Internal
e. Open the Ladder Diagram Start_process:
f. Open and observe the rest of the example Sections to see written examples using
other languages
g. Close this instance of EcoStruxure Control Expert
34
Internal
Creation of new projects
Overview of the project for the workshop
In this course, a project will be created for a PAC. This will be a pasteurization project.
They will program various sections of the project using a variety of programming languages.
IEC 61131 controllers. This will assist students in becoming familiar with the languages.
EcoStruxure Control Expert supports 5 different languages and all can be used within the same one.
project if desired.
A section may be easier to program in one language than another due to the actions.
involved in that section.
This course will develop elements that are part of a pasteurization plant - a diagram of
this plant is observed below.
Upon completing this course, the graphical version of this project will be imported from Citect SCADA to do
a monitoring and control application.
35
Internal
First step in the setup
The first step to setting up EcoStruxure Control Expert is to create a new project. The project is
where all the information is stored
A project must be based on a PLC/PAC and cannot be saved until it has been defined or selected.
a controller. In any case, it is possible to switch to a different controller at a later stage.
advanced.
or else
36
Internal
Exercise - Create a new project
Expected results
After completing this exercise you will be able to:
37
Internal
2. Create a new project (cont.)
a. When the new project opens, it is displayed in the Explorer panel.
Projects
Click on Save
38
Internal
Language editors
Common tools
The editors for each of the five languages provide a number of common tools used
to write, read, and analyze programs in a user-friendly way
The graphic editors for Ladder Diagram (LD), Function Block Diagram (FBD), and the
Sequential Function Chart (SFC) has the following common elements:
• Palette
• Context menu
• Comentarios
• Data input functions
• Standard editing functions
• Bookmarks
Palette
A palette of graphic elements for direct access to various graphic symbols of the language through the
mouse or keyboard.
Context menu
A pop-up contextual menu that can be accessed with a right-click
39
Internal
Unlimited amount and extent of comments
EcoStruxure Control Expert provides an unlimited amount and length of comments. These comments
They can be positioned as text objects in any cell (graphic languages) or at any point
of the expressions (text languages).
Show/Hide
Add comments comments
In graphical language interfaces, comments are always positioned at the back behind everything.
the active objects of the page.
Bookmarks
Placing bookmarks on lines of text or in the margin allows users to easily locate these lines.
in important sections of the program
40
Internal
Tasks
Types of tasks
The first operation that needs to be carried out to create an application program is to define the Tasks.
There are four types of tasks:
• Master
• Fast
• Auxiliary
• I/O and Timer Events
Master
The Master task, usually abbreviated as MAST, is the main controller code for example of the
Training [Link]. This type of task is defined in the project by default under the section
Program.
The sections of the Master task can be programmed in Sequential Function Charts (SFC).
Each of the sections and subroutines that compose it can be programmed in LD, FBD, ST, or IL.
41
Internal
Fast
The Fast task has a higher priority than the Master task. The Fast task interrupts the Master task.
and is used for situations of criticism in time or events, for example, alarms that require
very quick responses.
While the Fast task is running, the execution of the Master task (of lower priority) is suspended.
Once the Fast task is completed, the MAST task continues at the exact point where it was.
interrupted.
Each of the sections and subroutines of the Fast task can be programmed in IL, ST, LD, or FBD.
Auxiliary
Auxiliary tasks are of low priority, such as measurements, process control, diagnostics and
HMI operations. For example, checking the values of a variable that typically changes slowly.
perhaps the water level in a tank.
Auxiliary tasks are only available with the highest Premium and Quantum drivers.
specification. Periodic auxiliary tasks have the lowest priority level and are executed when
The high-priority periodic tasks (Master and Fast) have completed their cycle. Each of the sections and
Subroutines that make up an AUX task can be programmed in IL, ST, LD, or FBD.
These processing tasks are executed with priority over all other tasks. They are therefore
prepared for processing tasks that require a very brief response time in relation
with the event
The number of event processing tasks that can be scheduled depends on the time of
processor.
Events can be programmed either in LD, FBD, IL, or ST language. There are two types of events:
• I/O Events
• Timer Events
42
Internal
Sections
Program Organization
IEC 61131-3 defines programs, function blocks, and functions as Organizational Units
Program (PUs). The functions of a PU enable a wide modularization of user programs.
and reuse of already implemented and tested software modules. At least the declaration of the
an interface is required to allow program modules to access a PU. After its
declaration, a PU is available for all other PUs.
A PAC/PLC project contains PUs that can be sent by the PAC/PLC manufacturer or created.
by the user. User programs can be used to generate tested PU libraries that
They can be used later in new projects. IEC 61131-1 supports this aspect of reuse.
the software stipulating that functions and function blocks must remain 'universal' i.e.
Hardware independent, as much as possible
Autonomous Entities
Tasks are subdivided into Program Units (PU), and each PU contains multiple Sections. The Sections
they are autonomous programming entities, for example, the code block to control a pump
puede ser escrito en una sola sección.
Similarly, all the plant objects (such as valves, the clarifier, and the homogenizer)
they can have written sections to control their functionality. Alternatively, a section
it can contain the control programming for more than one object.
Each section can only have one type of IEC 61131-3 language. However, within the same
it is possible to use more than one language
43
Internal
Subroutines
Subroutines are created as separate units in sections. Subroutines are called from
the sections or from other subroutines
Subroutine calls are made in sections or from another subroutine. Each subroutine is
linked to a task. It cannot be called from sections or subroutines of another task.
44
Internal
Exercise - Create a section
Expected results
After completing this exercise you will be able to
d. This will open the New dialog. Write FBD_Average in the Name field
45
Internal
e. Click on the language selector: select FBD from the list of available languages
Click OK
g. An editing window will open in the right panel. The left panel
it will deploy a new object called FBD_Average
h. To safeguard the project
Note:
The programming language icon is displayed both in the object tree and in the box.
from the programming window menu.
Elementary functions
Included functions
EcoStruxure Control Expert comes with over 900 included functions. These are:
• Elementary functions
• Elementary function blocks
Functions are organized within different libraries depending on the type of use. The
Elementary Functions (EF) are the simplest functions. They are defined as those that do not have
internal states. Internal states are the values within the function that will affect the outcome.
its output. If the input values are the same, the output value must be equal for all the
executions of the function.
See also:
An EF is graphically represented as a box with multiple input pins and one output pin.
the name of an EF (that is, the type of EF) is displayed in the center of the box.
The execution order for the EF is shown to the right of the EF type. The function counter is
shows at the top of the box. This is the sequential number of the EF within the current section
(based on the order in which it was added to the section). Function counters cannot be
modified or influence the current execution order
46
Internal
AND function
The output of the function AND is True when all inputs are True. That is, if
any of the inputs False, the output will be False. The simplest AND function has only two
tickets
OR function
The output of a function is True when any of its inputs is True. The function
OR more simple has only two inputs.
See also:
For more information about Elementary Functions, see EcoStruxure Control Expert help topic
EF/EFB/EFB Libraries.
47
Internal
Exercise - Use a function block
Expected results
After completing this exercise you will be able to:
48
Internal
The Function Entry Assistant is displayed:
Click on OK
e. Observe that the course has changed and is preparing to place the new function block
dentro de la ventana de edición
Click once and the new Function Block will be placed inside the window.
The new function block has only two input pins (IN1 and IN2).
There are four tanks, the function block must be modified.
49
Internal
Click once to select the function block. Marks will appear around it.
Slide the cursor over the bottom mark to expand the function block when the
the cursor changes to a double-headed arrow.
h. Slide the marker and show two new entries
Tip:
50
Internal
Variables
Variables exist in most, if not all, programming languages. A variable is a
name used to reference a value.
Within EcoStruxure Control Expert, there are two main types of variables:
• Localized Variables
• Unlocalized variables
Localized variables
A localized variable is defined by a 'symbolic name' (32 characters), mapped to an address.
This address can be a bit of memory or a word in the PAC's RAM or a topological address.
that has been assigned to an I/O module
A data type must also be assigned to the variable. The data type will determine what type of data
can be stored in each memory location and the amount of RAM required to store
the data.
A comment is optional, but it is recommended to add it for more detail to the project.
51
Internal
Localized variables (cont.)
Some variables are named after the action they initiate. Other variables represent the state of a
device. For example:
If the data is required externally by a PAC application (i.e. from a SCADA system),
can be read using the symbolic name to refer together with the Data Dictionary and
OFS (OPC Factory Server)
See also:
52
Internal
Data I/O Types
The I/O data type is the term used for the addressing scheme within EcoStruxure.
Control Expert. There are two types of I/O data types.
The I/O data types supported in EcoStruxure Control Expert depend on the controller family.
and from the location of the team, here are some examples:
Modicon M340 X -
Quantum - X
53
Internal
Exercise–Variables
Expected results
By the end of this exercise, you will be able to
Since the variable FBD-level1 is not defined, EcoStruxure Control Expert marks it with
a red line
In addition, the dialog 'Create variable?' appears automatically. The Type is selected by
default as DINT(Double Integer) which is one of the possible allowed data types
for this function block. Change the data type to REAL
i.e. Click on the Tic button.
Now the variable FBD_Level1 has been created and defined, so that the instructions of
Warning disappears. The design window should look similar to this:
54
Internal
f. Repeat the following steps for the next three entries, using FBD_Nivel1.
FBD_Level2, FBD_Level3, FBD_Level4.
55
Internal
Exercise - linking functions
Expected results
After completing this exercise you will be able to
b. Drag the mouse and click on the pinIN1 of the DIV function
56
Internal
Summary
This chapter covered the following topics:
Questions
Las siguientes preguntas te ayudarán a verificar la comprensión de los temas cubiertos en este capítulo:
57
Internal
Test a project
EcoStruxure Control Expert provides tools to check the project for errors and for
{"text":"test the project in simulation. The first step to testing a project is to analyze for"}
syntax errors. Any detected error will be displayed in the information window below the
screen. The second step is to simulate the project using the simulator included in the installation
Objectives
Upon completing this chapter you will be able to
• Syntactic errors
• Semantic errors
• Missing program parts
If a section is selected, (the section is the active window), there is the option to analyze exclusively.
that section (Analyze Ctrl+Shift+B). This can save a lot of time on large projects that
They can have hundreds of sections.
If no section is selected, only the Analyze Project item will be available in the menu.
Exit window
All errors and warnings are displayed in the output window located at the bottom of the
EcoStruxure Control Expert window
Errors that require manual correction are displayed in red text. This message shows the
ubicación del error entre llaves, y el contexto del error después de los dos puntos. Los usuarios pueden
double-click the error to gain direct access to the part of the program that needs to be corrected.
58
Internal
Generate a project
After the analysis has been completed, the next step is to generate the project. When using the
regenerate the entire project, EcoStruxure Control Expert checks the related limitations
with the project. If the limitations related to the data of the configured devices and the
bus parameters are not met, the scanning table is not completed.
The complete setup remains invalid until the issue is corrected by the user. A
Invalid configuration cannot be transferred to a PAC.
The Exit Window confirms that there are no errors in the construction
b. The indicator in the status bar changes from NOT BUILT to BUILT
->
c. Save the project
59
Internal
Software Simulator
EcoStruxure Control Expert Simulator
The PLC simulator included in EcoStruxure Control Expert enables the use of a PC terminal for
test the application program for Modicon M340, M580, Momentum, Premium and Quantum without
connect to the real processor
Bug correction functions are available for Master, Fast, and Auxiliary tasks.
As the simulator does not manage the controller's I/Os, it is possible to use Animation Tables for
simulate the state of the inputs by forcing them to 1 or 0. The simulator can connect to applications
from third parties through an OPC server with OFS (OPC Factory Server) or with EcoStruxure Control Expert
The PLC simulator will start and will be visible through the icon. in the notifications area of the Bar
from Windows tools. The next step is to download the application to the Simulator.
60
Internal
Exercise - PLC Simulator
Expected results
After completing this exercise you will be able to:
[Link] on Transfer
61
Internal
When we select the option to run the project, a dialog will be displayed.
confirmation. Click OK
The status bar will show the status of EQUAL indicating that the programs in the
the computer and the controller are the same. The status bar will also show that the
the program is running.
62
Internal
Animation
Run mode (execution)
When the controller is in RUN mode, the following items can be seen at the same time.
• The animation of a section of the program, regardless of the language in which it is written
• The Animation Table that contains the application variables can be created directly.
from the view section.
Tip:
Pressing CTRL + T will initialize an animation table based on the selected variables within.
of a viewed section.
63
Internal
Animation Tables
Online tool
An animation table is an online tool used to determine the value of a variable.
They also have the ability to force and modify changes in variables and are therefore a
very useful tool for testing and eliminating errors in projects
Cuando unaSalidaes cambiada conModificación,el cambio es temporal. Durante el siguiente ciclo del
PLC, the controller will modify the variable.
When an entry is changed with modification, the change remains [?] until it is changed.
by the user.
The current value of an entry can be forced to a specific value. This will be studied in depth.
in chapter 13
64
Internal
Exercise - Create an Animation Table
Expected results
After completing this exercise, you will be able to:
c. Examine the Project Explorer. The Animation Table has been added to the tree.
Note:
The animation tables can be saved as part of the application.
65
Internal
Exercise - Working with animation tables
Resultados esperados
By completing this exercise you will be able to:
66
Internal
[Link] with the other variables to verify that the section works
correctly. Observe the effect on theSalidadeDIV
67
Internal
Summary
This chapter addressed the following topics
Questions
The following questions will help verify the understanding of the topics covered in this chapter.
68
Internal
Project Management
EcoStruxure Control Expert allows the user to perform fundamental tasks such as creating, exporting, and
import projects. There are also other project management tools like archiving that creates
a highly compressed version of the project.
Objectives
At the end of this chapter you will be able to:
• Show how to export and import projects from EcoStruxure Control Expert
• Completar el proceso de Archivar Proyecto
• Investigate the Project Explorer interface
Documents .STU
The STU documents are the standard document types used for an application document.
the EcoStruxure Control Expert project. The project can be saved at any stage
(Built) through the Save command. The saving and opening of the project is
quick since the internal database is stored in the document.
The [Link] is compressed and can become very large and therefore not convenient for
transfer it from PC to PC, the recommendation for that is to use a [Link]. the [Link] NO
It is compatible when updating EcoStruxure Control Expert from one version to another.
Documents .STA
The document type .STA is used to archive projects and can only be created after
The project has been built. This type of document allows for later compatibility between different
versions of EcoStruxure Control Expert.
• Manually, access File > Save Archive in the main window of EcoStruxure Control.
Expert or
• Automatically every time the project is saved as .STU it is in state
built.
69
Internal
Documents .XEF
The .XEF document is used to export projects in XML format and can be created in any
project stage.
The XML source format ensures the project's compatibility with any version of EcoStruxure.
Control Expert.
The type of [Link] supported by the Modicon M340, Momentum, Premium platforms and
Quantum
Documents .ZEF
The [Link] is very similar to the document [Link], with the addition of supporting applications or
projects that contain DTM configuration and can be created at any stage of the project.
The document type. ZEF is the only available option to export an application when using
Modicon M580 is also supported by Modicon M340.
The export function generates a document that contains unprotected data and references to data.
protected. The user must define a name for this document and its location, the extension is
determined by the type of export (for example, XDB or DFB, etc.). The most common exports
son
70
Internal
Export of projects
Useful for escalation
When a project based on Modicon M580 is exported, the software generates a file in format
XML with a .ZEF extension. This contains all the unprotected information: input configuration
and outputs, sections, subroutine modules, etc. The complete list is shown below.
Exporting is essential when scaling a project to new versions of EcoStruxure Control Expert. The
Project file (STU) of one version cannot be opened in a new version of EcoStruxure Control
Expert
File content
The exported file contains
71
Internal
Exercise - Export a project
Expected results
By completing this exercise, you will be able to:
72
Internal
Import projects
Scale projects
EcoStruxure Control Expert allows a .ZEF file to be opened and thus a project.
complete. This is particularly useful when wanting to upgrade to a new version of EcoStruxure
Control Expert. Before opening the imported project, EcoStruxure Control Expert allows it to be saved.
the current project before closing it
If the imported application contains protected sections, these are imported and their content is
encoded.
If the imported application contains protected DFB types, these are referenced in the .ZEF file but not
they are imported
73
Internal
Exercise - Import projects
Expected results
After completing this exercise you will be able to:
[Link] the EcoStruxure Control Expert file that was created in the exercise
previous. Click on Open
74
Internal
Archive projects
Save the compiled project
A project file is a highly compressed version of the project. The compression ratio
it can result in a file that is one-fiftieth the size of an STU file. Archiving is
similar to exporting except that it saves the completed application. The consequences of this are that the
the user cannot archive a project until it is compiled. Until this is possible, it is
necessary to export.
Properties of a File
A project file is saved with the .STA extension. The STA file contains:
Note:
To archive it, the application must be in a built state. It must also include the information.
from reading (upload), in the Project Settings, this allows the application to be transferred from
controller to the PC in the future. And at a minimum include the comments. The comments are associated
with Variables and types, and also includes comments within programming sections
75
Internal
Exercise - Archive projects with EcoStruxure Control Expert
Expected results
After completing this exercise you will be able to:
76
Internal
c. Select Generate > Regenerate all project from the main menu.
d. Select File > Save file from the main menu
77
Internal
The Project Explorer
Deploy the contents of a project
The Project Explorer allows the contents of an EcoStruxure Control Expert project to be
deployment and move around its various elements. The project can be deployed in two
ways
• Structural view
• Functional view
Structural view
By default, the Project Explorer displays a tree based on the structure of the controller.
Project directory
The directory shown at the top of the tree is the name of a driver and is called
Project by default. The Project directory in the Structural view allows access to the structure of
a Project and its associated services.
78
Internal
Exercise - The project tree
Expected results
After completing this exercise you will be able to
79
Internal
Functional view
The functional view is a way to display the controlled code by emulating the layout of the plant.
Functional module
Each functional module includes:
• Program sections
• Animation tables associated with the functional module
• Operation screens associated with the functional module
• Hyperlinks to documentation
80
Internal
Exercise - Change of views
Expected results
Upon completing this exercise, you will be able to:
• Switch between the functional view and the Structural view within EcoStruxure Control Expert
Change to the functional view in the Project Explorer
Click on the functional view button in the toolbar
[Link] the view function is deployed, observe that the tree view is empty.
since functional elements have not been created in the project. Once the
code sections are added to the project, it is possible to introduce them into the hierarchy and
customize the functional view.
81
Internal
Summary
This chapter addressed the topics
Questions
The following questions will help verify the understanding of the topics covered in this chapter:
82
Internal
Ladder Language
The Ladder Diagram Language is a commonly used method of programming
controllers, is based on the use of ladder diagrams. Writing a program is equivalent to drawing
a switching circuit. The ladder diagram consists of two vertical lines that represent the
power rails. The circuits are connected like horizontal lines, representing the steps,
between these two vertical lines
Ladder Diagram is the first of the three graphical languages of the IEC 61131-3 standard for
driver programming.
Objectives
Upon completing this chapter you will be able to:
• The vertical lines of the diagram represent the power rails to which they are connected.
the circuits. The flow of energy is understood from left to right along each step
• Each step defines an operation in a control process
• A ladder diagram is read from left to right and top to bottom, the first step is read
from left to right, the second from left to right and so on
• Each step must begin with an entry or entries (contacts) and end with at least one.
output (coils)
• The structure of a Ladder Diagram section is similar to the schematic logic of
relays with the power rail on the left side of the LD editor and the neutral on the side
law. Only the LD objects linked to the power supply, or connected to the power rail,
They are "processed." In any case, all the coils and outputs of FFBs are connected to the power rail.
directly or indirectly, and this creates a flow of energy
• The energy flows from the power rail to the last object of the step, usually a coil.
• LD complies with the IEC 61131-3 standard
• A network (or line) is a group of objects linked to each other one after the other, and not
They have connections with other objects, except for the power rail.
83
Internal
Links of the Stair Diagram
There are two distinct types of links.
• Horizontal links consist of one or more segments that link boolean objects
(contacts, coils) with each other
• Vertical links - Enable switching with contacts and coils in parallel
Note:
Links should not cross each other as any line that joins will be treated as
connection, modifying the desired operation
• Links: links have the highest priority in defining the flow of the signal within
a section of LD
• Step by step – the processing of a network is fully concluded before it is
start processing another network
• Output sequences - The outputs from the same function block or vertical link outputs are
they process from top to bottom
• Line by line - The execution sequence of networks, which are linked only to the rail.
left, is determined by the graphic sequence from top to bottom in which they are connected to the
power rail (only applies if none of the other rules apply)
84
Internal
Programming Window
Properties of the LD window
An LD section consists of a window that contains a single page. This page has a mesh that
divide the section into rows and columns. You can define from 11 to 64 columns and from 17 to 2000 lines in the
LD sections. The LD programming language is cell-oriented, e.g. only one object can be
placed in each cell.
LD Tool Palette
Next, you will see the main tools of the toolbox. The toolbox will appear in
the toolbar automatically when an LD programming window is open
selected.
85
Internal
Contacts of the Ladder Diagram
A contact is an LD element that transfers a state in the horizontal link to its right.
This state is the result of a boolean AND operation of the state of its horizontal link to the
left with the state of the relevant Boolean parameter of the contact. A contact does not change the value
of the parameter that it represents. Contacts occupy a cell. The following data are allowed.
as parameters:
- Boolean variables
- Boolean constants
- Boolean directions (topological or symbolic)
The expressions the Ladder Diagram that deliver a Boolean result (e.g., VarA OR VarB) like
Contact parameters are a supplement to IEC 61131-3 and must be enabled explicitly.
In the case of normally open contacts, the status of the left link is transferred to the
link on the right if the relevant boolean parameter state is ON. Otherwise, the state of the
right link is OFF
Designation Representation
Usually open
Note: the value is passed when the contact is TRUE
Normally closed
Note: the value passes when the contact is FALSE
86
Internal
Coils of the Ladder Diagram
A coil is an element of a Ladder Diagram that transfers the state of a horizontal link.
to its left, unchanged, to the horizontal link on its right. The state is stored in the parameter
Boolean represented.
Normally, the coils follow the contacts or FFBs, but they can also be followed by
contacts. The coils occupy one cell.
Designation Representation
Bobbin
Denied coil
Set coil
Reset coil
Stop coil
87
Internal
Functions of the Ladder Editor
Adaptive column width
Users can choose from three adaptable sizes for the LD columns.
• Small
• Medium
• Big
• Context menu
Copy Ctrl + c and
Copy Ctrl + Shift + V
The functions described above can also be easily performed using the mouse:
88
Internal
Mnemonic LD
Programmers can use quick input functions for ladder symbols by typing a
short name. These short names are editable labels from the main menu by selecting
Tools > Options
Insert functions
Using the button inside the menu toolbar, inserting ladder symbols becomes
very simple writing your Mnemonics
89
Internal
Quick access to standard features
It is possible to access many more functions from the toolbar
• Comments
o Double-clicking on a line number creates a comment on the entire line
Customization of LD color
The user can customize their own colors for the different elements of Ladder (in
animation) from the color editing menu. Select from the main menu
90
Internal
Exercise - Create a new Stair section
Expected results
By the end of this exercise, you will be able to:
Click OK
A new section has been created and it should look similar to this:
91
Internal
2. Configure the contacts
a. Locate the LD Editor toolbar
92
Internal
d. Select the Boolean connections tool and connect the contacts as
it is shown
93
Internal
3. Configure the coils
a. Locate and select the winding tool from the toolbar
LD editor, and insert two coils as shown. The new coils are
they will automatically link with existing contacts
[Link] the auto link in the third row and delete it by pressing Delete on the keyboard.
Another option is to right-click on the autolink and select Cut from the menu.
context.
94
Internal
c. Complete the basic design with a vertical connection
Slide to the right of the editing window and observe that the coils have
automatically linked to the right rail
95
Internal
d. Generate and transfer the program to the Simulator, Execute the controller.
96
Internal
The following dialog will appear granting direct access to the variable.
f. Change the value of start_process back to 0. What happens to the program? Why?
What?
g. Test the functionality of Stop_process by changing its value to 0
h. Save the project
97
Internal
Summary
This chapter addressed the following topics:
Questions
The following questions will help verify the understanding of the topics covered in this chapter.
98
Internal
Function Block Language
A Function Block Diagram is a graphical language that was designed to represent a
circuit board with several "wired" objects connected to each other. This was done with the idea that users,
generally with backgrounds related to electricity and electronics, they will feel familiar
with the symbols and expressions
Objective
Upon completing this chapter, you will be able to:
99
Internal
Function Block Diagram Language
Introduction
A function block diagram is a block diagram that describes a function between variables.
Input and output variables. A function is described as a game of elemental blocks. The
input and output variables are connected to the blocks through connection lines. An output
a block can also be connected to an input of another block:
The inputs and outputs of the blocks are linked together with connection lines, or links.
Simple lines can be used to connect two logical points of the diagram:
FBD is described as a graphical language for describing data flows and signals through blocks.
(which are reusable software elements). A function block is a unit of instructions for
program that when executed returns one or more output values
100
Internal
Programming window
Properties of the FBD window
The FBD sections have a mesh behind them. Each section consists of ten units of mesh.
A mesh unit is the minimum possible space between two objects in a FBD section. A section
FBD contains 360 units of horizontal mesh (36 mesh sections) and 240 units of mesh
vertical (=24 mesh sections). The FBD programming language is not cell-oriented, but the
objects are still aligned with the mesh units.
101
Internal
Exercise
Expected results
After completing this exercise, you will be able to:
102
Internal
c. The right panel will display all functions and function blocks in the library
from EcoStruxure Control Expert. Write OR in the Name field. This will filter the list.
to display the functions that start with the letters OR
Note:
One of the functions of the EcoStruxure Control Expert graphical interface is that it is easy.
add many functions at the same time. The Add block cursor remains
active and clicking again will add more OR functions.
g. Return the cursor to its normal mode by pressing ESC while clicking the button of
selection mode
[Link] a variable called: Pump_Start in the pin IN1 of the OR function block.
Create and define this variable as a BOOL data type
i. Save the project
Comments
Why use comments
It is a good programming practice to include comments throughout the programming. The comments
They allow users to quickly understand how a function works the next time they or
103
Internal
another designer needs to modify it. The comments also make the diagrams more
easy to identify and make them more readable and understandable.
In EcoStruxure Control Expert, comments are light-colored rectangles with text in the corner.
top left. It is possible to change its color through the main menu: Tools > Settings of
color... comments can be placed anywhere in the section.
104
Internal
Exercise - Comments
Expected results
After completing this exercise you will be able to
Expand and move the new comment box so that it surrounds the function.
OR. Leave additional space for the AND function that will be added later.
105
Internal
Execution sequence
The execution sequence is determined by the position of the Functions and the Function Blocks.
(FFB) within the section (executed from left to right and top to bottom). If the FFBs are linked
Graphically, the execution sequence is determined by the flow of the signal.
Note:
FFB is a collective term for EF (elementary function), EFB (elementary function block), and DFB.
(derived function block).
The execution sequence is indicated by the execution number, this is the number in the corner.
top left corner of the FFB frame
106
Internal
Show and hide comments
The user can show and hide the comments in the current edit window by clicking on the
107
Internal
Exercise – Execution sequence
Expected results
After completing this exercise, you will be able to
108
Internal
c. Click inside the FBD window to place the AND function in the diagram. The
the order of execution is from top to bottom. If the AND function is placed or moved very high up,
It will be the first to be executed, indicated by execution number 1.
Adjust the AND function so that it is to the right of the OR function or in the
same level or a little lower in the diagram
109
Internal
2. Add another variable to the project
Add the variable Bomba_Arranque to the output connection in the AND function.
Remember to create and define the variable as BOOL.
The same variable, Bomba_Arranque, is used for the output of the AND function and the
second input of the function [Link] click on IN2o in the function Or.
The variable has already been created, it can be selected from a dropdown list.
Select Pump_start from the list and click on the tic button
110
Internal
Exercise - Link the functions
Expected results
After completing this exercise, you will be able to
111
Internal
Exercise - Complete the FBD
Expected results
After completing this exercise you will be able to
Note:
This is only true if the signal comes from an HMI or SCADA. If it comes from a physical input of a push.
button will not be reversed as the electrical code requires that the "Stop" controls are
normally closed.
112
Internal
d. Increase the number of block entries to 4
e. Right-click on the pinIN3 and invert it, then assign a variable called
Bomba_EParo.Create the variable as BOOL
f. Add the variable Bomba_Disponible to pin IN4. Create the variable as BOOL.
g. The complete FBD should look something like this:
113
Internal
Resumen
This chapter covered the topics
Questions
The following questions will help verify the understanding of the topics covered in this chapter:
114
Internal
Function Blocks
In addition to the Basic Functions, the EcoStruxure Function Block Diagram language
Control Expert uses Elementary Function Blocks and Derived Function Blocks. In EcoStruxure
Control Expert, the abbreviation FFB (Functions and function blocks) is a generic term for
represent
Objectives
By completing this chapter you will be able to
For example, a timer block has an internal counter and the output can therefore change without
need for the tickets to change.
Imagine a situation where the processor executes this timer instruction where the internal value
The timer is 7 at that moment.
5 + = 12
The next time the processor executes this instruction, the internal value of the timer may be 15.
5 + = 20
This results in a different output value for each pass even when the input value
remained identical.
115
Internal
Representation of a EFB
An EFB is graphically represented as a box with input pins and output pins. The pins of
inputs are always represented on the left and the output pins are always on the right of the frame.
EFBs can have more than one output. The name of the EFB (e.g., the type of EFB) is displayed at the center of
frame
The execution number of the EFB is shown to the right of the type of EFB within the box.
The instance name serves as a unique identifier for the block (EFB) in the project.
The instance name is created automatically and has the following structure: FBI_n
Tip:
The numbers are not reused. For example, if FBI_1 is deleted and reintegrated, the new block will not be
116
Internal
Fault Processing and Counters
Why use fault processing?
The simple pump (previously scheduled) does not account for failure conditions. The verification
Errors can be added using the Elementary Function Block.
If the pump does not start within 15 seconds, the fault verification will prevent the program from continuing.
intentando encender la bomba
Below are the new conditions that will be added to the program.
Exception Handling
The condition will be identified as follows:
State of Exception The pump received the start command and has not started.
Failure Condition This will happen if the exception condition continues for too long.
time. It is necessary to take action if the exception condition
continues beyond the pump startup time.
This exercise will use 15 seconds as a time limit.
A manual intervention is required to restart the system.
other words, if the bomb starts running after 15
seconds, we do not want the system to simply switch to mode
We want a manual intervention (for someone to press)
Stop and then Start
Logical design
The following functions will be used to determine the failure states
117
Internal
Exercise - Fault Processing
Resultado esperado
Upon completing this exercise, you will be able to
118
Internal
b.AddBomba_running to the pin IN2 of the second block AND. This is a new
variable so it will need to be defined. Deny the pin
c.AddBomb_stop to pinR1 of blockRS.
d. Add the links between the functions as shown in the diagram
[Link] the pinIN5 of the original block since Q1 of the RS block is a
failure condition.
Note:
The execution order of the blocks has changed. The original AND is now number 5 in
the sequence. The order of execution is determined by the logical flow. Only the blocks not
linked take their number from the position in the diagram.
Add a 15-second delay to the timer
Double click on the input pin daPT (Preset Time) of the TON block.
[Link] t#15s in the field
See also:
For more information about the time data type, see EcoStruxure Control Expert Help – the type
time
119
Internal
Derived Function Blocks (DFB)
Function blocks used as templates
In a broader view of the dairy plant, there are three identical pumps. Instead of duplicating the
program for each pump, it is possible to create a function block for the type of pump and then use it
in the programs. This is called derived function block.
Structure
The derived function blocks have an identical structure to the EFBs but are created by the
user with one or more programming languages FBD, ST, LD or IL
A type of DFB can have one or more instances. Each instance is referenced by a name.
(symbol) and has data types of DFB
The only difference in the representation of the Derived Function Block is that the framework has
double vertical lines
120
Internal
Advantages of DFBs
The advantage of DFBs is that they allow users to standardize specific functions of
Procedure to automate or standardize application devices (Pump, Valve, etc.)
offering
• Generic Processing due to the possibility of exchanging data through parameters. The
parameters can be passed by reference (pointer) or directly by value
• Activation of parameters and internal variables used during processing
121
Internal
Exercise - Create a derived function block
Expected results
After completing this exercise you will be able to
Entries Start_bomb
Pump_stop
Loud explosion
Running_bomb
Pump_available
Since Bomba_Arranque is not an input from any field device, it can remain as the
only exit
Note:
For future expansion, it is a good idea to add an output for failures from pin Q1 of the block.
Reset
122
Internal
2. Create a derived function block
a. Right-click on FB derived types in the Project Explorer and
select open from the menu
Note that the incomplete function icon appears next to the name
c. Expand the tree to display the space for inputs, outputs, and code.
123
Internal
d. Fill in the inputs and outputs. Note that all of them are Boolean (BOOL).
Note:
As the name Bomba_liquido has already been assigned to the DFB, the inputs and outputs can be
simplified Start, Stop, etc. Instead of Liquid_pump_stop,
Liquid_start_pump,etc.
[Link] a new section in the FUNCTION BLOCK DIAGRAM
a. Right click on the sections folder in the new DFB
124
Internal
b. Name the sectionControl_pump.SelectFBDas language. Click OK
Note:
The DFBs can have multiple sections. These sections do not need to use the same
languages between each other
c. Copy and paste the logic from the original Section of Control_bomba. The names of
variables will appear underlined because they are not defined in this section
d. Rename the variables that were created in part 2 of the exercise. The
names of the Variables can be added to the links, for example, Failure
125
Internal
Exercise - Use the DFB block Liquid_Pump
Expected results
After completing this exercise you will be able to:
c. Assign the same input and output variables that were used previously. It will be necessary
a new boolean called Bomba_Falla
[Link] project
Connect the simulator, transfer and execute the project.
126
Internal
Exercise - Test and detail the DFB
Expected results
After completing this exercise you will be able to:
Fix the windows in such a way that the viewing of the DFB and the animation table
can be deployed at the same time
Try the DFB Liquid Pump
Change the online program
a. Open the section Control_pump in the DFBB Pump_liquid
[Link] the timer value to 10 seconds:t#10s
A message will appear. Click OK to accept the modification.
Click on PLC > Generate > Generate changes to automatically generate.
Transfer these changes online (still connected to the PAC)
e. Test the changes
[Link] the project
127
Internal
Exercise – Renumber the Pins
Expected results
After completing this exercise you will be able to
When the inputs and outputs of a DFB are created, the pin numbers are positioned in a way
automatic. Sometimes it is convenient to have pins in a different order or to leave
spaces in the sequence.
[Link] sure not to use duplicate numbers, as this would generate errors in the analysis.
d. Analyze the project
Open the task Masty section and observe the new spacing between the pins. This makes
that the diagram is easier to understand.
128
Internal
Tipos de Dato Derivados de Usuario y Bloques de función
Derived Data Types (DDT)
The program user can create their own data items to define a data structure. A
data item can contain a group of data:
The defined EFB function blocks are written by the user in C language. They consist of
• Internal variables
• Input variables
• Output variables
• A processing algorithm in C
If the application requires very complicated algorithmic processing, using the C language allows you to
the user to take advantage of the complete set of instructions that this language offers.
• Greater security - the internal code cannot be refined to deploy the code within the
function block
• Higher speed - the PLC can process an EFB faster than an equivalent DFB.
129
Internal
Resumen
In this chapter, the topics were addressed:
Questions
The following questions will help verify the understanding of the topics covered in this chapter.
• What are the differences between elemental function blocks and elemental functions?
• What is failure control?
• What are the advantages of derived function blocks?
130
Internal
Structured Text Language
With lines that end in semicolons, Structured Text language resembles a language of
high-level computer programming such as PASCAL or C. A survey of Engineers
Control indicated that of all the programming languages defined by IEC 61131-3, the text
Structured is the one that has grown the most in its adoption.
This language may embrace the increasing complexity of driver programming, just as
process control functions. This is the most widely used language now in automation,
especially for the new engineers
Objectives
After finishing this chapter you will be able to:
131
Internal
Structured Text Language
Introduction to Structured Text
Structured Text (ST) is a programming language that closely resembles Pascal.
The ST statements use predefined texts or subroutines to change variables, these being values.
defined, internally stored values, or inputs or outputs.
Assignment statements are used to indicate how the value of a variable should be changed, for
example:
Luz := SwitchA;
It is used to indicate that a light, the variable, should have its value changed to the same as that of the switch.
A. the general format of an assignment is:
X := Y;
Where Y represents an expression that produces a new value for the variable X and := is the symbol of
assignment. The variable retains the assigned value until another assignment changes the value. Others
examples are:
132
Internal
Structured text
Structured text programming, defined by the IEC 61131-3 standard, is a high-level language
level similar to Pascal. Students with exposure to other languages like C or BASIC will recognize the
syntax and structure of the structured text language. ST programming has the added benefit
to use 'de facto' standards (enter, select, delete, copy, paste, move, search, replace, etc.)
to edit the statements.
The Structured Text can be used to invoke function blocks, execute or repeat statements of
conditional manner. Although it is possible to execute mathematical expressions with other IEC languages
(using operation or computation blocks of the same type), these types of expressions are more intuitive.
in the domain of ST. The use of an expression is one of two functions that make programming ST
unique sea among IEC languages. The other function is the ability to create iterative loops (FOR–NEXT).
The statements that make up an ST program are separated by the delimiter ';' (semicolon). The
delimiters are used throughout this environment to separate one object from the next. In the case of
Semicolons separate statements. In some function calls, the elements of the list are
separated by commas.
Delimiters of
Debounce (IN:=Float_Switch (*BOOL*), parameters
PT:=t#250ms (*TIME*),
Q=>Float_Done (*BOOL*),
Delimiter of
ET=>Current_Time(*TIME*));
statements
133
Internal
Blank spaces
In the previous example, the statement became so long (a statement can contain up to 300
characters) that line breaks were added in certain spaces, but they could have been added
in any place where a space could be used. Line breaks, tabs, and spaces are
ignored at compile time and have no effect on the execution of the program.
For example, the Timer shown above could also be written as:
Debounce (IN
= Float_Switch (*BOOL*),
PT
:=t#250ms (*TIME*),
Q
=>Float_Done (*BOOL*),
ET
Current Time
);
And any of those statements would execute exactly the same way.
134
Internal
Equal signs
In the previously used time example, there are some things that happen with the 'Equal' signs.
Note that there is another character associated with the equal sign. This association is used to indicate to the
compiler that the equal sign IS NOT a comparison operator for equality.
An equality comparator would be written as 'X=Y' for example. An equality test will result
always in a boolean value (True or false). Either X equals Y or it does not. When the symbol of
equal appears only between two operands, it implies a test of equality.
IN := Float_switch
In this statement, the IN parameter 'is assigned' the value stored in the variable Float_Switch. It is of
help think about the two points associated with the equal sign as the symbol of 'assignment'.
Q => Float_Done
En este caso el valor del parámetro Q se redirige a la variable Float_Done. Se debe tener cuidado al usar
the symbol for 'greater than' together with the symbol for equals. In this example, the greater than symbol
that is preceded by the equals sign. If the greater than sign is placed before the sign of
equal (>=) this is a test of equality. 'X>=Y' is a test to see if the value of X is greater than or equal
to the value of Y.
Note:
135
Internal
Expressions
The structured text language works with 'Expressions'. Expressions consist of operators and
operandos que regresan un valor al ejecutarse. Los operadores definen el tipo de acción que será
tax on the operand or operands. In a mathematical sense, things like“+” o“- “son
considered operators. The operands are the numbers or variables that are added or subtracted from each other.
For most editors, when entering keywords, separators, and comments, a runs
immediate spell check that identifies errors by changing color. Since ST allows
enter a complete mathematical expression in one line of code, the 'order of operations' will be
important. ST uses the same rules as any other mathematical discipline. Consider for example the
next expression:
In the previous expression, the operands Potential and Length are global variables of type REAL. It is very
It is important to note that the elevation of 'x' to the power of 2 occurs before it is used as a divisor in
the last term of the expression.
136
Internal
Text operators
If two operators have the same level of precedence, execution proceeds from left to right.
137
Internal
Ventana de Programación
Properties of the window
A ST section consists of a window that contains a simple page. Each line is limited to 300.
characters. It is possible to have line breaks in statements (multi-line statements). It is possible to include
labels, symbols and comments at any point where whitespace is allowed. It is executed
a review of syntax and semantics immediately after the statement is created. The result of this
review is highlighted in colors in the text. The sections with syntactic or semantic errors still
can be saved.
Tool palette
Below are the tools available in the ST palette, the palette will appear in the
toolbar when the mouse hovers over a ST programming window.
138
Internal
ST Expressions
The ST programming language works with 'Expressions'.
Expressions are constructions that consist of "Operators" and "Operands" that return a
value when executed
Operators are symbols that represent the operations that will be executed.
Operators are used with Operands. Operands are variables, literals, inputs, or outputs of
FFBs, etc.
Instructions are used to assign the values that will be returned to the parameters and for
structure and control the expressions.
ST Operators
An ST operator is a symbol for
Operators are generic, i.e. they automatically adapt to the data type of the operands.
Operator ST Description
* Multiplication
/ Division
+ Suma
- Stay
AND AND logical
< Less than comparison
> Greater than comparison
<> Inequality
= Equality
139
Internal
Operands ST
Operators are used with operands. The operands can be
• An address
• A literal
• A variable
• An element of a multi-element variable
• A function call
• An output of a FFB
The data types in the processing of an operation must be identical. If operands are processed
of various types, before executing the operation, a conversion must be performed
ST Instructions
The instructions are 'Commands' of the ST programming language.
• IF…THEN
• ELSE
• CASE
• FOR
• WHILE
• REPEAT
See also:
For more information regarding the Operators, Operands, and ST Instructions, see Help of
EcoStruxure Control Expert - General Information About Structured Text.
140
Internal
Exercise - Create a new Section ST
Expected result
By completing this exercise, you will be able to:
141
Internal
e. The system needs to be protected, add the following blocks to the program
142
Internal
Summary
In this chapter, the following topics were addressed:
Questions
The following questions will help verify the understanding of the topics addressed in the chapter:
143
Internal
Instruction List Language
Instruction List programming is defined as part of the IEC 61131 standard. It uses
very simple instructions similar to original programming languages with mnemonics
developed for controllers. It is the most fundamental level of programming languages and
It is not generally used every day, but it can normally be found within some.
function blocks or DDTs.
Objectives
144
Internal
Instruction List Language
The instruction list language is the oldest source language among all languages.
programming. Many of the early controllers used either this language or Boolean, as
he was sometimes called, because his mnemonic nature brought brevity to the devices of
programming that mostly consisted of light sequences or switches. This still enjoys great
popularity in Europe
It is a language called 'accumulator-oriented'; that is, each instruction uses or alters the
current content of the accumulator (a type of internal cache). IEC 61131 refers to the accumulator as the
result
List of Instructions
A list of instructions consists of a series of instructions.
If multiple operands are used, they are separated by commas. It is possible to place a label at the front.
an instruction. This label will be followed by ':'
It is called an accumulator-oriented language; that is, each instruction uses or alters the content.
current of the accumulator (a type of internal cache). The IEC 61131 refers to this accumulator as the
result
For this reason, an Instruction List will always start with the operand LD ("Load command
in the accumulator)
The length of a section of IL is only limited by the size of the controller's memory.
145
Internal
The following is a list of the mnemonics used for the operators:
Instruction Description
LD Load the operand value into the accumulator
ST Save the value of the accumulator in the operand.
146
Internal
Programming Window
Properties of the window
An IL section consists of a window that contains only one page. Each statement begins
with a new line. Each line is limited to 300 characters. Line breaks within statements
are possible (multi-line statements). Labels, symbols, and comments can be located at
any part of the section (Comments can be entered wherever it is possible to insert
blank spaces).
Palette of instructions
Below are the main tools available in the IL palette, the palette
It will automatically appear in the toolbar when the IL window is selected.
147
Internal
Instructions IL
IL Operators
An operator is a symbol for:
The operators are generic, i.e. they automatically adapt to the data types of the operands.
The operands are divided into seven groups, as shown in the following table.
Operands IL
Operators are used to manipulate operands.
- An address
- A literal
- A variable
- A multi-element variable
- An element in a multi-element variable
- A function call
- The output of an FFB
The operand and the current content of the accumulator must be of the same type. If operands of
various types, before that a type conversion must be carried out.
148
Internal
IL Modifiers
Modifiers influence the execution of operators.
Modifier Description
N It is used to invert the value of the operands bit by bit
C C is used to carry the associated instruction.
CN A combination of C and N
( It is used to delay the evaluation of an operand until the parenthesis.
law
A continuación, hay un ejemplo de una sección IL que muestra el uso de Operandos, Operadores y
Modifiers
See also:
For more information about Operands, Operators, and IL Modifiers, see Control Help
Expert - General Information about Instruction List (IL)
149
Internal
Exercise - Create a new section IL
Expected result
Upon completing this exercise you will be able to:
This new section will recreate the same function seen in the exerciseUse a block of
function, but using Instruction List
c. In the editor enter the following text:
150
Internal
Resumen
In this chapter, the topics discussed were:
Questions
The following questions will help verify the understanding of the topics covered in the chapter:
151
Internal
Operator screens
Objectives
Upon completing this chapter, you will be able to:
The operator screen editor provides all the necessary HMI elements for visualization.
animated and design of the processes. When the PC running EcoStruxure Control Expert is
connects to the controller, the user can dynamically display screens depending on the state
of the process.
152
Internal
Online mode
In online mode, operator screens enable direct access to the application program of
EcoStruxure Control Expert from summaries to simply clicking on the selected object.
It is also possible to activate the animation table or cross-reference functions once one or
More variables have been selected on the screen. Summaries can be displayed on the screen.
complete to facilitate visualization.
Graphic Screen
Operator Screens
The operator screen tool enables the design of these screens using tools
orientadas a objetos.
Toolbars
When the Operated Screens window opens, the toolbar changes to IOSEditor.
153
Internal
Design Operator Screens
Standard Graphic Techniques
EcoStruxure Control Expert uses graphical techniques to design the Operator Screen. Users
Those familiar with HMI graphics software will find the steps for designing screens.
easy to use.
154
Internal
Exercise – Add Text as Tags
Expected result
By the end of this exercise, you will be able to:
The cursor will change to a text cursor. Draw a text object near the corner.
upper left of the operator screen.
c. Select the text object, then right-click and select Properties of
menu.
155
Internal
d. Add these text properties
Property Value
Text Pump Simulator
Font Arial
Size 12
Style Bold, Italic
Color Coffee
Tip:
[Link]
otro texbox para la etiquetaEntradas. Usa estas propiedades
Property Value
Text Entries
Font Arial
Size 10
Style Bold
Color Coffee
2. Use the standard editing tools.
[Link] and paste the textboxEntries
[Link] the second textbox below the first, select both.
Click the left align button in the toolbar
156
Internal
i.e. Click on the properties of the text below and modify it to say 'Commands'
The operator's screen should look approximately as follows:
The push buttons will be used to toggle the values of the variables they control during the
simulations and when the controller is running in the field.
157
Internal
d. Write Available in the Text field
Select 'With retention' since this is a continuous or state variable
Note:
The retention means that once the button is pressed, it keeps the new state.
retention, the state changes only while the button is pressed.
3. Change the animation properties
a. Select the Animation tab. Change the properties shown below.
Click OK.
b. Select the new Available button, right-click and select Information from the
menu.
158
Internal
The dialogue unveils information about control.
4. Complete the control buttons
a. Copy the Available button.
b. Stick the button on the screen three times.
c. Arrange the screen by organizing the controls
d. Add rectangles to group the controls and their descriptions
e. Use the Image tool to add a graph to the page. The graph will be
provided by the instructor.
f. Adjust the properties for the start, stop, emergency stop buttons as follows
show below
Button Tab Campo Value
Start Control Variable FeedPump_Start
Text Start
Animation Variable FeedPump_Start
Stop Control Variable FeedPump_Stop
Text Stop
Animation Variable FeedPump_Stop
Stop Control Variable FeedPump_Estop
Texto Emergency Stop
Animation Variable FeedPump_Estop
Note:
Make sure that the start, stop, and emergency stop buttons do not have any retention.
159
Internal
Exercise - Add Failure Test
Expected result
By the end of this exercise, you will be able to:
160
Internal
Exercise – Display Text at Runtime
Expected result
By the end of this exercise you will be able to:
2. Create a text object that displays when the pump's power command is activated.
be in ON
Insert an object with the text 'Power command sent'. Adjust the color to
green, 20pt, Arial, bold, italic
b. Set the line type to None
c. Adjust the animation so that the text is displayed only when the bit of
on has a value of 1.
In the Animation Type, select standard view. Click OK.
e. Place both overlapping objects. This will make it seem during runtime that
It is about a single text object that changes.
161
Internal
3. Reduce the size of the Operator screen
Right-click on the screen from the Project Explorer.
[Link]
c. Locate the Display tab and reduce the Width and Height of the screen to
that all objects fit correctly on the Operator Screen.
162
Internal
Exercise - Test the logic of the bomb
Expected result
By completing this exercise you will be able to:
g. When the simulation and animation are running, the FBD diagram is
illumination to show the values of the variables. Red=0, Green=1.
h. Place the cursor and click on the Operator Screen
i. Select Services >> Enable Variable Modification from the menu
Note:
Neither the menu nor the button will be available unless the Operator Screen is the
active window.
163
Internal
2. Test the operator screen logic using the operator
a. Click on the buttons and confirm that the behavior of the system is
agreement with what was designed during the previous chapters.
Disconnect the controller.
3. Save and Archive (backup) the project
a. Save the project
b. Archive the project as Graphics_finished.sta
Summary
In this chapter, the following topics were addressed:
Questions
The following questions are to verify the understanding of the topics addressed in the chapter:
164
Internal
Sequential function diagram
The Sequential Function Chart (SFC) language is a graphical method for organizing a program.
The Function Block Diagram was used to program a single object as a pump. The
Sequential Function Chart is used to program the entire process.
Objectives
By the end of this chapter, you will be able to:
SFC Sections
Size of the sections
A section of the Sequential Function Diagram consists of a single-page window. The window
it has a logical grid of 200 lines and 32 columns.
165
Internal
• A maximum of 1024 steps can be placed in each SFC section (including its sections.
macro
• A maximum of 100 pasps can be active in each SFC section (including its sections)
macro
• A maximum of 64 steps can be manually initiated at the same time in each section.
• A maximum of 20 actions can be assigned to each SFC step.
• It is possible to nest macro steps up to eight levels.
166
Internal
3. Export the elementary variables to a text document
a. Open the data editor in the Project Explorer >> Variables and FB instances >>
Elementary variables
[Link]-click on Elemental [Link] Export… from the menu
Open the [Link] file in Excel. When the import wizard appears,
Excel text select Delimited and click next.
167
Internal
Select the Tab delimiter in the Descriptor field select {none} from the list
dropdown. Click on next and then on finish.
The instructor will give you an Excel sheet with these variables already listed. Copy and paste.
the variables in the [Link] and save it.
168
Internal
4. Import the necessary variables for the SFC
Return to Project Explorer
b. Right-click on Variables and FB instances
[Link]...from the menu
When EcoStruxure Control Expert tries to import variables with the same name to the
A report of problems in the import will be generated identifying the variables.
duplicates. If it is necessary to handle each tag separately, double click on the cell
specific to keep or replace.
169
Internal
Tip:
As an alternative, EcoStruxure Control Expert provides the Excel Import Export tool that allows the
user create, sort, edit or filter application variables of EcoStruxure Control Expert within
Microsoft Excel.
SFC Editor
Components
Sequential function diagrams are similar to flowcharts. The three components
elders are:
• Steps (actions)
• Transitions (Tests)
• Jumps
Test Sequences
In a dairy plant, the following sequences would need to be programmed.
• Start
• Paro
• Cleaning before product change
Toolbars
When the SFC window is selected, the toolbar changes to the SFC one.
170
Internal
Structure of an SFC Section
An SFC section is a 'state machine', that is, the state is created by the active step and the
transitions execute the behavior of 'change'. The steps and transitions are linked to each other.
others with directional links. It is not possible for two steps to be directly connected, they must
always be separated by a transition.
The active status signal is sent along the links and is triggered when a transition changes.
The process chain direction follows the directional links and runs from the end of the step.
previous towards the beginning of the next step. The branches are processed from left to right. Each step
has zero or more actions
For each transition, a condition is necessary. The last transition in the chain must always be
connected to another step in the chain to create a closed loop. The steps in the chain are processed from
cyclical manner.
The transition acts as a 'guardian' denying access to the next section until the requirements are met.
all the conditions.
171
Internal
Exercise - Create the first step
Expected result
By the end of this exercise, you will be able to:
Note that the step line is blue. This indicates that the step is incomplete.
c. Double click on the step to open its Properties. Name the step Start. Check the
casillaPaso inicial y haz clic enOK
Times of Steps
Tiempos de Pasos
At each step, a minimum supervision time, a maximum supervision time can be assigned, and
a delay time.
172
Internal
Minimum supervision time
The minimum supervision time sets the minimum time during which the step should be, under conditions
normal, being active. If the step is deactivated before this time has passed, a generation occurs.
Error message. In animation mode, the error is additionally identified by a yellow line.
around the step.
If a minimum supervision time is not defined, or a minimum time of 0 is defined, supervision is not carried out.
supervision of the step.
So no maximum supervision time is defined or if it is set to zero, supervision is not carried out
step.
The error state remains the same until the step is deactivated.
Delay Time
The delay time sets the minimum time for which the step will remain active. The step always
will remain active (meaning the cycle will not proceed to transition) until this time has passed
elapsed.
173
Internal
Exercise - Step Times
Expected result
By the end of this exercise, you will be able to:
[Link] OK
174
Internal
Actions
Game Instructions
When the sequence reaches a step, execute actions within that step. These actions can be
tan simples como encender un bit o pueden ser tan complejas que requieran una sección de código en
particular.
Una acción puede ser sobre una variable Booleana (variable de acción) o una sección (sección de acción)
in programming language FBD, LD, IL or ST.
function executions.
See also:
For more information on Actions, see EcoStruxure Control Expert Help – SFC - Actions
Descriptors
Each action linked to a step must have a descriptor that identifies the control for that action.
Descriptor Description
N/None Not stored
R Reset
S Set
L Limited time
D Delayed
P Pulsar
DS Delayed and stored
P1 Pulse (Rising edge)
P0 Pulse (Downward flank)
175
Internal
Exercise–Actions
Expected result
At the end of this exercise, you will be able to:
Click on New action. This will transfer the new section Available_team to the
list of actions and will leave it selected
176
Internal
This is a new section, so you must choose a language. Select FBD and click
in OK
The dialogue will be closed and a new section called Available_Equipment will be generated.
2. Add content to the section you created to define the initial state of the team for the
project of this training.
a. Create the section shown below.
The purpose of this section is to ensure that the team is closed and in the state
correct to start the process.
177
Internal
Exercise–Comments
Upon completing this exercise, you will be able to:
[Link] on the Comment button and then in the upper cell of the third
column. Note that all the comments are the same size, that is,
they occupy a full cell.
178
Internal
The comments will look like this
179
Internal
Transitions
Verify the condition
In a sequential function diagram, the steps define the actions. Each step must have sections.
of significant code. These sections can be in any of the four languages FBD, ST, IL,
LD.
If the process requires that more than one condition be met, a section can be written within the
transition to combine all conditions into one.
A condition does not need to be Boolean. For example, an integer condition can be used to control.
the branches.
180
Internal
Exercise - Transitions
By completing this exercise, you will be able to:
e. Note that the transition lines are in blue indicating that the
the transition is not complete.
Note:
The transition itself is complete, but the sequential function diagram is not.
All diagrams must form a closed loop. This can be done with a jump or with
a graphic link.
181
Internal
Exercise - Add steps to the transitions
At the end of this exercise, you will be able to:
c. The cursor will change to indicate that a sequence is being inserted. Click on the cell
next to the transition AllEquipment_Available.
182
Internal
[Link] properties to steps and transitions
a. Double click on the first of the new steps (Line 3). Name the step
Heating and add a maximum time of t#3s.
183
Internal
3. Add properties to the following transition.
a. Double click on the following transition (Line 4). The sequence will move to this
Transition after the heating valve and the bypass valve have been
open
[Link] the Transition section button
c. Assign a name to the section and click the Edit button
184
Internal
6. Add properties to the following transition variable
a. Double click on the following transition. The previous steps, open the valves of
heating and bypass, and turning on the pump are to raise the temperature of the
spirals at more than 50°C. The transition requires that the variable
HoldingTube_Temp_OKsea is true before the sequence progresses to the step
next.
b. Click on the Variable button and add the variable HoldingTube_Temp_OK
7. Add properties to the next step that requires the Agitator, the Clarifier and the
Start homogenizer.
a. Double click on the following step.
[Link] the stepTeams
Add a maximum time value of t#60s
Open the Actions tab
Add these Actions
Descriptor Tiempo | Literal Acción | Variable
P Clarifier_Start
D t#5s Agitator_Start
D t#10s Homogeniser_Start
185
Internal
Exercise - Add a jump
By the end of this exercise, you will be able to:
To complete the SFC, a jump is needed that returns to the initial step.
Add a jump
a. Select the jump step
b. Click with the Jump cursor in the cell immediately below the last transition.
c. Open the properties of the jump and add the name of stepStart. This indicates that the
sequence must return to the beginning.
186
Internal
d. The complete section should look as follows
187
Internal
Exercise - Animation in SFC language
By the end of this exercise, you will be able to:
188
Internal
2. Test the project
a. Analyze and regenerate the project
[Link] the project to the controller
Execute the project
d. Select the screen you imported so that it becomes the active window.
SelectServices >> enable modification of variables in the main menu.
e. Use the new screen to enable the controls and test the program. Open the
SFC diagram and arrange the windows so that they are side by side.
189
Internal
3. Go through the actions step by step, fulfilling the conditions for each step and transition.
a. Double click on the Start step and notice that the maximum time is 15 seconds.
b. After that time has passed, the step changes to purple.
c. Open the Actions tab and double click on the Available Teams section
d. Use the Operator screen to turn on the necessary signals and assign a
value of level higher than 50 to the balance tank.
190
Internal
Summary
In this chapter, the following topics were addressed:
• SFC Sections
• Sequential Function Diagram Editor
• Step times
• Actions
• Transitions
Questions
The following questions are to verify the understanding of the topics covered in the chapter:
• What is the difference between the use of Function Block Diagrams and Function Diagrams?
Sequential?
• What are the three main components of a sequential function diagram?
• What are step times?
• What are stocks?
191
Internal
Communication to the controller
La aplicación de comunicación hace posible intercambiar datos entre diferentes equipos conectados a
a network or a bus.
All Unity controllers have the ability to handle multiple communication systems,
Examples of the available options among EcoStruxure Control Expert controllers are:
With the adoption of Ethernet networks, cybersecurity threats arise, therefore it also
It will cover an introduction to cybersecurity services within EcoStruxure Control Expert.
Objectives
By the end of this chapter, you will be able to:
Communication drivers
Installation Page - Communication Drivers
EcoStruxure Control Expert automatically installs the most common communication drivers.
includes others that can be installed as needed.
192
Internal
Connection Mode
EcoStruxure Control Expert allows two types of communication:
• Standard Mode
• Simulation mode
The selected mode will determine the communication pathway that the software takes when a user
try to connect the controller.
The Standard mode will try to connect to a physical controller (hardware) at a specific address.
using a pre-selected protocol.
The Simulation mode will attempt to connect to a PC-based simulator using Modbus TCP/IP.
This simulator can be located on the local PC or on a remote PC and accessed through the
IP address of the PC.
Note:
Since the simulator has characteristics different from the hardware, a mode change will always result in
in the Complete Regeneration of the program.
Or click on the icon in the toolbar. This will require a complete reconstruction of the
project.
USB and serial ports do not require any specific configuration information, as
assume the default firmware parameters when the system starts. The default parameters can
change using CPU configuration tools.
193
Internal
For Ethernet communications, it is usually not possible to determine the parameters by
advanced, so we need to provide more information to the system.
Note:
The USB port is the default of EcoStruxure Control Expert and is the most convenient for downloading the
initial program. The AddressField must always be set as SYScwhen the medium is USB
194
Internal
b. Set the address as SYS
c. El USB será el medio default
d. Connect the USB cable from the training computer to the USB port on the
processor.
e. Click on the Test connection button.
195
Internal
Ethernet networks
Ethernet configuration
A fundamental aspect of almost all automation projects is the inclusion of devices.
connected in an Ethernet network. Whether it is a simple connection between a PAC controller and a station of
Supervision or collecting data from field devices will require a level of configuration in
EcoStruxure Control Expert.
Both in the CPUs of the controllers and in the communication modules, it is possible to find
Ethernet ports.
Within EcoStruxure Control Expert, there are two different ways to create network configurations.
Ethernet, which one is used will depend on the family that is being used.
The M580 platform uses one method, while all other platforms use a method.
alternative.
➢ 1 x service port
➢ 2 x ports for the device network
The role of the port of DEVICE NETWORK varies depending on the selected CPU and can be used to
Distributed teams (DIO) or for Remote IO (RIO).
- DIO allows communication with modules and devices connected on an Ethernet bus.
distributed using a non-deterministic DIO scanner embedded in the CPU
- RIO (Remote I/O) uses an embedded scanner in the controller that enables exchanges of
Deterministic I/O with the modules in the X80 drops
When using an M580, all Ethernet network configurations are achieved by accessing the port.
Ethernet PLC relevant through the PLC Bus screen
196
Internal
You simply double-click on the Ethernet ports in any relevant module, this will allow
access the corresponding property pages. The IP address will be found in the tab.
IPConfig.
➢ Main IP address: This is the IP address of the module, similar to a traditional network port.
allows communications with EcoStruxure Control Expert, SCADA, etc.
➢ IP Address A: This is the IP address of the RIO or DIO header in the device network.
There are two additional IP addresses that can be configured, Primary IP Address +1 and IP Address B.
these are used in M580 Redundant (Standby mode).
197
Internal
Ethernet configuration of other controllers
For M340, Quantum, and Premium, the Ethernet configuration process consists of three or four
steps, depending on the location of the Ethernet port.
➢ Map the module in the local bus (if not included in the processor)
➢ Create a named network link
➢ Configure the link
➢ Add the link to an Ethernet port or module
Locate the physical slot that contains the communications module, right-click on the slot on the screen
PLC Bus and select New device
Select the correct network module from the Communication Library in the Hardware Catalog. Click on
OK. The module is added to the local rack.
From the Project Explorer open the branch Communication > Networks
198
Internal
Right-click on Networks and select New network
Select Ethernet as the network type, then name the network as required or leave it as default.
Ethernet_1 and click OK
The new Ethernet_1 network is deployed with a red cross. This indicates that the network is not connected to a
port.
Set up a Link
Then, the correct configuration must be added to the Network link. The necessary information can
to be
- Family of controllers
- Communication module model
- Cybersecurity
- I/O scanning
- IP Address
- Other properties related to networks
199
Internal
➢ To set up the link
Double click on Ethernet_1. Change the Model Family to the communications module
relevant
The most common task is to set the IP address and the subnet mask needed for this
module on the network, this is done through the IPConfig tab.
Once the adjustments are correct, click on validate. and close the properties window.
200
Internal
Add the link
The final task is to attach the Logical link to the physical module or port.
When the Ethernet properties window appears in the right sidebar, select Channel 0.
Note:
The project cannot be generated until the network link has been validated.
201
Internal
Cybersecurity with EcoStruxure Control Expert
Introduction to Cybersecurity - What is Cybersecurity?
Cybersecurity is a branch of network management that addresses attacks to or from
computational systems through computer networks that can result in disruptions
intentional or accidental.
The objective of cybersecurity is to provide increased levels of protection for information and the
assets against theft, corruption, misuse or accidents while maintaining access for users
desired. Cybersecurity is an ongoing process that includes policies, procedures, software and
hardware.
In EcoStruxure Control Expert V11.1, the cybersecurity service offering was expanded to cover
todas las familias de controladores Unity excepto una (Modicon Momentum)
EcoStruxure Control Expert allows configuring cybersecurity services for M340, M580.
Premium and Quantum.
Note:
For each platform, a minimum firmware version is required to use the services of
Cybersecurity, this can be consulted in the online help of EcoStruxure Control Expert.
The system is extensively tested for attacks against Ethernet services and ARP protocols,
ICMP, TCP, UDP, IP...
No Ethernet packet sent with garbage should cause problems since the level of resilience
It is designed to prevent the performance of the processor from being affected.
202
Internal
If too many packets are sent, known as a data storm, M580 will recover and
will continue to work when the storm has passed.
Security services
Throughout the implementation of Achilles level 2, a main function of M580 is its ability to
prevent certain Ethernet-based services from executing.
203
Internal
The following table explains the functions of the security tab
Unlock Enable all services, manually disable only the ones that are not
Security used
EIP Ethernet/IP
• A storage server
• Storage clients
204
Internal
Syslog con EcoStruxure Control Expert
Some examples of events stored using a syslog server are:
Syslog Originators
There are several M580 devices that can generate Syslog events:
• Control Expert
Select the Event Registration checkbox and enter a valid IP address of a syslog server.
205
Internal
Resumen
In this chapter, the following topics were addressed:
• Communication drivers
• Ethernet Networks
• Cybersecurity with EcoStruxure Control Expert
Questions
The following questions are to verify the understanding of the topics covered in the chapter:
• What is the default port for downloading programs to the PAC in EcoStruxure Control Expert?
• Where in the menu is the connection to the controller configured?
• Where do you start setting up a new Ethernet network?
• How do you connect that network to the controller?
• How do you access the network settings of M580?
• What is the hardware catalog?
• Name three examples of families within the Hardware catalog
206
Internal
EcoStruxure Control Expert plays a pivotal role in managing the entire lifecycle of automation systems by providing integrated tools for design, development, commissioning, operation, and maintenance. The platform consolidates functionalities necessary for device configuration, logic programming, simulation, cybersecurity, and diagnostics into a cohesive environment. These capabilities enable seamless transitions between stages of system implementation, improving efficiency and reducing potential for errors throughout the system's operational life .
In EcoStruxure Control Expert, communication drivers are integral for establishing network connections between industrial controllers and other devices. These drivers manage data exchange across various protocols such as Ethernet, Modbus, and Fipio, supporting systems that require flexible and robust networking capabilities. Automatically installing common drivers minimizes initial setup, while allowing additions as needed ensures scalability. They enable seamless integration and management of different communication methods, essential for complex and distributed control systems .
The execution sequence in a Function Block Diagram (FBD) critically impacts the control program's functionality because it determines the order in which operations are processed. In an FBD, functions are executed top-to-bottom and left-to-right, based on their position in the diagram. Incorrect sequencing can lead to logical errors, especially in operations dependent on-specific order, such as timers or conditional logic checks. Proper sequencing ensures reliable operation and correct response to input signals .
The Function Block Diagram (FBD) in EcoStruxure Control Expert facilitates logical programming by allowing the visualization of program logic through graphical representation. It enables users to connect different logical operations such as AND, OR, and NOT using simple drag-and-drop interface, promoting ease of understanding and debugging. Users can simulate and test logic before implementation which improves reliability. FBD also supports both complex and simple operations through customization of function blocks, enhancing its utility in diverse automation tasks .
Derived Function Blocks (DFB) in EcoStruxure Control Expert are significant because they enable the modular design of control logic by encapsulating frequently used functionalities into reusable blocks. DFBs reduce redundancy and increase efficiency as they allow programmers to create custom blocks for specific tasks that can be reused across multiple projects or instances. This modularity supports a structured programming approach and simplifies maintenance and updates as changes in DFB behavior are automatically propagated to all instances .
Simulation within EcoStruxure Control Expert offers control system developers significant advantages by allowing them to test and validate program logic in a controlled environment before deploying it on physical hardware. It helps in identifying and rectifying errors early, simulating failure conditions to see their impact without risking actual equipment, and optimizing code for performance. This mode supports both standalone simulations and simulating interactions with remote systems using Modbus TCP/IP, enhancing flexibility in testing procedures .
EcoStruxure Control Expert supports cybersecurity through functionalities such as enabling Syslog clients for event logging, implementing cybersecurity audits, and establishing comprehensive security services like encryption and authentication measures. These allow for monitoring network activities and protecting data integrity within automation systems. Furthermore, M580 controllers include settings to adjust and ensure enhanced security against unauthorized access and potential threats from connected networks .
EcoStruxure Control Expert enables a user-friendly interface by incorporating a graphical user interface similar to other Windows-based applications, which facilitates easy navigation and use. It includes toolbars for rapid access to frequent actions, an application browser for organized project management, and tool windows that keep essential tools accessible. Moreover, EcoStruxure allows adjusting font sizes and adding favorite functions for customization according to user preference, all of which makes programming industrial controllers intuitive and reduces the learning curve .
EcoStruxure Control Expert supports different hardware configurations by offering a flexible programming environment that abstracts the hardware-specific details through the use of generic modules and data structures. This allows users to develop control applications independently of the hardware, assuring compatibility across various hardware types like Modicon M340 and M580. This uniformity in software application leads to simplified management of diverse control systems, enables scalability, and facilitates maintenance across installations from small-scale to complex systems .
To configure an Ethernet port for the M580 in EcoStruxure Control Expert, follow these steps: First, ensure the correct drivers are installed and set the configuration to the M580 system from the communication drivers available in the EcoStruxure Control Expert. Then, configure the IP addresses and network parameters including gateway and subnet masks. Add the M580 Ethernet module to the project, define its IP address, and ensure appropriate settings for cybersecurity are in place. Lastly, test the configuration to verify successful communication .