Snímky z 9. přednášky Soubor

Transkript

Snímky z 9. přednášky Soubor
Průmyslová informatika a
internet
(A0M35PII)
Richard Šusta
Procesy, základ OS, ale překážka sdílení...


procesy
operační systém
30.11.2015
Operační systém sice
bezpečně izoluje jednotlivé
procesy, ale ztěžuje tím
vzájemné poskytování
služeb
© K 13135, ČVUT FEL Praha
2
Některé metody komunikace mezi procesy
Operační systém
„pipe“=roura,
sdílená pamět
net socket, DDE
COM strukt.
COM strukt.
zprávy
[ A+X ]
• „DLL hell“ = infarktové potíže
s kompatibilitou různých verzí jedné DLL
[ D]
[ B+Y]
Vhodná metoda pro
omezené množství
přenášené informace
Proces Y
Proces X
smyčka
zpráv
DLL - Dynamic Linked Library
dynamické knihovny
• OLE (Object Linked Exchange) vycházející z COM (Component Objekt Model)
žádá složitou infrastrukturu a instalaci komponent se zápisy do registrů
→ obtížná manipulace i ztíženo korektní odinstalování
30.11.2015
© K 13135, ČVUT FEL Praha
3
Evolution of the Software Bus
Remote Msgs
Remote Procedure
Distributed Objects
DLL
LPC
DDE
OLE1.0
DCE
NCS RPC
ONC RPC
ONC+
UDP/TCP
IPC
OLE2.0
SHL
DCOM
COM/CORBA
CORBA/IIOP
RRBC
JAVA/RMI
Source: Rao, N.: Organizational Communications and Technologies
Terms
Abbreviation
Name
Purpose
LPC
Local Procedure Call
UDP
User Datagram Protocol
TCP
Transmission Control Protocol
IPC
Inter-process Communication
SHL
Shared Library/Object
RRBC
Release to release binary compat.
DDE
DLL
OLE 1.0
Dynamic data exchange
uSoft’s messaging between procs.
Dynamic Link Library
uSoft’s shared library/object
Object Linking and Embedding
Parameterized code segments
Intermachine messaging
Reliable delivery of UDP messages
Messaging between processes
Dynamic Linking of shared code
Support for versioning of shared Libs.
Extension of DDE for windows events
Terms
Abbreviation
COM
DCOM
RPC
Name
Component Object Model
Distributed COM
Purpose
Extension DLL/C++ supporting versioning
Extension of OLE2.0 supporting IPC
Remote Procedure Call
Proxies making RPC look like LPC
NCS RPC
Network Computing Service
Apollo’s inter-machine marshalling
ONC RPC
Open Network Computing
Common Object Request
Broker Architecture
Sun’s inter-machine marshalling
Internet Inter-ORB Protocol
CORBA 2.0 standard marshalling protocol
Remote Method Invocation
Dist. Java-java ipc marshalling protocol
CORBA
IIOP
RMI
SNMP
Simple Network Management
Protocol
Extends NCS/DCE for dist. Object comm.
Remote attribute query mechanism
Software Interconnect Bus
Application Objects
Common Facilities
Software Interconnect Bus
Services
Source: Rao, N.: Organizational Communications and Technologies
Local/Remote Architecture
Client
Communication
run-time
Security
Provider
Communication
run-time
Security
Provider
DCE RPC
LPC
Client
DCE RPC
LPC
Communication
Communication
run-time
Security
Provider
run-time
DCE RPC
Security
Provider
Protocol Stack
protocol

8

DCE RPC
Protocol Stack
Network-

