You are on page 1of 64

Woodhead

OPC Data Access Server

Woodhead Profibus Documentation

Document Edition: 1.1


Document #: APE-CEM-0005-11

a product of Woodhead Software & Electronics

OPC_server.doc 22/02/2005

Copyright © 2004 Woodhead Software & Electronics. All rights reserved.


http://www.woodhead.com
Woodhead

Document Edition: 1.1


Date: February 9, 2005
This document applies to the OPC Data Access Server product.
Copyright,
This document and its contents are the proprietary and confidential property of Woodhead Industries Inc.
and/or its subsidiaries and may not be used or disclosed to others without the express prior written
consent of Woodhead Industries Inc. and/or its subsidiaries.
applicom®, Direct-Link™ and SST is a trademark of Woodhead Software & Electronics. All other trade
names are trademarks or registered trademarks of their respective companies.
At Woodhead, we strive to ensure accuracy in our documentation. However, due to rapidly evolving
products, software or hardware changes occasionally may not be reflected in our documents. If you notice
any inaccuracies, please contact us.

Written and designed at Woodhead Software & Electronics, 43 rue Mazagran,


76320 Caudebec-lès-Elbeuf, France.

Hardcopies are not controlled.

OPC_server.doc 22/02/2005
® TM
Copyright © 2004 Woodhead Software & Electronics. All rights reserved. applicom , Direct-Link™, SST are registered trademarks
of Woodhead Industries, Inc. Other product names are trademarks of their respective owners.

http://www.woodhead.com
Woodhead

OPC_server.doc 22/02/2005
® TM
Copyright © 2004 Woodhead Software & Electronics. All rights reserved. applicom , Direct-Link™, SST are registered trademarks
of Woodhead Industries, Inc. Other product names are trademarks of their respective owners.

http://www.woodhead.com
Woodhead

Change Record

Edition & Date Author Pages/Sections Description/Reason for Change CCB


Draft # Affected #
1.0 05/28/2004 J.Combarieu All Creation
1.1 09/02/2005 F. Baudry 5.3 Correction of a bad argument

OPC_server.doc 22/02/2005
® TM
Copyright © 2004 Woodhead Software & Electronics. All rights reserved. applicom , Direct-Link™, SST are registered trademarks
of Woodhead Industries, Inc. Other product names are trademarks of their respective owners.

http://www.woodhead.com
Woodhead

OPC_server.doc 22/02/2005

Copyright © 2004 Woodhead Software & Electronics. All rights reserved.


http://www.woodhead.com
Woodhead

What Has Changed?

The following changes have been made in this document:

Edition Affected Section Change Description


1.0 All First version
1.1 5.3 PfbOpcServer –registry replaced by PfbOpcServer –regserver

OPC_server.doc 22/02/2005
® TM
Copyright © 2004 Woodhead Software & Electronics. All rights reserved. applicom , Direct-Link™, SST are registered trademarks
of Woodhead Industries, Inc. Other product names are trademarks of their respective owners.

http://www.woodhead.com
Woodhead

Table of contents

1 Preface............................................................................................3

2 General information.......................................................................6
2.1 Presentation of OPC ..................................................................................6
2.2 Rapid presentation of the "Woodhead profibus" OPC server ....................7
2.3 Limitations ..................................................................................................9

3 Access to data .............................................................................10


3.1 Connecting to the server -ProgID.............................................................10
3.2 Method of access to data of the OPC server ...........................................10
3.3 Data naming principle...............................................................................11
3.4 Table summarising the supported items ..................................................12
3.5 Predefined items of the "System" topic ....................................................13
3.6 Predfined items of the "Devices" and "Slave" topics................................14
3.7 DPV0 items of the "Devices" and "Slave" topics......................................15
3.8 DPV1 items of "Devices" topics ...............................................................17
3.9 Diagnostic items (slave diag) of "Devices" topics ....................................19
3.10 Browsing of ItemIDs .................................................................................21
3.11 Timestamping of data...............................................................................21
3.12 Quality of items.........................................................................................21

4 Setting of parameters of OPC server .........................................22


4.1 Setting of general parameters of OPC server..........................................22
4.2 Configuration of topics and of items.........................................................23

5 Start-up of OPC server ................................................................24


5.1 Offline mode; Online mode ......................................................................24
5.2 Using the OPC server without the configuration console.........................25
5.3 Using the OPC server in the form of a Windows NT service ...................26

6 Advanced functions.....................................................................27
6.1 Management of groups (OPC Group) ......................................................27
6.2 Deadband.................................................................................................28

7 Diagnostic interface.....................................................................29

OPC Data Access Server •i• Table of contents


Woodhead
7.1 Spy view of items .....................................................................................31
7.2 Messages view.........................................................................................33

8 Annexes........................................................................................35
8.1 Developing an OPC client ........................................................................35
8.2 Use through DCOM..................................................................................39

9 Support .........................................................................................56
9.1 Technical Support ....................................................................................56

10 Index .............................................................................................57

OPC Data Access Server • ii • Table of contents


Woodhead

1 Preface

Preface Sections:
• Purpose of this Guide
• Conventions

OPC Data Access Server •3• Table of contents


Woodhead
Purpose of this Guide
This guide contains technical and product-related information on the OPC server Data Access for
Woodhead Profibus product.
This OPC Data Access server is in compliance with specifications 2.05 and 3.0 of the OPC foundation
and enables you to access from any OPC client application the data in your profibus field bus through the
communication cards of the Woodhead Profibus product.

Conventions
This guide uses stylistic conventions, special terms, and special notation to help enhance your
understanding.

Style
The following stylistic conventions are used throughout this guide:
Bold indicates field names, button names, tab names, and options or selections
Italics indicates keywords (indexed) or instances of new terms and/or specialized words
that need emphasis
CAPS indicates a specific key selection, such as ENTER, TAB, CTRL, ALT, DELETE
Code Font indicates command line entries or text that you’d type into a field
Underlining indicates a hyperlink
“>” delimiter indicates how to navigate through a hierarchy of menu selections/options
“0x” indicates a hexadecimal value

Terminology
The following special terms are used throughout this guide:
OPC Ole for Process Control
Topic represents a data source available through the OPC server.

OPC Data Access Server •4• Table of contents


Woodhead
Special Notation
The following special notations are used throughout this guide:

Warning
Warning messages alert the reader to situations where particular attention is
required. Warnings are accompanied by the symbol shown, and precede the
topic to which they refer.

Caution
Caution messages alert the reader to situations where damage may result.
Cautions are accompanied by the symbol shown, and precede the topic to
which they refer.

Note
A note provides additional information, emphasizes a point, or gives a tip for
easier operation. Notes are accompanied by the symbol shown, and follow the
text to which they refer.

OPC Data Access Server •5• Table of contents


Woodhead

2 General information

2.1 Presentation of OPC

The "Woodhead Profibus" package includes high-level software interfaces enabling access to the
data to be made completely transparent for the user. These software interfaces enable "client
applications" to manipulate the data of the field bus without being concerned card access
management and communication.

OPC: What is it?


