Beruflich Dokumente
Kultur Dokumente
TABLE OF CONTENTS
Chapter 10 Control Modules........................................................................................................................................................ 10-1
10.1 General Information......................................................................................................................................................... 10-3
10.1.1 Description ................................................................................................................................................................ 10-3
10.1.2 Objectives.................................................................................................................................................................. 10-3
10.1.3 Reference Documentation......................................................................................................................................... 10-3
10.2 What are Control Modules? ............................................................................................................................................. 10-4
10.3 Difference between Function Block and Control Module .............................................................................................. 10-5
10.3.1 General Comparison ................................................................................................................................................. 10-5
10.3.2 Graphics .................................................................................................................................................................... 10-5
10.3.3 Execution and code sorting....................................................................................................................................... 10-5
10.4 When is it suitable to use Control Modules?................................................................................................................... 10-7
10.5 Using Control Modules.................................................................................................................................................... 10-8
10.5.1 Introduction ............................................................................................................................................................... 10-8
10.5.2 The Control Module editors...................................................................................................................................... 10-9
10.5.3 Create Control Module Instance............................................................................................................................... 10-9
10.5.4 Delete Control Module Instance............................................................................................................................. 10-11
10.5.5 Copy / Paste............................................................................................................................................................. 10-11
10.5.6 Connect Parameters ................................................................................................................................................ 10-12
10.6 Single Control Modules ................................................................................................................................................. 10-16
10.6.1 General .................................................................................................................................................................... 10-16
10.6.2 Create Single Control Module ................................................................................................................................ 10-16
10.6.3 Delete Single Control Module ................................................................................................................................ 10-18
10.6.4 Copy / Paste............................................................................................................................................................. 10-18
10.6.5 Create Control Modules below Single Control Module ........................................................................................ 10-20
10.6.6 Create Functions/Function blocks below a Single Control Module...................................................................... 10-20
10.6.7 Interaction Window ................................................................................................................................................ 10-21
10-1
10-2
10.1.2 Objectives
On completion of this chapter you will be able to:
10-3
10-4
10.3.2 Graphics
You can design a Control Module to include interactive and supervisory process
pictures (such as command buttons, input fields and trend curves). In addition, Control
Modules can be represented by certain interactive icons, which facilitates the process
control and supervision.
10-5
Each task forms its own group of co-sorted control modules. One code sorting is
therefore performed for each group of control modules connected to the same task.
For control modules, the compiler analyzes each code block separately ( ST, IL, FBD,
and LD. The compiler then determines the optimal execution order; a code block that
assigns a value to a variable has to be executed before the block that reads the value.
This technique is called code sorting and means that the optimal execution order will
be based on data flow instead of program flow (as is the case for function blocks).
Code sorting guarantees that the code will be executed in the correct order. Code
sorting suppresses time-delays and results in that a new control module automatically
being correctly placed in the process.
For any function blocks called from control modules, only the parameter interface (in,
out, or in_out) affects the code block sorting. That is, no analysis is made of how the
function blocks actually use the parameters. In addition, function block references to
external variables do not affect the execution order of control module code blocks.
Within an SFC code block, only the N action parts (not P1 or P2 actions) are sorted.
10-6
The figure shows that also the object-oriented solution typically involves function
blocks. This is because object orientation below a certain complexity level is not
justifiable. In this case, traditional programming with function blocks constitutes the
most rational alternative.
In summary, it is recommended to use control modules rather than function blocks in
the following cases:
When there is a need to concentrate the control of a certain object to one code
location (facilitates maintenance)
10-7
A Control Module always has a parent POU. This POU Type can be a Control
Module Type, Function Block Type, or an application.
A Control Module can be shown graphically inside the graphic of the parent (if the
parent is a module type or an application).
10-8
Right
click
Left
click
10-9
Left
click
3. Left mouse click onto the New Control Module icon and the Create a Control
Module window opens.
4. Select the AnalogInCC control module type in the ControlStandardLib library
5. Type in the instance name FI1001 and press the OK button.
6. Click onto the grid of the CMD editor window to place the control modul
symbol at a certain place.
7. The Connections window opens to create parameters related to your control
module.
8. Select the Name parameter field and type in FIC1001
9. Select the Description parameter field and type in TempTank1
10-10
10. Click onto the Save and Close icon in the toolbar of the Connections window.
11. The control module symbol is placed on the CMD editor window.
10-11
Right
click
Left
click
Left
click
6. Left mouse click on Paste and a copy of the control module is created.
10-12
the control module. The name of a component of a structured data type variable can
also be used. The node will serve as a connector for the specified variable. A
connection is established by connecting two nodes with a graphical connection, drawn
as a polyline whose ends are within the node circles.
Connect two control modules graphically:
1. Right mouse click onto Control Modules folder and select CMD Editor.
2. Create an instance of the control module type AnalogInCC ( Name:FIC1001 )
3. Create an instance of the control module type Level6CC (
Name:FIC1001_AL)
Left
click
4. Left click onto the Graphical Connection icon from the Graphics Toolbar on
left side
5. Draw the connection: Double left click on the Output of AnalogInCC and then
double left click on the input of Level6CC
10-13
Right
click
Left
click
10-14
10-15
Right
click
Left
click
10-16
Left
click
3. Left click onto the New Empty Single Control Modul icon .
4. Left click onto the grid of the CMD editor window to place the Single control
modul symbol at a certain place.
5. The Control Module Name window opens.
6. Select the Name field and type in FIC1002 and press the OK button.
10-17
Right
click
10-18
Left
click
2. Right mouse click onto the Single Control Module ( FIC1002 ) and click on
Copy.
Right
click
Left
click
3. Right mouse click onto Control Modules folder and click on Paste.
10-19
Right
click
Left
click
Right
click
10-20
Left
click
During commissioning, the graphics can be used for simulating the response from
parts of the plant that may not be available yet.
As a maintenance tool for process objects, a graphical faceplate can show the
status of interlocks, allow manual operation etc.
Hierarchic structures, where you zoom into a Control Module to see any objects
within, is accomplished by allowing each Control Module to have two layers of
graphical content: one directly visible to the user and one hidden beneath. The latter is
then reached by using the zoom tool or by using an interaction object on the first layer.
The picture below shows two examples of interaction windows, one for manual
operation of a process object and the other for tuning a PID controller..
10-21
Note that the Control Module graphics is not intended as a substitute to an HMI. It is
meant to be a complementary tool, to be used for testing, maintenance and navigation.
10-22
Command button
Input field
Text tool
Oval tool
Polygon tool