You are on page 1of 239

System Overview

Objectives

- Application Possibilities
- Forms of Delivery
- Core Functions
- Architecture

Application Possibilities of WinCC

Customer Benefits

The Basic Functions

anzahl () float zae


begin
if wert > 0 begom
zae = zae + 1
end end

Motor ein Ventil geschlossen Klappe


zu

Alarm Logging
(Message
System)

Programming
Interfaces

Process Visualization
Standard
Interfaces

Tag Logging
(Archiving)
Protokolle

Report Designer
(Report System)

PLC
Communication

Basic Process Control 1/2

OS-Projecteditor
Group Display
Picture Tree Manager
Time Synchronization
Horn Editor
Lifebeat Monitoring
Graphic Object Update Wizard*
Block List Editor*
Chipcard (Option)

As of Version 6.0, there is no longer a license check for the Basic Process Control
package. * Function can only be used in PCS7.

Basic Process Control 2/2


Subnavigation Window
Window Technique
Overview Area

Work Area

Toolbar Area

Licenses and Options


Options

Licenses

RC
64,000
Power Tags

64,000
Power
Pack
(8000)

Runtime

64,000

64,000

Power

WinCC Chip
card reading
function

WinCC Web
Navigator

WinCC
Redundancy

Power Tags
Pack (8000)

RC
8000
Power Tags

8.000

Runtime
8000
Power Tags

Power
Pack
(1024)

RC
1024

Runtime
1024

Power Tags

Power Tags

1024

RC
256

Power
Pack
(256)

Power Tags

Runtime
256

Power Tags

1024
Power
Pack
(256)

Power Tags

256

RC
128

8.000
Power
Pack
(1024)

Power
Pack
(128)

Runtime +
Configuration (RC)

Runtime
128
Power Tags

WinCC

Allen Bradly DF1


serial

WinCC
256
Power
Pack
(128)

Runtime (RT)

WinCC

ProAgent

Server

WinCC

Dat@Monitor
(Web_Client)

512 archive tags are included in the basic system.

WinCC

Software

ODK

WinCC

User
Archives

System Software and Systems


CD-ROM with system software,
options,
tools and documentation
Authorization diskette

W inCC

W inCC

S IE MEN
S

SI C OM P
IP C RI
20

SIMATIC
Office PC

SIMATIC
Industry PC

SIMATIC
Panel PC

PC 670

PC 870

WinCC Software Protection

W inCC

Installation
Option n
S IE M E N S

SI C O M P
IP C R I 2 0

Option1

De-Installation
WinCC and Multi authorization

System Configurations
Corporate
Management
Level

PC Network

Client

Server 1

Client

... Server 12
Distributed
systems with

...
Client

Client

Server and Client

Server / R.-Server

Management Level and


Production Level

Multi-user system with


Server and Client
Client

Client

Server

LAN-Netz

Single-user
system
with PC and OP

Process Supervision Level


and Production Management
Level
SIMATIC NET

Automation Level

SIMATIC
WinAC MP

Distributed
Peripherals

MPI
(not with S5)
S5/S7 S505 S5

S7 S505 S5/S7

Configurations for Single-user Systems

Example 1

Example 2
COROS OP45

Serial coupling

Coupling via
Network

Point to Point serial


V.24 / TTY
DK3964R + RK512

SIMATIC S5 / S7 / 505
or
PLCs from other manufacturers

WinCC

MPI (only S7) ,


SIMATIC NET PROFIBUS
SIMATIC NET Industrial Ethernet

SIMATIC S5 / S7 / 505
or
PLCs from other manufacturers

Multi-user System

Client 1

...

Client 32
SIMATIC NET
Industrial Ethernet:
TF (Technological
(S7), S5:
Functions)
S7: S7 Protocol

Terminal bus (PC Network)

all WinCC
applications

all WinCC
applications

SIMATIC NET
Profibus:
(S7), S5: FMS (PROFIBUS)
S7: S7 Protocol

Red. Server

Server

SIMATIC NET

SIMATIC 505

SIMATIC S7-400
SIMATIC S5

Note: This WinCC configuration is also used for multi-configuration.

Distributed Systems / Web Technology

WinCC Web Client

all WinCC
applications

all WinCC
applications

M Client 1

M Client 32

Terminal bus (PC Network)

WinCC Web Server


all WinCC
applications

all WinCC
applications

Red. Server

Server 1

all WinCC
applications

Server12

-Technological distribution
-Functional distribution
-Load distribution

...
SIMATIC NET

SIMATIC 505

SIMATIC S7-400
SIMATIC S5

The Architecture

WinCC Explorer

System Controller

CS RT

Grap
hics

CS RT

CS RT

CS RT

Glob
al
Scripti
ng

Alar
m
Loggi
ng

Tag
Loggin
g

CS RT

CS

Repo
rt
Design
er

RT

Option

CS

CS

CS
RT

Access
Protection

...

RT

TextLibaray

Tag Management Process


Data

RT

Data Manager

MS 2000
SQL-Server

.mdf
RT .mdf

S5

S7

Openness
OPC Client
Network