OPC (OLE for Process Control) is a communication standard based on OLE/COM technology
which constitutes a special means of exchanging data between MS-Windows applications. The
COM model is intended to ensure interoperability between software components developed
independently by different publishers. This interoperability is independent of the development
languages used. COM can be considered as a "software bus" playing a "Plug and Play" role
between software modules.
The OPC foundation, which was created on the initiative of the main operators of the automation
industry, publishes and maintains specifications satisfying more specifically the industrial
requirements of this sector. These specifications are thus intended to provide maximum
interoperability between control/command/supervision applications, industrial facilities (APIs,
sensors and actuators) and office-based management applications.
OPC Data Access is one of the specifications of the OPC foundation. It describes all the objects
and their interfaces which every OPC Data Access server must implement in order to expose data
for client applications. The latter can then access this data using generic methods. Access can be
accomplished on a one-off basis (using a synchronous or asynchronous query) or in an event-
related manner (subscription).
For more information concerning OPC specifications you can visit the site of the OPC foundation
http://www.opcfoundation.org.

OPC Data Access Server •6• Table of contents


Woodhead

2.2 Rapid presentation of the "Woodhead profibus" OPC server

The OPC server is an application ("PfbOpcServer.exe") playing the role of a server of data
originating from the DP profibus network, with the following characteristics:

General characteristics:
It is in compliance with OPC custom Data Access specifications 2.05a and 3.0
o It can thus be used easily from any application incorporating at base an OPC client
interface (supervision applications, applicom® communication ActiveX, applications
written in C or C++)
It may be used locally (from a client application on the same machine) or remotely through
DCOM (from a client application on another machine through by the network).
It is compatible with the Windows NT4.0 SP6, Windows 2000 SP4 minimum, Windows XP
SP1 minimum and Windows 2003 Server environments.
It may be used as a simple executable file or in the form of a Windows NT service.

Profibus function
The OPC server enables one to work simultaneously with one or more Profibus cards
When a card is used as a Profibus DP master, the OPC server enables you to access the
following data in the Profibus network:
o I/O data (Data exchange/DP class1)
o I/O data (DP class2) in read-only mode of the shared facilities (managed by another
master)
o slot/Index read/write DPV1 data. These accesses can be accomplished
either in DP class 1 or DP class 2 for facilities in which the card plays the role of
principal master
in DP class 2 for shared facilities
o diagnostic data (slave diag) of facilities in which the card plays the role of principal master
When a card is used as a DP slave, the OPC server enables you to access the following profibus
data:
o I/O data of the slave
The master and slave function can be used simultaneously.

Additional functions
The items exposed by the OPC server are declared in the configuration console during the
network configuration phase. Default items are added automatically when equipment or
modules are added to the configuration. It is then possible, if necessary, to modify the
parameter settings of these items, notably:
o to rename them
o to change their type
o to define their limiting values

OPC Data Access Server •7• Table of contents


Woodhead
o to associate a particular property (BCD, signed, etc.)
Even if the it configuration files are necessary for operation of the OPC server, it is perfectly
possible to install the server on a machine without installing the configuration console,
simply by transferring the appropriate files.
If required, the OPC server has a complete diagnostic environment allowing current
connections to be displayed, traces to be identified and a spy to be placed on a particular
item.
The server can operate in "Offline" mode, notably if the Profibus card is missing. This mode
does enable you, however, to browse the items, enabling you to define all the connections
in your client applications under development.

2.2.1 Objects and interfaces supported

OPCServer 2.05a 3.0


IUnknown Required/supported Required/supported
IOPCServer Required/supported Required/supported
IOPCCommon Required/supported Required/supported
IConnectionPointContainer Required/supported Required/supported
IOPCItemProperties Required/supported N/A
IOPCBrowse N/A Required/supported
IOPCServerPublicGroups Optional /Not supported N/A
IOPCBrowseServerAddressSpace Optional/supported N/A
IOPCItemIO N/A Required/supported

OPCGroup
IUnknown Required/supported Required/supported
IOPCItemMgt Required/supported Required/supported
IOPCGroupStateMgt Required/supported Required/supported
IOPCGroupStateMgt2 N/A Required/supported
IOPCPublicGroupStateMgt Optional/Not supported N/A
IOPCSyncIO Required/supported Required/supported
IOPCSyncIO2 N/A Required/ supported*(2)
IOPCAsyncIO2 Required/supported Required/supported
IOPCAsyncIO3 N/A Required/supported*(2)
IOPCItemDeadbandMgt N/A Required/supported
IOPCItemSamplingMgt N/A Optional/supported*(1)
IConnectionPointContainer Required/supported Required/supported
IOPCAsyncIO Optional/ Not supported N/A
IDataObject Optional/ Not supported N/A

*(1): IOPCItemSamplingMgt is supported but bufferisation is not

*(2): Timestamp and quality writes are not supported.

Note
OPC specification DA 3.0 allows a write of the quality and the timestamp
of items using interfaces IOPCItemIO, IOPCSyncIO2 and
IOPCAsyncIO3. The OPC server does not implement these functions. In
this case, the write will be rejected with an OPC_E_NOTSUPPORTED
error, as defined in the specification.

OPC Data Access Server •8• Table of contents


Woodhead

2.3 Limitations

When in use the OPC server is considered as the single master application of the profibus
network and, as such, prohibits any other application from accessing the card. In addition,
at start-up, the OPC server will re-initialise the profibus interface and the network.
Consequently,
o If another application is connected to the profibus card when the OPC server is
started, the latter will start up "Offline" mode" (no real access)
o However, when the OPC server has already started, it is possible to start another
application in read-only access mode. This notably allows the network diagnostic
tool to be started.

The text type items returned by the OPC server, together with the entire graphical interface
(diagnostic, log file, etc.) are exclusively in English.

The OPC server does not support OPC specification DA 1.0a, which is considered obsolete

OPC Data Access Server •9• Table of contents


Woodhead

3 Access to data

3.1 Connecting to the server -ProgID

The OPC server is identified using its ProgID (program identifier):


“Woodhead.PfbOpcServer” ;

3.2 Method of access to data of the OPC server

To access the data from an OPC client the specification provides three methods:

Method Comments
Event-related The client subscribes to a group in order to be notified on an event-
related basis of changes having occurred to the values of the items.
Only active points of the group having changed are returned to the
client. The group refreshment period determines the minimum
period between two transmissions of values.
Synchronous The client asks explicitly for an item to be read or written. The client
remains blocked during processing of their request.
Asynchronous The client asks explicitly for an item to be read or written. The call is
non-blocking. The result of the read or write will be returned
subsequently.
When you are the user of an application package which is itself an OPC client, the latter generally
manages the data access method in a completely transparent fashion, which is hidden for the user.
If this is not the case, major elements must however be taken into account:
The event-related mode generates minimum traffic between the server and the client
since only variables which have changed are returned. It is thus the most efficient of the three
modes.

OPC Data Access Server • 10 • Table of contents


Woodhead
In asynchronous mode, if the requests are made faster than the server is able to process
them, they are queued. If too many queries are queued, requests may be refused.

3.3 Data naming principle