Component
DCE - Distributed Computing Environment
LPC - Local Procedure Call
RPC - Remote Procedure Call
Component
Low-Cost Method of RPC:
Web Services based on TCP/IP
Message Serialization
ASP.NET uses XmlSerializer to
serialize/deserialize SOAP messages
SOAP
Client Proxy
Serialize
Request
Deserialize
Web Method
XML
Parameters
Return Value
Parameters
Deserialize
SOAP
Serialize
Response
XML
Client Application
Web Service
Return Value
Serialization/Deserialization
Object in memory
…binary or character stream…
Object in memory
Illustrating a SOAP Message
Envelope
Headers
Body
Method
Parameters
12
SOAP Extensions in ASP.NET
Web Service Method
SOAP Extensions
Validate/Transform
Authorize/Authenticate
Log
Decrypt
Decompress
HTTP
Response
ASPNET_ISAPI.DLL
HTTP
Request
ASP.NET Runtime
IIS
Web services architectural model (incorporate how Web
services are advertised, discovered, selected, and used).
Universal
Description,
Discovery and
Integration
Web Services
Description
Language
Simple Object Access Protocol
Underlying Technologies
Web Services Stack
Inspection
http://www.ibuyspy.com/ibuyspy.disco
Request Discovery Document
DISCO
Return Discovery Document (XML)
WSDL
Description
http://www.ibuyspy.com/ibuyspycs/InstantOrder.asmx?wsdl
Request Service Description
Return Service Description (XML)
SOAP
Wire Format
Web Service
Web Service Client
Link to Discovery Document (XML)
UDDI or
other
directory
service
UDDI
Directory
http://www.uddi.org
Locate a Service
Request Service
Return Service Response (XML)
[source: Jim Fawcett: Distributed objects]
11/30/2015
K 13135, ČVUT FEL Praha
15
OPC technologies
ActiveX
Object Linking and
Embedding (OLE)
OLE for Process
Control (OPC)
(Distributed) Component Object Model
(COM / DCOM)
only between
nodes
Transport
(TCP-IP, UDP, Queued)
Ethernet
OPC bases on Microsoft's COM/DCOM technology (i.e. it only works on Windows platforms).
Effort to port it to other platforms (Linux) and web transport protocols (XML) are in progress.
Advantages are the direct integration into all applications, such as Excel.
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 17/32
COM - Common Object
Model
basis for OPC
18
COM Defined
COM (Component Object Model) and
DCOM (Distributed COM)
are a set of binary and network
standards for the modeling of objects
and their communications.
What is COM?
Build software from parts, not from scratch
A framework for creating and using components
 Both a specification and an implementation
 Provides widest choice in services, tools, languages, and
applications
 Evolved from Object Linking and Embedding technology
 It should make software easier to write and reuse, but it is now more
considered as a false path of development
 Foundation in OLE Version 2, 1995
 OLE for Process Control (OPC), was developed in 1996 by
an industrial automation industry
 As of November 2011, the OPC Foundation has officially renamed
the acronym to mean "Open Platform Communications".
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
Identifiers

GUID (globally unique identifiers)



are stored in 16-byte (128 bit) structures
CLSID (class identifier GUID)
IID (interface identifier GUID)
IUnknown
• QueryInterface
– Returns a pointer to requested Interface
• AddRef
– Increases the RefCount
• Release
– Decreases the RefCount
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
Interfaces

An interface is a set of
similar methods
 Analogous
to a Java or
C# interfaces
HRESULT EatNuts();
HRESULT ClimbTree();
HRESULT RunAway();
 Binary

level, not
source code level
Indentified by an
Interface Identifier
(IID)
interface ISquirrel :
IUnknown {
};
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
IUnknown




Base interface
Polymorhic to all
other interfaces
Implements
reference counting
All other interfaces
are retrieved through
IUnknown
interface IUnknown {
ULONG AddRef();
ULONG Release();
HRESULT
QueryInterface(REFIID
iid, void **ppObject);
};
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
Interfaces

An interface is a named table of function pointers
(methods)

An interface is not a class

An interface is not a COM component


COM clients only interact with pointers to
interfaces
COM components can implement multiple
interfaces

Interfaces are strongly typed