User
Programs

Management
Analysis
Optimization
...

OPC Server

Graphics OCX
Trend

API

Windows
Applications

Active X
OLE

Excel

Alarm
ODBC/SQL

Report

Word
Access
OLE DB(ADO)
PowerBuilder
DDE

Data Manager

OPC Net Server

SIMATIC NET

OPC

...

Hardware and Software Requirements

Installation

Hardware
According to the Installation Guidelines (InstallNotes.pdf)

Software
Microsoft operating system Win2000 or WinXP
Windows 2000 SP3 or Windows XP SP1 (included in delivery)
Microsoft Message Queuing services (from Windows Installation CD)
Internet Explorer V6.0 SP 1 (included in delivery)
Microsoft SQL Server 2000 SP3 (included in delivery)
WinCC V6.0
SIMATIC NET, V6.0 SP5 (November 2002) for Windows 2000 and Windows XP
Installation of the authorizations

Migration of Configuration from V5 to V6 1/2


Requirements
WinCC V5.0 SP2 or V5.1 Project
Sybase 7 installed
from existing WinCC V5 installation
from WinCC V5 CD (WinCC\setup\Products\Sybase_7)

Tools: Project Migrator Wizard from Storage

Steps
Parameterize Migration Tool for the migration of Configuration
and Runtime databases (also Storage)
Convert Screens, Libraries, etc.

Migration of Configuration from V5 to V6 2/2

TCP/IP

1... n

SIMATIC NET

Standard Client/Server
Migration Tool automatically converts the Server project including the computer list
Sybase Installation must still exist on the WinCC computer for conversion to MS SQL.
Multi-Client/Server
Separate migration of the Server and ALL Client projects
Sybase must be present on ALL WinCC computers for the migration
Initial Export and Import (create new) of the Server packages is necessary after that it runs automatically.

Customer Support
Questions

selection

Questions on

on

handling

handling

products and systems ?


of products and systems ?

No guaranteed response
time Principle of first in - first
out
Weekdays (Mo. - Fr.) from 8:00
- 17:00

Product Support

Guaranteed response
time
< 2 hours
24h support on weekdays

Using a
SIMATIC AV Card
(if in a hurry)

Your regional partner in the region/worldwide

http://www3.ad.siemens.de/partner/

Automation & Drives -Technical Support


Your specialists for SIMATIC, SINUMERIK, Drives, ....

0180 5050 222


Fax
- 223
Basic Support (Free
Connect)

0911-895-7777
Fax
-7001
Premium Support (Fast
Connect)

More than 70 specialists are handling your inquiries

Dispatcher
E-mail: techsupport@ad.siemens.de

A&D on the Internet: http://www.ad.siemens.d


e/support then link to Product Support

Receives your inquiry and passes it on to the specialists

Questions about authorization


of software products: 0911-895-7200

Training Center Information

TC Nrnberg-Moorenbrunn

Basic and Advanced WinCC Courses 1/2


Project design/Programming/Commissioning engineers
Experience with graphic interfaces,
such as Windows

SIMATIC WinCC
Operating and Monitoring, System Training

ST-BWINCCS

5 Days

SIMATIC WinCC
Advanced Course

ST-BWINCCV

5 Days

Basic and Advanced WinCC Courses 2/2

1)
SIMATIC WinCC
Operating and Monitoring, System Training

ST-BWINCCS

5 Days

1) Programming engineer,
Project design engineer,
Commissioning engineer
possibly Decision
makers Maintenance
.
.
.
1)
SIMATIC WinCC
Advanced Course

ST-BWINCCV

5 Days

Creating a Project, Coupling a PLC, and Tag Simulation 1

Creating a Project, Coupling a PLC, Variable Simulation 2

Objectives

- Creating a Project
- Installing Communication Drivers
- Configuring Tags
- Tag Simulation
- Cross Reference

Configuration Preparation

- Programmable Logic Controllers


- Type of Coupling
- Process Tags

Creating a Project

Office PC or
Industrial PC

-one Single-User
-one Server, several Clients without their
own project
-Distributed Systems, several Clients
with their own
project

SIMATIC NET

PLC

WinCC Project Structure and Files

-Tag Logging RT-Data


-Alarm Logging RT-Data see Text

-Imported RT-Data
-Cross Reference List (.xfc)

-Database Logfile
-Main File of the Project

-Computer Name
-Configured Screens (.pdl, .sav)
-Screen Files (.bmp, .emf, .wmf)
-Action Lists (.act)

-Project Functions (.fct)


-Projekt Library (.pxl)
-Funktion Declarations (.h)
-Function Library (.dll)
-Project Actions (.pas)
-Report Layouts (.rpl)

-Database with
Configuration Data
-Cross Reference Main
File
-Log File to Database
-Master-DB with link to the RT-Files +
User Archive-Database

Interchanging between Projects

Project name. MCP

Specifying Project Properties

Computer Properties (1/2)

Computer Properties (2/2)

.cur
.ani

Function Modules within WinCC 1/2

Project(name) with