The OPC specification stipulates that the client application should reference a variable using a
string of characters named ItemID. For this OPC server, the OPC ItemID is the concatenation:
of a "topic" name defining the location of the variable
there are various types of topic representing data "sources" of different kinds
o of "Device" topics representing the slave stations configured in the profibus network
(master operation of the profibus card). The names of these topics can be configured in
the configuration console
o a "Slave" topic representing the Profibus card used as a slave DP. The name of this topic
can also be configured in the configuration console
o The "System" topic symbolising the OPC server itself and allowing access to internal
server data (status, general meters),
of a "category" defining the type of variable accessed
This category field is used only for "Devices" topics (representing the slave stations of the
network) and for certain types of data. It enables the nature of the accessed variable to be
distinguished:
o DPV1 for DPV1 data for reading/writing of slots/Indices.
o DIAG for diagnostic data (slave diag) of facilities in which the card plays the role of
principal master
of a "syntax" designating the variable
For "Devices" or "Slave" topics, the syntaxes corresponding to the field bus data can be
configured in the configuration console. Some predefined syntaxes also allow access to the
communication statuses or meters relative to the topic.

Notes
Access to the DPV0 data (data exchange) does not require that an
item category is specified
In the string referencing the item, the field delimiter is point ".".
The OPC specification also allows the possibility for a client to use an
AccessPath. The OPC server requires no user. However, if the latter
is not void, it will be concatenated with the ItemID string supplied by
the client to make the ItemID which is finally used by the server. For
example, if the client supplies as the AccessPath the string "TOPIC"
and as itemID the string "ITEM", the server will use the string
TOPIC.ITEM as ItemID.

OPC Data Access Server • 11 • Table of contents


Woodhead

3.4 Table summarising the supported items

Topic Name Categories syntaxes Comments


System (void) State Diagnostic and control variables in the server
(predefined) StateStr see "predefined items of the System topic"
StateMsg
ItemCount
ActiveItemCount
ErrorCount
(predefined)

"Devices" topics (void) Status Diagnostic and control variables in the item of
(configured for each StatusError equipment
item of equipment in StatusLastError see "predefined items of Devices and Slave topic"
the field bus in the ItemCount
configuration console) ActiveItemCount
ErrorCount
(predefined)

(void) Syntaxes DPV0 configured DPV0/DataExchange class 1 data or I/O class 2


(declared in the configuration data (shared facilities)
console) See "DPV0 items of Devices and Slave topics"

DPV1 Syntaxes DPV1 configured DPV1 data for reading/writing class 1 or class 2
(predefined) (declared in the configuration slots/Indices
console) See "DPV1 items of Devices topics"

DIAG station Diagnostic data (SlaveDiag query)


(predefined) station_not_ready see "diagnostic items (slave diag) of Devices topic"
cfg_fault
ext
not_supported
invalid_slave_response
prm_fault
master_lock
prm_req
stat_diag
WD_on
freeze_mode
sync_mode
deactivated
ext_overflow
master_address
ID_high
ID_low
ext_diag_length
ext_diag
(predefined)

"Slave" topic (void) Status Diagnostic and control variables in the local DP
(configured for the StatusError slave
local slave in the StatusLastError see "predefined items of Devices and Slave topic"
configuration console) ItemCount
ActiveItemCount
ErrorCount
(predefined)

(void) Syntaxes DPV0 configured DPV0/DataExchange data of the local slave


(declared in the configuration See "DPV0 items of Devices and Slave topics"
console)

OPC Data Access Server • 12 • Table of contents


Woodhead

3.5 Predefined items of the "System" topic

Item type Description


