Sie sind auf Seite 1von 287

List of contents:

Chapter 1 - Introduction to SIMATIC IT Services


Chapter 2 - Introduction to Production Modeler
Chapter 3 - Analysis: Project Requirements
Chapter 4 - Analysis: Library Development
Chapter 5 - Messaging Manager
Chapter 6 Class rules
Chapter 7 - Methods and Events

Chapter 8 - Rule Development


Chapter 9 Engineering: Plant instantiation
Chapter 10 Runtime: Monitoring
Chapter 11 - COM Integration
Chapter 12 Production rules

SIEMENS DF PL DER MOM DL 2015

In this first part of the course we are focusing on how to use SIMATIC IT Framework, i.e. the development
environment.

SIEMENS DF PL DER MOM DL 2015

SIEMENS DF PL DER MOM DL 2015

SIEMENS DF PL DER MOM DL 2015

Important Notes:
.NET framework 3.5 has to be installed on machines running Windows Server 2012 R2.
SIMATIC IT can run on x64 operating systems only through the WOW64 (Windows
32-bit on Windows 64-bit) subsystem.
SIMATIC IT 6.7 SP1 has been tested in both English and German on the supported
operating systems.
The Server Core installation option is not supported.

UAC has to be always disabled except for client machines with the following
requirements:
Windows 7 SP1 is installed, ZAC installation and HDD Lean Setup is installed or
Windows 8.1 is installed and ZAC installation

SIEMENS DF PL DER MOM DL 2015

SIEMENS DF PL DER MOM DL 2015

SIEMENS DF PL DER MOM DL 2015

The installation process allows the user to choose the SIMATIC IT installation folder (by default, C:\Program Files
(x86)\SIEMENS\).
In case of installation of Production Modeler server, the user is also prompted to select the path of the folder
containing all Production Modeler files. The default path is
C:\Program Data\Siemens\SIMATICIT\UserKbs.
The USERKBS folder contains:

a USERKBS folder, containing Production Modeler projects, libraries and plants


a DOC folder, containing images, documentation files and library and plant versions belonging to Production
Modeler

SIEMENS DF PL DER MOM DL 2015

A typical distributed architecture for SIMATIC IT Production Suite can look like the one in this picture.
Note that Component servers can be distributed on different machines, as well as Component clients.

SIEMENS DF PL DER MOM DL 2015

SIMATIC IT Production Suite Documentation:

SIEMENS DF PL DER MOM DL 2015

10

More information about SIMATIC IT licenses can be found in the SIMATIC IT Licensing Manual document.

SIEMENS DF PL DER MOM DL 2015

11

SIEMENS DF PL DER MOM DL 2015

12

SIEMENS DF PL DER MOM DL 2015

13

SIEMENS DF PL DER MOM DL 2015

14

SIMATIC IT may also be started from START menu, All Programs > Siemens Automation > SIMATIC > SIMATIC
IT > Management Console.

SIEMENS DF PL DER MOM DL 2015

15

The files containing the configuration of a


Services Plant are stored in a folder on the
PC hard disk.
This folder has the same name of the
Services Plant: <Plant_name>.PLT.
To display configuration details, double-click
the Services Plant, logging on the
SIMATIC IT Management Console.
Multiple Services Units can be defined inside
one Services Plant, but only one at a time
can be active. Therefore, if more Services
Units are needed, e.g. for performance
reasons, they must run on different computers.

SIEMENS DF PL DER MOM DL 2015

16

SIEMENS DF PL DER MOM DL 2015

17

The Foundation Server also hosts the Discovery Service: this allows the Components clients to discover the
machine where SIMATIC IT Servers are running, with no need to configure their location explicitly.

SIEMENS DF PL DER MOM DL 2015

18

SIEMENS DF PL DER MOM DL 2015

19

SIMATIC IT Network can be configured either


from the Management Console environment, by selecting Configuration > Network Configuration, or
from the Plant Management environment, by selecting Tools > Network Configuration

SIEMENS DF PL DER MOM DL 2015

20

Operation: To change user


1. Press SHIFT + ESC

Operation: To open User Manager

1. From Management Console, select


Tools User Manager

SIEMENS DF PL DER MOM DL 2015

21

SIEMENS DF PL DER MOM DL 2015

22

SIEMENS DF PL DER MOM DL 2015

23

SIEMENS DF PL DER MOM DL 2015

24

In this way SIMATIC Logon implements the integration between SIMATIC IT, SIMATIC and Windows users:
The same username and password is valid to log on to the Operating System and it is recognized both in
SIMATIC IT applications and in PCS7

SIEMENS DF PL DER MOM DL 2015

25

OPC DAC is a device driver enabling communication with any OPC-compliant field device.

SIEMENS DF PL DER MOM DL 2015

26

SIEMENS DF PL DER MOM DL 2015

27

The connection to physical devices is configured by defining the interfaces in RTDS (information about device
drivers).
From the Management Console, click your logical unit and select Unit > Real Time Data Engine > RTDE Offline
Configuration

Note: exhaustive information about this topic is provided during the Simatic IT Historian training course.

SIEMENS DF PL DER MOM DL 2015

28

RTDE must be activated, by selecting Unit > Real Time Data Engine > Start Real Time Data Engine.
During this training course you do not need to launch it manually, since it has been added to the automatic startup list, as we are going to see at the end of this chapter.

SIEMENS DF PL DER MOM DL 2015

29

SIEMENS DF PL DER MOM DL 2015

30

SIEMENS DF PL DER MOM DL 2015

31

For details about Messaging Manager server, refer to Chapter 5.

SIEMENS DF PL DER MOM DL 2015

32

Detailed information about Custom Objects can be found in the Custom Objects Management document:
Start > All Programs > Siemens Automation > SIMATIC > SIMATIC IT Documentation > English > Concepts and
Use > Custom Objects Portal Online Help.

SIEMENS DF PL DER MOM DL 2015

33

More information on the Logbook Configuration manual:


Start > All Programs > Siemens Automation > SIMATIC > SIMATIC IT Documentation > English > Concepts and
Use > Logbook Service Configuration Manual.

SIEMENS DF PL DER MOM DL 2015

34

The user that is logged on automatically when SIMATIC IT is started is the default user.
In order to define a different start-up user, you must select Configuration > System and
select the Automatic User Logon check box
click Set Automatic User
enter the start-up user username and password
The start-up user configured in the Training Room workstations is the manager user.

1
2

SIEMENS DF PL DER MOM DL 2015

35

SIEMENS DF PL DER MOM DL 2015

36

SIEMENS DF PL DER MOM DL 2015

37

Prerequisites:
A Services Plant (.PLT)
SIT must be configured to log-on to the Services Plant automatically.
Furthermore, the user that is logged on the SIT Services automatically must have sufficient permissions to
start the Components configured as Windows Service (the manager username is suggested)

SIEMENS DF PL DER MOM DL 2015

38

SIEMENS DF PL DER MOM DL 2015

39

The Windows Services related to SIT are


SIMATIC IT IPC: it provides the communication layer for SIMATIC IT Components (Inter-Process
Communication protocol) and makes it possible to start Components automatically by launching the Program
Server (prgserv.exe);
StarterService: it launches SIMATIC IT DIS connectors;
SIMATIC IT Application Broker
These services are visible in the Computer Management window (Windows Administrative Tools).
Even if possible, it is recommended not to start / stop them from the Windows Control Panel: in some cases, the
correct behavior may not be ensured.
It is possible to start the SIT Management Console at any time, in order to modify the configuration of
Components running as Windows services.

SIEMENS DF PL DER MOM DL 2015

40

Operation: To launch System Monitor


1. From Management Console, select
Tools System Monitor

SIEMENS DF PL DER MOM DL 2015

41