Editors
- Graphics system
- Message system
- Measured value acquisition
and archiving
- Report system
- C-Programs, VBS and actions
- Text library
- Password protection
- Cross Reference

- Computer
- Tag Management
- Structure Types

Transfer edited data to


the Operator Station

WinCC hierarchical tree structure

Function Modules within WinCC 2/2


Deactivate Activate

Editors

- Graphics system
- Message system
- Measured value acquisition
and archiving
- Report system
- C-Programs, VBS and actions
- Text library
- Password protection
- Cross Reference

-Option

Task Definition
17.02.96 11:15:45
SIMATIC WinCC

Motor picture

Bottling plant

Start picture

Alarm Logging Messages

Trends

Setpoint speed
Actual speed

Data Management

Reports

Tags for the Process Connection


Process

Coupling

Process Image

Function

such as, DB,DW for SIMATIC


10
11
12
13.0

Setpoint speed
Actual speed

20
SIMATIC S5
SIMATIC S7
SIMATIC 505

30
35

Archive

Other drivers
40.0
40.1

Message

events

Motor 1 defective
Valve 3 sticks
...

Data Exchange with SIMATIC S7

Programmable Logic Controller

WinCC Station

Actual value 190

Setpoint value 95
DB20
DBW 6 Int=190
DBW 8 Int=95
Image

Actual speed
DB20.DBW6

Setpoint speed
DB20.DBW8

Digital output
LAN
Digital input

MPI

Data Exchange with SIMATIC 505

Programmable Logic Controller

WinCC Station

Actual value 190

Setpoint value 95
V010

=190
=95

Image

Actual speed V010,

Setpoint speed
V010,

Digital output
LAN
Digital input

MPI

Installation of the SIMATIC Device Drivers (S7-DOS)

Communication Structure

WinCC Application (Graphics RT, Alarm Logging RT, Tag


Logging RT, etc.)

WinCC Data Manager

Lab Station:
WinCC communication drivers (e.g. SIMATIC S/Protocol Suite)

MPI

S7-DOS Driver

CP5611

S7-300

Channel unit (e.g.


PROFIBUS)

Hardware driver (e.g. S7CP 5613)

Communication processor (e.g. CP


5613)

PLC
(e.g. SIMATIC S7-300 withCP 342)

Exercise 3: Motor Operation and Motor Color Change

Motor operation

setpoint speed operation

Motor symbol with color animation

SIMATIC HMI
Siemens AG 2003. All rights reserved.

Aktionen.pdl

Exercise 4: Calculation of an Output Value with C

In Object Properties ->Miscellaneous set the attribute


Sizeable to yes.

SIMATIC HMI
Siemens AG 2003. All rights reserved.

Exercise 5: Calculation of an Output Value with VBS and Troubleshooting


Aktionen.pdl

Exercise 6: Bar Graphs for Setpoints and Actual Values

Bar graph for setpoint speed


Bar graph for actual speed

Exercise 7: Status Display


Zustandsanzeige.pdl

close
open

Exercise 8: Two-Step Operation

Operating picture: Mot1.pdl

Motor.pdl

Configuration with Direct Connection:


-Source: Constant 0
-Target: Current Window-> Display
Configuration with Dynamic Wizard:
-Picture Function
-Display WinCC Dialog Box with Mot1.pdl

Exercise 9: Setting a Bit in a Byte

Conveyer 2

Q0.1

Bandanlage.pdl

Exercise 10: Help Function

H
Object name: Help Text

Press right mouse button: display


help text
Release right mouse button: hide
help text

Tooltip text

Exercise 11: Customized Object


Customized object

Exercise 12: Indirect Addressing

textvariable with indirect addressing

Message System 1/3


Message
sequence
report
Internal tag

Binary tag

old /
new

Main Memory

Limit values
Ring buffer main memory

Process

SIEMENS

New page

Prepare message

SICOMP
IPC RI 20

WinCC Control

Message
frame
Interpretation

Selection in archive

Shift reporting
- Daily reporting
- Monthy reporting
-

Integrated backup function

Message system API

.mdf

Central WinCC
Archive Server

Add-On

ODK
User applications

Options
-SIMATIC IT PPA
-Dat@Monitor (Web-Client for Historian
display and analysis )

Message System 2/3


Swap in/swap out Depends on
the Requirement->Backup
Archives (.mdb)

RT Database (cyclic archive)


RT Master database

ALG Master
Database

Data acquistion
WinCC Data Manager
OPC Server
WinCC Server-Server
Communication

Long-term archiving
High performance archiving
Swap data in - swap data out

Note: ES=Single segment

Analysis / Evaluation
WinCC Standard Tool (Control)
Protocols (Report Designer)
WinBDE (recording operating data)
Dat@Monitor + Excel
Connectivity Pack + External Appl.
IndustrialDataBridge + Ext. Appl.

Message System 3/3

Runtime-Data Alarm Logging Segment:

Data acquisition

COMPUTER_PROJECT_ALG_<Time_from>_<Time_to>.LDF
COMPUTER_PROJECT_ALG_<Time_from>_<Time_to>.MDF
COMPUTER_PROJECT_ALG_YYYYMMDDHHMM.LDF
Example: DOZENT_Generatorhaus_ALG_200304300901.mdf