Interfaces are immutable
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
24
25
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
26
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
Objects and Interfaces
27
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
28
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
DCOM Architecture
Client
COM
run-time
Security
Provider
Client
COM
run-time
DCE RPC
Security
Provider
DCE RPC
LPC
LPC
COM
run-time
COM
run-time
Security
Provider
DCE RPC
Security
Provider
Protocol Stack
Component
Component
DCE RPC
Protocol Stack
DCOM networkprotocol
29
[Souce: Microsoft's Distributed Component Object Model, Microsoft]
COM/DCOM quick intro
1) same process
client
2) different processes
same computer
client
3) different computers
client
library
(DLL)
stub
proxy
local
procedure
call
local
procedure
call
stub
remote
procedure
call
COM/DCOM (COM+) maintains
the same interface regardless of
the location of the components
memory
proxy
network
TCP/IP
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
library
library
remote
procedure
call
TCP/IP
4.3.1 OPC Common - 30/32
Industrial Automation
Automation Industrielle
Industrielle Automation
4 Access to devices
OPC (Open Process Control formerly OLE for Process Control)
1 Common elements
What is OPC ?
OPC (formerly: "OLE1 for Process Control", now: "Open Process Control") is
an industry standard set up by the OPC Foundation (http://www.opcfoundation.org/)
specifying the software interface (objects, methods) to a server that
collects data produced by field devices and programmable logic controllers.
interfaces
covered by the
OPC standard
application
(OPC client)
OPC server
X
OPC server
(simulator)
node
servers
OPC server
Y
Ethernet
(not covered)
PLCs Brand X
Field bus
(not covered)
PLCs Brand Y
Sensors/Actors
1) OLE (Object Linking and Embedding) is a Microsoft technology for connecting software components.
It has since been extended by the COM / DCOM technology. It corresponds to Java Beans.
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 33/32
Before OPC
visualization
history
data base
MasterBus
MMS driver
ABB PLCs
XWAY
driver
Profinet
driver
Télémécanique PLCs
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
Siemens PLCs
4.3.1 OPC Common - 34/32
With OPC: ABB Operator Workplace Connection
OperatorIT
Historian
(Information
Manager)
application software is
written independently from
the type of controller
the drivers still exist,
but the clients do not
see them anymore
ABB AC800M
AC800M
OPC server
Schneider
OPC server
Siemens
OPC server
MMS
XWAY
ProfiNet
Télémécanique TSX
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
Siemens S7
4.3.1 OPC Common - 35/32
The main OPC Specifications
OPC
DX
OPC
Batch
OPC
HDA
batch
system
history
data base
OPC
Data Access
OPC
Alarms & Events
OPC
UA
future
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 37/32
OPC for internal communication: ABB’s 800xA as example
ABB's Integration Platform (800xA) is at the same time OPC server and OPC client.
Components (aspects) within AIP expose their properties as OPC objects.
Internal (within AIP) and external communication takes place over OPC.
AIP
aspects
aspects
aspects
aspects
Asset
Optimizer
Enterprise
Historian
OPC server
process
data base
OPC
connections
OPC client
AC800M
OPC server
Schneider
OPC server
Siemens
OPC server
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 38/32
Accessing a server in another node
client application
(OPC client)
stub
DCOM
TCP/IP
DCOM
Limitation:
does not work over firewalls.
Solution:
OPC UA (see later)
TCP/IP
TCP/IP
DCOM
DCOM
OPC
server
OPC server
FB Manager
fieldbus
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 40/32
Structure of an OPC server
OPC/COM Interfaces
OPC Group & Item Management
Item Data Optimization and Monitoring
Device Specific Protocol Logic
Hardware Connection Management
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 41/32
Specification 1: OPC DA for Data Access
Process variables describe the plant's state, they are generated by the sensors or
calculated in the programmable logic controllers (PLCs).
Process variables can be sent upon a change, on demand or when a given time elapsed.
The OPC DA (Data Access) specification addresses collecting Process Variables.
The main clients of OPC DA are visualization and (soft-) control.
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 42/32
OPC DA: Example of access to a variable
controller programming
OPC application
Reactor_1.Program2
ReadItem
("OPC:Reactor1:
Program2.MotorSpeed")
Value: 112
OPC
server
load
symbol
table
MW%1003
MotorSpeed
MW%1004
Temperature
…
….
symbols
code
Get (192.162.0.2), MW%1003)
Return (MW%1003, 112)
Network
Reactor_1
Marker: MW%1003
analog input to : IXD.11.2.1
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
Oven controller
4.3.2 OPC DA - 43
OPC DA: Objects as viewed by the OPC server
An OPC server is structured as a directory with root, branches and leaves (items)
Process Line 1
Tag Name
Controller 1
Controller 2
Controller_3.Prog_1
Controller_3.Prog_2
TAG
TAG
TAG
Level_1
Level_2
An item is identified by its
"fully qualified ItemID",
e.g.
Ramp4
"Process_Line_1.Controller_2.Level_2"
Cell 1
Machine 2
the hierarchical position may differ from
the fully qualified ItemID
this will be detailed under „browsing“
Branches may contain other branches and items
The structure may also be flat instead of hierarchical
This structure is defined during engineering of the attached devices and sensor/actors.
(Intelligent servers could configure themselves by reading the attached devices)
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.2 OPC DA - 44
OPC DA: Item properties
The process data are represented by three dynamic properties of an item:
value:
numerical or text
time-stamp:
the time at which this data was transmitted from the PLC to the server
this time is UTC (Greenwich Winter time), not local time.
quality:
validity of the reading (not readable, dubious data, o.k.)
and two optional static property:
description:
a text string describing the use and of the variable (optional)
engineering unit: the unit in which the variable is expressed (optional)
(when writing, only the value is used)
ID
V
Q
T
D
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
U
4.3.2 OPC DA - 45
OPC DA: Mapping items to groups
Each client structures its items by groups,
independently from the server.
clients
Client1
Initially, the client browses the server structure to
check if the items it is interested in exist.
GroupX
A client registers its groups and items at the server.
The server keeps the structure of all its clients.
Server root
Client2
GroupZ
Item1 Item2 Item3 Item1 Item2
server
Area 1
TAG
Temperature
TAG
Heat_On
TAG
Level
Area 2
TAG
Empty_Valve
Area 51
TAG
Fill_Valve
Oven_1
Tank_1
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.2 OPC DA - 46
OPC DA: communication paradigm
OPC DA works according to the “shared memory” paradigm.
This means that a newer value overwrites the older one, no queues or history are
kept.
The server does not guarantee that different clients see the same snapshot of the plant.
The server does not guarantee that all changes to variables are registered,
changes may be missed if the polling period is too low.
OPC DA Client
OPC DA Client
OPC DA Server
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.2 OPC DA - 48
Specification 2: OPC AE for Alarms and Events
Events are changes in the process that need to be logged, such as "production start"
Alarms are abnormal states in the process that require attention, such as "low oil pressure"
OPC AE (Alarms and Events) specifies how alarms and events are subscribed, under
which conditions they are filtered and sent with their associated messages.
The main clients of OPC AE are the Alarms and Event loggers.
determine the exact time of change
(time stamping)
categorize by priorities
log for further use
acknowledge alarms
(events are not acknowledged)
link to clear text explanation
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 51/32
AE: Configuration
OPC AE Client
e.g. event logger
OPC A&E
specified
interface
OPC AE Client
e.g. alarm printer
OPC AE Server
An OPC AE Server
is configured using
the information
coming from the
development tools
for the controllers
Events defined in
the controllers are
mirrored to the
OPC AE server
event notification
e.g. Ethernet
events
controllers
controller
controller
field bus
plant
measurement
points
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
field devices
4.3.3 OPC A&E - 53
AE: communication paradigm
OPC AE works according to the “message passing” paradigm,
contrarily to OPC DA, that works according to the "shared memory" paradigm.
This means that an event is kept in a queue until all clients have read it (or timed
out).
The server guarantees that different clients will see all events in the same sequence.
OPC AE Client
OPC AE
Client
OPC AE
Server
12:34 23.114
12:34 32.334
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.3 OPC A&E - 54
AE: Server Organization
A2
branches
Areas
A23
Sources
(objects)
leaves
Events
A24
S1
E1
S2
S3
E2
E1
E2
E2
E3
simple
tracking
condition
related
condition
related
condition
related
C2
C2
C2
properties
Conditions (alarms only)
Subconditions (alarms only)
SC1
SC1
SC3
SC1 SC1 SC3
SC1
An event is identified by a source (owner object in the controller) and an event name
this combination must be unique in the AE Server.
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.3 OPC A&E - 56
AE: Events - Notification
AE Client
Tank1LevelHigh_SimpleEvent
(source, timestamp, message,
severity, category)
OPC AE
Server
queue
event notification
message
timestamp
Controller
Event
FB
Tank1
Plant
Level Switch
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.3 OPC A&E - 57
To probe further….
OPC Foundation:
Specifications http://www.opcfoundation.org
SoftwareToolbox
Examples in Visual Basic
http://www.softwaretoolbox.com/Tech_Support/TechExpertiseCenter/OPC/opc.html
The Code Project
OPC and .NET
http://www.codeproject.com/useritems/opcdotnet.asp
Matrikon
Free client and server:
http://www.matrikon.com
WinTech
Toolkit for an OPC server
http://www.win-tech.com/html/opcstk.htm
NewAge Automation
Toolkit for an OPC server
http://www.newageautomation.com
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.3 OPC A&E - 58
Specification 3: HDA for Historical Data Access
Historical Data are process states and events such as: process variables, operator actions,
recorded alarms,... that are stored as logs in a long-term storage for later analysis.
OPC HDA (Historical Data Access) specifies how historical data are retrieved from the logs
in the long-term storage, filtered and aggregated (e.g. compute averages, peaks).
The main client of OPC HDA are Trend Displays and Historians.
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 59/32
Historians: An introduction
The role of HDA will become clearer
after a first glance at historians
The process database
decouples the plant from the analysis tools.
It contains recent and historical data.
Invensys (Wonderware) Archestra
4.3.3 OPC A&E - 60
Historian - examples of questions to the historian:
•
•
•
•
•
What was the value of FIC101 last week ?
What was the flow average during October ?
Which were the daily averages in October ?
What was the total flow in each month ?
How much fuel did we use for the batch ?
The answer should be given in tables, pie
diagrams, spreadsheet, reports
4.3.3 OPC A&E - 61
Historians Example
GE Fanuc/Intellution iHistorian (iFix...)
Questions to the historian:
What was the value of FIC101 last week ?
What was the flow average during October ?
Which were the daily averages in October ?
What was the total flow in each month ?
How much fuel did we use for the batch ?
Give the answer in form of tables,
pie diagrams, spreadsheet, reports
Features:
Unlimited Point Collection
Sub-Second Data Collection Rates
Enhanced Data Compression
True Thin Client Administration
Fault Tolerant Architecture
data collection, archiving and retrieval
report generation
computations (e.g. VBScript)
secure access (FDA 21 CFR 11)
20'000 actions/ s,
up to 100'000 data points
4.3.3 OPC A&E - 62
Historian implementation
application
OPC HDA
ODBC/SQL and OPC HDA are
complementary
log organisation
"SQL"
history
database
collector
corrections
operator actions
"OPC"
field data
4.3.3 OPC A&E - 64
HDA: Historical Data Access
HDA Clients
e.g. Trend Analysis
e.g. Event Logger
independent
processes
OPC HDA
Server
hidden
calculations
history
database
raw and
ordered data
collector
proprietary
data acquisition
OPC DA Server
Field device
Field device
4.3.3 OPC A&E - 65
HDA: Raw log
12.3.02 13:40
12.3.02 13:40
12.3.02 13:40
12.3.02 13:40
12.3.02 13:41
12.3.02 13:41
12.3.02 13:41
12.3.02 13:41
12.3.02 13:41
12.3.02 13:41
12.3.02 13:41
12.3.02 13:42
12.3.02 13:42
12.3.02 13:42
Gpcpt2ofpbonne
Cpt2bac
Gpcpt2bac
Gpcptbe2
Gpcpt1bac
Gpcpt1ofpbonne
Gpcptae2
Cpt1bac
Gpdefr2
Gpvoydef
Gpr3tempscycleprd
Gpstn1e1
Gpalarme1
Gpalarme2
4824
50
70
45
151
4826
45
49
64
2
318
16
0
0
12.3.02 13:43 Gpetatmodemarche
2
1346
1
16
0
317
0
0
0
1
1992
435
1
1
0
4823
12.3.02 13:43
12.3.02 13:43
12.3.02 13:43
12.3.02 13:43
12.3.02 13:43
12.3.02 13:43
12.3.02 13:43
12.3.02 13:43
12.3.02 13:44
12.3.02 13:44
12.3.02 13:44
12.3.02 13:44
12.3.02 13:44
12.3.02 13:44
12.3.02 13:44
Gptpscycle
Gpetatmodemarche
Gpdefgene1
Gpetatmodemarche
Gptpscycle
Gpdefr2
Gpvoydef
Gpdefgene1
Gpetatmodemarche
Gpr2tempscycleprd
Gptpscycle
Gpalarme3
Gpalarme4
Gpalarme3
Gpcpt2ofpbonne
By definition, values are registered when they change.
(even if data are acquired by periodic polling)
Data in the historical database are identified by their
• itemID (here, represented by their name),
• value, (of the respective type)
• quality (good, stale, bad), and
• timestamp (UTC).
4.3.3 OPC A&E - 67
HDA: How to reduce raw data (even before HDA comes into play)
Tag values are sent to the OPC DA server when they change (on events).
min time
max time
max time
max time
max
exception
deviation
min
time
= process value (event)
= log entry
Two situations can occur:
- the time scale of the log is smaller than that of the trend display
in this case, values have to be interpolated to be displayed correctly
4.3.3 OPC A&E - 68
HDA Application: Trend Display
Parameters:
log: how were data sampled
• time scale (with possible offset, zoom, pan)
• amplitude scale (low range, high range, scale units)
• style: smoothed, stepped, filled (several ways to display the same data)
• extrapolate: how to display values not received (e.g. because they did not yet change)
4.3.3 OPC A&E - 70
HDA: More logs
A log registers only one data point !
log 2.1
log 1
log 2.2
(log templates can be used for
several datapoints)
log 2
Data in the log may be:
Measured values (original, from the OPC DA)
Calculated values
Corrected values (replaced or inserted)
Annotations (explanation strings)
raw log
Collector
(OPC DA Client)
other servers
OPC DA Server
Field device
XML / CSV
Field device
4.3.3 OPC A&E - 71
HDA: Hierarchical logs
long-term log
1 hour_forever
 5.2 MB / Year