Operation: To configure the system to start PM automatically


1. From Management Console, select Configuration System
2. Select Startup tab
3. Click Startup Conf
4. Drag Production Modeler automotive project and drop it on your computer name.
5. Click Save
6. Click Apply now
7. Click Finish

8. Click OK
Operation: To open System Monitor
1. From Management Console, select
Tools System Monitor

SIEMENS DF PL DER MOM DL 2015

42

SIEMENS DF PL DER MOM DL 2015

43

SIEMENS DF PL DER MOM DL 2015

44

SIEMENS DF PL DER MOM DL 2015

45

Manual References
Release notes, hardware requirements and installation guidelines:
From Start menu, SIMATIC > SIMATIC IT Documentation > English:
- Follow the links to Release Notes and Installation /Configuration
License Management:
From Start menu, SIMATIC > SIMATIC IT Documentation > English:
- Follow the links to Installation /Configuration > SIMATIC IT Licensing Manual
Services help manual:
From Start menu, SIMATIC > SIMATIC IT Documentation > English:
- Follow the links to Application Development

SIEMENS DF PL DER MOM DL 2015

46

SIEMENS DF PL DER MOM DL 2015

47

SIEMENS DF PL DER MOM DL 2015

48

KB stands for Knowledge Base.


The configuration of the User-Root is contained in a file with .KB extension.
Libraries are represented by files with .LIB.KB extension.
Plants are represented by files with .PLN.KB extension.
These files are stored in C:\Program Data\Siemens\SIMATICIT\UserKbs\USERKBS.

The user root contains configuration information about the PM project, such as which plants and libraries to load,
which Components should be accessible, settings about debugging and logging, etc.

SIEMENS DF PL DER MOM DL 2015

49

SIEMENS DF PL DER MOM DL 2015

50

Available actions on PM Projects:


New / Add: create a new project
Modify: change the configuration of an
existing project
Delete: delete an existing project

Clicking Advanced makes it possible to configure the initial size of three memory regions for PM:

Region 1: memory reserved to the Production Modeler engine


Region 2: memory reserved for the evaluation of PM keywords
Region 3: memory reserved for the interpretation of graphic steps

SIEMENS DF PL DER MOM DL 2015

51

The following commands are accessible by right-clicking the connection:


Connect
Disconnect
Show TW
Hide TW

SIEMENS DF PL DER MOM DL 2015

52

SIEMENS DF PL DER MOM DL 2015

53

Operation: To open System Monitor


1. From Management Console, select
Tools System Monitor
Operation: To start PM User Interface
1. From Management Console, select
Components Production Modeler Production Modeler User Interface

2. Select AUTOMOTIVE-PROJECT
3. Click Connect

SIEMENS DF PL DER MOM DL 2015

54

The constraints for using multiple instances of PM Server are the following:
A specific plant can be loaded in more than one PM Server instance, but it can be ACTIVE only in one PM
instance, and it must be in STAND-BY mode in all other instances (this check is performed at runtime via
BPM)
Each PM Server instance can load more than one plant, without violating the previous constraint

Each PM Server instance is identified by the host name and the TCP port number. The TCP port number
allows other applications (e.g.: PM User Interface, SIMATIC IT MULTI COM Interface, etc.) to specify which of
the PM instances running on the same host they want to connect to
Each PM Server instance has its own set of processes (PM Launcher and system GSIs) that is duplicated.

SIEMENS DF PL DER MOM DL 2015

55

SIEMENS DF PL DER MOM DL 2015

56

The RTDS Units folder allows the user to monitor the status of the connection to Services Units (RTDS Unit
Monitor).

SIEMENS DF PL DER MOM DL 2015

57

SIEMENS DF PL DER MOM DL 2015

58

SIEMENS DF PL DER MOM DL 2015

59

SIEMENS DF PL DER MOM DL 2015

60

click to
drop

click and
release

SIEMENS DF PL DER MOM DL 2015

61

SIEMENS DF PL DER MOM DL 2015

62

SIEMENS DF PL DER MOM DL 2015

63

SIEMENS DF PL DER MOM DL 2015

64

SIEMENS DF PL DER MOM DL 2015

65

According to ISA-95, a plant definition should always start either with an ENTERPRISE, a SITE or an AREA.
The ENTERPRISE and SITE levels can be used to manage a distributed architecture, where several PM Servers
can run on a single multiprocessor workstation or on different workstations.
In the hierarchy proposed by PM, those levels are meant as coordination layers: several production plants (local
or remote) within the same company can share high-level information and have common operating procedures,
which are stated in the ENTERPRISE or SITE.
The architecture can be made up of several distributed PM Server installations: an Enterprise PM Server
contains the project with the definition of the ENTERPRISE or SITE and one or more local plants; each Client
PM Server contains one or more remote plant definitions, consisting of SITES or AREAS.
LOGICAL-CELLS may also be recursive (i.e. they can contain other LOGICAL-CELLS)
SITE-LINKS and AREA-LINKS are used in the Enterprise PM Server in order to access plants running on other
Client PM Servers.
The PROCESS-SEGMENT level is used to describe the production processes and not the physical layout of the
production plant. More information about this is given in the chapter dedicated to Process Segments.

SIEMENS DF PL DER MOM DL 2015

66

SIEMENS DF PL DER MOM DL 2015

67

SIEMENS DF PL DER MOM DL 2015

68

SIEMENS DF PL DER MOM DL 2015

69

When saving a library, the related .LIB.KB file is overwritten.

SIEMENS DF PL DER MOM DL 2015

70

SIEMENS DF PL DER MOM DL 2015

71

Versioning is available for plants too, with the same criteria.


The compatibility between plant and library versions is checked by the system.

SIEMENS DF PL DER MOM DL 2015

72

Manual References
Release notes, hardware requirements and installation guidelines:
From Start menu, SIMATIC > SIMATIC IT Documentation > English:
- Follow the links to Release Notes and Installation /Configuration
PM help manual:
From Production Modeler User Interface:
- Help > Contents and Index
From Start menu, SIMATIC > SIMATIC IT Documentation > English:
- Follow the links to Engineering > Production Modeler

SIEMENS DF PL DER MOM DL 2015

73

SIEMENS DF PL DER MOM DL 2015

74

During the course you have to:


Model the production plant layout: you will model the physical machines, production lines, and functional areas (e.g.
production area, warehouse area) (Production Modeler)
Implement the logic to manage a truck that delivers raw materials (e.g. engines) to the plant (Production Modeler)
Model the processes to manage equipment involved in the assembling of a chassis and of a complete car (Production
Modeler)
Use SIMATIC IT Material Manager to define initial, intermediate and finished materials. You will describe the parts that
compose the cars (BoM). During production, MM will update warehouse stocks with the movement and assembling of
materials

Use SIMATIC IT Product DEFinition Manager to define the PM processes involved in the production of a car model and
the related requirements (input / output materials, machine parameters, execution equipment)
Use SIMATIC IT Production Order Manager to define orders to assemble a car (e.g. a coupe or a station wagon)
Use SIMATIC IT Data Integration Service to manage data exchange between the ERP and the MES layers. Production
orders, materials and product specifications will be received from an external application, manipulated and stored in the
Production Suite database
Implement a WEB application using SIMATIC IT Client Application Builder to manage orders from an Internet Explorer
page. You will also build a GUI to display equipment availability

SIEMENS DF PL DER MOM DL 2015

75

Using SIMATIC IT Production Modeler you will model the equipment present in your production plant and its
hierarchical layout.
The Plant is composed of:
One Site
Two Areas (the Production Area and the Warehouse Area)
The Production Area contains:
Two Production Lines (the Chassis Assembling Cell and the Car Assembling Cell)