+WinCC Data Manager


+OPC Server
+WinCC Server-Server
Communication(max.11)

Message list
Long-term archive
Short-term archive

Message Blocks and Message Line

System blocks
Clock time
Date

User blocks

Process value blocks

Error cause

Process value 2

Error location

Process value 1

Number
max. 10

Message
line

max. 10

Message System Call-Up

1. Call the shortcut menu.


2. Click on the mouse to select Open. Result: Alarm Logging starts.
3. Maximize the window and set up the interface as you want it.

Message System Configuration Interface

Select Wizard

Editing window
Analog Alarm
Menu Bar: Options, drop-down menu: Add Ins ...

Navigation window

Table window

Wizard Overview

Wizard

Configuration dialogs

Editing Message Blocks


Shortcut menu

Shortcut menu

Structure of Messages with Message Classes and Message Types


1) Technological Division

1...

1...

Types

16

Message Classes

1...

16

2) Priority Division
1...
16

Types

1...

Message Classes

16

Editing and Configuring Message Classes


- Acknowledgement theory
- Acknowledgement of central signaling devices

Max. 16

- Status texts
for the message

Editing the Message Types

Setting Up a Message Archive


Shortcut menu

OR OR

Ring buffer archive

Setting Up Messages for Reloading

Shortcut menu

Backup Configuration
Shortcut menu

RT Data

Resetting the Archive and Evaluating Old Archives

Shortcut menu for WinCC in CS mode

Shortcut menu for WinCC in RT mode

Reset:
All Database files in the
long-term archive are deleted after check
back.
In the first RT mode, DB files are
automatically recreated.

Connect:
Necessary when old archive files are to be
evaluated

Disconnect: Opposite of
Connect

Editing a Single Message


- Infotext
- Text for user
blocks

Shortcut menu
"Properties"

- Tags for
process value
blocks
- Loop in Alarm
picture

WinCC Alarm Control in Graphics Designer

Window Properties for WinCC Alarm Control


- Status bar on/off
- Elements of status bar
enabled
- Alignment

- Separation lines
- Selection
- Auto Scrolling
- Line properties
- Column properties
- Shorten Title

Toolbar
Double-click

Preview Message line


Status bar

- Edit Message
blocks
- Edit
Message line

- Toolbar on/off
- Keyboard functions
- Alignment
- Hotkeys

Double-click

Configuration Notes

Bit Message Procedure

- WinCC polls the message bits every 500ms


+ easy to configure
- central acknowledgement through
acknowledgement tags

Reporting in the Correct Chronological Order

+ message telegrams are only sent when events occur


+ exact time-stamp for messages (length of the CPU cycle;
e.g. 50ms)
- with PMC central acknowledgement without additional work
- S5-PMC: higher capital expenditure (PMC channel; PMCPRO and special
FBs)

- S5-PMC: higher CPU scan cycle time and higher memory usage
+ Advantage with S5 communication: S5-PMC does Blocking
+ S7 blocks integrated in the operating system

Message Blocks Exercise


System blocks

Properties

-Sequence
-Two-digit year

-Time format

-Length
-6 digits
8 characters -With leading
zeros

User blocks

Properties

-10 characters

-14 characters

Process value blocks

Properties

-4 characters

-12 characters

-Length
-Length
8 characters 15 characters

Message Class, Message Types, and Archives Exercise


Configuring message classes

Message types

Blast furnace
Alarm
General

Acknowledgement

- Name: blast furnace


- Message types Alarm,
error

Failure

- Arrived: red
Properties
- Departed: green
- Acknowledged: yellow

-Acknowledgement
came in
Archive

Status texts

- ARR
- DEP
- ACK
- A/D

Properties

-100 messages for


reloading

-See screenshot in text

Single Message Exercise

Table window

Or process tag IB0

WinCC Alarm Control Exercise

General

-Date
-Time
-Number
-Status
-Message text
-Point of error
-Cause
-Class
-Type

Window Title: Blast furnace-W. Window Type:


Message Window

Message Line
Parameters Status
Bar
-Display
-Alignment down
-Select all
elements
of the status bar

Toolbar

-Display
-Alignment up
-All key functions

-Separation lines horizontal and vertical "activated"


-Selection: Cell "activated"
-Auto Scrolling not activated
(for Window Type: Message Window)
-Line Title "activated"
-Column Title "activated"
-Change Column Width "activated"

Copy (if present) the picture melden.pdl into your project from the catalog ab_uebung.

Message Screen Exercise

WinCC Alarm Control

Group Messages

1) From message classes:


Message class A

Message class B ..... ...


Message class P

Message type 1 ....message type 16

......

...

.....

Mess. type 1 .... mess. type 16

2) From user-defined messages:


Message numbers x to (x+2n)

...........
Message numbers y to (y+2m)

Messages .... ....messages


x to x+n .... .... x to x+2n

Messages .... ....messages


y to y+m .... .... y to y+2m

Creating the Tag for a Group Message