1
2
3 27 28 29 30
september octobre
1
2
3
4
5
6
7
8
9
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
october
1 mn_7 days log
 6 MB
d-7
1s_24 hours log:
50 traces @ 12 B
 52 MB
23
24
1
2
3
d-6
4
5
d-5
6
7
8
d-4
9
10
d-3
11
12
13
A hierarchical log is built on the data contained in the parent log.
To reduce the log size, several aggregations can be applied:
- record only maximum, minimum, average over a period, etc...
d-2
14
15
16
yesterday
17
18
19
today
20
21
22
Actual data
4.3.3 OPC A&E - 72
HDA interpolation
interpolation is an aggregate used when the time scale of the derived log is smaller than
that of the parent log.
= parent log
= filtered log
resample interval of the new log
time
This is useful to display smoothly trend diagrams.
4.3.3 OPC A&E - 76
Operator Workstation design
Graphical User Interface
access by Keyboard, Mouse,
Trackball, Touch screen, Light pen
page code
page layout
operations on visual objects
(scaling, combination, events)
and on acting objects
(page change, sequence of
events,..)
page logic
SQL
DB optimised
for
fast access
(in RAM)
historical
data base
on-line
data base
OPC
display of values, colours, shape
depending on variable value
navigation from page to page
(hierarchical, shortcuts, search,..)
OPC
I/O interface
I/O interface
fieldbus
Ethernet
Oracle
dBase
Access
MS SQL, ….
4.3.3 OPC A&E - 77
Specification 4: OPC Batch
based on:
IEC 61512-1 Batch Control – Part 1: Models and Terminology
(ANSI/ISA S88.01 1995)
ISA-dS88.02-2000 draft 17 of May 2000
Procedure
allows to access:
• equipment capabilities,
• current operating conditions,
• historical and
• recipe contents
consists of an
ordered set of
Unit
Procedure
consists of an
ordered set of
Operation
consists of an
ordered set of
Phase
[Prof. Dr. H. Kirrmann přednáška PII 2011 v Praze, snímky použité s jeho svolením]
4.3.1 OPC Common - 78/32
Manufacturing model: Restaurant
accounting
controller
recipes
menu
table
clients
clients
clients
clients
clients
cashier
table
table
cooks
cooks
suppliers
chef
fresh
food
waiters
waiters
prepared
food
dish washer
dish washer
table
waste
4.3.3 OPC A&E - 79
Notions
Serial number: a unique identifier assigned to a produced good, lot or part
Bill of Material (BOM): list of parts and consumables needed to produce a product
Recipe: the operations needs to produce a part
Bill of Resources; non consumable resources required for production
Workflow: the flow of parts within the factory
Traceability: ability to track where the parts a product come from and who assembled them
Work Order: order to produce a certain quantity of a product
Push / pull: produce when parts are available, require parts when product is required
Kanban: supplier cares that the parts tray of the client are never void.
Scheduling / dispatching: (flight timetable / tower) (Planer / Disponent)
Engineering Change Order (ECO): design or recipe errors reported to engineering.
4.3.3 OPC A&E - 80