A Workplace Cell
The Warehouse Area contains:
A Raw Material Warehouse
A Final Material Warehouse
The assembling production lines are composed of:
A Side-Line Warehouse (Unit)
An Assembling Machine (Unit)

An Inspection Unit
A Repair Center (Unit)

SIEMENS DF PL DER MOM DL 2015

76

Using PM you will model the workflows for the management of each equipment from an MES point of view.
For example, in the Raw Material Warehouse, you will model a workflow to:
Ask the Operator to insert the License Plate in a form
Store the License Plate on the Database
Ask the Operator to insert the Engine Serial Number in a form
Ask the Operator to check if the Engine Serial Number is in the arrival list:
- If so, unload the Engine in the Warehouse
- If not, display a Warning Message

SIEMENS DF PL DER MOM DL 2015

77

Using SIT PM two sets of Production Rules will be created:


the Chassis-Production-Rules (which are executed inside the Chassis Assembling Cell)
the Car-Production-Rules (which are executed inside the Car Assembling Cell)

SIEMENS DF PL DER MOM DL 2015

78

When a production process is started, the following actions are performed:


The status of the production line is set to BUSY
Production starts and materials are assembled
The output material is inspected and if necessary moved to a repair station for rework
The status of the production line is set to FREE

SIEMENS DF PL DER MOM DL 2015

79

Using SIMATIC IT Material Manager you will model and hierarchically classify the materials involved in the
production process.

SIEMENS DF PL DER MOM DL 2015

80

Using SIMATIC IT Material Manager you will define Bills of Materials (BoMs) containing the ingredients and the
quantities needed for obtaining each product.
Using SIMATIC IT Material Manager you will model and hierarchically classify the materials involved in the
production process.

SIEMENS DF PL DER MOM DL 2015

81

Using SIMATIC IT Product Definition Manager you will specify the PM processes involved in a specific car model
assembly (e.g. Chassis and Car Assembling Processes will be used as Coupe Chassis and Coupe Car
Assembling Processes).
For each process you will define production specifications (e.g. input / output materials, machine set point values,
etc.).

SIEMENS DF PL DER MOM DL 2015

82

Using SIMATIC IT Production Order Manager you will define an order for the car model you want to assemble
(e.g. one coupe model).
In SIMATIC IT Production Order Manager you may wish to specify other product characteristics (e.g. the color).
At runtime, product specifications are sent to SIMATIC IT Production Modeler and production is started on the
specified plant.

SIEMENS DF PL DER MOM DL 2015

83

SIMATIC IT Data Integration Service enables data exchange between the ERP and the MES system.
You will use SIMATIC IT Data Integration Service to import from an ERP system:
Material Definitions
Material BoMs
Product specifications
Production Orders
You will also learn how to manipulate the contents of the imported information.

SIEMENS DF PL DER MOM DL 2015

84

SIEMENS DF PL DER MOM DL 2015

85

In the GUI, a yellow or green rectangle indicates the availability of production lines in the plant:
when the operator decides to dispatch an order the Chassis Assembling Line will be the first to be busy;
then it will be care of the Car Assembling Line to manage the output of the previous process.

SIEMENS DF PL DER MOM DL 2015

86

SIEMENS DF PL DER MOM DL 2015

87

SIEMENS DF PL DER MOM DL 2015

88

SIEMENS DF PL DER MOM DL 2015

89

A new library contains the Common-Tools-Folder, which in turn provides the:


Custom-Data-Type-Folder
Data-Builder-Definition-Folder
Log-Files-Folder
Custom-Function-Folder
Life-Cycle-Folder

SIEMENS DF PL DER MOM DL 2015

90

SIEMENS DF PL DER MOM DL 2015

91

Operation: To open GSI-INDUSTRY-LIBRARY


1. Right-click the root of the Libraries environment tree
2. Select Open
3. In the browser window that appears, select the GSI-INDUSTRY-LIBRARY
4. Click Ok

SIEMENS DF PL DER MOM DL 2015

92

SIEMENS DF PL DER MOM DL 2015

93

Operation: To set GSI-INDUSTRY-LIBRARY as AUTOMOTIVE sublibrary

Right-click the AUTOMOTIVE library

Select Sub-Libraries

Select the GSI-INDUSTRY-LIBRARY in the list provided

SIEMENS DF PL DER MOM DL 2015

94

SIEMENS DF PL DER MOM DL 2015

95

SIEMENS DF PL DER MOM DL 2015

96

Operation: To create a new class (i.e. to derive a new class from S95 library):
1. Right-click the library in which you want to create the class
2. Select Add Class
3. Select the parent ISA-95 level from which you want to derive your class in the browser window displayed
4. Set the following:
Class-Name
Operation: To create a subclass (i.e. to derive a new class from an existing user defined class)

1. Right-click the parent class


2. Select New Subclass
3. Set the following:
Class-Name

SIEMENS DF PL DER MOM DL 2015

97

Operation: To override superior class behaviors:


1. Right-click the subclass
2. Select Override
3. Select the kind of behavior you need to override
4. Browse one of the available entries in the Inherited Methods/Events/Rules/Transaction Rules/Configuration Rules
window
5. Apply the changes you require to the selected behavior

The difference between rules and methods / events is that you cannot visualize and override just one single inherited rule,
only the rule container as a whole.

SIEMENS DF PL DER MOM DL 2015

98

Operation: To add the WAREHOUSE-AREA class


1. Right click the Automotive library
2. Select Add Class
3. Select Area
4. Set the following:
Name: WAREHOUSE-AREA
5. Click OK

Operation: To add the PRODUCTION-AREA class


1. Right click the Automotive library
2. Select Add Class
3. Select Area
4. Set the following:
Name: PRODUCTION-AREA
5. Click OK
Operation: To add the CAR-ASSEMBLING class
1. Right click the Production-Line cell
2. Select New Subclass
3. Set the following:
Name: CAR-ASSEMBLING
4. Click OK

SIEMENS DF PL DER MOM DL 2015

99

Operation: To load an existing image:


1. Right-click the class or subclass,
2. Select Modify Load-Icon
3. Select the image file on your hard drive
Operation: To edit a new icon:
1. Right-click the class or subclass
2. Select Modify Edit-Icon

SIEMENS DF PL DER MOM DL 2015

100

Operation: To modify CAR-ASSEMBLING class icon


1. Right click the CAR-Assembling class in the tree view
2. Select
Modify Load-Icon
3. Select CAR.JPG
4. Click Open

SIEMENS DF PL DER MOM DL 2015

101

Operation: To define an attribute


1. Right-click the class in the tree-view
2. Select Properties
3. Select Class Attributes tab
4. Set the following:
Attribute Name
Attribute Type
Persistency
Note: The Attributes tab in the Class Properties window contains some information about the class and not the
class attributes!

SIEMENS DF PL DER MOM DL 2015

102

SIEMENS DF PL DER MOM DL 2015

103

In the Class Attributes tab, class attributes are displayed with different colors:
grey for system attributes
dark green for inherited attributes
light green for specific and overwritten attributes

SIEMENS DF PL DER MOM DL 2015

104

NOTE: A CUBE-VARIABLE attribute cannot be persistent.

SIEMENS DF PL DER MOM DL 2015

105

Operation: To add and configure the TRUCK-LICENSE-PLATE attribute to RAW-MAT-WH


1. Open the AUTOMOTIVE library
2. Right-click the RAW-MAT-WH CELL in the library tree-view
3. Select Properties
4. Select Class Attributes tab
5. Click Add
6. Set the following
-

Name: TRUCK-LICENSE-PLATE

Type: TEXT

Persistency: persistency and log

7. Click OK
8. Click OK
Operation: To add and configure the FIELD-INSPECTION attribute to INSPECTION-UNIT
1. Open the AUTOMOTIVE library
2. Right-click the INSPECTION-UNIT unit in the library tree-view
3. Select Properties