Connect Tag with the Group Message (Message Class)


in Alarm - Logging

Evaluating the Status Tag for a Text Object


Bit 0: 0- there is no malfunction 1- there is a malfunction
Bit 8: 0- message is acknowledged
1- message is not acknowledged

15...

8...

00000001 00000001

incoming not ackn.

00000000 00000001
00000001 00000000
00000000 00000000

incoming ackn.
outgoing not ackn.
outgoing ackn.
(finished)

Incoming not acknowledged Outgoing


not acknowledged

Evaluating the Status Tag for a Text Object


Bit 0: 0- there is no malfunction 1- there is a malfunction
Bit 8: 0- message is acknowledged
1- message is not acknowledged

15...

8...

00000001 00000001

incoming not ackn.

00000000 00000001
00000001 00000000
00000000 00000000

incoming ackn.
outgoing not ackn.
outgoing ackn.
(finished)

Exercise: Group Messages

Group message with message classes

Blast furnace

Loading blast furnace

Incoming

Alarm

Incoming

Incoming

Error

Incoming

Alarm

Incoming

Error

Incoming

New: Database Tools 1/2

Display only in RT

New: Database Tools 2/2

Open Table->Return all rows

Archive segments

Trend Display and Measured Value Archiving

Objectives

- Measurement Point
- Trend Display
- Trend Archive

- Archive Description
- Archiving Time Period
- Trend Analysis
- Displaying Measured Values

Tag Logging 1/3


Trend and
table display

Int. Tag

Measured Value Calculation

n<HD
Ring buffer RAM

Measured Value(s)

SIEME
NS

SICO

Process

Fast Archive
<=1min

Measured va lues
frame

MP
IPC
RI 20

Slow Archive
>1min

Interpretation
Shift report
- Daily report
- Monthly report
-

Integrated backup function


Archive system API

.ldf
.mdf
Central WinCC
Archive Server

AddOn
PM
Analysis

ODK
User applications,
such as diagnostics

Options
-SIMATIC IT PPA
-Dat@Monitor
(Web-Clients
for display
and
analysis )

Tag Logging 2/3


Swap out Depends on
the Request->Backup
Archives (.mdb)

RT Master Database

TLG Master Database

RT-DB (Fast cyclic archives with compressed data)


RT-DB (Slow cyclic archives with uncompressed data)

Data acquistion
WinCC Data Manager
OPC Server
WinCC Server-Server
Communication

Analysis / Evaluation
WinCC Standard Tool (Control)
Protocols (Report Designer)
WinBDE (recording operating data)

Long-term archiving
High performance archiving
Swap data in and swap data out

Note: ES=Single segment

Dat@Monitor + Excel
Connectivity Pack + External Appl.
IndustrialDataBridge + Ext. Appl.

Tag Logging 3/3

Data acquisition
+WinCC Data Manager
+OPC Server
+WinCC Server-Server
Communication(max.11)

Runtime Data Tag Logging Fast Segment:


COMPUTER_PROJECT_TLG_Fast_<Time_from>_<Time_to>.LDF
COMPUTER_PROJECT_TLG_Fast_<Time_from>_<Time_to>.MD
F COMPUTER_PROJECT_TLG_Fast_YYYYMMDDHHMM.MDF
Example: DOZENT_ab#graf#V5.1_TLG_F_200306020629.mdf
DOZENT_ab#graf#V5.1_TLG_F_200306020901_200306021000.md
f

Runtime Data Tag Logging Slow Segment:


COMPUTER_PROJECT_TLG_Slow_<Time_from>_<Time_to>.LDF
COMPUTER_PROJECT_TLG_Slow_<Time_from>_<Time_to>.MDF
COMPUTER_PROJECT_TLG_Slow_YYYYMMDDHHMM.MDF
Example: DOZENT_ab#graf#V5.1_TLG_S_200306020629.mdf
DOZENT_ab#graf#V5.1_TLG_S_200306020901_200306021000.md
f

Measured Value Archiving and Processing


Calculations
Sum
A
r
c
h
i
v
i
n
g
1
)
Mean
Value
Acquisiton Cycle

Time

Minimum

Archiving/Display Cycle
1)

1)

Maximum
Action
Last acquired
value

Tag Logging Call-Up

1. Call the shortcut menu.


2. Use the mouse to click on Open.
Result: Tag Logging starts.
3. Maximize the window and set up the interface as
you want it.

Tag Logging Configuration Interface

(1)

Data window
Navigation window

Table window

Archive Wizard

(1) Shortcut menu

Process Value Archive Properties


-Main memory or hard disk memory location
-For main memory, size in data records
Shortcut menu:
-Properties

Editing Measurement Points


-Editing mean value, maxetc.
-Unit (currently not usable)
-Saving during an error
-Archive only upon change

-Configured directly
-No display limitation
-Start Event
-Stop Event

Shortcut menu:
-Properties

Archive Configuration

OR OR

Cyclic archive

Cyclic archive

Backup Configuration Fast and Slow Archive

RT Data

Resetting the Archive and Evaluating Old Archives

Shortcut menu for WinCC in CS mode

