Академический Документы
Профессиональный Документы
Культура Документы
Content 7
7 Connection to the process ..................................................................................... 3
7.1 Learning Targets .................................................................................................................... 3
7.2 Component View and Plant View .......................................................................................... 4
7.2.1 Component View ................................................................................................................... 4
7.2.2 Plant View .............................................................................................................................. 5
7.2.3 Assignments .......................................................................................................................... 6
7.3 Task and Checkpoint ............................................................................................................. 6
7.4 Basics for charts and blocks .................................................................................................. 7
7.4.1 Device control functions......................................................................................................... 7
7.4.2 Charts .................................................................................................................................... 9
7.4.3 Catalog for libraries, blocks and charts ............................................................................... 11
7.4.4 Inserting a block into a chart ................................................................................................ 13
7.4.5 Block properties ................................................................................................................... 14
7.4.6 I/O Properties ....................................................................................................................... 15
7.4.7 Interconnections .................................................................................................................. 15
7.4.8 Graphical representation of blocks in the CFC Editor ......................................................... 16
7.4.9 Compile and Download........................................................................................................ 18
7.4.10 Selective download .............................................................................................................. 20
7.4.11 Test mode ............................................................................................................................ 21
7.5 Organization blocks ............................................................................................................. 22
7.6 Run Sequence ..................................................................................................................... 24
7.6.1 How to Adapt the Run Sequence ........................................................................................ 24
7.6.2 Runtime properties .............................................................................................................. 26
7.6.3 Optimization of the Run sequence ...................................................................................... 26
7.6.4 Runtime properties for experts: Activating/Deactivating runtime groups............................. 28
7.6.5 Runtime properties for experts: Switching runtime groups on and off during operation ..... 29
7.6.6 Chart-based Insertion of Runtime Groups in OB 100 .......................................................... 30
7.7 Different groups of blocks .................................................................................................... 31
7.8 Driver Blocks ........................................................................................................................ 32
7.8.1 General ................................................................................................................................ 32
7.8.2 Digital Input and output ........................................................................................................ 33
7.8.3 Analog Input and Output ...................................................................................................... 33
7.8.4 Module drivers ..................................................................................................................... 34
7.8.5 Process Image Partitions ..................................................................................................... 36
7.8.6 Symbolic Addresses ............................................................................................................ 38
7.8.7 Pcs7DiIn in brief ................................................................................................................... 39
7.8.8 Pcs7AnIn in brief .................................................................................................................. 40
7.8.9 Pcs7DiOu in brief ................................................................................................................. 42
7.8.10 Pcs7AnOu in brief ................................................................................................................ 43
7.9 Trend Display ....................................................................................................................... 45
7.10 Dynamic Display .................................................................................................................. 46
7.11 Task and Checkpoint ........................................................................................................... 46
SITRAIN
Connection to the process 7-2 Siemens AG © 2012
1
4
2
5
1. Stations
2. Subnet objects: only renaming is possible here.
Course ST-PCS7SYS 7-3 SITRAIN - Siemens AG © 2014
3. Shared declarations contain the elements Enumerations, Units and Equipment
Properties. They can be used by several tools and editors.
4. S7 Program folder: it is recommended to assign a unique and proper name to
prevent mistakes when identifying the station using this name. Blanks are not
permitted.
5. Symbol table: for every S7 Program (every CPU, every AS) there exists a unique
symbol table, for storing the relation between Symbolic names and addresses or
block types.
Stations and components are to be inserted first before data can be edited. Subnet
object are inserted here only, they are edited by HW Config and NetPro.
7.2.3 Assignments
PlantConfigurable
View objects like charts and pictures are created in the Plant View window of
Assignments
the project. An assignment to a station in the Component View will organize its real
target station (AS or OS).
Goal
The starting point of the Plant Hierarchy
Task: Plant Hierarchy
Checkpoint
Checkpoint
Compare …
the arrangement of folders on your
ES to what is listed in this task.
4
5
Course ST-PCS7SYS
1. Drive in the plant 7-8 SITRAIN - Siemens AG © 2014
The control of motors, valves and other process devices (process tags) in process
control systems is done by device control functions.
They offer the control, monitoring, operating from devices by supplying the connection
to control devices and their feedback. They also include parameter setting and
diagnosing faults.
Blocks
In modular designed user applications in process control software, device control
functions are realized by technological blocks. The inner side of these blocks is hidden
for the users.
Device control
For example, functions
the control of a motor can be done in PCS 7 using a motor block MOTOR
from the standard library
Block types and block or the MotL from the Advanced Process Library (APL).
instances
They differ in the scope of control features and their graphical representation for
monitoring and controlling.
DB x DB y DB z
SITRAIN
Connection to the Signal Box 6-8 Siemens AG © 2012
7.4.2 Charts
Charts are the placeholders of blocks. Each chart has a name that is unique within a
CPU. Charts will hold the blocks using a graphical representation in the CFC editor. In
general a chart contains several block, which are connected to each other.
Charts – Overview
Sheet view and navigation
Each chart consists of up to 26 chart partitions each with 6 sheets. You can see all of
the sheets in the Overview:
Overview
sheet 1 sheet 4
Sheets
sheet 2 sheet 5
chart partitions,
initially one,
can be A … Z
sheet 3 sheet 6
Charts – Sheet view and navigation
Sheet bar
Sheet bar
After inserting a new chart into the Charts folder, and opening, the chart starts with
one partition, containing 6 sheets.
You can switch between the sheet view and overview by clicking the button in the
tool bar, or double click in a sheet (on the white background).
As an alternative, you can use the pull down list.
CFC Editor –The sheet bars are used for references of connections outside of the sheet.
Tool bar Use the text box to enter a chart comment. You can position a text box in the chart
just like blocks.
1 3 5 7 9
2 4 6 8
Using the toolbar button Catalog, you can toggle the display of the catalog.
Catalog of libraries, blocks and charts
33tabs
tabs
3 tabs at the bottom separate the catalog into 3 areas:
1
2 3 4
See [302] PCS 7 V8.1 CFC for SIMATIC S7 - Function Manual - 08_2014, 7.2.2 for
more details
7.4.4
InsertingInserting
a blocka into
blockainto a chart
chart
When you insert a block in your CFC chart, you generate an instance of this block type.
In this context, “instance” refers to an instance of the selected block type.
Block
1 header
2
Drag 4
3
You can drag blocks from the catalog (library) into a chart. The installed blocks are
assigned to the OB where the Runtime Group of the chart belongs to (this example:
Course ST-PCS7SYS OB35). 7 - 15 SITRAIN - Siemens AG © 2014
The name has a maximum length of 16 characters and is displayed in the block
header. Illegal characters: / \ ." %.
Remember when assigning names that the variable name must not be longer than
128 characters for transfer to the OS. This includes not only the block name but also
hierarchy path, chart name, separator and I/O names.
2. Name of the block type: This name cannot be changed in the CFC Editor.
3. Block comment: The comment, a user-specific text, appears in the block header.
The block header can display up to 14 characters of comment. Small blocks do not
display the comment.
4. Predecessor for blocks: One block per chart will have a light green colored
Runtime properties area in the block header (instead of dark green). This indicated
the block is de predecessor block. A new inserted block for this chart will be
inserted behind it in the run sequence.
1. After a double click in the block header, the Properties dialog window appears, with
Course ST-PCS7SYS 7 - 16 SITRAIN - Siemens AG © 2014
the General tab opened.
2. The name field is preset by just a number. Usually it is replaced by a more useful
name.
3. The comment field is preset by a brief block description. It can be changed.
4. Some areas in this dialog window may not be valid for a block type. The objects are
grayedproperties
Block out then.
I/Os I/Os
A second tab lists the properties of the individual inputs and output:
1
2
1. Course
Inputs of a block
ST-PCS7SYS 7 - 17 SITRAIN - Siemens AG © 2014
2. Outputs of a block
3. Several settings, initially with their default values. White fields can be changed.
SIMATIC PCS 7 – Connection to the process
7 - 14 Training Documentation, V8.1.0, ST-PCS7SYS
SIMATIC PCS 7 System Course
I/O Properties
7.4.6 I/O Properties
1 2
1. After a double click on a block input field, the Properties dialog window of the input
Course ST-PCS7SYS will appear. When an input7has
- 18 been designed as a structure,
SITRAIN the Select
- Siemens
first AG © 2014
7.4.7 Interconnections
For transferring a value from a block output to a block input, an interconnection can be
configured.
In general:
To make an interconnection, you can click at the output and then at the input (or in
opposite order).
Alternative you can drag from the output to the input (or in opposite order).
An output may have several connections to several inputs.
An input can have only one connection to an output.
Hidden interconnections
Display of instances with invisible interconnected block I/Os
Course ST-PCS7SYS
If interconnected block I/Os are7made
- 20
invisible, this is shown inSITRAIN
the instance header
- Siemens AG © 2014
using a cyan triangle.
Color settings
Adaption ofThe
Colors inbethe
color can set CFC Editor
using the Layoutposition/Parameters (changed)” option in
“Block insertion
the “Customize colors” dialog box. The color “red” was set in the figure below.
Compile
Data flow ofand Download
configuring in CFC
Data flow of configuring in CFC
After creating the required functions in the charts, they are to be send to the CPU:
Block library
Compilation
S7 User Programm
Compile
1. The Compilation process converts the functions in the charts into blocks, and
stores them in the offline blocks folder.
2. With the Scope, you select if the program is to be compiled entirely (only option for
the first time) or with changes only (compared to an earlier compilation).
SITRAIN
Connection to the Signal Box 6 - 20 Siemens AG ©
SIMATIC PCS 7 – Connection to the process
7 - 18 Training Documentation, V8.1.0, ST-PCS7SYS
Compile and Download
SIMATIC PCS 7 System Course
Download
Download
1 2
3 4
If you want to ensure that your program retains its ability to download changes, you
should generate a backup copy after each completed download.
See [302] PCS 7 V8.1 CFC for SIMATIC S7 - Function Manual - 08_2014, 11.3 and
11.4 for more details about the system support for avoiding causes of CPU STOP
Selective Download
7.4.10 Selective download
• Chart modified
• Chart downloaded
• Chart compiled
You can use selective downloading as a user to specifically select which configured
changes should be transferred to the CPU and enabled. This makes it possible, for
example, to configure multiple units on a CPU at one time, because only the changes to
a specific unit are compiled and tested.
Course ST-PCS7SYS 7 - 25 SITRAIN - Siemens AG © 2014
See [302] PCS 7 V8.1 CFC for SIMATIC S7 - Function Manual - 08_2014, 11.6 for
more details about selective download
3
4
You can also toggle the Watched status of a block I/O by “Ctrl + click”.
Course ST-PCS7SYS 7 - 26 SITRAIN - Siemens AG © 2014
SIMATIC PCS 7 – Connection to the process
Training Documentation, V8.1.0, ST-PCS7SYS 7 - 21
SIMATIC PCS 7 System Course
Tasks
Organization blocks
Our main group of OBs is the OB30s: OB30 … OB38.
They represent cyclic execution (on a regular time base).
By assigning PCS 7 blocks to these Cyclic Interrupt OBs (settings for a Runtime group),
a designed time interval is achieved.
SITRAIN
Connection to the Signal Box 6 - 26 Siemens AG © 2012
Startup behavior
In a warm restart, execution of the program restarts at the beginning of the program with
a "basic setting" of the system data and user address areas. Non-retentive timers,
counters, and memory bits are reset. All data blocks and their contents are retained.
ATTENTION!
Warm restart = Default setting for PCS 7 and normal applications
In some situations, the block behavior at startup must differ from the normal behavior. It
may e.g. be required to suppress alarm for a number of cycles after startup.
In that case, a block must additionally be assigned to a startup OB (OB100). Due to
settings on the level of block attributes, this kind of blocks will be installed in OB100 at
creation.
When you restart (warm restart) an S7-400 (for example by changing the mode selector
from STOP to RUN or by turning the power ON) organization block OB100 is processed
before cyclic program execution begins (OB 32 - OB 38). As default, all the PCS 7
blocks that have a special startup behavior are installed in OB100.
Cyclic interrupt
Cyclic OBs OBs
Interrupt
The properties of the Cyclic Interrupt OBs can be watched via CFC’s Options menu:
Task (OB)
Runtime
groups
2
1
3
Course ST-PCS7SYS
1. For every chart a Runtime 7group
- 32
(blue folder) is created inSITRAIN
the Run Sequence,
- Siemens AG © 2014
containing the individual blocks per chart. It is assigned a cyclic OB. This is
important in PCS 7, because it ensures that the channel drivers and technological
blocks will be executed in the same cycle in a run sequence.
2. The green background color represents a pointer, controlling the position (after this
one) for the next new chart.
3. The pointer can be moved using the indicated menu option.
4. Runtime Groups can be moved by dragging, within an OB or to another OB.
Installation pointer
Chart installation pointer
Block installation pointer
Manual
Change the position of the block by dragging to the new position (installs behind the
block you are pointing to):
Indications in the
Indications
CFC editorin the
CFC editor
See [103] PCS 7 V81 Engineering System - 11_2014, 8.12.3.9 for more information
how to adapt the run sequence.
When the “Chart-based insertion” option is checked in the chart folder, the chart
reference data additionally displays the chart in the runtime group. This additional
display makes it easier to identify an existing dependency that influences selective
Course ST-PCS7SYS
downloading. 7 - 37 SITRAIN - Siemens AG © 201
ES OS
Plantbus
Signal
Input drivers processing Output drivers
SITRAIN
Input
Connection drivers
to the Signal Box Read values from6 - the
29 PII as process feedback, and offer them to outputs
Siemens AG © 2012
to be read by other blocks inputs for processing.
Signal processing Processing values without users interference.
Monitoring and Controlling Monitoring and Controlling functions, including an interface to the
Operator Station. Block Icons and Faceplates in the OS offer information
about states and modes and allow process operations.
Output drivers Write values to the PIQ as the commands to the process.
Process Images
The Process Image Inputs (PII) and Process Image Outputs (PIQ) form the interface
between the signals from the I/O modules and the user program in the CPU of an AS.
Update
The transfer of values between the I/O modules and the Process Images is controlled
by properties (settings) on the CPU and the I/O modules.
The update of the information should be in the same rate as the signal processing.
ES OS
Plantbus
Chart
PII PIQ
Pcs7DiIn MotL Pcs7DiOu
4 5 6 7
PV_In PV_Out FbkRun Start PV_In PV_Out
8
3
M
2 1
SITRAIN
1.
Connection to the Signal Box
The control signal from a channel
6 - 37
of the output module is wired toSiemens
the (control logic
AG © 2012
of the) motor.
2. The feedback signal from the (control logic of the) motor is wired to a channel of the
input module.
3. The signals from the input module are transferred to the Process Image for Inputs
(PII), situated on the CPU.
4. The input driver reads the signal from the PII, and brings it into the chart to be
used by control blocks.
5. A control block reads the process value from the input drivers. Its logic will
generate one or more control signals.
6. The output driver reads the control signal from the control block.
7. The output driver writes the control signal to the Process Image for Outputs (PIQ),
situated on the CPU.
8. The control signals are transferred to the output module. The output module
converts them to proper electrical signals.
Process value
to be used by
control blocks
Signal from PII
(representing the input Input
from the process) driver
Signal to PIQ
(representing the
output to the process)
Control signal from
control block
Output
driver
Process value
to be used by
control blocks
Signal from PII
(representing the input
from the process)
Input
driver Signal to PIQ
(representing the
output to the process)
Output
driver
Module drivers
7.8.4 Module drivers
Module drivers are blocks created by the driver generator. This generator is activated by
default at the compilation of charts:
Course ST-PCS7SYS Creates charts “@(1) … @(7)” with blocks (module drivers)
7 - 42 SITRAIN -for diagnosing
Siemens AG © 2014
Module drivers
information when errors appear in the I/O circuits
Makes connections between module drivers and channel drivers to supply the
The driver generator
channel drivers with information about the I/O modules.
This “line” offers diagnostic information to the channel driver, to be used in the
application.
ATTENTION!
No changes are allowed to the system charts since these involve system functions
(indicated by "@"). This also applies to changes to the installation in OBs or runtime
groups.
The content of runtime groups, created by the driver generator ("Generate Module
Drivers" @......) are not optimized since the correct order is already set here.
If optimization is executed after creating the module drivers, there is no guarantee
that the runtime groups of the driver blocks are in the order specified by the driver
generator. Therefore the module driver is restarted during the next compilation (the
"Create module driver" check box is activated).
ProcessProcess
7.8.5 Image Image
Partitions
Partitions
Example for settings
The picture below shows an example of settings concerning the Process Image
Partitions.
T PIP2
I
AO4
AI8 1
Chart OB32 (1s) 5
5
PIP3
PIP3 Pcs7DiIn VlvL Pcs7DiOu
Pcs7DiIn
DO16
DI16
2
Chart OB33 (0,5s)
OB1
The time sequence diagram above indicates with the same colored arrows as the
picture before, on what moment the transfer is done of the signals from the I/O modules
to and from the Process Images.
See [103] PCS 7 V8.1 Engineering System - 11_2014, 8.9.4.8 for more details
4
3
5
Symbolic Addresses
Connection
SITRAIN
to
Connection to the process
the channel
Connection driver
to the channel driver:
7 - 47 It is strongly recommended to use symbolic
Siemens names
AG © 2012
for all I/O signal. This is the way how to connect to the channel drivers:
Process value (Raw value – link with DI) Process value is not valid
Feature parameter Standard value (physical variable)
Simulation active
Inputs for simulation and substitute value Module / device faulty –
Corresponding error number(s)
Maintenance release from faceplate Out of service is active
...automatically interconnected
to the diagnostic block
MOD during „Generate Flutter suppression
Module drivers“
Simulating signals
The block provides the standard function "Simulating signals".
Process value (Raw value – link with AI) Process value is not valid
Scaling of the process value as structure / unit
Standard value (physical variable) and its unit
of the process
and scale
Feature parameters
Limit value violation of the process value active
Inputs for simulation and substitute value
Simulation active
Maintenance release from faceplate Module / device faulty –
...automatically interconnected Corresponding error number(s)
to the diagnostic block Out of service active
Flutter suppression
MOD during „Generate
Module drivers
Simulating signals
The block provides the standard function "Simulating signals".
LowCutOff
The output value PV_Out is set to the low value of the signal range (Scale.Low) when it
drops below the LowCutOff value. This function is released by feature bit 5.
Simulating signals
The block provides the standard function "Simulating signals".
Technological block,
Preview
The output parameter PV_ChnST provides the signal status of the output channel and
value of PV_Out as structure. This information can be returned back to the
corresponding technological block.
For this purpose, an additional interconnection is necessary (e.g. PV_ChnST >
StartChn).
limit you have entered is output at the PV_Out output parameter. This is displayed at
the PV_HiAct or PV_LoAct = 1 output parameter. The signal status of the PV_ChnST
output parameter is set to 16#78.
Flutter suppression
This block provides the standard function Flutter suppression for channel blocks.
Simulating signals
The block provides the standard function Simulating signals.
For more information on the signal status for PCS7 channel blocks, see
[113] PCS 7 V8.1 Advanced Process Library - 07_2014, 1.1.5.9
For more information on simulating signals, see
[113] PCS 7 V8.1 Advanced Process Library - 07_2014, 1.1.1.9
7
2
Course ST-PCS7SYS
1. From CFC’s View menu, select Trend Display.
7 - 54 SITRAIN - Siemens AG © 2014
2. The Trend Display window will share the work area of CFC with the chart windows.
Add, delete and rename a Trend Display. Make a proper arrangement of the
windows.
3. Choose suitable recording parameters: number of values (10 …16000), acquisition
cycle (1 …9 s, 10 … 90 s) and Recording mode.
4. Use dragging to assign any input or output of a block to each of the up to 12
channels of a Trend Display. Values from several blocks and from several charts
can be assigned.
5. Set the High and Low limit values to fit the vertical axis (for each channel).
When Boolean values are used, a predefined range in the vertical axis is used per
channel to display the values false and true. Determine the number of values to be
displayed in the horizontal direction.
6. The "Start" button is active only in test mode. After starting, the start button changes
into a “Hold” button and is relabeled accordingly. You can then use it to stop
recording at any time.
7. Export the stored data to a file. You should check the settings for export using the
menu command
Options > Customize > Export Trend Data
Goal
Task: Drivers for the Signal Box drivers for the I/O signals of the Signal Box.
4 charts containing
Checkpoint
Checkpoint
Let us summarize …
Why have the @(..) charts
appeared in the Charts folder?
What is the use of it?
Pcs7AnIn
AO
Process Pcs7AnOu
DI
Process value
Motor block
Name Pcs7DiIn
DO
Pcs7DiOu
Johnsson
Process
simulation
Symbol table
SITRAIN
The
Connection to the process
process simulation (running7 -in
8
the CPU as a Function Block) is using the original
Siemens AG © 2012
Process Image as an interface to the application software in the automation system.
This makes it possible for you to configure functions with channel drivers, similar to real
applications.
The symbol table contains the corresponding signal names for the process values in the
Process Image and their addresses. These addresses should not overlap the addresses
of the real hardware.
4
Johnsson
V311_O Pcs7DiIn VlvL block Pcs7DiOu
V311 3
1 V311_C Pcs7DiIn
2 V311
Process
images
“V311_C” = closed
4. A chart with a minimum of blocks to control and monitor the block. This chart is to
appear in the plant hierarchy.
7.12.2 Overview
The number of I/O is based on the devices in the plant.
The following table gives an overview of the number of devices and the related I/O:
number DI DO AI AO
open-close valves 25 50 25
status valves 5 5
motors 11 11 11
level measurement 13 13
temperature measurement 4 4
control valve 4 4 4
total 62 66 36 21 4
Goal
A running process simulation of the Johnsson plant.
Task: Installing the
After this process
task simulation
the functions for the plant can be configured.
Checkpoint
Checkpoint
Consider …
What is the use of channel driver
blocks, why not just connecting to
the I/O addresses?
SITRAIN
Connection to the process 7 - 11 Siemens AG © 2012