4. Select Class Attributes tab


5. Click Add
6. Set the following:
-

Name: FIELD-INSPECTION

Type: CUBE-VARIABLE

Persistency: no persistency or log

7. Click OK twice

SIEMENS DF PL DER MOM DL 2015

106

Operation: To initialize a non CUBE-VARIABLE attribute


1. Right-click the class icon in the workspace (Template view)
2. Select Properties
3. Select the User attributes tab
4. Set the attribute default value

SIEMENS DF PL DER MOM DL 2015

107

SIEMENS DF PL DER MOM DL 2015

108

Operation: To initialize a CUBE-VARIABLE attribute


1. Right-click the class icon in the workspace (Template view)
2. Select Properties
3. Select the User attributes tab
4. Click the attribute ellipsis icon

5. Set the following:


Unit
Cube-Name
Type Filter
Validity Interval
Default Update Interval
Cube Polling Class

SIEMENS DF PL DER MOM DL 2015

109

If the configuration of a class attribute is set as fixed reference to a specific RTDS tag: when you create instances
of the class, they will all contain the same attribute, related to the same field value.

SIEMENS DF PL DER MOM DL 2015

110

In general, you can use the value of any class attribute or any PM expression in the parametric part of the tag
name:
[the attribute name of THE-OBJECT]_fixed_part
It is also possible to combine more that one parametric parts in the tag name:
[the ATTR1 of THE-OBJECT]_fixed_part_[the ATTR2 of THE-OBJECT]
However, be aware that tag names have a maximum length of 32 characters.
Examples:
[the ID of THE-OBJECT]_attribute
[the NAME of THE-OBJECT]_attribute
[the ID of the object superior to the workspace of THE-OBJECT]_inspection
This expression refers to the identifier of the object containing the current instance of the class as a content.

SIEMENS DF PL DER MOM DL 2015

111

Operation: To initialize the TRUCK-LICENSE-PLATE attribute:


1.

Select the RAW-MAT-WH in the tree view

2.

From the Template workspace, right-click the RAW-MAT-WH and select Properties

3.

Select the User Attributes tab

4.

Set the following:


-

TRUCK-LICENSE-PLATE = plate

Operation: To initialize the FIELD-INSPECTION attribute:


1.

Open the INSPECTION-UNIT Properties

2.

Set the following:


-

Unit: CAR

Cube Name: [the ID of THE-OBJECT]

(to be typed in exactly!!!)

Type Filter: PI

(Permanent attribute containing an INTEGER value)

Validity Interval: indefinite

(to be typed in exactly!!!)

Default Update Interval: none

Cube Polling Class: 7 : On Changes

When instantiating INSPECTION-UNIT and after triggering the Synchronize-Tags command, a new RTDS tag will be created
(if it does not already exist) and linked to the FIELD-INSPECTION attribute of the single INSPECTION-UNIT instance

SIEMENS DF PL DER MOM DL 2015

112

SIEMENS DF PL DER MOM DL 2015

113

Operation: To display one or more attribute values next to the icon of the class
1. Right-click the class in the Template view
2. Select Attribute Displays Change
3. Select one or more attributes to be displayed
4. Move the attribute anywhere in the workspace
5. Right-click the class in the Template view
6. Select Attribute Displays Set As Default

SIEMENS DF PL DER MOM DL 2015

114

SIEMENS DF PL DER MOM DL 2015

115

Operation: To show the Contents folder of a class


1. From the Libraries environment treeview, right-click the class
2. Select New Content
3. If needed, refresh the treeview: select View > Refresh
Operation: To remove contents of a subclass
1. Right-click the Contents folder
2. Select Delete
Operation: To go straight to the related class definition
1. Right click a library-instance
2. Select Show Show-Library-Class

SIEMENS DF PL DER MOM DL 2015

116

Operation: To add new specific Contents for a class