Shortcut menu for WinCC in RT mode

Reset:
All Database files in the
long-term archive are deleted after check
back.
In the first RT mode, DB files
are automatically recreated.

Connect:
Necessary when old archive files are to be
evaluated

Disconnect: Opposite of
Connect

WinCC Online Trend Control in the Graphics Designer

Window Properties for WinCC Online Trend Control


-Window Title
-Background Color
-Display Status/Toolbar
-Writer Orientation
-Staggered trends
-Common Axis
-Print job
-Data supply

Toolbar:
-Keyboard functions
-Hotkeys

Double-click

-Label
-Coarse/Fine Scaling

-Label

- Limit Values
-Time Overlap
-Time Jump automatic or
-Value with uncertain
status

-Coarse/Fine Scaling

-Update (factor, range) -Range Selection


fixed
-Time selection
-Time range

Configuration Notes 1/2


Acquisition:
Archiving/Display:

5 sec
5 sec

This setting results in an optimized communication


load

Acquisition:
Archiving/Display:

1 sec
5 sec

This setting results in an unnecessary communication


load

Acquisition:
Archiving/Display:

1 sec
1 sec

Archive becomes very large, unnecessary


communication load

Acquisition:
Archiving/Display:
Note: You have to take into consideration that the
acquisition cycle is a permanent load in the background
(communication)

2 sec
10 sec

Makes sense for arithmetic, e.g. mean value

Configuration Notes 2/2

Start Events and Stop Events are functions that are called every 500 ms for every trend! Better: Global Script Action (*.pas)
with TLGLockArchiv

Exercise Step 1/5 Archive Wizard

(1) Shortcut menu

Exercise Step 2/5 Archive Configuration

Exercise Step 3/5 WinCC Online Trend Control in the Graphics Designer

Exercise Step 4/5 Window Properties for WinCC Online Trend


Control

Double-click

Exercise Step 5/5 Function Test

New: Database Tools 2/3

Archive segments
Open Table->Return all rows

New: Database Tools 3/3

Archive segments
Open Table->Return all rows

User Archives

Objectives

- Creating a User Archive


- Creating a Table View
- Creating a Form View
- Accessing a User Archive
- Data Transfer to a Controller

User Archives
Advantages of user archives for:
Recipes
Batch data
Production data
Data storage for data from the controller
Tool management

Access to user archives through:


Table window
Internal functions
API functions (described in the WinCC Help, among others)
ODBC / SQL
MS Query
Communication with the controller using tags
Communication with the controller using raw data

WinCC Help (System)


WinCC Help

Creating a User Archive


Toggle for Table window or Wizard enabling

Navigation window

Data window

Table window for editing


online data records

Archive name: H1_Heating H1


_Heater
_Actual
_Setpoint

Exporting/Importing a User Archive

Archive
Fields

Note:
You can copy Fields and Archives with Ctrl+C, and insert them with
Ctrl+V

Table View of the User Archive Control


Switchover

Create new
record

Delete
record

Change
current field

Scroll in
table
window

Read and Write


tags
Import/Export
archives
(.CSV)
Define filter
condition

Time Base
Print

Define sort
condition
Help

Floor/Room
Actual room
temp.
Setpoint
room temp.
LastUser
Last data record
change
Note: The ID number is an internal reference of the database. The numbering does
not have to be consecutive. It should not be used for selections.

Form View of the User Archive Control

Operation outside of the Control

Communication with the Controller using Tags,


Operator Controlled
Runtime

Select

Interface tags

Communication with the Controller using Tags,


PLC Controlled
Runtime

Control tags

Are supplied by the controller

Interface tags

Sort
Runtime

Exercise 1: Creating an Archive

User Archive Editor


Creating an Archive
Creating Archive Fields
Editing Table Windows

Archive fields

Exercise 1: Integrating a Control

You can activate the editing mode for the form window by
pressing Ctrl+double-click!
Form window call

You can change the column width after you press Ctrl+double-click.

Exercise 1: Setting Control Parameters

Double-click

Note: Every time you make a change to the archive structure, you have to reselect the source (archive).

Exercise 2: Form View


Expanding the exercise picture with the form view of the
User Archive- Table Element

Switch over

Shortcut menu

Co
nfiguration

Runtime

Exercise 3: A Second User Archive


Expanding the exercise picture

Views Archives

Exercise 4: Views of the Two Databases


Expanding the exercise picture

Exercise 4: Integrating a Control

Double-click
for views

Report System (Report Designer)

Objectives

- Message sequence report


- Message archive report
- Measured value report
- Screenshot picture area (x,y)
- CSV Provider
- Feedback documentation
- User report

Object Palette of the Report Designer

Report Designer
Name of print job

F=File
P=Print
RP=Report

Name of layout

Message sequence report print job

Online Messages (Message List) using Page Layout


Report Designer
Page Layout

Double-click
Report

-Here you define


the message format,
for example

Online Messages (Message List) using Page Layout


Report Designer
Page Layout

Double-click
Report

-Here you define


the message format,
for example

Message Archive Report 1/2

