Matrikonopc Client For Odbc: User'S Manual
Matrikonopc Client For Odbc: User'S Manual
User’s Manual
MatrikonOPC Client for ODBC
User’s Manual
Phone: +1.780.448.1010
Fax: +1.780.448.9191
www.matrikonopc.com
Document
Date Description Author
Version
2008-06-10 1.0 Initial User‟s Manual for newly designed DOC
MatrikonOPC Client for ODBC.
Version: 3.1.4.0
DOCUMENT VERSION
Version: 5.1
COPYRIGHT INFORMATION
© Copyright 1997 - 2011, Matrikon Inc. All rights reserved. No part of this document may be reproduced, stored in
a retrieval system, translated, or transmitted in any form or by any means, electronic, mechanical, photocopying, recording,
or otherwise, without prior written permission of Matrikon Inc.
CONFIDENTIAL
The information contained herein is confidential and proprietary to Matrikon Inc. It may not be disclosed or transferred,
directly or indirectly, to any third party without the explicit written permission of Matrikon Inc.
LIMITATIONS
Matrikon has made its best effort to prepare this manual. Matrikon makes no representation or warranties of
any kind with regard to the completeness or accuracy of the contents herein and accepts no liability of any kind
including without limitation warranties of merchantable quality, satisfactory quality, merchantability and
fitness for a particular purpose on those arising by law, statute, usage of trade, course of dealing or otherwise.
Matrikon shall not be liable for any losses or damages of any kind caused or alleged to be caused directly or
indirectly from this manual.
LICENSE AGREEMENT
This document and the software described in this document are supplied under a license agreement and may only be used
in accordance with the terms of that agreement. Matrikon reserves the right to make any improvements and/or changes to
product specifications at any time without notice.
TRADEMARK INFORMATION
The following are either trademarks or registered trademarks of their respective organizations:
OTHER
Table of Appendices
Appendix A Distributed COM (DCOM) ........................................................................ 70
DCOM Configuration Utility ............................................................................................... 70
Default Properties ............................................................................................................ 70
Security Permissions ........................................................................................................ 71
Server Identity ................................................................................................................ 75
Default Protocols ............................................................................................................. 75
Remote Program ID ......................................................................................................... 76
Appendix B ODBC DSN Configuration ......................................................................... 77
DSN Types Note .............................................................................................................. 77
Data Source Configuration ................................................................................................ 77
Table of Figures
Figure 1 - MatrikonOPC Welcome Screen ....................................................................... 12
Figure 2 - Read Me File Screen ....................................................................................... 13
Figure 3 - Choose Destination Location Screen .............................................................. 14
Figure 4 - Advanced Settings Window ............................................................................ 14
Figure 5 - Select Program Manager Group Screen .......................................................... 15
Figure 6 - Registration Information Screen .................................................................... 16
Figure 7 - Installation Information Screen ..................................................................... 17
Figure 8 - Transaction Number Screen ........................................................................... 17
Figure 9 - Licensing Screen ............................................................................................ 18
Figure 10 - Start Installation Screen .............................................................................. 19
Figure 11 - Installation Complete Screen ....................................................................... 19
Figure 12 - Tool Tray ...................................................................................................... 23
Figure 13 - Tool Tray Menu............................................................................................. 24
Figure 14 - Configuration Window .................................................................................. 25
Figure 15 - Database Connection Configuration Window ................................................ 28
Figure 16 - Deleting Database Connection ..................................................................... 30
Figure 17 - Database Deletion Confirmation Message .................................................... 30
Figure 18 - Table Write or Custom Write ........................................................................ 31
Figure 19 - Table Write Transaction Configuration Panel ............................................... 32
Figure 20 - Select OPC Server Connection Window ........................................................ 34
Figure 21 - Add OPC Item(s) Window ............................................................................ 35
Figure 22 - Browse OPC Item(s) Window ....................................................................... 36
Figure 23 - Set Transaction Properties Window ............................................................. 38
Figure 24 - Configured Table Write ................................................................................ 39
Figure 25 - Confirmation Message .................................................................................. 40
Figure 26 - Confirmation Message .................................................................................. 41
Figure 27 - Add Query Window - Data Values Tab .......................................................... 42
Figure 28 - Add Query Window - Transaction Options Tab ............................................. 43
Figure 29 - Add Query Window - OPC Options Tab ......................................................... 45
Table of Tables
Table 1 - Terms and Definitions...................................................................................... 10
Table 2 - Files Installed in "OPC ODBC" Folder ............................................................... 21
Table 3 - Files Installed in "Common" Folder ................................................................. 21
Table 4 - MatrikonOPC Support Regional Contact Information ....................................... 22
Table 5 - After-Hours Support ........................................................................................ 22
Table 6 - Tool Tray Menu Commands .............................................................................. 24
Table 7 - Configuration Window Commands ................................................................... 25
Table 8 - File Menu Commands ....................................................................................... 26
Table 9 - Edit Menu Commands (Server Configuration) .................................................. 26
Table 10 - View Menu Commands ................................................................................... 27
Table 11 - Help Menu Commands ................................................................................... 27
Table 12 - Database Connection Configuration Window Components ............................. 28
Table 13 - Table Write Transaction Configuration Panel Components ............................ 33
Table 14 - Set Transaction Properties Window Components .......................................... 39
Table 15 - Add Query Window - Transaction Text Panel Components ............................. 42
Table 16 - Add Query Window - Data Values Tab Components ....................................... 43
Table 17 - Add Query Window - Transaction Options Tab ............................................... 44
Table 18 - Add Query Window - OPC Options Tab Components ...................................... 46
Table 19 - Add Query Window - Transaction Results Tab Components ........................... 47
Table 20 - Add Query Window - Current Transactions Tab Components ......................... 48
Table 21 - Preferences Window - General Tab Components ........................................... 56
Table 22 - Preferences Window - Logging Tab Components ........................................... 58
Overview of Manual
This document uses icons to highlight valuable information. Remember these icons and what they
mean, as they will assist you throughout the manual.
The User’s Manual has been designed as such so that you can click on references in the document
to jump to that referenced point without having to scroll through several pages (in some cases).
For example, if you were to see the sentence “Refer to Figure 1 for more information”, pressing the
CTRL key and clicking your mouse on the text “Figure 1” will automatically take you to the location
of Figure 1 within the document.
This manual consists of several sections and is structured as follows:
Introduction – this introductory chapter.
Getting Started – provides instructions for installing the client, and how to contact
MatrikonOPC‟s Support team.
Configuration – shows how to start and configure the client, and describes each
component in detail, including windows/screens, panels, tabs, and menu commands.
References
This document references information found within the following documents/sites:
www.opcfoundation.org
www.matrikonopc.com
www.opcsupport.com
Document Terminology
The terms screen and window are used interchangeably throughout this document.
Table 1 provides a list of definitions for terms used throughout this document.
Term/Abbreviation Description
Component Object Model. A method for organizing software, specifying how to
COM
build components that can be dynamically interchanged.
DA OPC Data Access. Provides access to real-time process data.
Distributed Component Object Model. An extension of COM that allows
DCOM
communication between COM components over a network.
Human Machine Interface. Device that allows interaction between the user and
HMI
machine. Typically used in process control applications.
Matrikon Matrikon Inc.
MatrikonOPC Matrikon‟s brand name for its OPC servers and clients.
A communication standard. Refer to www.opcfoundation.org for more
OPC
information.
PLC Programmable Logic Controller.
Open Database Connectivity. A standard defining a method for applications to
ODBC
interact with compliant databases.
Table 1 - Terms and Definitions
System Requirements
The software has minimum Software and Hardware system requirements. These requirements
must be met for the software to function properly.
Software Requirements
The product requires the following software:
Microsoft Windows XP or 2003 or 2000
Microsoft Internet Explorer 6 SP1 (or better)
.NET 1.1 Framework (included in install package)
Hardware Requirements
The product requires the following hardware:
Intel® Pentium® 4 Processor
512 MB RAM
40 GB 7200 RPM hard drive
Installation
Once the system requirements have been met, you are ready to install the software.
6. Read the End-User License Agreement (EULA), using the scroll bar to view the entire
message.
7. Click on the Accept button. The Choose Destination Location screen (Figure 3) appears.
8. Click on the Advanced button to display the Advanced Settings window (Figure 4).
9. Leave all of the checkboxes selected to install all client components (you may clear any
components that you do not want to install). It is recommended that you install these files.
12. Click on the Next button to add the client icons to the default program manager group. If
required, scroll through the list to select another program manager group. The
Registration Information screen (Figure 6) appears.
13. Enter the name and email address, as well as the company’s name, address, and
telephone number in the appropriate fields. The Computer Name field is automatically
populated.
15. Select the I am evaluating this software option button to enable the software for a 30-
day evaluation period, or until a permanent license is obtained. Go to step 18.
16. If the user already has a transaction number, select the I have or will be purchasing the
software option button. Click on the Next button. The Transaction Number screen
(Figure 8) is displayed.
19. Click on the Next button. The Start Installation screen (Figure 10) appears.
20. Click on the Next button. The installation begins and the client files are copied to the
computer.
Note: Prior to starting the installation, you have the option of clicking on the Back button
to change any of the installation information.
21. When the installation has finished, the Installation Complete screen (Figure 11) appears.
Installed Files
The installation program copies all necessary files to the target computer and creates shortcut
icons in the Start menu.
The files listed in Table 2 are installed by default, in the following location:
C:\Program Files\Matrikon\OPC\OPC ODBC
The files listed in Table 3 are installed by default, in the following location:
C:\Program Files\Common Files\MatrikonOPC\Common
IMPORTANT TO NOTE:
The following licensing information is described in detail within the
Licensing Procedures document which accompanies the ODBC Client
software and User’s Manual:
Requesting a software license.
Enabling a temporary software authorization.
Installing a permanent software license.
Generating a new AuthorizeRequest.MTK file.
De-licensing software.
Installing a Hardware licensing
Licensing Q&A and Troubleshooting.
Note: De-licensing deactivates the transactions and re-licensing does not activate them. You will
have to activate them again, manually.
Contacting Support
The MatrikonOPC Customer Services department (www.opcsupport.com) is available 24 hours a
day, seven days a week.
Contact MatrikonOPC Support using the information below, or send an email
([email protected]). For Monday to Friday daytime support requests, contact
MatrikonOPC Support using the regional phone numbers provided in Table 4.
For after-hours support in all regions, please use either of the following numbers. There is no
extra charge from MatrikonOPC for calling their after-hours support numbers.
If the client is not installed as a Windows service, the Welcome screen appears briefly
when the client starts up.
Command Description
Configure Displays the main Configuration window.
Shutdown Shuts down the server.
Table 6 - Tool Tray Menu Commands
Configuration Window
Note: If the client is installed as a Windows service, the Tool Tray Menu is not available. In this
case, the Configuration window is then accessed via the Windows Start menu: Start ->
Programs -> MatrikonOPC -> OPC Client for ODBC -> OPC Client for ODBC
The Configuration window allows the user to configure database connections, table writes and
custom writes. These operations will be discussed in depth later in this section.
If the client runs as a local executable, it will remain running even after the main configuration
window is closed, even if no database transactions are configured.
If the client runs as an NT service, it will remain as long as it is not manually shut down. Closing
the main configuration window will shut down the configuration utility, but will not interfere with
the normal operation of the client.
To view the Configuration window:
1. From the Tool Tray Menu or the Control Panel, select Configure.
2. The Configuration window (Figure 14) appears.
Command Description
Main Menu Provides access to the File, Database, View, and Help menus.
Main Toolbar Provides shortcut buttons for commonly performed operations.
Launches the Database Connection Configuration window
Connect to Database… (Figure 15) to allow the user to configure the database connection.
Displays a tree of configured table writes. By right-clicking on a
Configuration Overview
component, the user can choose to delete the component.
Undoes changes to a transaction. By selecting this option, the
Undo
transaction is reverted to the last applied state.
Adds or updates the current transaction with the configuration
Apply
specified in the GUI.
Deletes the current database, transaction or OPC item from the
configuration. When deleting a database, transaction or OPC item,
Delete note its position in the Current Overview tree. The deletion
operation will delete the current tree leaf and every leaf below it.
Table 7 - Configuration Window Commands
The following sections describe the menus available from the Configuration window, and what
they are used for.
Command Description
Clears the current configuration and starts a new one. You will be given
New the option to save the current configuration before clearing the existing
one.
Clears the current configuration and loads a new one from an existing file.
Open Before clearing the old configuration, you are prompted to save the
current one. Displays the Open window to prompt for the file name
Saves the current configuration to an XML file. Displays the Save
Save Configuration window to prompt for a new file name if the configuration
is new and has not been saved before.
Saves the current configuration to an XML file. Displays the Save
Save As
Configuration window to prompt for a new file name.
Shuts down the MatrikonOPC Client for ODBC and closes the
Shutdown
Configuration window.
Closes the Configuration window. If the current configuration has not
been saved, you are prompted about whether or not to save the
Exit
configuration before closing. Upon exiting the window, the MatrikonOPC
Client for ODBC remains running in the background.
Table 8 - File Menu Commands
Database Menu
Table 9 describes the Database menu commands used to configure database connections and
transactions.
Command Description
Connects an ODBC data source to the client. Selecting Connect to
Connect to Database Database will launch the Database Connection Configuration
window (Figure 15).
Begins configuring a new table write transaction for the selected
Table Write database. This option is greyed out when the currently selected tree
leaf is not a database.
Begins configuring a new custom write for the selected database. This
option opens the Custom Write configuration window. The custom
Custom Write
write option is greyed out when the currently selected tree leaf is not a
database.
Table 9 - Edit Menu Commands (Server Configuration)
View Menu
Table 10 describes the View menu command.
Command Description
Displays the Preferences window which is described in detail in the
Options section General Preferences of this manual. The Preferences window
Help Menu
Table 11 describes the Help menu command.
Command Description
Displays the Welcome screen, which includes information about the
About
software version.
Table 11 - Help Menu Commands
Connecting to a Database
Before configuring a transaction, it is necessary to define a database connection. The database
connection is configured in the Database Connection Configuration window (Figure 15).
The Database Connection Configuration window components are described in Table 12.
Command Description
The name of the data source, which can be obtained from the ODBC “Data
Database Sources” section in the Windows Control Panel. For more detailed
information, refer to Appendix B - ODBC DSN Configuration.
Select this button to refresh the Database list. This option is used to
allow newly configured ODBC data sources to be shown in the Database
dropdown.
Selecting this button will access the ODBC Data Source Administrator
Configuration window. This option provides the ability to configure new ODBC data
sources.
The name of the user that the MatrikonOPC Client for ODBC must use to
connect to the database.
User Name
Note: This field is dependent upon the setup of your database. If the
database does not require authentication, then this field can be left blank.
The password for the above user name.
Password Note: This field is dependent upon the setup of your database. If the
database does not require authentication, then this field can be left blank.
The amount of time (in seconds) that the MatrikonOPC Client for ODBC
Timeout(s)
must wait for the ODBC data source before declaring a timeout.
Specifies whether the MatrikonOPC Client for ODBC is permitted only to
Read Only read from the database (i.e., checkbox is selected), or if it can write as
well (i.e., checkbox is cleared).
Table 12 - Database Connection Configuration Window Components
5. If a username and password are required for the database, enter them in the User Name
and Password fields.
6. Click on the OK button to add the database. The Database Connection Configuration
window closes.
Click on the Delete icon (highlighted in green in Figure 16) on the toolbar.
2. A confirmation message (Figure 17) appears asking you to confirm the action and warning
that deleting a database connection also deletes any table and custom writes configured for
the database.
3. Click on the OK button. The confirmation message closes and you are returned to the
Configuration window and the selected database is no longer listed in the Configuration
Overview pane.
Creating a Transaction
Note: Before creating a table write, a database connection must be configured. For assistance,
refer to Connecting to a Database.
To create a transaction:
1. To create a table write for a database select the desired database node from the
Configuration window in the Configuration Overview pane.
Table Writes
Table writes are used to write attributes of an OPC item to a database table. The user selects a set
of OPC items to be associated with each transaction.
A table write may be classified as either an insert or an update. Both inserts and updates are
analogous to their corresponding SQL operation. An insert transaction writes a new table entry to
the database each time it is executed. An update transaction updates each entry in the database
meeting the update criteria. A table write update will only ever update database entries with the
same item name. Additionally, you may specify whether to update database entries only if their
quality matches that of the current OPC item. The behaviour of update transactions for this query
is subtly different than SQL updates. There is one minor difference between an ODBC client update
and an SQL update. For ODBC client updates where there are no table entries that match the
update criteria, an entry with the new OPC item information is inserted into the database.
To launch the table write transaction configuration panel:
1. From the Configuration window, in the Configuration Overview pane, select the required
database (Figure 18).
Command Description
Allows you to enter the name used to identify a transaction. When a
Transaction Name
transaction is first created, it is given an automatically generated name.
Click on this button to access the Set Transaction Properties window
which is used to define custom properties for the transaction. See
Properties
Customize the OPC Specific Settings to view the window and for an
explanation of these properties.
The name of the computer containing the OPC server. If applicable, this
Computer Name name includes the network path. This field can be entered manually, or
populated using the Browse Servers command.
The ProgID for the OPC server. This field can be entered manually, or
OPC Server
populated using the Browse Servers command.
Use this button to browse for the OPC server to use with the transaction.
Browse Servers OPC servers can be browsed on the local machine or, if applicable, the
network neighbourhood.
From the Select OPC Server Connection window, select a server from either a local or network
machine. This option will automatically populate the Computer Name and OPC Server fields.
Alternately, these names can be entered directly into these fields.
Click on the OK button to close the Select OPC Server Connection window.
3. Choose OPC Items
To browse OPC items, from the table write transaction configuration panel on the Configuration
screen, click on the Configure button to display the Add OPC Item(s) window (Figure 21).
To instantiate a browse for available items, click on the Browse button on the Add OPC Item(s)
window. This will launch the Browse OPC Item(s) window (Figure 22) containing the browsed
items.
Multiple items can be selected from the Browse OPC Item(s) window. Browsing items will
populate the OPC Items field in the table write transaction configuration panel on the
Configuration screen. Items may also be typed directly into the OPC Items field. If the server
address space cannot be browsed, OPC items may be entered manually.
Select the item or items you wish to add.
Click on the Add Item button. The Browse OPC Item window closes and you are returned to the
Add OPC Item(s) window where the selected item or items are now listed.
Click on the OK button to close the Add OPC Item(s) window and return you to the
Configuration window where the selected items are now listed in the OPC Items field.
Command Description
OPC Server Displays the ProgID for the OPC server.
Displays the machine and network information where the OPC server
Mchine
resides.
The name of the current transaction. This name may be modified in this
Transaction Name
window.
The minimum update rate (in milliseconds) for the transaction group. This
Update Rate(ms) corresponds to the update rate for the OPC group containing each of the
items in this transaction.
A value which is used for asynchronous communication to specify what
constitutes a change in an OPC item. For example, a dead-band value of
%Deadband
10% means that the value must change by at least 10% to be considered a
change.
Allows you to specify (by selecting an option from the drop-down list) how
data for items in this group will be retrieved from the OPC server. Selecting
a synchronous type tells the client to make a request for data and wait until
the server retrieves it. Selecting an asynchronous type means that the
client makes a request for data, but does not wait for the server to retrieve
the data. Rather, the server responds with an update only after retrieval,
I/O Type and only if item values in the group have changed.
Note that each type in this drop-down list refers to an OPC communication
standard. Not all standards may be implemented by your OPC server.
Selecting Autodetect attempts to automatically choose the I/O type.
Autodetect will attempt to choose an asynchronous type first, but will
default to synchronous if this fails.
After completing these five steps (and two optional steps, if required), click on the Apply button to
activate this transaction. A transaction cannot be executed until it has been applied. Figure 24
shows a complete example transaction.
3. Click on the OK button. The confirmation message closes. You are returned to the
Configuration window and the selected transaction is no longer listed in the
Configuration Overview pane.
5. Click on the OK button. The confirmation message closes and you are returned to the
Configuration window and the selected tag is no longer listed in the Configuration
Overview pane.
Custom Writes
Using table write transactions, simple insert and update transactions can be configured with a
minimum amount of effort. Sometimes, more sophisticated data manipulation is required.
The MatrikonOPC Client for ODBC can be used to construct complex SQL statements using OPC
item characteristics (name, value, timestamp or quality) and database table columns as
parameters.
To launch the custom write editor:
1. Ensure that you have first created a database connection, described previously in the
section Connecting to a Database.
2. Once a database connection has been established, highlight the database in the
Configuration Overview pane for which you wish to create a custom write. The
Configuration screen will appear similar to that shown in Figure 18.
3. To launch the custom write editor, either click the Custom Write (SQL) button, or select
the Custom Write option from the Database menu. The Add Query window (also referred
to as the custom write editor) appears (Figure 27).
The custom write editor is composed of two panes. The pane on the left (labelled Transaction
Text) is where the SQL statements are entered. The right pane contains a series of tabs used to
configure transaction options, display results of executed transactions, and display query results.
The following sections explain the Add Query window tabs, and illustrate how custom writes are
used by presenting examples.
The Add Query window includes five tabs:
Data Values
Transaction Options
OPC Options
Transaction Results
Current Transactions
The options available in the Transaction Text panel are described in Table 15. These fields appear
in this panel regardless of which tab is selected.
Command Description
Transaction Text Allows you to enter the required SQL statements.
Transaction Name Allows you to enter the name used to identify this custom transaction.
Select this button to create a new blank custom query with a unique,
New Transaction
automatically-generated name.
Select this button to execute the transaction displayed in the Transaction
Text field. This option executes this custom transaction only once, and does
Execute (F5)
not add it to the scheduled transactions for the client. Pressing the F5 key
in the query editor will also execute the query.
Table 15 - Add Query Window - Transaction Text Panel Components
Command Description
Use this drop-down list to choose which connected database for which to
Database
configure a custom write.
Command Description
Allows you to enter or select the minimum update rate (in milliseconds) for
Update Rate (ms) the OPC group(s) associated with the transaction. This will be the minimum
time between entries for an OPC item in the database.
Allows you to enter or select a value which is used for asynchronous
communication to specify what constitutes a change in an OPC item. For
% Deadband
example, a deadband value of 10% means that the value must change by
at least 10% to be considered a change.
Allows you to specify (by selecting an option from the drop-down list) how
data for items in this group will be retrieved from the OPC server. Selecting
a synchronous type tells the client to make a request for data and wait until
the server retrieves it. Selecting an asynchronous type means that the
client makes a request for data, but does not wait for the server to retrieve
IO Type the data. Rather, the server responds with an update only after retrieval,
and only if item values in the group have changed.
Note that each type in this drop-down list refers to an OPC communication
standard. Not all standards may be implemented by your OPC server.
Selecting Autodetect attempts to automatically choose the I/O type.
Autodetect will attempt to choose an asynchronous type first, but will
As you can see, the MatrikonOPC Client for ODBC can act as a query analyzer for your databases.
The range of queries that can be executed by the client is limited only by the database that you are
connected to, and the ODBC driver that you are using to connect to the database.
2. Select an OPC item that will provide the values for the transaction. To associate an OPC
item with this transaction, following the procedure described in Using an OPC Item in a
Transaction.
3. Click on the Apply button. This will schedule the transaction for execution. The GUI will
switch to the Current Transactions tab.
Note: On the Current Transactions tab, after expanding each node in the tree, the
transaction is displayed as shown in Figure 37.
Similar to transactions using OPC item variables, a tag must be chosen for this transaction. Click on
the red Tag button to browse the available servers, and select a tag from one of these servers.
This chooses the tag that is to receive database column information. The above example may
return more than one value to be written to the selected OPC item. Depending on the options
selected, the client will either write only the latest value returned, or each of the values returned.
General Preferences
The Preferences window is used to configure basic client behaviour, logging and performance
settings. This window is accessed by choosing the Options menu item from the View menu. This
window consists of three tabs:
General
Logging
Advanced
Command Description
Selecting this option specifies that the ODBC client should save its current
configuration whenever the client is shutdown. This option refers to the
Save current shutdown of the entire client, not just the configuration GUI. The
configuration on configuration is saved to the file name displayed in the textbox shown in
shutdown Figure 39.
Note: This option is only applied after the ODBC client restarts.
Load this Selecting this checkbox enables the text field and Browse button below the
configuration on checkbox, allowing you to select and load the ODBC configuration file when
startup the client starts up.
Click on this button to display the Open window to select an existing file
Browse name. For this button to be enabled, the Load this configuration on
startup checkbox must be selected.
Logging Tab
The Logging tab (Figure 40) allows you to customize error and debug information. The tab
components are described in Table 22.
Command Description
Minimum log file size This option cannot be changed. 500 KB is the minimum default log file size.
Maximum log file size Sets the maximum log file size before logs will wrap.
Sets the general logging activity logging at the specified detail level (High,
Log Level
Medium, Low, or None).
Log File Name Displays the full path for the general activity log file.
Click on the Browse button to display the Open window used to select an
Browse
existing file name.
Commit all log file Purges the file buffer after each message is logged in the event of an
writes unexpected server shut down.
Overwrite old log Overwrites the old log file each time the server starts up, if selected.
information Otherwise, rename the old log file with a (*.bak) suffix.
Selecting this button commits any changes made in the Preferences
OK
window and closes the window.
Advanced Tab
The Advanced tab (Figure 41) is used to define the request queue settings. The tab components
are described in Table 23.
Command Description
Allows you to specify the maximum number of ODBC Client transactions
Maximum Requests
that can be queued. Setting this value to 0 means that there is no
Queued
maximum value for the queue size.
Saving a Configuration
Note: When the client configuration is complete, use the Save Configuration window to save the
configuration to an XML file.
To save a configuration to an XML file:
1. From the File menu, select the Save As menu option.
2. The Save Configuration window appears.
3. Enter a file name if saving the file for the first time.
4. Click Save.
5. The configuration is saved.
Clearing a Configuration
Note: Starting a new configuration will clear the existing one.
To clear a configuration:
1. From the File menu, choose the New menu option.
2. You will be prompted as to whether or not you want to save the configuration, select Yes to
save the configuration, No to clear without saving, and Cancel to retain the current
configuration.
3. If you have not selected Cancel, the configuration is cleared.
Note: The shutdown command is not available for the server if it runs
as a Windows service. Services can be shut down only from the
Service Control Manager applet in the Windows Control Panel.
Logging
All MatrikonOPC servers produce log files that record errors and debugging information. The log
files can be extremely valuable for troubleshooting. As such, it is important to note that the default
log level is set to low. The General Logging tab of the Options dialogue in the main configuration
window contains settings to control server logging.
General Activity Logging records information about the internal workings of the OPC server. It is
useful for troubleshooting problems with configuration and device communication. Interface
Activity Logging records information about the client/server OPC communication. It is useful for
troubleshooting compliance issues.
For General logging, the higher the log level, the more information that is recorded. However,
server performance may decrease at higher log levels. The recommended operating level is
Medium. More log levels are available for both types of logging which record more detailed
information, as well as the ability to output log statements to a console window at run time.
Contact MatrikonOPC support for further instructions on how to enable the higher log levels and
console logging.
For Interface logging, the log level can be considered very high and therefore should never be used
during normal operation of the OPC server unless specifically working on problems related to
interfacing.
MatrikonOPC Sniffer is a useful tool for logging OPC client/server communication. It enhances
the Interface Activity Logging by recording the client-side transactions. It can also be used with
other OPC servers. MatrikonOPC Sniffer is a utility used to troubleshoot OPC client/server
interoperability issues. Contact the MatrikonOPC Sales department for further information about
this product, or use the following link to access the Matrikon Sniffer Download.
In general, the server logs all errors and other information of immediate importance to the user at
the low detail level, all warnings and other information of moderate importance to the user at a
medium detail level, and additional information concerning the normal functioning of the software
at a high detail level. The server also logs further information of concern to support personnel at
the debug log level.
Note: The higher the log level, the slower the performance of the
server. It is recommended that the log level be left at the default,
unless troubleshooting needs to be performed.
Refer to the MatrikonOPC Client for ODBC Release Notes for known issues.
Problem: The client cannot be configured because there is no Matrikon logo in the Tool
Tray.
Solution: If the client is running as a service, the Matrikon logo does not appear in the Tool
Tray.
To configure the client, start the configuration utility by using the shortcut to the OPC
server in the Windows Start menu (this shortcut starts the Configuration utility as
well as the OPC Server).
Registered ODBC data sources not visible from the configuration GUI
Problem: When connecting to a database, a registered ODBC data source does not appear in the
dropdown list.
Solution: ODBC data sources must be registered as either a system, file or user DSN. If the
data source is registered as a user DSN, it may be necessary to execute the client as
that user. If the client runs as a service, make sure the service is set to execute as
the appropriate user.
Problem: The client does not retain its previous settings and needs to be reconfigured each time
it starts up.
Solution: In the Configuration window, choose Options from the View menu. Under the
General tab, ensure that the Load this configuration on start-up checkbox is
selected and that the correct file name appears in the edit box.
Problem: The OPC client cannot save the configuration in XML format.
Solution: Microsoft Internet Explorer 4.01 (or later) must be installed to use the .XML format.
Problem: The OPC server I wish to connect to, does not show up in a list of remotely available
program IDs in the client application.
Solution: Follow the steps found in Appendix A – Distributed COM (DCOM) to copy the
Access denied or time-out error when connecting to remove server via DCOM
Problem: Access Denied error message appears, or time out occurs when trying to connect to
a remote OPC server via DCOM.
Ensure that the access and launch permissions for the OPC server are set correctly on
Solution:
the server machine. For more information, refer to Appendix A – Distributed COM
(DCOM).
Problem: The client tries to connect to the server and fails, or the server does not start up.
Solution: Ensure that the access and launch permissions for the OPC server are set correctly.
For more information, refer to Appendix A – Distributed COM (DCOM).
Problem: The About screen and Configuration window do not show up when a remotely
connecting client or a client that runs as a service (such as the Aspen Technologies
CIMIO OPC Manager) tries to launch the OPC server.
Solution: Either set the identity for the OPC server to the interactive user, or consider running
the server as a service. For more information, refer to Appendix A – Distributed
COM (DCOM).
Problem: After installing an older OPC server, DA 2.05 asynchronous I/O no longer works.
Solution: The old installation program installed and registered its own (older) version of the OPC
proxy/stub DLL.
Reinstall the standard OPC proxy/stub DLLs, using an up-to-date installation program
or re-register them using the REGSVR32 command-line utility.
Problem: How can I get OPC data into Microsoft Excel, Microsoft Word, or another application
with support for Visual Basic, VBA, or VB Script?
Solution: Use the MatrikonOPC Automation Component to create a Visual Basic script that
connects to a server, creates groups and items, and receives data change updates.
Contact Support for examples of how to do this in Excel, Visual Basic, or an HTML
document.
Search the MatrikonOPC Support Knowledge Base at www.opcsupport.com to find the answers
to other commonly-asked MatrikonOPC Client for ODBC questions.
5. Click on the Change/Remove button associated with the MatrikonOPC Client for ODBC
program to initiate the un-install process.
6. The Select Uninstall Method window appears (Figure 43).
7. From the Select Uninstall Method window, select the required option button.
Note: MatrikonOPC recommends the Automatic option method of un-installing.
8. Click on the Next button.
9. The Perform Uninstall window (Figure 44) is displayed.
12. The Remove Files? window asks whether to remove all log and configuration files. To keep
all log and configuration files, clear the Remove all log files and Remove all
configuration files checkboxes. By default, both checkboxes are selected, indicating that
all log and configuration files are to be removed.
13. Click on the Next button.
14. The Remove Files? window closes and you are returned to the Perform Uninstall window
and the un-install process continues.
15. When the un-install is complete the Perform Uninstall window closes and the program no
longer appears listed in the Add or Remove Programs window.
Notes:
The following steps are suggestions only. Ask your Windows
Network Administrator for more information about the settings
that you should use, especially between different domains.
The steps provided in this appendix apply to Windows NT
operating systems only. For information on how to configure
DCOM settings for newer Windows operating systems, please
refer to the MatrikonOPC Online Support page on DCOM
Settings.
Note: DCOM settings are stored in the registry and loaded by COM
(and OPC) servers at start-up. Therefore, server processes must be
shut down and re-started for these changes to take effect.
Default Properties
The Default Properties tab contains settings that affect all DCOM communication on the machine.
First of all, ensure that the Enable Distributed COM on this computer is selected in
so that the machine is available to others via DCOM.
Select the Enable COM Internet Services on this computer to allow DCOM access to
the machine from the Internet (check with your administrator).
In general, the other settings do not need to be changed.
The Authentication Level specifies when COM should authenticate the identity of calling clients
(each call, each packet, etc).
Normally, it should be set to Connect, indicating that COM should authenticate clients
when they first connect to a server. If it is set to None, then COM performs no
authentication and ignores any access permission settings.
Security Permissions
The most important DCOM settings for an OPC server are the security permissions. There are two
ways for you to set these:
1. Change the specific settings for the server (recommended).
2. Change the default settings (not recommended) and make sure that the OPC server will use
these.
Either way, be certain that the access and launch permissions are correct for the server.
4. Click on the Security tab to set the security for the server.
5. The Distributed COM Configuration Security tab (Figure 47) appears.
Notes:
The Access Permissions contain an Access Control List of principals that are
allowed to interact with objects supplied by a server.
The Launch Permissions contain an Access Control List of principals that are
allowed to start up a server process or service.
6. Include the names of users or user groups from trusted domains that you wish to be able to
use the OPC server on this machine. Include the Everyone group to allow access to all
users on a particular domain.
7. To set the Access permissions, click Use custom access permissions and then click Edit.
8. The Registry Value Permissions window (Figure 48) appears.
11. To add a user to the list, select the user, and then click Add. If the user you wish to add
does not appear then click Show Users.
Server Identity
The Identity tab for a selected COM (or OPC) server specifies the user account that should be
used when COM starts up the process. The available settings are different for servers that run as
local executables as opposed to those that run as NT services.
Servers that run as local executables have the option of running as the launching user (the calling
client–this is the default), the interactive user (the one currently logged onto the machine), or a
specified user. It is usually best to use the interactive user or a specified user. Otherwise, remote
clients might start up multiple separate server processes that are not accessible to others.
Servers that run as NT services should generally run as the local System account. Alternatively,
the server can be set to run as a specified user, although this is usually done from the Service
Control Manager applet rather than DCOMCNFG. Access and Launch permissions are particularly
important when installing a server to run as an NT service.
Default Protocols
The Default Protocols tab specifies the communication protocols available to DCOM. The order
that protocols appear in the list indicates the priority in which they will be used (the topmost
having the highest priority).
The more protocols that appear in the list, the better the chances of connecting to an OPC server
on an unknown remote machine (such as at an OPC Interoperability Workshop). However, it may
also take longer for DCOM to time out if a server machine is not present since it has to try each
protocol in turn.
For most situations, it is best to remove all unused protocols from the list and only include those
that are necessary for your network. For example, on a TCP/IP network, one would include the
Connection-oriented TCP/IP protocol. Contact your IT personnel for more information about
your network.
Remote Program ID
Before the OPC Server Browser became available, OPC client applications had to search the
registry to generate a list of available OPC servers. Therefore, some older OPC clients need to have
a program ID in the local registry in order to connect to a particular OPC server.
The simplest solution is to install the OPC server software on the client machine even if it is not
used. Alternatively, use the following steps to copy a program ID to the client machine.
Note: This method may not work for every OPC client. Please check the client documentation for
more information.
9. Now you need to configure the name of the DSN. Enter TestDatabase in the Data Source
Name field. Note: This name can be anything you would like, however, the configuration
file that is included with this installation assumes that you will name the DSN as
TestDatabase.
10. Click on the Select button.
11. The Select Database window (Figure 54) appears.
12. Browse to the OPC server installation directory path and select the SampleDB.mdb file.
13. Click on the OK button to close the Select Database window and return to the ODBC
Microsoft Access Setup window.
14. From the ODBC Microsoft Access Setup window, click on the OK button to finish your
DSN configuration.
15. TestDatabase should now appear in the list of system DSNs (Figure 55) that you see in
the ODBC Data Source Administrator window.
Note: If you have moved your database location, you need to update your DSN information.
Otherwise 11616 will occur. Please refer to the Release Notes to read about the bug.