1. Select the Contents folder of the class
2. Select Tools Add Object (or click Add Object button (

3. Select either the class palette or a source library from the ones available

4. Use the Click and Click mechanism to drop objects from the palette to the workspace

5. Give each instance a name


6. Configure the remaining properties, if required

SIEMENS DF PL DER MOM DL 2015

117

CHASSIS-ASSEMBLING CELL

SIEMENS DF PL DER MOM DL 2015

CAR-ASSEMBLING CELL

118

CHASSIS-ASSEMBLING

CAR-ASSEMBLING

WAREHOUSE-AREA

SIEMENS DF PL DER MOM DL 2015

PRODUCTION-AREA

AUTOMOTIVE-SITE

119

SIEMENS DF PL DER MOM DL 2015

120

SIEMENS DF PL DER MOM DL 2015

121

Template Editor and Data Template Editor:


Messaging Manager provides two client applications to create the layout of messages:
Messaging Manager Template Editor
This application is a basic editor to generate messages in the form of Windows pop-ups. This editor is more
suitable for simple dialogs: in particular, for example, it is not possible to write custom code in the message to
define its behavior when a button is pressed or data selected
CAB Data Template Editor
This is a tool embedded in Client Application Builder, which allows you to define the structure of the message,
in terms of
- input and output parameters to be exchanged with the operator
- a link to an ASPX web page which defines the appearance of the HTML pop-up to be shown; on this page
you, the developer, are free to add custom code to configure the behavior of the message
For the exercises in this training course, some preconfigured standard Templates and Data Templates are
already provided.
You will learn how to create a standard template using Messaging Manager Template Editor in this chapter; you
will see how to define a Data Template in Chapter 19, which is dedicated to CAB.

SIEMENS DF PL DER MOM DL 2015

122

SIEMENS DF PL DER MOM DL 2015

123

Each item, including the template dialog itself, is uniquely identified by a name, the Mnemonic.
Double-click an item to configure it.

SIEMENS DF PL DER MOM DL 2015

124

SIEMENS DF PL DER MOM DL 2015

125

The following actions can be simulated using MSM:


Obtain-License-Plate
Obtain-Engine-Serial-Nr
Display-Warning-Message

SIEMENS DF PL DER MOM DL 2015

126

Operation: To open Messaging Manager Template Editor


1.

From the Management Console, select Component Messaging Manager (MSM) Template Editor

Operation: To create the SERIAL-NUMBER template


1.

Select File New Template

2.

Right click the template and select Properties

3.

Set the following:


Name: SERIAL-NUMBER
Caption: Obtain Engine Serial Number

4.

Click OK button

Operation: To add and configure the static-label


1.

From the Controls toolbox, add a static-label to the template

2.

Right click the label and select Properties

3.

Set the following:


Caption: Engine Serial Number

4.

Click OK button

(continues to next page)

SIEMENS DF PL DER MOM DL 2015

127

Manual References
MSM Server, Client and Template Editor help manual:
From Start menu, SIMATIC > SIMATIC IT Documentation > English :
- Follow the links to Engineering > Messaging Manager Online Help
MSM Template Editor help manual:
From MSM Template Editor:
- ? > Contents and Index

SIEMENS DF PL DER MOM DL 2015

129

SIEMENS DF PL DER MOM DL 2015

130

SIEMENS DF PL DER MOM DL 2015

131

Operation: To show / hide step names


1. Select Tools Options GUI Plant objects name Visible (this is applied to all steps in all workspaces)
2. Right-click the workspace and select Layout Hide / Show Names (this is applied to all steps in the
workspace)
3. Right-click the single step and select Layout Hide / Show Name (this is applied to the single step)
In any case, the general option (Tools Options) must be activated in order for the more specific ones (on the
workspace and on the single steps) to have an effect.

SIEMENS DF PL DER MOM DL 2015

132

Operation: To define rule arguments:


1. Right click the rule step
2. Select Properties
3. Select Input / Return Arguments tab
4. Click Add
5. Set the following:
Name
Type
Default Value
6. Click Ok
7. Click Ok

SIEMENS DF PL DER MOM DL 2015

133

SIEMENS DF PL DER MOM DL 2015

134

SIEMENS DF PL DER MOM DL 2015

135

SIEMENS DF PL DER MOM DL 2015

136

SIEMENS DF PL DER MOM DL 2015

137

In this picture suppose that Rule-Container-0 is Instance-Based.

SIEMENS DF PL DER MOM DL 2015

138

In this picture suppose that Rule-Container-1 is Class-Based.

SIEMENS DF PL DER MOM DL 2015

139

The NOT OK End-Of-Rule is required in case of failure of the Engine-Serial-Nr-Rule to inform its caller about the
failure.

SIEMENS DF PL DER MOM DL 2015

140

Operation: To add a new Root step


1. Select the Messaging-Rules container in the Raw-Mat-Wh
2. Click the Add object button
3. Add a new Root step to the main workspace
4. Set the following:
Name: ENGINE-SERIAL-NR-RULE
Description: ENGINE-SERIAL-NR-RULE
5. Click OK.
Operation: To add the Send-Message step
1. Add the Send Message step
2. Set the following properties
Name: ASK-ENGINE-SERIAL-NR
Comment: ASK-ENGINE-SERIAL-NR
Destination: {LOCALHOST}
Call Type: CALL
Message Type: {UNSOLICITED}
Message template: {SERIAL-NUMBER}
Always on top: Yes
3. Click OK.
4. Link to the root
Operation: To add the End-Of-Rule step
1. Add an End Of Rule step
2. Set the following properties
Name: NOT-OK
Comment: NOT-OK
Exit-Status: NOT-OK
3. Click OK.
4. Link the EOR (false input!) to the Send message step (false output)

SIEMENS DF PL DER MOM DL 2015

141

Transactions are defined by four properties referred to as ACID:


- Atomicity: changes are saved in the database only if all the queries are executed successfully
- Consistency: a transaction will not break any database constraint
- Isolation: during a transaction no concurrent tasks are able to retrieve or alter any intermediate data created by
a particular transaction task
-Durability: once a transaction is committed, all its effects will be retained even in case of system failure
SIMATIC IT supports database transactions through the following technologies, operating at database level:
Bound Sessions
Distributed Transaction Coordinator (MS DTC)
Note As of SIMATIC IT 6.5, Bound Sessions are used by default to manage transactions. If you upgrade from a
version of SIMATIC IT prior to 6.5 to version 6.5 or higher, however, MS DTC is left as default.

SIEMENS DF PL DER MOM DL 2015

142

SIEMENS DF PL DER MOM DL 2015

143

SIEMENS DF PL DER MOM DL 2015

144

SIEMENS DF PL DER MOM DL 2015

145

SIEMENS DF PL DER MOM DL 2015

146

SIEMENS DF PL DER MOM DL 2015

147

SIEMENS DF PL DER MOM DL 2015

148

For example, the Task Type can be:


Rule-Task, if the action modeled by the method is executed by a Production Modeler rule
Generic-Com-Task, if the action modeled by the method is executed by a COM application integrated with
Production Modeler

SIEMENS DF PL DER MOM DL 2015

149

SIEMENS DF PL DER MOM DL 2015

150

Notice that
if you right click the method icon (e.g. Action-Method-Definition-0 in the picture above) and select Properties
from the contextual menu, you can choose the task type of the method;
if you click the method icon (e.g. Action-Method-Definition-0 in the picture above) and select Task-Details from
the contextual menu, you can browse for the task (i.e. the rule in case of Rule-Task, the script in case of
Script-Task, etc.) linked to the method.
You can browse the method arguments by right-clicking the method and selecting Properties or Task-Details.

SIEMENS DF PL DER MOM DL 2015

151

Operation: To expose the Unload-Truck-Rule as method


1. From Libraries tree view, right click RAW-MAT-WH class
2. Select New Method
3. Set the following:
Name: UNLOAD-TRUCK-MTH
Type : INSTANCE-BASED
Task Type : RULE-TASK
4. Click OK

5. Right click the UNLOAD-TRUCK-MTH method


6. Select Task Details
7. Set the following:
Event to infer: UNLOAD-TRUCK-RULE
8. Click OK to import Input / Return Arguments
Repeat steps from 1 to 8 for all other methods

SIEMENS DF PL DER MOM DL 2015

152

SIEMENS DF PL DER MOM DL 2015

153

SIEMENS DF PL DER MOM DL 2015

154

Notice that
if you click the event icon (e.g. Event-Method-Definition-0 in the picture above) and select Properties from the
contextual menu, you can choose the event type of the event;
if you click the event icon (e.g. Event-Method-Definition-0 in the picture above) and select Task-Details from
the contextual menu, you can browse for the source of the event (i.e. the RTDS tag in case of Cube-Event, the
details of the COM application in case of Generic-COM-Event, etc.).

SIEMENS DF PL DER MOM DL 2015

155

SIEMENS DF PL DER MOM DL 2015

156

The arguments of an event can be used to provide additional information concerning the occurrence signaled. For
example, an automated system signaling the arrival of a raw material in the warehouse could bring as additional
information the bar code of the incoming material lot.
Event arguments are displayed in the Input Arguments tab of the Properties window.

SIEMENS DF PL DER MOM DL 2015

157

Operation: To create a CUBE-EVENT to be linked to the TRUCK-ARRIVED tag


1. From the Libraries treeview, right click RAW-MAT-WH class
2. Select New Event
3. Set the following:
Name: TRUCK-IN-DELIVERING
Type: INSTANCE-BASED
Event Type : CUBE-EVENT
4. Click OK
5. Right click the TRUCK-IN-DELIVERING event
6. Select Task Details
7. Set the following:
Unit: CAR
Cube-Name: TRUCK_ARRIVED
Default Update Interval: 1 second
Cube Polling Class: 1 : 1 second
Activation Value: 1
Reset Value: 0
Reset Mode: Immediate

SIEMENS DF PL DER MOM DL 2015

158

SIEMENS DF PL DER MOM DL 2015

159

SIEMENS DF PL DER MOM DL 2015

160

SIEMENS DF PL DER MOM DL 2015

161

Operation: To create the TRUCK-MANAGEMENT rule container


1. From the AUTOMOTIVE library, navigate to RAW-MAT-WH
2. Right click the Rules folder and select New Rule Container
3. Set the following:
Name: TRUCK-MANAGEMENT
Rule-Type: Instance-Based
Operation: To rename the Root step in the TRUCK-MANAGEMENT rule container
1. From main workspace, right click the Root step and select Properties
2. Set the following:
Name: Truck-Arrival
Description: Truck-Arrival

SIEMENS DF PL DER MOM DL 2015

162

SIEMENS DF PL DER MOM DL 2015

163

The Expression configured in the Condition step is evaluated as soon as the runtime execution reaches the step:
If the Expression is TRUE, the step turns green and execution goes on following the TRUE output path
If the Expression is FALSE, the step turns red and execution goes on following the FALSE output path

1
R
2

SIEMENS DF PL DER MOM DL 2015

164

In the Expression field of a data Parameter you can configure complex expressions by using PM scripts
The same scripts can be used also in the Script-Caller rule step.
Allocation-Functions: to check how many rules are booking a piece of equipment
Arithmetic-Functions: to perform mathematical calculations (square root, random numbers generation,
trigonometric functions, ...)
Bitwise-Functions: to perform logical operations (AND, OR, XOR, ...)
Date-Time-Functions: to manage date-time format and convert between System, Unix, UTC and COM
representation
Equipment-Specification-Functions: to retrieve information about runtime values for equipment specification
parameters
Error: to manage error descriptions and sources
Evaluate-Expression: to get the values of Windows environment variables
GSI-Checking-Functions: to get information concerning the connections between PM and SIMATIC IT
Components or between SIMATIC IT Components and the SITMesDb database
Material-Specification-Functions: to retrieve information about runtime values for material specification
parameters
Quantity-Functions: to convert a TEXT or TRUTH-VALUE input argument into a QUANTITY

Retrieve-Caller-Object: returns the step which called the current rule


Retrieve-Executor-Object: returns the Root of the rule which is called by the current step
Retrieve-Previously-Executed-Object: to retrieve information about the previously executed step (name, a
specific attribute, ...)
Retrieve-Parent-Object: to retrieve information about the parent of a specific item (parent class, a specific
parent attribute, ...)
RDTS: to interact with RTDS

SIEMENS DF PL DER MOM DL 2015

165

SIEMENS DF PL DER MOM DL 2015

167

SIEMENS DF PL DER MOM DL 2015

168

You can use the Expression field to read from a source step and Destination Object and Attribute to write to some destination.
Note that the Root has the opposite configuration:
Destination Object and Destination Attribute are available to store the values of input arguments to some destination to be
used by other steps within the rule
and
Expression is available to create a value for return arguments.
When giving a constant value to an input argument, it is exactly the same to write it in the Default Value field or in the
Expression field.
If the data type of the argument is TEXT, remember to type the expression value between double quotes.
For example, if you want to assign an initial value equal to value1 to the Input Argument 1 of type TEXT you can open the
properties window and either
type value1 in the Default Value field
or
type value1 in the Expression field.

SIEMENS DF PL DER MOM DL 2015

169

SIEMENS DF PL DER MOM DL 2015

170

For the Return Argument configure Destination Object only, the Destination Attribute must be left blank:

For the Input Argument configure the Expression:

SIEMENS DF PL DER MOM DL 2015

171

Configure Destination Object and Destination Attribute in a rule step argument:


Destination Attribute: insertion policy to be used (INSERT-AT-BEGINNING, INSERT-AT-END or CURRENTVALUES)

Configure the Expression in a rule step argument:


Expression: the name of the local list and a position index between square brackets (indexes start at 0)

SIEMENS DF PL DER MOM DL 2015

172

Configure Destination Object and Destination Attribute in a rule step argument:

Configure the Expression in a rule step argument:

SIEMENS DF PL DER MOM DL 2015

173

Configure the Expression in a rule step argument:

SIEMENS DF PL DER MOM DL 2015

174

Display Object
configuration:
1.

first window:

2.

second window (it opens


after clicking OK in the
first one):

SIEMENS DF PL DER MOM DL 2015

175

SIEMENS DF PL DER MOM DL 2015

176

The Engine-Serial-Nr-Rule opens a dialog where the operator enters the serial number of the engine, containing
two buttons: OK and Add To List.

We suppose that the operator is given a paper list of expected engines. The operator must click:
- OK to acknowledge the engine if present in the list
- Add To List if the engine is not present in the list (because it was not ordered by the car company): in this
case we suppose the new engine is nevertheless accepted, but it must be added to the list and a complaint
letter is prepared to be sent to the vendor

SIEMENS DF PL DER MOM DL 2015

177

SIEMENS DF PL DER MOM DL 2015

178

The use of local variables in the current exercise is suggested as the easiest way; nevertheless other methods
(display object, direct link, equipment attribute) can be used
If the operator has clicked OK in the previous Send-Message step, then continue, otherwise (which means that
the operator clicked Add_To_List) you need to display a warning message

SIEMENS DF PL DER MOM DL 2015

179

SIEMENS DF PL DER MOM DL 2015

180

SIEMENS DF PL DER MOM DL 2015

181

SIEMENS DF PL DER MOM DL 2015

182

Note: When you browse the Destination Object and Destination Attribute, the system will write the appropriate
syntax for you. E.g. note that, as you click OK, the system replaces AUTOMOTIVE.RAW-MAT-WH with THEPLANT-OBJECT (i.e. a keyword that, in each instance of the class, is automatically substituted for the identifier of
the instance)
Add a new setting action to the arguments of the Set-Multi-Variable
Set the following:
Name: Record-License-Plate
Type: TEXT
Expression: LICENSE-PLATE local-variable
Destination Object: browse for AUTOMOTIVE.RAW-MAT-WH
Destination Attribute: browse for TRUCK-LICENSE-PLATE

SIEMENS DF PL DER MOM DL 2015

183

SIEMENS DF PL DER MOM DL 2015

184

The value contained in a Display-Object rule step can be retrieved with the following expression:
the ACTUAL-VALUE of <name of Display-Object>

SIEMENS DF PL DER MOM DL 2015

185

Note:
Exit-Condition may be set in order to check the values of event arguments, in case the event is not a Cube-Event.

SIEMENS DF PL DER MOM DL 2015

186

SIEMENS DF PL DER MOM DL 2015

187

The value contained in a Display-Object rule step can be retrieved with the following expression:
the ACTUAL-VALUE of <name of Display-Object>

SIEMENS DF PL DER MOM DL 2015

188

Both steps are available in two versions:


One-shot (parallel):
the execution goes on along the stubs corresponding to all true expressions
In sequence (serial):
the execution goes on along the path corresponding to the first true expression

SIEMENS DF PL DER MOM DL 2015

189

SIEMENS DF PL DER MOM DL 2015

190

The steps are used to convert the code value into a description and write it into the MES-QUALITY attribute of the
INSPECTION-UNIT class

SIEMENS DF PL DER MOM DL 2015

191

The steps are used to convert the code value into a description and write it into the MES-QUALITY attribute of the
INSPECTION-UNIT class

SIEMENS DF PL DER MOM DL 2015

192

SIEMENS DF PL DER MOM DL 2015

193

SIEMENS DF PL DER MOM DL 2015

194

Visibility of steps involved in a loop:


After the configuration of the PORT-NAME attribute in the LOOP step, all the steps following the LOOP-IN will be
able to browse information available before the LOOP.
On the opposite side, a step in the branch that contains the LOOP step cannot work on steps that follow the
LOOP-IN.
Loop cycle iteration number
Usually loops are used to cycle through Rule-Local-Lists. It often happens that you need to identify the current
iteration of the loop in your syntax. This can be done by means of the following keywords:
"the current-loop-cycle of the-port-in"
Loop cycle numbering starts at 1.
Note that indexing in Rule-Local-Lists starts at 0. Thus, in order to keep the two numerations aligned youll use
the following syntax:
"the current-loop-cycle of the-port-in 1

SIEMENS DF PL DER MOM DL 2015

195

SIEMENS DF PL DER MOM DL 2015

196

SIEMENS DF PL DER MOM DL 2015

197

SIEMENS DF PL DER MOM DL 2015

198

SIEMENS DF PL DER MOM DL 2015

199

SIEMENS DF PL DER MOM DL 2015

200

You can find as many palettes as libraries that you have loaded in the project (including the S95-Industry-Library).

SIEMENS DF PL DER MOM DL 2015

201

SIEMENS DF PL DER MOM DL 2015

202

Only one version of the same plant (i.e. the current version) can be used by SIMATIC IT Components at a time:
e.g., this means that you can define production orders to be executed only in the current version of the plant.
You will have a complete picture of the relationship between the equipment model defined in PM and SIMATIC IT
Components at the end of the training course.

SIEMENS DF PL DER MOM DL 2015

203

SIEMENS DF PL DER MOM DL 2015

204

Synchronization mechanisms always propagate the changes made to a class (in the Libraries environment) to its
instances, either in the Libraries or in the Plants environment.
The model is always the class, it is not possible to use synchronization in order to propagate changes from an
instance to the class.

SIEMENS DF PL DER MOM DL 2015

205

It is also possible to synchronize the following separately:


a single rule container (if changes have been applied only to one or more of the rules inside it);
a single method (if changes have been applied only to that specific method);
a single event (if changes have been applied only to that specific event).
SYNCHRONIZATION OF PLANTS ENVIRONMENT OBJECTS:
In order to propagate changes made in the Libraries environment to the Plants environment, right-click the rule
container, method or event in the tree-view and select Synchronize > Instances.

SIEMENS DF PL DER MOM DL 2015

206

SYNCHRONIZATION OF LIBRARY OBJECTS:


The only synchronizable items belonging to library instances (i.e. when you click a class and select Synchronize >
Library Instances or when you click an instance and select Synchronize > Instance) are Attributes and Contents.
You cannot synchronize Methods, Rules, Rule of Rules, because they are not contained in library instances, only
in class definitions and plant instances.

SIEMENS DF PL DER MOM DL 2015

207

SIEMENS DF PL DER MOM DL 2015

208

Example:
My-Cell class contents have been modified, by adding to it a new instance My-Unit-1. Imagine you want to
propagate the change until the Plants environment using the synchronization commands.
The plant My-Site-0 in the Plants environment is an instance of the class My-Site, i.e. My-Site is the template for
My-Site-0. Therefore you have to:
1. update My-Site class first (the easiest way to do it is to proceed bottom-up)
2. synchronize its plant instance My-Site-0 after

SIEMENS DF PL DER MOM DL 2015

209

1. To synchronize all the library instances contents at any level:


A. Right-click the class My-Cell and select Synchronize > Library Instances: the class My-Cell is the
template for the contents of My-Area My-Unit-1 is added to My-Area
B. Right-click the class My-Area and select Synchronize > Library Instances: the class My-Area is the
template for the contents of My-Site My-Unit-1 is added into the hierarchy of My-Site
C. My-Site, i.e. the template for the contents of the plant instantiated in the Plants environment, is now up to
date

SIEMENS DF PL DER MOM DL 2015

210

1. To synchronize the My-Site-0 plant contents, right-click the class My-Site, i.e. the template for My-Site-0,
and select Synchronize > Instances

SIEMENS DF PL DER MOM DL 2015

211

SIEMENS DF PL DER MOM DL 2015

212

In case the tag already exists in the Unit, the Synchronize-Tags command establishes the connection between
the attribute / event and the tag.
In case the tag does not exist in the Unit yet, the Synchronize-Tags command creates a tag with the name
specified by the syntax explained in Chapter 4 and connects it to the given attribute/event.

SIEMENS DF PL DER MOM DL 2015

213

For example, the FIELD-INSPECTION attribute of the INSPECTION-UNIT:

SIEMENS DF PL DER MOM DL 2015

214

Manual References
PM help manual:
From Production Modeler User Interface:
- Help > Contents and Index

From Start menu, SIMATIC > SIMATIC IT Documentation > English:


- Follow the links to Engineering > Production Modeler

SIEMENS DF PL DER MOM DL 2015

215

SIEMENS DF PL DER MOM DL 2015

216

SIEMENS DF PL DER MOM DL 2015

217

In the Plants environment it is possible to select a rule and activate it manually choosing either Activate or
Activate-And-Show:
With the second command you are redirected to the execution copy of the rule in the Run Time environment
automatically.

SIEMENS DF PL DER MOM DL 2015

218

SIEMENS DF PL DER MOM DL 2015

219

SIEMENS DF PL DER MOM DL 2015

220

SIEMENS DF PL DER MOM DL 2015

221

SIEMENS DF PL DER MOM DL 2015

222

SIEMENS DF PL DER MOM DL 2015

223

SIEMENS DF PL DER MOM DL 2015

224

Logging must be enabled in PM options (Tools > Options > Logs > Object Execution Log Level), as seen in the
previous slides.

SIEMENS DF PL DER MOM DL 2015

225

SIEMENS DF PL DER MOM DL 2015

226

Note:
If you trigger the Show > Calling Stack command by clicking the Method-Caller, you will be displayed all
subroutines called by the rule.

Otherwise, if you trigger the Show > Calling Stack command by clicking the task icon (representing the action
activated by the Method-Caller), you will be displayed only the subroutine called by the task the step is related to.

SIEMENS DF PL DER MOM DL 2015

227

SIEMENS DF PL DER MOM DL 2015

228

The number and type of available details depends on the step for which you are configuring the breakpoint.
For example, for a Method-Caller:

SIEMENS DF PL DER MOM DL 2015

229

Continue:
to acknowledge the breakpoint and complete the execution of the rule.
Step-Into:
to acknowledge the breakpoint in the single step and perform a step-by-step execution of the rule, including a
step-by-step of the sub-routines.
Step-Over:
to acknowledge the breakpoint in the single step and perform a step-by-step execution of the rule, but not of the
sub-routines.
Step-Out:
to acknowledge the breakpoint in the sub-routine and complete its execution, before going back to the calling rule.

SIEMENS DF PL DER MOM DL 2015

230

Operation: To enable logs


1. Select Tools Options Log Object Execution Log Level

SIEMENS DF PL DER MOM DL 2015

231

SIEMENS DF PL DER MOM DL 2015

232

SIEMENS DF PL DER MOM DL 2015

233

The logging objects are defined in the Common-Tools-Folder Log-Files-Folder of the library.
The possible kinds of logging objects are:
CSV Log File: to log on CSV file
EVL Log File: to log on System Event Logger
LBK Structure: to log through the Logbook service
TEXT: to log on a text file

SIEMENS DF PL DER MOM DL 2015

234

Business Process Execution Language


Business Process Execution Language (BPEL) is an XML-based specification language for the formal specification of
business processes and business interaction protocols.
It defines many activities that are used to compose an execution flow. Typical BPEL activities are: receiving messages,
evaluating expressions to update message values and metrics, deciding on next steps, invoking external services, waiting,
and starting parallel executions.
BPEL process flows are usually described in XML documents.

SIEMENS DF PL DER MOM DL 2015

235

For more information about compiling rules, refer to the Production Suite Advanced Course or to the
documentation:
From Start menu, SIMATIC > SIMATIC IT Documentation > English > Production Suite:
- Follow the links to Engineering > Compiled Rules

SIEMENS DF PL DER MOM DL 2015

236

SIEMENS DF PL DER MOM DL 2015

237

The recovery feature affects the performance of the system (around 50% less): to avoid this, it is possible to
customize recovery settings in each single workflow.
Due to their nature, transactional rules are not recovered in case of PM crash; instead, the corresponding
transactions are automatically closed and their data rolled back. At subsequent PM restart, those rules are
restarted automatically from the beginning and new transactions are created.

SIEMENS DF PL DER MOM DL 2015

238

For more information about custom application logging, refer to the Production Suite Advanced Course.

SIEMENS DF PL DER MOM DL 2015

239

Manual References
PM help manual:
From Production Modeler User Interface:
- Help > Contents and Index

From Start menu, SIMATIC > SIMATIC IT Documentation > English > Production Suite:
- Follow the links to Engineering > Production Modeler
- Follow the links to Engineering > Compiled Rules
- Follow the links to Concepts and use >Production Modeler Transaction Management
- Follow the links to Engineering > Logbook Configuration

SIEMENS DF PL DER MOM DL 2015

240

SIEMENS DF PL DER MOM DL 2015

241

SIEMENS DF PL DER MOM DL 2015

242

Operation: To open the PM Com Server interface


1. From Management Console, select
Component Production Modeler Production Modeler COM Server Configurator
Note: The PM COM Server connected to the local PM Server is already running on your workstations, as it has
been added to the start up list.
.

SIEMENS DF PL DER MOM DL 2015

243

SIEMENS DF PL DER MOM DL 2015

244

The PM COM Server has to be installed, configured and launched locally on the workstation which hosts the
COM application to be integrated.
In the configuration phase, the PM COM Server retrieves the description of the COM application from the local
registry, and sends it to PM.
At runtime, PM accesses COM Properties, calls COM Methods and receives COM Events of the COM
application via the PM COM Server.
Communication between the PM COM Server and the COM applications takes place via COM (they both reside
on the same PC), while the PM COM Server and PM communicate via TCP/IP.
COM communication with PM is used by SIMATIC IT Messaging Manager and any 3rd-party COM-compliant
application. Other SIMATIC IT Components use a proprietary interface: GSI (e.g. POM-GSI, MM-GSI, etc.).

SIEMENS DF PL DER MOM DL 2015

245

When you click OK in the Parameters window, the system establishes a link between the subclass of the COMLOGICAL-UNIT you have created and the real COM application. After that, when you click the class icon you
can import COM-Properties, COM-Methods and COM-Events. The list of imported objects becomes available
in the tree-view in the PM user interface.
The COM application you are going to integrate is MS Word

As a good programming practice, the new COM-LOGICAL-UNIT class to model MS-Word has been created in a
dedicated library, since the AUTOMOTIVE library should contain only the physical equipment of the plant.
In this way, the integration with the external application can be esaily re-used in other projects.

SIEMENS DF PL DER MOM DL 2015

246

Operation: To import COM Methods / Events / Properties


1. From the main workspace, right click the modeling class
2. Select
Import COM Methods (or COM Events or COM Properties)
3. Flag all the needed behaviors
4. Click OK

SIEMENS DF PL DER MOM DL 2015

247

Operation: To manage the failure of an external method


1. Open the Properties of the Method-Caller
2. Set the following:
Owner-Class
Method-To-Call
3. Click Apply (this allows the system to import the arguments of the selected method)
4. Set the following:
Expression: <expression to be evaluated in order to manage the failure>

2
4
3

SIEMENS DF PL DER MOM DL 2015

248

Release notes, hardware requirements and installation guidelines:


From Start menu, SIMATIC > SIMATIC IT Documentation > English:
- Follow the links to Release Notes, Installation and Configuration
PM COM Interface help manual:
PM COM Interface:

- Help > Contents and Index


PM Multi-COM Interface:
- Help > Contents and Index

SIEMENS DF PL DER MOM DL 2015

249

SIEMENS DF PL DER MOM DL 2015

250

Note: For training purposes the high level rules for the chassis production has been already designed in the
project (You will layout the other and the auxiliary ones in later exercises.)

SIEMENS DF PL DER MOM DL 2015

251

SIEMENS DF PL DER MOM DL 2015

252

In the training scenario two MOs are required to produce the car (one per each assembling cell):
Chassis-MO (already implemented in the training scenario, but with some missing configurations)
Car-MO (to be implemented)

SIEMENS DF PL DER MOM DL 2015

253

In order to manage the production, 3 MTs will be invoked from a MO:


Init-MT: manages point 1
Exe-MT: manages point 2-4
End-MT: manages point 5

SIEMENS DF PL DER MOM DL 2015

254

SIEMENS DF PL DER MOM DL 2015

255

SIEMENS DF PL DER MOM DL 2015

256

SIEMENS DF PL DER MOM DL 2015

257

The MOs are started by the CATCH-ORDER-ACTIVATION rule.


Each MO invokes its INIT-MT, EXE-MT and END-MT subroutines in sequence and then, depending on their
successful or unsuccessful execution, it sets the entry status to COMPLETED or NOT-CONFORMED.
This final status change will be trapped back by the CATCH-ORDER-ACTIVATION rule which will go on with the
workflow.
Note: For training purposes the Chassis-MO for the production has been already designed in the project (You will
layout the auxiliary ones in later exercises.)

SIEMENS DF PL DER MOM DL 2015

258

The INIT-MT rule sets 1 into the IN-USE attribute of the CHASSIS-ASSEMBLING line.
The END-MT rule sets 0 into the IN-USE attribute of the CHASSIS-ASSEMBLING line.
The EXE-MT is already laid out but only partially configured. You will complete its configuration in later exercises.

SIEMENS DF PL DER MOM DL 2015

259

SIEMENS DF PL DER MOM DL 2015

260

If the result of the inspection is not of good quality, the rework function is activated (for this reason the CallRework Method-Caller has been connected to the FALSE output branch of the Call-Inspection Method-Caller)
The rules must then be exposed as methods in order to be called by the Method-Callers

SIEMENS DF PL DER MOM DL 2015

261

SIEMENS DF PL DER MOM DL 2015

262

SIEMENS DF PL DER MOM DL 2015

263

SIEMENS DF PL DER MOM DL 2015

264

In the table below you can see a comparison beetween functions and procedures.
Object Independence

Nesting

Single Step Execution

Recursion

Function

Yes, functions can be used to


Yes. The
perform specific tasks within any nesting of
object that accepts an Expression functions is
unlimited

No, some objects (e.g. the


Set-Multi-Variable) can be
configured to execute more
than one function at time

Yes, but
functions
cannot exceed
the 50th
recursion

Procedure

No, procedures can only be used


in the Script-Caller

Yes, each script execution


requires a dedicated step in
the rule

No

SIEMENS DF PL DER MOM DL 2015

No

265

SIEMENS DF PL DER MOM DL 2015

266

Action-Type:
START: the rule is called asynchronously (i.e. the main workflow goes on without waiting for its completion);
CALL: the rule is called synchronously (i.e. the main workflow waits for the subroutine to be completed before
going on).
Note: A PM-Event-Deduction with Action-Type = CALL acts in the same way as a Method-Caller with Task-Type
= RULE-TASK

The Method-Caller can call any type of method synchronously, including rule-task methods
The PM-Event-Deduction can only call rules, both synchronously (CALL) and asynchronously (START)
If you need to call a rule synchronously, the PM-Event-Deduction performs better than the Method-Caller,
because it does not use a middle-interface (i.e. the method)

SIEMENS DF PL DER MOM DL 2015

267

SIEMENS DF PL DER MOM DL 2015

268

SIEMENS DF PL DER MOM DL 2015

269

SIEMENS DF PL DER MOM DL 2015

270

The workflow described in this rule is very simple


1. The Set-Multi-Variable step reads the Serration-Torque rule input and stores it in the Assembling-Machine
SERR-TORQUE attribute
2. The Delay simulates the physical assembly, pausing the rule for a lapse of time proportional to the value of
the serration torque

SIEMENS DF PL DER MOM DL 2015

271

SIEMENS DF PL DER MOM DL 2015

272

SIEMENS DF PL DER MOM DL 2015

273

SIEMENS DF PL DER MOM DL 2015

274

SIEMENS DF PL DER MOM DL 2015

275

SIEMENS DF PL DER MOM DL 2015

276

SIEMENS DF PL DER MOM DL 2015

277

SIEMENS DF PL DER MOM DL 2015

278

SIEMENS DF PL DER MOM DL 2015

279

SIEMENS DF PL DER MOM DL 2015

280

SIEMENS DF PL DER MOM DL 2015

281

SIEMENS DF PL DER MOM DL 2015

282

SIEMENS DF PL DER MOM DL 2015

283

SIEMENS DF PL DER MOM DL 2015

284

SIEMENS DF PL DER MOM DL 2015

285

SIEMENS DF PL DER MOM DL 2015

286

SIEMENS DF PL DER MOM DL 2015

287

SIEMENS DF PL DER MOM DL 2015

288

SIEMENS DF PL DER MOM DL 2015

289

Das könnte Ihnen auch gefallen