Message Archive Report 2/2

100\ means that the last


100 messages will be
printed.

Measured Value Report (Trends) 2/4

Measured Value Report (Trends) 3/4

Layout

Shortcut menu

Measured Value Report (Trends) 4/4

-Trend color
-Scaling of y axis

Shortcut menu

Measured Value Report (Trends) 4/4

-Trend color
-Scaling of y axis

Shortcut menu

Measured Value Report (Tables)

Screenshot of a Picture Area

{
#pragma code("prtscrn.dll")
BOOL PrtScreenPart (ULONG left, ULONG top, ULONG width,
ULONG height);
#pragma code()
ULONG ObenX,ObenY,Breite,Hoehe;

80
ObenX=GetLeft(lpszPictureName,"Control1");
ObenY=GetTop(lpszPictureName,"Control1");
Breite=GetWidth(lpszPictureName,"Control1");
Hoehe=GetHeight(lpszPictureName,"Control1");
PrtScreenPart (ObenX,ObenY,Breite,Hoehe+80);
}

CSV Provider

Runtime

.CSV files created with Excel

Feedback Documentation of the Configuration Data 1/2

Feedback Documentation of the Configuration Data 2/2

User Report - Print Preview

.emf

Object Hardcopy

Background Processing (Global Script)

Objectives

- Project Functions
- Standard Functions
- Internal Functions
- Project-wide Actions

Global Script C Actions and Functions


Project functions
Standard functions
Internal functions

Actions

Output field for:


-Search files
-Compile All Functions

Example of a Project Function and/or Standard