State VT_I2 Binary indication of the operating mode of the OPC server:
read-only - 0: The OPC server is in Online mode
- 1: The OPC server is in Offline mode
see section "Offline mode/online mode"
StateStr VT_BSTR Indication in ASCII form of the operating mode of the OPC server:
read-only - "ONLINE": The OPC server is in Online mode
- "OFFLINE": The OPC server is in Offline mode
see section "Offline mode/online mode"
StateMsg VT_BSTR Indication in ASCII form of the explanation of the operating mode
read-only of the OPC server:
Possible values for ONLINE mode:
- “PfbOpcServer OK, %s card(s) detected”
Possible values for OFFLINE mode:
- “Card %s not detected”
(Card %s is not present)
- “Connection Impossible for card %s:
exclusive access right denied”
(Another application is already connected to card
%s with write access rights)
- “Connection Impossible for card %s: Card In
Use”
(Another application is already connected to card
%s)
- “Access denied for card %s. Software
protection issue”
(Card %s does not authorise use of the OPC
server)
- “Configuration file(s) not found”
(At least one necessary configuration file is not
present)
- “Impossible to connect to the Card %s :
Status ”
(An error occured during connection to the
card(s) or during reinitialization

ItemCount VT_UI4 Number of items (active and inactive) created by the OPC clients
read-only connected within the OPC server
ActiveItemCount VT_UI4 Number of active items created by the OPC clients connected
read-only within the OPC server
ErrorCount VT_UI4 Number of times when the connection status of an item of
read-only equipment has changed from OK to fault.

OPC Data Access Server • 13 • Table of contents


Woodhead

3.6 Predfined items of the "Devices" and "Slave" topics

item type Description


Status VT_UI1 Indication of the status of the connection with the item of
read-only equipment to which it is attached:
For a “device” topic
- 128: connection OK
- 0: fault
For a “slave” topic
- 192: slave OK/ master in RUN mode
- 128: slave OK/ master in STOP mode
- 0: défault

StatusError VT_UI1 Bit field specifying the status of the connection with the item of
read-only equipment to which it is attached
The possible values depend on the type of topic ( « Device »,
shared « Device », or « slave ».
Cet item à la valeur 0 si tout est OK.

To understand the meaning of this byte, refer to the firmware


documentation « Firmware/DLL Reference Guide »

StatusLastError VT_UI1 This item records the last error returned by the StatusError item
read-only
ItemCount VT_UI4 Number of items (active and inactive) created by the OPC clients
read-only connected within the topic to which the item is attached
ActiveItemCount VT_UI4 Number of active items created by the OPC clients connected
read-only within the topic to which the item is attached
ErrorCount VT_UI4 Number of times when the status of connection with the item of
read-only equipment to which the item is attached has changed from OK to
fault.

OPC Data Access Server • 14 • Table of contents


Woodhead

3.7 DPV0 items of the "Devices" and "Slave" topics

Note
The DPV0 item names useable in the OPC server are configured in the
configuration console. For more specific information, please consult the
configuration console manual.

When items of equipment and/or modules are declared, default items are generated automatically
by the configuration console. It is then possible, if necessary, to modify the parameter settings of
these items, notably:
to rename them
o The following characters are not allowed
:. & é "‘ ( - è ç à ) = + } ° ] @ \ ` | [ { ~ ² < > ? / § ! µ * ^ ¤ £ ù % ‘space’ ‘nothing’
o Names must have fewer than 32 characters.
to change their size. The following types may be used, as a simple variable or table:

Variable Canonical type by default


Boolean VT_BOOL or VT_ARRAY| VT_BOOL
Byte VT_UI1 or VT_ARRAY| VT_UI1
16-bit word VT_I2 or VT_ARRAY| VT_I2
32-bit word VT_I4 or VT_ARRAY| VT_I4
IEEE floating point value VT_R4 or VT_ARRAY| VT_R4

to define limiting values (for non-Boolean items)


o These limiting values will be used for calculating the deadband
o They are also taken into account in the qualities returned when a limits-exceeded
appears.
o If no particular value is specified, the default values for the data type are used
to associate a particular property (depends on the data type)
o BCD: enables the item to be processed as being a value in BCD format
o Signed: enables, if necessary, the default canonical type of the item to be
changed, specifying that the data is of the signed type.
o Unsigned: enables, if necessary, the default canonical type of the item to be
changed, specifying that the data is of the unsigned type.

OPC Data Access Server • 15 • Table of contents


Woodhead
Important note
DPV0 items can be used:
In network facilities in which the card is the principal master. In
this case:
The DataExchange mechanisms are used. Performance
specifications are maximum
The output items can be read and written
In network facilities in which the card is the secondary master
(shared facilities). In this case:
the class2 access mechanisms are used. Performance
levels are then significantly less good. It is
recommended to access these items only when needed
via synchronous or asynchronous request and not to
advise these items
All items are accessibly only in read-only
In the local slave. In this case
Attention: output variables correspond to the input data
of the remote master, and vice-versa

OPC Data Access Server • 16 • Table of contents


Woodhead

3.8 DPV1 items of "Devices" topics

Note
The DPV1 item names useable in the OPC server are configured in the
configuration console. For more specific information, please consult the
configuration console manual.

When the item of equipment supports DPV1 functions, it is possible to declare one or more items
within the configuration console, corresponding to the various Slot/Index offered by the equipment.
The following properties must or can be entered:
Name of item
o The following characters are not allowed
:. & é "‘ ( - è ç à ) = + } ° ] @ \ ` | [ { ~ ² < > ? / § ! µ * ^ ¤ £ ù % ‘space’ ‘nothing’
o Names must have fewer than 32 characters.
Slot/Index number and size of variable
o A single item must be configured for each slot/Index and the specified size must
match the real size. Consult the documentation of your equipment to find precisely
which Slot/Indices are exposed by the equipment
Access right (read/write, read-only)
limiting values (for non-Boolean items)
o These limiting values will be used for calculating the deadband
o They are also taken into account in the qualities returned when a limits-exceeded
appears
o If no particular value is specified, the default values for the data type are used
to associate a particular property (depends on the data type)
o BCD: enables the item to be processed as being a value in BCD format
o Signed: enables, if necessary, the default canonical type of the item to be
changed, specifying that the data is of the signed type.
o Unsigned: enables, if necessary, the default canonical type of the item to be
changed, specifying that the data is of the unsigned type.

OPC Data Access Server • 17 • Table of contents


Woodhead
Important note
DPV1 items can be used:
In network facilities in which the card is the principal master. In
this case, depending on the way in which the equipment's
parameters have been set in the configuration console
(properties of node DPV1 items), access can be accomplished
Either by the class 1 access mechanisms.
Either by the class 2 access mechanisms.
In network facilities in which the card is the secondary master
(shared facilities). In this case:
The class 2 access mechanisms are used.

OPC Data Access Server • 18 • Table of contents


Woodhead

3.9 Diagnostic items (slave diag) of "Devices" topics

Warning
These items are available only for remote facilities in which the card plays the
role of principal master

The following items are supported. Their meaning is taken directly from the Profibus norm

Name of item Type/access Position in the slave diag query


(Diag.ItemName)
Station VT_BOOL/ read only Byte 1/ bit 0. station does not exist
station_not_ready VT_BOOL/ read only Byte 1/ bit 1. Slave is not ready for data exchange
cfg_fault VT_BOOL/ read only Byte 1/ bit 2. Configuration data does not agree

ext VT_BOOL/ read only Byte 1/ bit 3. Slave has extended diagnostic data

not_supported VT_BOOL/ read only Byte 1/ bit 4. Requested function is not supported in the
slave

invalid_slave_respo VT_BOOL/ read only Byte 1/ bit 5. Sets slave to O, fixed


nse

prm_fault VT_BOOL/ read only Byte 1/ bit 6. Incorrect parameterisation (ID,etc)

master_lock VT_BOOL/ read only Byte 1/ bit 7. Slave is parameterised by a different master

prm_req VT_BOOL/ read only Byte 2/ bit 0. Slave has to be reparameterised

stat_diag VT_BOOL/ read only Byte 2/ bit 1. Static diagnosis (byte Diag bits)

WD_on VT_BOOL/ read only Byte 2/ bit 3. Threshold monitoring activated

freeze_mode VT_BOOL/ read only Byte 2/ bit 4. Freeze command received

sync_mode VT_BOOL/ read only Byte 2/ bit 5. Sync command received

deactivated VT_BOOL/ read only Byte 2/ bit 7.(sets master)

OPC Data Access Server • 19 • Table of contents


Woodhead
ext_overflow VT_BOOL/ read only Byte 3/ bit 7.

master_address VT_UI1/ read only Byte 4. Master address after parameterisation (FF without
parameterisation)

ID_high VT_UI1/ read only Byte 5. ID high byte

ID_low VT_UI1/ read only Byte 6. ID low byte

ext_diag_length VT_UI1/ read only Byte 7. Extended diagnosis: header length

ext_diag VT_ARRAY|VT_UI1 Byte 8 and followings. Extended diagnosis


/read only
(241 bytes max)

OPC Data Access Server • 20 • Table of contents


Woodhead

3.10 Browsing of ItemIDs

The OPC supports browsing capacities (interfaces IOPCBrowseServerAddressSpace (optional) of


specification DA 2.05 and IOPCBrowse of specification DA 3.0 ). They enable the client applications
to undertake a search on the available items in the addressing space of the OPC server, supplying
a classified list of valid itemIDs.
The client application can use the browsing capacities even when the OPC server is in the "offline"
status (no access to the cards)

Note
The addressing space of the OPC server is structured in hierarchical fashion:
topic > category > syntax

3.11 Timestamping of data

With the OPC server, timestamping of a data item indicates the last time the value of the variable
was changed, as detected by the server. If the client makes two successive read operations in
synchronous or asynchronous mode in relation to a given variable the returned timestamping may
be identical if the value has not changed in the mean time.

3.12 Quality of items

A quality is associated with each item returned to the client


The following table indicates the various qualities used by the OPC server:

Quality
De Hexa Bit Meaning
c
0 0x000 0000 0000 The quality of the point is poor. The returned value is not useable.
0
20 0x001 0001 0100 The quality of the point is poor. The returned value matches the last
4 known value of good quality.
24 0x001 0001 1000 The data element was not able to be read or written following a
8 communication problem between the facilities and the server. The value
of the returned data element is not useable.
32 0x002 0010 0000 The data element is waiting for a first event-related return.

OPC Data Access Server • 21 • Table of contents


Woodhead
0
64 0x004 0100 0000 The quality of the data element is uncertain. The returned value is not
0 useable.
19 0x00C 1100 0000 The data element has been read correctly and any conversions have
2 0 been able to be undertaken.
19 0x00C 1100 0001 The value of the data element is less than the minimum configured
3 1 value. However, the value of the data element is correct and useable.
19 0x00C 1100 0010 The value of the data element is greater than the maximum configured
4 2 value. However, the value of the data element is correct and useable.

4 Setting of parameters of OPC server

4.1 Setting of general parameters of OPC server

The OPC server supports options which can be set in the configuration console (parameters of the
OPC server in the configuration description zone). Additional options appear when the console
is switched to Expert mode.

Option Mode description


Enable Server Normal Authorises the contextual menu of the taskbar icon; the latter allows the
Diagnostic View graphical diagnostic environment to start
Deadband Range Expert Enables the way in which the OPC server interprets the
PercentDeadband parameter for calculating the deadband to be modified.
By default the server considers that the value received is between 0 and
100 (see section on management of the deadband)
Enables the format used by the OPC server for the Boolean type to be
Boolean Expert
modified.
compatible to
2.05a - checked: The format used is compatible with OPC specification
2.05a and higher (-1 ; 0)
- unchecked: The format used is non-compatible with OPC
specification 2.05a: (1; 0)

OPC Data Access Server • 22 • Table of contents


Woodhead
4.2 Configuration of topics and of items

The topic and item names useable in the OPC server are configured in the configuration console.
Please consult the configuration console manual.

Note
Certain predefined topics and/or items, and item categories (DPV1,
DIAG) cannot be renamed.

OPC Data Access Server • 23 • Table of contents


Woodhead

5 Start-up of OPC server

5.1 Offline mode; Online mode

When it is started, the OPC server commences a start-up sequence to connect to the hardware
interfaces, reinitialise the network and detect any operational anomaly. After this start-up sequence
the server will then operate:
Either in Online operational mode. The OPC server is then considered to be in normal
operational condition, meaning that access to the Profibus network can operate normally.
Or in Offline operational mode. The OPC server is considered as not being in normal
operational condition.

5.1.1 Start-up; Initialisation of network

Each time the OPC server is started up it will make an attempt to initialise the Profibus card. To this
end it uses the configuration files generated by the configuration console.
This initialisation notably requires that no other application is connected to the card when the OPC
server starts. In the contrary case the server will start up in offline mode

Important notes
It is however possible to start up another application requesting to
access the card in read-only following the start-up of the OPC server.
This is, notably, the case of the "Woodhead Profibus" package network
diagnostic

The initialisation is undertaken on start-up of the OPC server and not


on first connection of a client application. It is thus possible to control
easily the moment of initialisation, either by manually starting the OPC
server (simple executable), or by using the NT service form of the OPC
server in automatic start-up mode.

OPC Data Access Server • 24 • Table of contents


Woodhead
5.1.2 Offline mode

After its start-up sequence, the OPC server is switched automatically into offline mode if the
connection with at least one of the Profibus interfaces cannot be established correctly for one of
the following reasons

Card not present


One of the configuration cards is not present or is not detected in the PCI bus
Another application is already connected to the Profibus card
The OPC Server cannot then re-initialise the network. Close all applications using the card
Protection problem
The card does not have the rights allowing use of the OPC server.
Run the “ViewerKeyPfb3” tool to verify your rights, then consult your vendor.
Configuration file not present
At least one configuration file is not present in the configuration folder. When the console is
used on another station, please transfer the configuration (see configuration console
manual)

During operation in offline mode the OPC server has the following specific behaviour:
OPC clients can connect to the server completely normally
Items can be browsed and added within the client applications
All items corresponding to network data will be returned with poor qualities

Important notes
The OPC client application can determine the operational mode of the
OPC server using items System.State, System.StateStr and
System.StateMsg.

When the OPC server has started in offline mode, it is no longer


possible to switch back to online mode without stopping and restarting
the OPC server.

5.2 Using the OPC server without the configuration console

It is possible to install and use the OPC server on a machine where the network configuration
console is not present. However, a configuration console must be able to be used on another
machine in order to allow the network and the names of the useable topics and items to be
configured.
The OPC server relies of configuration files generated by the console to initialise the network and
expose the appropriate items. It is thus essential that these files are present for the OPC server to
be able to operate normally. It is necessary to make a configuration transfer to the station where the
OPC server resides. To do so:
The menu File>Export of the configuration console enables the active configuration of the
configuration station to be copied to another PC or a physical support

OPC Data Access Server • 25 • Table of contents


Woodhead
The copy must be made to the sub-folder config/config01 of the installation folder of the
OPC server

5.3 Using the OPC server in the form of a Windows NT service

It is possible to use the OPC server in the form of a Windows NT service. It is, however,
recommended that your client applications are set correctly in normal mode before switching to
service mode.
By default, after installing the OPC server, service mode is not installed. To install it, start
the OPC server from the menu Start>Execute with the following option:
"PfbOpcServer –service"
To switch back to simple executable mode, start the OPC server from the menu
Start>Execute with the following option:
"PfbOpcServer –regserver"

Warning
To switch the OPC server from simple executable mode to service mode, and
vice versa, you have to verify that the OPC server is stopped before to use the
commands above.
Otherwise, these commands will have no effect.

Note
In service mode it is not possible to activate the diagnostic environment

OPC Data Access Server • 26 • Table of contents


Woodhead

6 Advanced functions

6.1 Management of groups (OPC Group)

For the client groups constitute a simple means of organising data they wish to access. This
organisation is left entirely free for the client. Consequently, a group may contain completely varied
variables collected in different facilities.
When you are the user of an application package which is itself an OPC client, the latter generally
manages groups of data in a completely transparent fashion, and one which is hidden for the user.
If this is not the case, important elements must however be taken into account when creating
groups:
It is at group level that the client application has the possibility of setting the refreshment
period.
The application has the possibility of activating or deactivating a group, i.e. of authorising
or prohibiting feedback of event-related data in relation to all the group data.
The deadband can be managed at group level. OPC specification DA 3.0 allows, through
interface IOPCItemDeadbandMgt, the deadband to be positioned for each item. The latter
replaces of cancels any which might have been configured at group level.

Note
Some client applications set the group refreshment period to 0 (return of
data as rapidly as possible). This can undermine general performance of
the system due to the scale of the data flow between the server and the
client. For this reason the OPC server uses a minimum refreshment period
of 25 ms (minimalUpdateRate of the OPC specification)

OPC Data Access Server • 27 • Table of contents


Woodhead
Note
The OPC server, supportant OPC specification DA 3 .0, implements the
optional interface IOPCSamplingMgt. This enables a sampling period to
be defined for each item. The item will then be collected by the OPC server
using the period configured in relation to the item, but the item notification
"callback" will be sent only using the period configured for the group.

6.2 Deadband

The client application has the possibility of specifying a "deadband"


- Either at group level (it will then assign all the items contained in the group)
- Or in relation to the item (specification 3.0 only).
This parameter indicates the minimum change percentage which will cause the data element to be
sent to the client application. It influences only the event-related information feedback mode. It has
become apparent that not all OPC clients set this parameter in the same manner. For this reason
the OPC server allows the range used to be defined for each configuration. It may thus be set,
according to this choice, between:
0 and 100 (1% =1). This option is the default and matches the OPC specification
Or between 0 and 1 (1% = 0.01).
The very notion of "deadband" requires that the variable concerned is of the analog type and that it
has a maximum value and a minimum value enabling a change percentage to be calculated. The
data element will thus be fed back to the client application if:
absolute value (last value fed back – current value) > pPercentDeadband * (max value - min value)
The min. value and the max. value of a data element may be configured within the configuration
console (except for predefined items). If no particular configuration has been made, it is defined by
its type:

VT_UI1 0 to 255
VT_I1 -128 to 127
VT_UI2 0 to 65535
VT_I2 -32768 to 32767
VT_UI4 0 to 4294967295
VT_I4 -2147483648 to 2147483647
VT_R4 –3.4e+38 to 3.4e+38
VT_R8 -1.79e+308 to 1.79e+308

OPC Data Access Server • 28 • Table of contents


Woodhead

7 Diagnostic interface

By default the OPC server has no graphical interface. It is however possible, when the server is
used as a traditional application (simple executable) to activate a complete diagnostic environment
notably enabling the internal behaviour of the OPC server to be analysed.

Note
The diagnostic interface is not available when the OPC server is used in the
form of a Windows NT service. If required, it is thus necessary to change back
to the form of a simple executable. If this proves impossible, consult our
technical support

After it is started (as an executable), the presence of the server is made tangible by an icon
inserted in the taskbar (if allowed by the DCOM security criteria). By default this icon has no
contextual menu. It can however be activated from the box to configure the OPC parameters of the
configuration console, by validating the option Enable Server Diagnostic View. This menu then
allows you, by right-clicking the mouse:
to display the diagnostic environment (Diagnostic menu).
to close the server (Exit menu)

The diagnostic interface is useful only for the adjustment phases of your application. Using it
consumes resources. It must not therefore be activated during operational phases. The diagnostic
interface allows:
files to be generated which can be used automatically by the application
"DumpLogger.exe", containing data concerning the configuration and communications
pending
traces to be displayed with generation of a log file (pfbopcserver.log), thus enabling the
general behaviour of the server to be checked along with communication with the client
applications.
spying more specifically on events occurring in relation to an item, with generation of a
trace file (pfbopcserverspy.log)

OPC Data Access Server • 29 • Table of contents


Woodhead
Description of general commands

Icon Description

When you press this button, the file "dumpOPC.xml" is generated in the current
configuration folder. The application "DumpLogger.exe" becomes activated and
immediately loads this latter file, displaying in the items and groups overview,
managed by the OPC server. This view is static. It is thus necessary to run the
command again to update the data.
Double-clicking one of the objects in the tree displays a box enabling the list of
internal properties of the object to be displayed.

When you press this button, the file "dumpTopic.xml" is generated in the current
configuration folder. The application "DumpLogger.exe" becomes activated and
immediately loads this latter file, displaying in the overview of topics which are
configured, and thus useable within the OPC server
Allows a list of items to be spied on. See section "Spy view of items"

Closes the messages zone of the diagnostic environment.

Activates the message zone by using a single display window, where all the
messages are written, of whatever kind. See section "Viewing messages".
Activates the message zone using several display windows, each containing
different message categories. See section "Viewing messages".
Displays information concerning the application.

OPC Data Access Server • 30 • Table of contents


Woodhead

7.1 Spy view of items

This view is divided into three parts. At the top left a browser enables the various accessible data
elements to be viewed. The bottom left part shows the list of items to be kept watch of, and the
right-hand part displays the messages of events affecting the items in the list.

To spy on an item
select the item to be kept watch on in the browser
do a "slide – move" of the browser to the list below
if necessary complete the syntax (press F2 to rename) and click on the checkbox to select
the item

start the watch by pressing button:


From this time, it is no longer possible to modify the items under active watch. It is however
possible to add items to the list or to modify those which are not active.

The watch may be stopped using the button:

OPC Data Access Server • 31 • Table of contents


Woodhead
Note
The command Logger parameters... in the Diagnostic menu allows all
messages displayed in the view to be saved in a file "PfbOpcServerSpy.log"
located in the configuration folder. Attention: these parameters are also applied
to file "PfbOpcServer.log" allowing messages from the application to be saved.

Available commands

Icon Description

Create a new list of items to watch. If there is already a list which has not been
saved, a message appears.
Opens a list of items to be watched which was previously saved on the disk. If
there is already a list which has not been saved, a message appears.
Allows the active list of items to be watched to be saved to disk.

Searches for a string of characters in the current window. It is case-insensitive.

Deletes all messages in the message display window.

Copies the selected text from the message window to the clipboard. It can then
easily be pasted into any other text-type file.
Puts all selected items in the list under watch.

Stops watching of all items.

Adds the selected item from the tree into the list.

Deletes the selected item from the list.

Selects the item (or items) to place a watch on it/them.

OPC Data Access Server • 32 • Table of contents


Woodhead

7.2 Messages view

This view enables information relating to the execution of the application to be displayed. This view
is activated using the following three buttons:

Icon Description

Closes the message zone

Displays the view by incorporating all the messages in the same window

Displays the view by separating the messages into three tabs:


Read tab: displays a message whenever the server is about to acquire a
data element from the emulator
Write tab: displays a message whenever the server sends a data element
to the emulator
Error tab: displays a message whenever an error occurs (syntax error,
incorrect conversion of a value, etc.)

It is possible to stop tracing of messages in the windows by selecting the command Diagnostic >
Output View > Stop Messages. The command Restart Messages allows traces to be resumed.
Both these commands act on the all the message windows at the same time. On stoppage or
resumption, a message is signalled in each of the tabs. The command Clear Output View allows
all the messages of the visible tab to be deleted. The messages of the other tabs are not affected
by this command.

Warning
All the messages issued by the server between stop (Stop Messages) and
resumption (Restart Messages) are lost.

OPC Data Access Server • 33 • Table of contents


Woodhead
Note
The command Logger parameters... in the Diagnostic menu allows all
messages displayed in the view to be saved in a file "PfbOpcServer.log"
located in the configuration folder. Attention: these parameters are also applied
to the file "PfbOpcServerSpy.log".

OPC Data Access Server • 34 • Table of contents


Woodhead

8 Annexes

8.1 Developing an OPC client

8.1.1 Development contexts

Many supervision applications include the OPC client function as standard. However, in the case of
specific requirements, it is possible to develop one's own OPC client oneself, using the
development tool of one's choice. This section is intended solely to supply the basic information
required by developers

Developments can be classified in two main categories:


Developments using the custom interface.
This interface can be used with languages of the C/C++ type. Its use requires complete
knowledge of the OPC Data Access specification, OPC mechanisms in general and
OLE/COM mechanisms.

Developments undertaken using the Automation DLL.


This interface is more specifically intended for fast development tools such as VB, Delphi,
offices tools, etc. It in fact constitutes an additional automation layer of the custom
interface useable in languages of the C/C++ type. Its use requires complete knowledge of
the Data Access Automation Interface specification and of OPC mechanisms in general.
This DLL is not supplied in the package. If required, the Automation DLL sources can be
obtained from the OPC foundation

8.1.2 ProgID and CLSID

The OPC server is identified using its ProgID (program identifier) and its CLSID (class identifier),
recorded in the registers database of the machine during installation.

OPC Data Access Server • 35 • Table of contents


Woodhead
The CLSID is the single and universal identifier of the server and it is independent of its version.
The ProgID is a string of characters translated from the CLSID using the registers database. It
constitutes a legible synonym of the CLSID.
ProgID: Woodhead.PfbOpcServer
CLSID: {283618B5-8349-11D0-8F82-0080C85344A1}

8.1.3 Developing a client in C and C++


The OPC server is based on specifications 2.05a and 3.0 of the OPC foundation. It supports access
through the OPC custom Interface.
The aim of this documentation is not to replace the specification published by the OPC foundation.
The latter describes in detail the different interfaces and the role of the methods they expose. The
purpose of this section is to describe particular features relating to the development of an OPC
client in C++ with this OPC server in particular.

8.1.3.1 Creation of an OPCServer object


The OPC server is identified using its ProgID (program identifier) and its CLSID (class identifier),
recorded in the registers database of the machine during installation.
The CLSID is the single and universal identifier of the server and it is independent of its version.
The ProgID is a string of characters translated from the CLSID using the registers database. It
constitutes a legible synonym of the CLSID.
ProgID: Woodhead.PfbOpcServer
CLSID: {283618B5-8349-11D0-8F82-0080C85344A1}
To instance the OPC server, the client application must:
1 – Initialise the COM library
2 – Obtain the CLSID from the OPC server from the ProgID
3 – Create an OPCServer object
4 – Call one or more functions of the OPCServer object
5 – Release the interfaces used.
This is an example of code undertaking the above stages (for the sake of code legibility error cases
are not handled):
//Stage 1: Initialise the COM library
HRESULT hr;
hr = CoInitialize(NULL);

//Stage 2: Obtain the CLSID from the ProgID


CLSID clsid;
hr = CLSIDFromProgID((L" Woodhead.PfbOpcServer "),&clsid);

//Stage 3: Create the OPCServer object and obtain the first


interface (here IOPCServer)
IOPCServer* pServer;
hr = CoCreateInstance(clsid,NULL,
CLSCTX_LOCAL_SERVER,IID_OPCServer,(void**)&pServer);

//Stage 4: Call one of the functions of the interface.



pServer->GetStatus(…);

//Stage 5: Release the interfaces

OPC Data Access Server • 36 • Table of contents


Woodhead
pServer->Release();
UnInitialize();

8.1.3.2 Creation of an OPCGroup object

A group is created by the client using a call to the method AddGroup of the interface IOPCServer
of the object OPCServer. The latter notably contains the following parameters:

Name Description
szName Name of group. If it is not supplied, the server generates a unique one (in the
form New_Group_x , where x is an incremental number).
dwRequestedUpdateRate Refreshment period requested by the client. The period actually accepted by
the server will be returned in the return parameter
dwRequestedUpdateRate.
dwLCID This parameter is not used.
pPourcentDeadBand This parameter allows return of the variable with a strong variation (see
"Group management")

8.1.3.3 Managing items

Items are created by the client using a call to the method AddItem of the interface IOPCItemMgt of
the object OPCGroup. Each item symbolises a connection to a physical variable. In fact the client
describes the variable which interests it by means of a OPCITEMDEF structure.
The fields of this structure are as follows:

Name Description
szAccessPath Not actually used by the OPC server. If this field is used its content will be
concatenated to that of the item (szItemID) to form the name of the item
szItemID String of characters referencing the item.
bActive indicates the state of activation of the item at the time of its creation.
hClient Reference handle of point for the client.
dwBlobSize the "blob" mechanism is not used by the OPC server.
pblob the "blob" mechanism is not used by the OPC server.
vtRequestedDataTyp Type of variant requested by the client. The value VT_EMPTY designates the
e default type (decided by the server).

OPC Data Access Server • 37 • Table of contents


Woodhead
Notes
When a new item is added to a group using the method AddItems, the
OPC server automatically determines the canonical type of the variable
and returns it in the field vtCanonicalalDataType of the structure
OPCITEMRESULT.
If there is no specific requirement, it is thus recommended that the
client application should always pass the value VT_EMPTY in the field
vtRequestedDataType, thus allowing the server to determine itself the
type of the variable

OPC Data Access Server • 38 • Table of contents


Woodhead

8.2 Use through DCOM

8.2.1 Introduction to DCOM


What is DCOM?
COM objects, such as the OPC server, do not necessarily have to be on the same machine as the
client. With DCOM (distributed COM), a client can create and use COM objects both on their own
system and on other machines. This enables the components of an application to be distributed
across the network.

The COM library


A client does not address an object directly to start it or to use it, but goes through the COM library.
The latter forms part of the operating system. The COM library manages the data in the register
database for all known COM objects in the system.

Transparency
For the client, use of a COM object through DCOM or through the COM mechanisms locally is
completely transparent. The operating system, through the COM library, manages the object and
determines where it must be instanced according to the configuration associated with the object.

8.2.2 Installation

When implementing the OPC solution in DCOM, you will be undertake the following operations:
Establishment of a "server station" (under Windows NT4, Windows 2000 or Windows XP)
containing the OPC server and able to be accessed either from a local OPC client (running on
the machine), or from a remote OPC client (running on another machine)
Establishment of a "client station" (under Windows NT4, Windows 2000 or Windows XP)
interrogating a remote station.

Establishing a "server station"


The OPC server is installed by checking the corresponding option during the installation program.
After installation, the OPC server can be accessed from any OPC client running on the local
machine. To be sure that this is so, try to connect to the OPC server from the OPC client utility.

Establishing a "client station"

The package of the "OPC server" includes a file PfbOpcServer.reg allowing the server to be
registered in the client station in the registers database, thus allowing it to be configured in the utility
dcomcnfg.
To register the OPC server, include the file PfbOpcServer.reg in the register database by
double-clicking the file.

OPC Data Access Server • 39 • Table of contents


Woodhead

8.2.3 Configuring DCOM


The "DCOMCNFG" program
Before a client is able to use a COM object on another machine, the properties of the COM object
must be configured in the client machine and in the remote machine. DCOM and the COM objects
used are configured using the program supplied with the system, dcomcnfg. After starting the
program, for example by entering the command dcomcnfg in the dialogue box of the menu Start>
Execute), four tabs are available for the DCOM configuration.

Specific features for Windows XP


Under Windows XP, the utility dcomcnfg has the following form:

To obtain the box for configuring the general properties, select node ‘My Computer’ in the tree
under \Console Root\Component Services\Computers\, and then choose the option Properties in
the contextual menu or in the menu Action. The properties box is then similar to that of dcomcnfg
under Windows 2000 or NT4 and it contains tabs ‘Default Properties’ and ‘Default COM
Security’. Configuring these parameters is then identical to that described below.

Note
If you reduce the security parameters it will always be necessary to
restart the system before they are taken into account.

OPC Data Access Server • 40 • Table of contents


Woodhead
Warning
The screen copies were made under Windows 2000; under N4 they
may be slightly different.
Under Windows XP, the DCOM configuration utility dcomcnfg is
slightly different from the one present on a Windows 2000 or NT4
station. These differences will be described in detail if they could pose
difficulties in finding the parameters to be configured.
Only the tabs requiring modifications are described.
The parameters specified in this documentation guarantee simply that
the DCOM protocol will start. However, most of the security
parameters of Windows NT have been reduced. To satisfy a higher
security level, you must comply strictly with parameter settings in
agreement with DCOM principles. For more information, refer to article
number Q176799, Q158508 and Q169321 in the "Microsoft Knowledge
Base".

OPC Data Access Server • 41 • Table of contents


Woodhead
8.2.3.1 Configuring the DCOM general properties in the server machine and the client machine

"Default properties" tab


The Default properties tab enables the basic DCOM properties to be specified.

To use DCOM with the OPC server:


check Activate Distributed COM (DCOM) on this computer
set the parameters to:

Type of network controller Authentication level Identity borrowing


level
Workgroup (no domain server available for the None Anonymous
authentication)
Domain server Connection Identifier

OPC Data Access Server • 42 • Table of contents


Woodhead
"Default security" tab

Warning
Do not use this tab. The permissions of the OPC server will be set individually
later.

The Default security tab enables the permissions for DCOM operations to be specified. These
parameters certify that only clients with the necessary permissions will be able to use the server.

The following default permissions can be set to use DCOM. These permissions can also be set
individually for each object and these default properties will then be ignored.

Type of permissions Information


Access permissions The Default access permissions enable it to be specified for all COM
objects which user accounts will be able to access the object; in other
words, to call its methods.
Execution permissions The Default execution permissions enable it to be specified for all
COM objects which user accounts will be able to create a new
instance of the object.
Configuration The Default configuration permissions enable it to be specified for all
permissions COM objects which user accounts will be able to modify the register
database information.

OPC Data Access Server • 43 • Table of contents


Woodhead
Specific features for Windows XP
Under the node ‘My Computer’, expand the node ‘DCOM Config’ to obtain all the COM objects
available from the machine:

Then select the OPC server Woodhead OPCPfbServer and select the option Properties in the
menu Action to start configuring the specific parameters of the OPC server.
The same dialogue box containing the same tabs as under Windows 2000 is then found.
Then undertake the same configuration for OpcEnum.

OPC Data Access Server • 44 • Table of contents


Woodhead
"Applications" tab
The Applications tab displays all the COM objects available from the machine.

Select the OPC server Woodhead.OPCPfbServer and click the button Properties… to start
configuring the specific parameters of the OPC server.
Then undertake the same configuration for OpcEnum.

OPC Data Access Server • 45 • Table of contents


Woodhead
8.2.3.2 Configuring 'applicom OPC Server' on the server machine
"General" tab
In the General tab you can change the level of authentication of an object.

For the OPC server, leave this property at default

OPC Data Access Server • 46 • Table of contents


Woodhead
"Location" tab
The Location tab is used to specify the machine in which the server has started.

In the server station, select Run application on this computer.

OPC Data Access Server • 47 • Table of contents


Woodhead
"Identity" tab
The parameters of the Identity tab specify which accounts will be used to check the user's
permissions in relation to this object.

There are several possibilities:

Type Action
The interactive user This choice is the one recommended by default for the OPC server.
The account of the user having opened the current session is used. If,
however, no user is logged on the machine there is no interactive user and
the COM object cannot be created. In this case, select This user.
The launching user The account of the user having initiated the OPC client is used. This user
must then have the required permissions, and thus be included in the
Security tab. This mode generally causes a server instance to be initiated
for each executing user. This option must not be used with the OPC
server.
This user The account of the indicated user is used. This user must then have the
required permissions, and thus be included in the Security tab. The user
must have the default permissions assigned to the Users of the machine
group; in other words, must belong to the Users group. This choice must
be used for servers where no user is logged.

OPC Data Access Server • 48 • Table of contents


Woodhead
"Security" tab
You can specify the access permissions for the OPC server from the Security tab. For the three
security aspects used by DCOM you can either:
user the default permissions
In this case, the account configured in the Identity tab must have the requisite permissions in the
Default security tab (default access permissions, default execution permissions).
use customised permissions for the selected object
If you want one particular user not to be able to access all the available COM objects, you must use
customised permissions.

To work with the OPC server, only the access permissions and the execution permissions need to
be configured:

OPC Data Access Server • 49 • Table of contents


Woodhead
Choose Use customised access permissions
Press Modify and set the following permissions:

Then choose Use customised execution permissions


Press Modify and set the following permissions:

Note
On the server machine and on the client machine, the accounts of both logged
persons must exist.
Example: User Alpha is logged on the machine with the server and user Beta is
logged on the machine with the client.
To use DCOM a Beta account must exist on the server station (with the same
password as on the client machine) and an Alpha account must exist on the
client station (with the same password).

If you work with a domain, it is recommended that a group containing user


accounts is used. The permissions are then managed from the domain server.

OPC Data Access Server • 50 • Table of contents


Woodhead
8.2.3.3 Configuring 'applicom OPC Server' on the client machine
For the client part, the screen copies below show a simple configuration enabling the OPC server to
be used through DCOM

"General" tab

OPC Data Access Server • 51 • Table of contents


Woodhead
"Location" tab

OPC Data Access Server • 52 • Table of contents


Woodhead
"Identity" tab
In the Identity tab you can specify which user account will be used for the client machine. It is
logical to specify Interactive user, or in other words, the user logged on the machine.

OPC Data Access Server • 53 • Table of contents


Woodhead
"Security" tab

OPC Data Access Server • 54 • Table of contents


Woodhead
Access type: Allow access

Access type: Authorise initiation

OPC Data Access Server • 55 • Table of contents


Woodhead

9 Support

9.1 Technical Support

Technical support is available during regular business hours by telephone, fax or email from any
Woodhead Software & Electronics office, or from contact.pdf.

OPC Data Access Server • 56 • Table of contents


Woodhead

10 Index

A I
AccessPath, 11 initialisation, 24
Asynchronous, 10 Interfaces, 8
Item, 11, 37
B ItemID, 11
Items diagnostic, 19
Browsing, 21
Items supported, 12
C N
category, 11 note, definition, 5, 50
caution NT service, 26
definition, 5
CLSID, 35
O
configuration files, 25
Configuration of topics and of items, 23 Objects, 8
conventions Offline mode, 24, 25
special notation, 5 Online mode, 24
special terms, 4 OPC, 6
style, 4 OPC Groups, 27, 37
Custom interface, 35 OPC server, 6
OPC, definition, 4
D
P
DCOM, 39
DCOMCNFG, 39 ProgID, 10, 35
Deadband, 27, 28 purpose, of guide, 4
Diagnostics, 29
DLL automation, 35 Q
DPV0, 15
DPV1, 17 Quality, 21
Quick introduction, 7
E
R
Event-related, 10
Reg file, 39
F
S
firmware
definition, 4 Slave diag, 19
Functions, 7 Start-up of OPC server, 24

OPC Data Access Server • 57 • Table of contents


Woodhead
State, 13 Timestamping, 21
Status, 14 Topic, 11
support, 56 topic Slave, 11
Synchronous, 10 topic System, 11
System, 13 topics Devices, 11

T W
technical warning
support, 56 definition, 5

OPC Data Access Server • 58 • Table of contents

You might also like