Function
Switching
on a motor: 2);
BitSet
( 1, "MotorStatus",
Events/ Mouse/ Left mouse button/ C function...
/*Bit 2 is set in the MotorStatus tag, to reset
the bit use: BitSet ( 0, MotorStatus, 2)*/

A function defined in the Global Script (Standard Functions:


void BitSet(BOOL OnOff, char* lpszWordtag, WORD wbitnumber)
{
WORD
int

winput = 0;
iscreen = 1;

winput = GetTagWord ( lpszWordtag ) ;


iscreen <<= ( wbitnumber );
if (OnOff == 0 ) {
winput = (WORD) ( winput &
(~iscreen) );
}
else {
winput = (WORD) ( winput | iscreen );
}
SetTagWord ( lpszWordtag, winput);
}

// Create local tags


// Read process tags
// Create bit mask
// Reset bit ?
// Reset bit
// Set bit
// Rewrite process tag

Internal Functions: Example of Graphics 1/3

Internal Functions: Example of Graphics 2/3


20
20

Event/ Button/ Mouse/ Press left/ C-Action...


Box_mit_Pos1 (lpszPictureName, lpszObjectName,
"Bildfenster1", Motor.pdl");

Activate dialog box

Internal Functions: Example of Graphics 3/3


Activate dialog box

Events/ Button/ Mouse/ Press left/ C action...


Box_mit_Pos2 (lpszPictureName, lpszObjectName,
Bildfenster1", Motor.pdl");

You can place dialog screen windows where you want them on the screen. To establish a
reference to the operated object, it is advantageous if the dialog box appears where it
is used. You can attain this positioning with the following steps:
- Scanning the properties of the operated object and the entire screen
- Scanning the size and stretching the dialog window
- Specifying the appearance location of the dialog window (to the right or left next
to the operated object)
These functions are combined in a standard function that can then be used from
any location (each screen and operating object).

Background Processing (Actions) with Global Script

Operating hours.PAS
WORD HOUR, MINUTE;
BYTE Z_ON;
Z_ON = GetTagByte ("Z_On");
if (Z_ON) {
MINUTE = GetTagWord
("Minutes");
MINUTE = MINUTE + 1;
SetTagWord ("Minutes", MINUTE);
HOUR = MINUTE / 60;
SetTagWord ("operating hours", HOUR);
}
return(HOUR);

Note: Global Script must be activated in the computer startup list

Example with Functions from DLLs


Counting with the DLL function

Events/ Button/ Mouse/ Press left/ C action...


#pragma
code("c:\a_WinCC_Kurs_Prj_301_00\ab_pas\library\demo_dll.dll")
int CountingDll(int start, int end);
#pragma code()
int result, start, end, partial step;
partial step = GetTagDWord("partial step");
printf("\r\n\r\noutput of 10 partial steps with DLL function ");
printf("to max. value: %d",partial step*10);
for (start=0;start<10;start++) {
end = start * partial step + partial step;
result = countingDll(start*partial step,end);
printf("\r\nReturn value DLL function: (%d)
%d",start,result);
}

Global Script VBS Actions and Procedures 1/2

Procedures
(Function)

To be created by the user


(empty)

O
u
t
p
u
t
w
i
n
d
o
w
f
o
r
c

Global Script VBS Actions and Procedures 2/2

In the project
Module
Procedure A
Procedure
B
Procedure C
Action
Instruction 1
Instruction 2
Trigger

Procedure C
.
Instruction n

Instruction a
Instruction
b

Procedure D
Procedure E

Example of a VBS Project Function


.pdl

Call

Using the Windows Standard Interfaces

ODBC
OCX

OLE

SQL

OPC

ActiveX
DDE

Objectives

- Open Architecture
- OLE Automation
- ODBC
- DDE
- OCX
- ActiveX
- OPC
- VBS

An Overview of the WinCC Open Architecture


Connectivity
(4)

ActiveX(1)*

CHN (3)

OPC(1)*
DDE (1)*
OLE (1)*

OLL (3)

COM
(1)

API (2)

ODBC (1)
SQL (1)

Action (2)
OCX (1)*

(1) Windows
(2) WinCC
(3) WinCC Objects
(4) SYBASE

OLE Automation (1/2)


(Access to WinCC Tags through Excel, for Example)

OLE Automation (2/2)


(Access to WinCC Tags through Excel, for Example)
WinCC Excel Data Exchange
OLE Test Application

ODBC Application with Data from WinCC 1/3

WinCC Database

Evaluation
Valve 1: 3x
Valve 2: 3x
.
.
.

ODBC Application with Data from WinCC 2/3

ODBC Application with Data from WinCC 3/3

Integrating OLE Objects in WinCC with MS WordArt 2.0,


for Example

Using OCX and ActiveX, Standard Market Objects 1/3


VB Object Palette with OCX Objects
WinCC OCX

Using OCX and ActiveX, Standard Market Objects 2/3

Type O

Using OCX and ActiveX, Standard Market Objects 3/3

collective noun

DDE Linking 1/3


(Accessing WinCC Tags through Excel, for Example)

Linking using DDE Server 2/3 (Accessing WinCC Tags


through Excel, for Example)

WinCC Excel Data Exchange


DDE Test Application

Linking using WinCC DDE Channel 3/3


(Accessing WinCC Tags through Excel, for Example))

Linking using OPC according to the COM Model


Computer A
OPC client

OPC server

Windows operating system


COM library
Siemens OPC
DAAutomation 2.0

Computer A

Computer B
OPC server

OPC client
Windows

network

COM
library

Windows
COM
library

DCOM

Direct Access to the Complete MS Excel Functionality


under WinCC

Direct Access to the Complete MS Word Functionality


under WinCC

Objectives

API
(Application
Programming Interface)

- ODK (Open Development Kit)


- CDK (Channel Development
Kit)

WinCC Software Architecture


WinCC Explorer

Contorl Panel

CS

CS

CS
RT

G
ra
ph
ics
CS
RT

C
ust
om
for
m
pro
ces
sin
g

Access
protection

RT

Si
gna
llin
g

M
eas
ure
d
val
ues

CS

...

CS

RT

RT

R
T

Text
library

use
r
arc
hiv
e

CS

CS

RT

RT

Report

Option

CS
RT

Tag management
Process data

Data Manager
.mdf
RT .mdf

S5

S7

Application Programming Interface API (1/4)


Q

ANSI-C Functions

Access to data
Q
Q
Q

in the Tag Management


in the archives
configuration data

Using system functions (ODK)


Q
Q

configuration functions
Runtime functions

Integration of communication channels (CDK)

Basis for
Q
Q
Q

individual functions
technological-type options
industry-referenced function modules

API

API

API

API

API

API
API
API
API

API API
API
API
API

Application Programming Interface API (2/4)

User
application

Integrating configuration
functions

User

application

Integrating Runtime

functions

Integrating
communication
channels

Application Programming Interface API (3/4)


Additional
application
Using
functi
ons

WinCC API DLL


Communication

WinCC Module

The following is needed for creating


applications:
QExternal C compiler
(for example, Microsoft Visual C++ 5.0 )
QLibrary file for the desired
WinCC API ( *.LIB )
QHeader file for the desired
WinCC API ( *.H )

Application Programming Interface API (4/4)


Q

Application examples:
Q

Access to values from the Tag Management

Access to archive data

Integrating communications channels

Direct display of processing results in Graphics

Generic configuration based on API functions

Integrating already existing processing programs

Generating messages from user routines

Controlling the measured value recording from user routines

Controlling reports from the user programs

FAQs on the Internet: http://www.siemens.de/hmi

Diagnosis and System Information with WinCC Scope

WinCC
Client

WinCC
Client

C
TTCCPP
//IIPP
TTeerrmiinnaall-

bus

WinCC

WinCC

NNeettBE

Server

EUUII

Server

Process bus
Plant Part
1

Plant Part
2

WinCC and Standard PC communicate with the process via OPC

WinCC - OS
Standard PC
WinCC
Data Manager
OPC
Client

OPC
Server

Microsoft
Excel
(OPC Client)
OPC
Server

WinCC Server 3
OPC Server
Data Manager
OPC
Client
WinCC Server 1

Connection 1

e.g.
Simatic S5
Connection 2

WinCC Server 2

OPC Server

OPC Server
Connection 3

Data Manager
Channel DLL
e.g.
(Com.-Driver)
Simatic S7

Data Manager
e.g.

Channel DLL

Simatic S5 (Com.-Driver

cascadable Client/Server configuration

You might also like