Download as pdf or txt
Download as pdf or txt
You are on page 1of 50

Aspen Cim-IO for OPC DA

User’s Guide
Version: V12.2
Copyright (c) 2021 by Aspen Technology, Inc. All rights reserved.

Aspen InfoPlus.21, Aspen Process Explorer, Cim-IO, the aspen leaf logo, Plantelligence and Enterprise Optimization
are trademarks or registered trademarks of Aspen Technology, Inc., Bedford, MA.

All other brand and product names are trademarks or registered trademarks of their respective companies.

This document is intended as a guide to using AspenTech's software. This documentation contains AspenTech
proprietary and confidential information and may not be disclosed, used, or copied without the prior consent of
AspenTech or as set forth in the applicable license agreement. Users are solely responsible for the proper use of
the software and the application of the results obtained.

Although AspenTech has tested the software and reviewed the documentation, the sole warranty for the software
may be found in the applicable license agreement between AspenTech and the user. ASPENTECH MAKES NO
WARRANTY OR REPRESENTATION, EITHER EXPRESSED OR IMPLIED, WITH RESPECT TO THIS DOCUMENTATION,
ITS QUALITY, PERFORMANCE, MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.

Aspen Technology, Inc.


20 Crosby Drive
Bedford, MA 01730
USA
Phone: +(781) 221-6400
Toll Free: (1) (888) 996-7100
http://www.aspentech.com
Contents
1 Introduction .........................................................................................................1
Content and Audience ....................................................................................... 1
Related Documentation ..................................................................................... 1
Technical Support ............................................................................................ 1

2 Release Notes ......................................................................................................3


Changes and Fixes ........................................................................................... 3

3 General Overview .................................................................................................9


Data Types .................................................................................................... 10
Cim-IO Standard Data Types ................................................................. 10
Cim-IO Structure Data Types ................................................................. 10
Device Data Types ............................................................................... 10
Smart Data Types ................................................................................ 10
Tag Name Addressing ..................................................................................... 11
Unit Number .................................................................................................. 11
Frequency ..................................................................................................... 11

4 Software Installation .........................................................................................13


Before Installing the Interface ............................................................... 13

5 Interface Configuration and Startup...................................................................15


Adding a Cim-IO for OPC Interface ................................................................... 15
Watchdog Tag Monitoring ...................................................................... 19
OPC DA Properties .......................................................................................... 20
Connection Settings.............................................................................. 21
The Timeout Window ............................................................................ 22
General Settings .................................................................................. 22
The OPC Sub-Window ........................................................................... 23
The Smart Data Types Window .............................................................. 23
Specifying Redundant OPC Server Nodes Using the Command Line ...................... 25
Starting and Stopping Cim-IO for OPC DA Interface Servers Individually ............... 25

6 Configuring the Cim-IO Client for InfoPlus.21 ....................................................27


Creating and Using Get, Put, and Unsol Records with Cim-IO for OPC DA .............. 27
Cim-IO OPC as an OPC Client........................................................................... 32
Transfer Records vs. Groups .................................................................. 32
Cim-IO OPC Get and Put I/O .................................................................. 32
Cim-IO OPC Unsolicited I/O ................................................................... 33
Reading and Writing OPC Array Data ...................................................... 33

Contents iii
7 Features for DA 3.0 Servers ...............................................................................37
Introduction .................................................................................................. 37
Deadbanding ................................................................................................. 37
DA 3.0 Data Access ........................................................................................ 38

8 Troubleshooting .................................................................................................39
Troubleshooting ............................................................................................. 39
Connectivity Issues .............................................................................. 39
DCOM UDP on Windows ........................................................................ 39
Isolating a Fault to the Device Level ....................................................... 40
Isolating a Fault to the OPC Server Level ................................................ 41
Isolating a Fault to the Cim-IO Components ............................................ 41
Isolating a Fault to the Client Level......................................................... 42
Failover and Redundancy ................................................................................ 42
Frequently Asked Questions............................................................................. 42
Error Codes ................................................................................................... 43

9 Glossary .............................................................................................................45
Client.................................................................................................. 45
DIOP .................................................................................................. 45
DLGP .................................................................................................. 45
Logical Device ...................................................................................... 45
Logical Device Name............................................................................. 45
OPC .................................................................................................... 45
OPC Group .......................................................................................... 45
OPC Cache .......................................................................................... 46
OPC Device ......................................................................................... 46
OPC Update Rate ................................................................................. 46
Service ............................................................................................... 46
Service Name ...................................................................................... 46

iv Contents
1 Introduction

Content and Audience


This document describes the installation, configuration, and use of the Aspen
Cim-IO™ to OPC Interface. Any aspect of this interface is subject to
refinement and reorganization by AspenTech as is deemed necessary. A basic
knowledge of Cim-IO is assumed (we recommend you read the Aspen Cim-IO
User’s Guide prior to reading this manual).
The manual is divided into several parts:
Introduction – provides a general overview of the interface.
Software Installation – describes the interface software installation.
Software Configuration and Startup – describes how to configure the
interface and how to start and stop it.
Error Codes – describes the various errors that occur.

Related Documentation
The following publications contain additional information that may be needed
to fully understand the Cim-IO for OPC DA Interface:
 Aspen Cim-IO User’s Guide, AspenTech
 OPC Data Access Specification versions 1.0a, 2.0, and 3.0
OPC Foundation

Technical Support
AspenTech customers with a valid license and software maintenance
agreement can register to access the online AspenTech Support Center at:
https://support.aspentech.com
This Web support site allows you to:
 Access current product documentation
 Search for tech tips, solutions and frequently asked questions (FAQs)
 Search for and download application examples

1 Introduction 1
 Search for and download service packs and product updates
 Submit and track technical issues
 Send suggestions
 Report product defects
 Review lists of known deficiencies and defects
Registered users can also subscribe to our Technical Support e-Bulletins.
These e-Bulletins are used to alert users to important technical support
information such as:
 Technical advisories
 Product updates and releases
Customer support is also available by phone, fax, and email. The most up-to-
date contact information is available at the AspenTech Support Center at
https://support.aspentech.com.

2 1 Introduction
2 Release Notes

This chapter describes known limitations and problems in the interface, recent
changes or fixes in the interface, and configuration and installation
comments.

Note: Beginning with aspenONE V8.0, known issues are recorded in the
Aspen InfoPlus.21 Product Family Release Notes.

Changes and Fixes


Changes, fixes, and known issues in Cim-IO for OPC DA version 11.1.0
ID Description

CQ00296528 OPC Properties - Delayed OPC Servers


CQ00311813 ATIMUS V7.9 Minimum Refresh Time for CIMIO for
Enhancement OPC Unsolicited Scanning.
A new option in OPCProperties now specifies the Force
Update number of secods of the minimum refresh
rate.

Changes, fixes, and known issues in Cim-IO for OPC DA version 3.0.1
ID Description

170582 Reading/Writing an Array of Strings does not work.


Known Issue
179390 Unexplained data conversion error message in log
CQ00181824 Misleading AsyncIO2 read results log line
CQ00187612 Remove AsyncDLGP automatic logical device and
service creation
CQ00192173 Make writing a UNC timestamp configurable
CQ00194465 Do not use default progid to connect to
Known Issue
CQ00195355 “Class not found” error when creation and start-up is
done using Cim-IO snap-in
CQ00199385 Cim-IO OPC does not always send an initial update out
Known Issue on a DECLARE if using failover.

2 Release Notes 3
ID Description

CQ00199648 Nodename not validated by manager.exe; a


Known Issue nodename of 1 or more blanks result in Class Not
Registered errors.
CQ00199650 Browsing issues in FindRemote, DisplayTags, and
Known Issue OPCProperties.

Changes, fixes, and known issues in Cim-IO for OPC DA version 3.0.0
ID Description

137347 Add DA 3.0.0 features to Cim-IO for OPC DA.


Enhancement Upgraded features, upgrade to DisplayTags.
162008 “Class Not Registered” errors when attempting to
connect to a remote pre-DA 2.0 OPC server.
167019 String handling incorrect in Write section, causing data
“shifting” when writing strings.
170582 Reading/Writing an Array of Strings does not work.
Known Issue
170804 Add a DA3 compatible version (browse only) of
OPCAutomation for use with OPC Properties.
170858 Time data not written correctly to OPC server.
175301 Delimiter for EU, etc. is now variable. First character in
string determines what the delimiter is. For example,
if the user types in #EngUnit as the engineering units
string, the program will search the tagname for the
"#" character and replace everything after it with
"EngUnit".

Changes and fixes made to Cim-IO for OPC DA version 2.53


ID Description

159517 The StartStop Program does not run on XP


61401 The StartStop program does not have an option for
AlternateNodeName
164257 CIMIO OPC does not return correct # of items in
CIMIO Unsol reply, causing crashes
164594 Cache on OPC server getting corrupted. Data in IP.21
is incorrect (skewed after bad tags not receiving data).
166721 DisplayTags does not start properly.
166738 CIMIO OPC Installservice.exe doesn't run properly.

Changes and fixes made to Cim-IO for OPC DA version 2.52


ID Description

152912 OPC Server takes a very long time to Initialize all the
Enhancement points, during which time none of the points are
transmitting values.
An option has now been added to OPCProperties that

4 2 Release Notes
will allow the user to specify the initial read from the
CACHE of the OPC server, rather than a DEVICE read.

Changes and fixes made to Cim-IO for OPC DA version 2.51:


ID Description

130933 AsyncDLGP crashes when no CIMIO_INTID structure is


sent
132661 Findremote.exe has an incorrect version.
137346 If ignore no valid items is set to true, the Cim-IO client
never gets a response on write operations that do not
contain any valid tags
141006 Re-declaring a list from CIMIO_T_API crashes CIMIO
OPC
141007 AsyncDLGP does not handle shutdown properly with no
alternate nodename
141591 AsyncDLGP will crash when the opc server it is
connected to crashes.

Changes and fixes made to Cim-IO for OPC DA version 2.50:


ID Description

135228 Support for redundant OPC Servers. The Cim-IO for


Enhancement OPC AsyncDLGP process now tries to connect to
another OPC server with the same name but residing
on an alternate node in case the connection to the
primary node fails.

Changes and fixes made to Cim-IO for OPC DA version 2.41:


ID Description

136571 Problems connecting to Emerson DeltaV on reboot.


Enhancement CIMIO must be restarted after DeltaV service is running
in order to connect.

Changes and fixes made to Cim-IO for OPC DA version 2.40:


ID Description

110993 Cim-IO for OPC Interface Manager launches multiple


instances of Asyncdlgp.exe for a single OPC server
116646 UNSOL records don’t work with Devicedeadband
123263 CIMIO OPC crashes if started with incorrect service
name
127932 Making changes to unsolicited transfer records results
in "scan off" status for individual points

2 Release Notes 5
Changes and fixes made to Cim-IO for OPC DA version 2.35:
ID Description

91146 Puts seem to be successful, but data doesn’t show up


on DCS
95596 Error message: CIMIO_OPC_NOVALIDITEMS, No Valid
Items in the List, all the tags in the list are invalid.
96316 CIMIO always returns data with a status of suspect on
the demand requests.
97504 AsyncDLGP crashes when reconnecting to CIMIO Server

Changes and fixes made to Cim-IO for OPC DA version 2.01:


ID Description

132337 The Cim-IO for OPC interface can be started using NET
START.
132818 Fixed the problem where the interface was not using
the service name specified in the servicenames.txt file.

Changes and fixes made to Cim-IO for OPC DA version 2.0:


ID Description

Enhancement This version of Cim-IO for OPC works with OPC servers
complying to version 1.0A or 2.0 of the OPC
specification.
Enhancement Support for the “description” and “engineering units”
smart data types were added.
131754 If the OPC server is not up when the Cim-IO for OPC
131441 interface manager starts up, the interface retries a few
times before the Cim-IO for OPC interface program
(asyncdlgp.exe) exits. A message saying that the OPC
server is not installed is logged to the
CIMIO_MSG.LOG file.
131381 The StartStop Utility will return to the dialog box
instead of exiting after an error occurs.
131380 The StartStop Utility input strings of "TCP Service
Name" and “Node Name” are now limited to 32
characters, and the "OPC Service Name" input string is
unlimited.
131378 When the StartStop Utility is launched, the “OK”
button is no longer active until data has been entered
into the input areas.
131377 The Start menu was referred to as "StartStop Utility"
and on the application dialog box, it was referred to as
"StartAndStop". This has been changed to be
consistent.
131376 When the user is in the "StartStop Utility" the Start
and Stop buttons are now accessible using the TAB
key.

6 2 Release Notes
Changes and fixes made to Cim-IO for OPC DA version 1.4:
ID Description

README.TXT is not distributed anymore


131090 If a boolean is read and its value is true, the value 1 is
Enhancement returned.
131089 Under certain circumstances, the AsyncDlgp program
kept running after the Cim-IO for OPC Manager was
stopped.

Changes and fixes made to Cim-IO for OPC DA version 1.3:


ID Description

130808 If the Cim-IO client did not exit gracefully, OPC groups
were not properly released by the Cim-IO for OPC interface.
130809 After rebooting the system, the Cim-IO for OPC interface
service started before the OPC servers required for the
proper operation of the AsyncDLGP programs.
130811 When demand reads were made, the status of each point in
a Cim-IO list was set to the status of the first point in the
list.
130812 IO operation from/to OPC DEVICE (as opposed to OPC
CACHE) took at least one second.
129934 In certain circumstances, the program AsyncDlgp.exe
crashed when getting ASCII string data.
130813 Store and Forward could not be used if the service name
generated from OPC server name was longer than 15
characters.
NOTE: The solution to this problem required the generated
service name to be truncated to 15 characters.
Example: The Cim-IO service name for an OPC server name
called OPC.NAMELONGERTHAN15CHARS.1 will not be
CIOOPCNAMELONGE instead of
CIOOPCNAMELONGERTHAN15CHARS1
If for any reason the service name generated by the
interface is not acceptable, the user can specify what the
service name should be by adding a line to the file
ServiceNames.txt located where the interface was installed.
130814 When browsing the address space for some servers, the
DisplayTags Utility sometimes would crash.

Changes and fixes made to Cim-IO for OPC DA version 1.2:


ID Description

130815 In certain circumstances, the StartStop utility did not work.


130816 When the interface server shutdown, the OPC server was
not released properly.

2 Release Notes 7
Changes and fixes made to Cim-IO for OPC DA version 1.1:
ID Description

122510 Deadband was interpreted as absolute instead of percent.


129862 In certain circumstances, the interface could not access
tags when a frequency of 0 was specified or when
unsolicited mode was specified.
122510 With some OPC servers, a request to access a tag name
was rejected if the data type specified was not the same as
the data type of the tag in the device.
122510 Even if a Cim-IO service was mentioned in the file
excludedServices.txt, the manager still started the DLGP for
the OPC server associated to the Cim-IO service.
123532 The interface could not connect to OPC server with spaces
in their name.

8 2 Release Notes
3 General Overview

OLE for Process Control (OPC™) provides a common method for applications
to access data from any data source (such as a device or a database) without
having to know about the specificity of the device or the database.
Applications communicate with OPC servers in a standard way, independent
from the data source.
The Cim-IO for OPC DA Interface is used to transfer data between OPC
servers and Cim-IO Client programs, such as InfoPlus.21™, DMCplus™, user-
written Cim-IO Client programs, and so on.
The Cim-IO for OPC DA Interface consists of a Manager program, which starts
and stops the Cim-IO for OPC DA Servers. Cim-IO for OPC DA Servers are
processes that communicate with OPC Servers. One Cim-IO for OPC DA
Server exists for each OPC Server installed on the system.
Cim-IO for OPC DA Servers receive Cim-IO requests from Cim-IO clients
(GET, PUT, UNSOLICITED GET) and send replies to these clients.

Cim-IO Client

Cim-IO for OPC Cim-IO for OPC Cim-IO for OPC


Server A Server B Server C

OPC OPC OPC


Server A Server B Server C

The figure above illustrates a possible configuration. Modules on each side of


the lines in bold can reside on the same or different computers.

3 General Overview 9
Data Types
These data types are associated with the Cim-IO for OPC DA interface:
 Cim-IO-specific
 Device-specific
 Smart data types

Cim-IO Standard Data Types


The interface converts acquired data into a Cim-IO standard data type format
compatible with the client request. A Cim-IO standard data type is defined for
each tag or piece of data. The interface supports the following interface data
types:
 Single-precision floating point (REAL)
 Double-precision floating point (DOUBLE)
 16-bit integer (SHORT)
 32-bit integer (LONG)
 ASCII text string (ASCII)

Cim-IO Structure Data Types


Reading from and writing to OPC “ARRAY OF” points using IP.21 custom
record definitions is possible. See “Reading and Writing OPC Array Data.”
When the interface is used with an InfoPlus.21, InfoPlus-X, or Setcim client,
the Cim-IO data type is not directly defined in the data retrieval record
(defined by IoGetDef, IoGetHistDef, IoPutDef, or IoUnsolDef).
When the interface is used with another client, the Cim-IO data type must be
identified or defined in your data request structures, as described in the
documentation for your client.

Device Data Types


The only device data type used by this interface is the smart data type of
Control Block Anti-Windup status (CBAW). The other device data types are
NOT used by this interface.

Smart Data Types


The interface supports the following smart data types:
 Control Block AntiWindup (CBAW)
 Description (DESC)
 Engineering Unit Description (EUDESC)
The interface does NOT support the following smart data type:
 Control Block Status (CBST)

10 3 General Overview
Control Block Anti-Windup
The CIMIO for OPC server supports the CONTROL BLOCK ANTI-WINDUP
(CBAW) status but not all OPC servers will. If the OPC server supports the
limit bit field described in the OPC specification then the CBAW can be used to
read it.

Description & Engineering Units


The Cim-IO for OPC DA interface supports the smart data types of
DESCRIPTION and ENGINEERING UNITS. To use these smart data types, first
modify the extensions.txt file located where the interface was installed. This
file is used by the interface to determine if an attribute should be appended to
the tag name. Format of the file is:
OPC Server Name Description attribute EU attribute

Example: The extensions.txt file has the contents:


OPC.SERVER.1 .DESC .EU
If the client requested a tag FC1001 from the OPC server OPC.SERVER.1 with
a smart data type of DESCRIPTION, the interface would pass the tag name
FC1001.DESC to the OPC server.
If one of the attributes is not supported, enter N/A for the value of the
attribute.

Tag Name Addressing


The tag name syntax is dependent on the OPC server that is communicating
to the Cim-IO for OPC DA interface. Refer to the vendor’s OPC server
documentation for tag name syntax.

Unit Number
The interface does not use a device unit number specification.

Frequency
The interface does use a frequency specification. For GET requests, a
frequency of 0 specifies a single asynchronous device read. A frequency
greater than 0 specifies an OPC cache read, with the device updating at the
specified frequency. For performance reasons, it is recommended that you
use cache reads for most operations. For UNSOL requests, the frequency
specifies the rate at which the device is polled. 0 is an invalid frequency
for Unsolicited data transfer.

3 General Overview 11
12 3 General Overview
4 Software Installation

Beginning with aspenONE V7.1, Cim-IO server and Cim-IO for OPC DA
versions are matched. No restrictions so far are imposed on earlier versions.
As a general rule, the most recent version of Cim-IO or Cim-IO for OPC DA
should be compatible with at least two earlier versions. As a general practice,
earlier versions should be maintained at the latest patch revision level to
eliminate potential incompatibilities with subsequent, newer versions. In all
cases, the user must consult for compatibility restrictions on the AspenTech
Support web site.
For more information about Cim-IO client and server requirements, see the
Aspen Cim-IO User’s Guide.

Before Installing the Interface


Before you install the interface, make sure that you determine the username
and the password of the account that will be used to start the Cim-IO for OPC
DA interface. Also, the account needs to have administrative privileges.

Installing the Interface


For instructions to install the Cim-IO for OPC DA interface, see the Aspen
InfoPlus.21 Product Family Installation Guide.

4 Software Installation 13
14 4 Software Installation
5 Interface Configuration and
Startup

Adding a Cim-IO for OPC


Interface
The Cim-IO Interface Manager has a wizard that simplifies adding Cim-IO for
OPC Interface instances. After launching Cim-IO Interface Manager, click Add
Cim-IO Interface in the right Actions pane or right click the Cim-IO
Interfaces heading on the right pane that shows a tree of instances created.

From the first wizard page, select Cim-IO for OPC from the list of supported
Cim-IO Interfaces and then click Next. The Give the interface a name and
description form displays.

5 Interface Configuration and Startup 15


Enter the desired name for the interface, its description and whether
credentials are required to connect to the target OPC Server.
Select the Start at boot check box. The interface should be started up
automatically when the system boots up or the Cim-IO Manager service is
restarted.
Select the Check health option, if the Cim-IO Manager service will monitor
the instance processes to restart them if they stopped.
Click Next tto display the Interface configuration form.

16 5 Interface Configuration and Startup


Enter the server computer name in the OPC DA server computer box, and
click the Discover button. Select the OPC DA server that will be associated
with the instance being defined. The selected server displays in the OPC DA
server box.
Click Next to display the Summary form that shows the steps that will be
performed by the wizard.

5 Interface Configuration and Startup 17


Click Next to continue. The Progress form displays.

Click Finish, which will automatically start the interface just defined and
bring the form showing all the interface’s processes and the configuration
form to define other properties.

From this form you can edit the Store and Forward fields, select a different
OPC server by clicking the Discover button, change the Start at boot and
Check health options.

18 5 Interface Configuration and Startup


You an also use the Actions in the right pane to stop, delete, define a
watchdog tag, apply changes made, refresh the screen to see whether the
status of a process has changed, and to obtain help describing the fields on
the form.

Watchdog Tag Monitoring


This feature allows you to choose a tag in the DCS that can be read and
written under the control of the instance. The monitoring of this tag will allow
a site to determine whether the connection to the OPC server has become
stale or unresponsive.

To enable, change, or view watchdog monitoring


configuration:
1 Select the interface in the left pane tree.
2 In the Actions pane, click Stop. If you are only viewing the configuration,
you can leave the interface running; you will not be able to change
settings, however.
3 In the same Actions pane, note the icon preceding Change\View
watchdog monitoring configuration. A yellow question mark indicates
that the watchdog monitoring option has not been configured yet.
4 Click Change\View watchdog monitoring configuration. The
Watchdog Configuration dialog appears.
5 To enable the watchdog configuration option, enter a valid Item name in
the box under the New values column as well as a Maximum time in
seconds without change. The Validate Item button is enabled

5 Interface Configuration and Startup 19


6 Click Validate Item to confirm whether the item name entered is valid or
not. Validation status indicates the result. Items can be validated when
the actual OPC DA server is up and running. Additionally, if the item name
is valid:
o Device data type will indicate the item data device (canonical)
type. Watchdog monitoring only supports items with floating point
values (real or double) or integer values. Any other data types will
invalidate the item name entered.
o The Accept Changes button is enabled.
7 Click Accept Changes to save your changes. The Watchdog
Configuration dialog box closes.
8 If the interface is started after its watchdog monitoring has been enabled,
the icon in the Actions pane indicates the monitored tag's status:
OK
Suspect
Frozen

The most current data displays as well:


o Last monitoring check time indicates the time the DLGP associated
with the interface checked whether the value, timestamp or status of
Item name has changed. If it hasn’t after 4 consecutive grace periods
of Max time, and alarm will be generated.
o Monitoring check status indicates whether the result from the
watchdog check activity in the DLGP associated determined that the
watchdog is OK, Frozen, or Suspect.
o Value, Value timestamp, and Tag device status are actual Item name
real-time values obtained from the DCS the last time the watchdog
check was executed.
o Current time is the local time in the system where Cim-IO Interface
Manager is running.

OPC DA Properties
The Cim-IO Interface Manager will allow you to configure how Cim-IO for OPC
DA behaves.

20 5 Interface Configuration and Startup


Connection Settings
Timeout and Retries: If a connection to the OPC server takes more than
Timeout seconds, a new connection will be attempted. This will continue until
the number specified by Retries has been exhausted. At this point, if a
redundant OPC server has been specified using the –alternatenodename
parameter, it will switch to this server and attempt a connection again using
the Retries and Timeout settings.
Delayed OPC Servers: If you want a delay between OPC server startup and
when the first OPC group is added, click Edit and then Add your OPC server
and timeout in the Timeout window.

5 Interface Configuration and Startup 21


The Timeout Window

To add a server, click Add and then enter the OPC server’s Program ID and
the delay you want into the appropriate boxes. Click OK to enter a server.
You will see that server appear in the OPC Servers box. To change or
remove a delay, select the OPC server and click the appropriate button. Click
Close to go back to the initial window.
Force Update (secs) This parameter specifies the number of seconds until a
changed is forced and reported by the Cim-IO for OPC DA server for
unsolicited values that not updated from the OPC server since the last time a
change was reported to Cim-IO clients. The forced update will report the
same value sent last time but with the current present time. If zero, values
are only updated when received from the OPC server. The default value is
3600 secs.

General Settings
Timezone: If you are reading or writing values of OPC type VT_DATE, you
may wish to specify your time zone so that the conversion to and from UCT is
performed appropriately. Simply select a time zone. The setting will default to
your computer’s current time zone. Note that time for Distributed Control
Systems is absolute as a timestamp identifies a particular absolute second of
time. It is not the result of a conversion to a time-of-day. If you wish to select
another, choose one from the pull-down menu.
Configure OPC Servers: If you want an OPC server to be automatically
available when the computer reboots, you use this feature to configure it to
do so. Click the Edit button to bring up the configuration window to select
OPC servers to connect to automatically. This brings up the OPC Manager
Configuration Window, below.

22 5 Interface Configuration and Startup


Adding Smart Data Types: If your OPC server supports smart data types,
you can add them by clicking on Configure Smart Data Types. This brings
up the Smart Data Types window, as seen in the section “The Smart Data
Types Window” below.

The OPC Sub-Window


The Ignore No Valid Items in List error check box, when selected, will
suppress the “No Valid Items” log message when there are no valid items in a
Cim-IO request.
Perform Initial Synchronous CACHE Read determines the first action Cim-
IO for OPC DA will perform to get data from a point. Generally, when an OPC
client connects, the data in the OPC cache is of bad quality. The actual data is
obtained by doing a DEVICE read (reading directly from the device). This
operation can take a significant amount of time, so you are offered the option
of selecting this check box to do a CACHE read instead of a DEVICE read as
the first read operation.
Perform Synchronous Writes determines whether writes will be done using
SyncIO (checked) or AsyncIO (unchecked).
Allow Output of Values with Bad Status? Determines whether values with
a Bad Status in the transfer record or list of values to be output should be
output. If the option is selected, values with a Bad Status are output,
otherwise the value will be skipped.
Allow Output of Values with a Suspect Status? Determines whether
values with a Bad Status in the transfer record or list of values to be output
should be output. If the option is selected, values with Suspect Status are
output, otherwise the value will be skipped.
SKIPPED BAD and SUSPECT values return a Bad Status? Determines
whether values that were skipped due to settings above should return a Bad
Status to the client. If the option is selected, values skipped due to a Bad or
Suspect Status will report a Bad Status back to the client, otherwise they will
be reported as Good.
Timestamp Origin determines how the Cim-IO timestamp will be obtained:
either from the OPC server (OPC Server Time), or from the Cim-IO for OPC
DA server computer’s time when an OPC message is received (System Time).

The Smart Data Types Window


The Configure Smart Data Types window allows you to add and remove
Smart Data Type associations. To add a server, click Add. To remove a
server, click Remove. If you click Add, the Adding a Smart Data Type
window appears below. When you are finished adding and removing
associations, click Close to close this window.

5 Interface Configuration and Startup 23


Enter your OPC Server’s progid, the Description and Engineering Units,
with the appropriate starting delimiter. All characters starting with this
delimiter and onward will be replaced by the string you have entered. For
example, server “Aspentech.OPC.Sample.1” might use “/ID” for its description
and “/UNITS” for its units. If the item “Boiler1.Valve25/PNT” was entered into
an IP.21 Get record, and the selected data type was “Engineering Units”, the
item ID would be modified to “Boiler1.Valve25/UNITS”, since all of the
characters starting with the delimiter “/” character would be replaced by the
Engineering Units string below. Note that if the delimiter exists in multiple
locations in the tag name, all characters starting with the last occurrence of
the delimiter will be replaced. Click OK to add the association, or click
Cancel.

24 5 Interface Configuration and Startup


Specifying Redundant OPC
Server Nodes Using the
Command Line

Cim-IO for OPC DA supports automatic fail-over functionality. When


configured, the interface will attempt to connect to a backup OPC server of
the same name, but residing on an alternate node, when the connection to
the primary server fails. The fail-over will occur if the primary OPC server
stops running or the communication link between the server and the client is
lost. The backup OPC server node may be specified at the command line or in
the configuration. See the –alternatenodename parameter in the section
“Running Cim-IO for OPC DA Using the Command Line or Batch Files” below.

Starting and Stopping Cim-IO


for OPC DA Interface Servers
Individually
When the Cim-IO Manager service starts, it starts all the Cim-IO for OPC
DA Servers that are configured to start automatically. When the manager
stops, it stops all the Cim-IO for OPC DA Servers that were running. If you
wish to start or stop one particular server, you will need to use the Cim-IO
Interface Manager utility listed, by clicking on the right pane for Actions,
which will show the proper Start/Stop actions depending on whether the
interface is stopped or started, respectively.

Note: In order for the utility to have any effect, the Cim-IO for OPC DA
Interface Manager must be running.

5 Interface Configuration and Startup 25


26 5 Interface Configuration and Startup
6 Configuring the Cim-IO
Client for InfoPlus.21

Creating and Using Get, Put,


and Unsol Records with Cim-IO
for OPC DA
Note: If you are not using InfoPlus.21, skip this chapter.
Assume that you want to read and write data from the OPC Server
OPC.SERVER.1. To have the InfoPlus.21 database communicate with this OPC
Server (in read/write and unsolicited mode), the following steps need to be
taken:
1 Create Cim-IO external task records:
Using the IoExternalTskDef definition record, create a Cim-IO external
task record named TSK_M_OPC1 for the main task. If asynchronous
request are to be made, create a Cim-IO external task record for the
asynchronous task: TSK_A_OPC1. If unsolicited data acquisition is to be
used, create a Cim-IO external task record for the unsolicited task:
TSK_U_OPC1. Set the field IO_DEVICE to CIOOPCSERVER1 (the same
name as the logical device name in the cimio_logical_devices.def file).
2 Create the logical device record.
Using the IoDeviceRecdef definition record, create a Cim-IO logical
device record named CIOOPCSERVER1 (the same name as the one
specified in the IO_DEVICE field of the external task record).The
IO_MAIN_TASK field must be set to the name of the task record for the
main task: TSK_M_OPC1. If asynchronous requests are made, set the field
IO_ASYNC? to YES and set the field IO_ASYNC_TASK to the name of the
task record for the asynchronous task: TSK_A_OPC1. If unsolicited data is
to be received, set the field IO_UNSOL? to YES and set the field
IO_UNSOL _TASK to the name of the task record for the unsolicited task:
TSK_U_OPC1. The other fields can be ignored.
3 Create GET records:
A standard Cim-IO GET record is used to retrieve data from the device
and store the values in the database. The layout of the GET record and

6 Configuring the Cim-IO Client for InfoPlus.21 27


details of the fields are provided in the Aspen Cim-IO User’s Guide. This
section emphasizes only those fields to which settings have to be made for
the Cim-IO for OPC DA Interface.
o Create a GET record using IoGetDef as the definition record.
o Fill in the fixed area of the Cim-IO GET record as described in the
following table:
Required GET Record Description
Field

IO_MAIN_TASK Set to the Cim-IO main client task:


TSK_M_OPC1 in this example.
IO_DEVICE_UNIT Not used by this interface.
IO_GROUP Optionally specify the group name
with which the set of points is
associated. Note: This field is NOT
related to the OPC group.
IO_PRIORITY Specify the priority (1-9, 1 highest)
that the client uses to send the
request to the interface when the
record is activated.
IO_DEFAULT_DATA_TYP Not used by the interface.
E
IO_TIMEOUT_VALUE Specify a positive timeout value, such
as 00:00:10 (for 10 seconds). If a
negative or null value is specified, the
client task waits forever for a reply
from the interface.
IO_FREQUENCY Frequency at which the OPC Server
should poll the data. If 0 is specified,
the data is read from the device,
otherwise it is read from the OPC
server cache.
IO_#TAGS Specify the number of points to read.
o Complete the information for each point to be read from the device.
Enter the fields in the GET record as described in the following table:
Required GET Record Description
Field

IO_TAGNAME Specify the device tagname to


access the data. The syntax for the
tagname depends on the device
accessed by the OPC Server. Refer
to the OPC server manual for the
tagname syntax.
IO_DATA_PROCESSING Specify if the indicated point is to
be processed. Possible values are:
OFF: Do not read the value of this
point from the device, but scan
other points whose
IO_DATA_PROCESSING field is ON.
ON: Read the value of this point
from the device.
IO_DATA_TYPE Not used by this interface.

28 6 Configuring the Cim-IO Client for InfoPlus.21


Required GET Record Description
Field

IO_VALUE_RECORD&FLD Specify the names of the data


record and field to store the value
of the point. The data record must
already exist.
4 Create PUT Records:
A standard Cim-IO PUT record is used to read data from the InfoPlus.21
database. The record specifies where to find the values in the database
and where to place (write) the values in the OPC device. The layout of the
PUT record and details of the fields are provided in the Aspen Cim-IO
User’s Guide. This section emphasizes only fields to which settings have to
be made for the Cim-IO for OPC DA Interface.
o Create a PUT record using IoPutDef as the definition record.
o Fill in the fixed area of the Cim-IO PUT record as described in the
following table:
Required PUT Record Description
Field

IO_MAIN_TASK Set to the Cim-IO main client task:


TSK_M_OPC1 in this example.
IO_DEVICE_UNIT Not used by this interface.
IO_GROUP Optionally specify the group name
with which the set of points is
associated. This field is NOT related
to the OPC group.
IO_PRIORITY Specify the priority (1-9, 1 highest)
that the client uses to send the
request to the interface when the
record is activated.
IO_DEFAULT_DATA_TYP Not used by this interface.
E
IO_TIMEOUT_VALUE Specify a positive timeout value, such
as 00:00:10 (for 10 seconds). If a
negative or null value is specified, the
client task waits forever for a reply
from the interface.
IO_#TAGS Specify the number of points to write.
o Complete the information for each point to be read from the device.
Enter the fields in the PUT record as described in the following table:
Required PUT Record Description
Field

IO_TAGNAME Specify the tagname on the device to


access the data. The syntax for the
tagname depends on the device
accessed by the OPC Server. Refer to
the OPC server manual for the
tagname syntax.
IO_DATA_PROCESSING Specify if the indicated point is to be
processed. Possible values are:

6 Configuring the Cim-IO Client for InfoPlus.21 29


Required PUT Record Description
Field

OFF: Do not write the value of the


point to the device, but write other
points whose IO_DATA_PROCESSING
field is ON.
ON: Write the value of this point to the
device.
IO_DATA_TYPE Not used by this interface.
IO_VALUE_RECORD&FL Specify the names of the data record
D and field to store the value of the
point. The data record must already
exist.
5 Create UNSOL READ records:
A standard Cim-IO Unsol Read record is used to read data in the
InfoPlus.21 database from the OPC Server in an unsolicited way. The
layout of the GET record and details of the fields are provided in the
Aspen Cim-IO User’s Guide. This section emphasizes only those fields to
which settings have to be made for the Cim-IO for OPC DA Interface.
o Create an UNSOL READ record using IoUnsolDef as the definition
record.
o Fill in the fixed area of the record as described in the following table:
Required UNSOL Description
READ Record Field

IO_MAIN_TASK Set to the Cim-IO main client task:


TSK_M_OPC1 in this example.
IO_DEVICE_UNIT Not used by this interface.
IO_GROUP Optionally specify the group name with
which the set of points is associated.
Note: This field is NOT related to the
OPC group.
IO_PRIORITY Specify the priority (1-9, 1 highest)
that the client uses to send the
request to the interface when the
record is activated.
IO_DEFAULT_DATA_TYP Not used by the interface.
E
IO_TIMEOUT_VALUE Specify a positive timeout value, such
as 00:00:10 (for 10 seconds). If a
negative or null value is specified, the
client task waits forever for a reply
from the interface.
IO_FREQUENCY Frequency at which the OPC Server
should poll the data. This value must
be greater than 0.
IO_#TAGS Specify the number of points to read.
o Complete the information for each point to be read from the device.
Enter the fields in the UNSOL READ record as described in the
following table:

30 6 Configuring the Cim-IO Client for InfoPlus.21


Required UNSOL READ Description
Record Field

IO_TAGNAME Specify the device tagname to access


the data. The syntax for the tagname
depends on the device accessed by
the OPC Server. Refer to the OPC
server manual for the tagname
syntax.
IO_DATA_PROCESSING Specify if the indicated point is to be
processed. Possible values are:
OFF: Do not read the value of this
point from the device, but scan other
points whose IO_DATA_PROCESSING
field is ON.
ON: Read the value of this point from
the device.
IO_DATA_TYPE Not used by this interface.
IO_VALUE_RECORD&FLD Specify the names of the data record
and field to store the value of the
point. The data record must already
exist.
IO_DEVICE_DEADBAND Point-by-point relative deadbanding
is only supported in OPC DA 3.0. If
you are connecting to an OPC DA 3.0
server, you may use relative
(percent) deadbanding, which will
be passed on to the OPC server. In
all other cases (including attempting
to pass an absolute deadband to a
DA 3.0 server), this field is ignored.
6 In the InfoPlus.21 Manager, configure the Cim-IO Client tasks associated
to the external task records previously created.
There should be at least one Cim-IO main client task per logical device
you want to communicate with (in our case, just one task, TSK_M_OPC1
for the logical device CIOOPCSERVER1).
Optionally, you may start an asynchronous task (TSK_A_OPC1) for
asynchronous communications and an unsolicited task (TSK_U_OPC1) to
receive unsolicited data. All Cim-IO Client tasks are specified like any
other InfoPlus.21 external tasks using the InfoPlus.21 Manager. In our
example, three Cim-IO Client tasks are to be created:
o TSK_M_OPC1 as the Cim-IO main client task
o TSK_A_OPC1 as the Cim-IO asynchronous receive task
o TSK_U_OPC1 as the Cim-IO unsolicited receive task
7 Start the InfoPlus.21 Manager.
8 To create the TSK_M_OPC1 task, enter the following in the NEW TASK
DEFINITION area:
o TSK_M_OPC1 in the task name field.
o cimio_c_client.exe in the executable field.
Make sure that the External Task check box is selected. Click the ADD
button to add the task to the Defined Tasks list.

6 Configuring the Cim-IO Client for InfoPlus.21 31


9 To create the TSK_A_OPC1 task, enter the following in the NEW TASK
DEFINITION area:
o TSK_A_OPC1 in the task name field.
o cimio_c_async.exe in the executable field.
Make sure that the External Task check box is selected. Click the ADD
button to add the task to the Defined Tasks list.
10 To create the TSK_U_OPC1 task, enter the following in the NEW TASK
DEFINITION area:
o TSK_U_OPC1 in the task name field.
o cimio_c_unsol.exe in the executable field.
Make sure that the External Task check box is selected. Click the ADD
button to add the task to the Defined Tasks list.
11 To start these Cim-IO Client tasks, select them one at a time in the
Defined Tasks window and click the RUN TASK button for each task.
This action will start all three tasks. After these tasks have been started,
they should appear in the Running Tasks window. If they do not appear,
there was a problem starting them. Check the output and the error files
for the task(s) that could not be started. Also check the Cim-IO log file
(CIMIO_MSG.LOG) for any error messages from Cim-IO.

Cim-IO OPC as an OPC Client


Transfer Records vs. Groups
Cim-IO OPC acts as a normal OPC client. It will connect to the OPC server and
establish one OPC group per I/O transfer record according to the following
table:

I/O Cim-IO Group OPC Group Rd/Wr


Transfer Xfer Rate Enabled Update From/To
Record Rate
Type
Io…GetDef 0 No 0 AsyncRead
OPC Device
Io…GetDef >0 Yes Same as SyncRead
Cim-IO OPC Cache
Io…UnsolDef =0 NOT ALLOWED
Io…UnsolDef >0 Yes Same as OPC
Cim-IO Callback
Io…PutDef N/A No 0 AsyncWrite
OPC Device

Cim-IO OPC Get and Put I/O


Get and Put records are handled by synchronous or asynchronous OPC reads
and writes, not by subscription. For Get records with an update rate of 0, and

32 6 Configuring the Cim-IO Client for InfoPlus.21


Put records, a disabled group with an update rate of 0 is created and all
transfers are done using OPC_DEVICE as the source. Since OPC_DEVICE
takes precedence over whether the group is active or not, these commands
should always succeed. If, however, an OPC server is not correctly written,
this action may fail. This would not be due to a Cim-IO for OPC DA or a
transfer record configuration issue, but due to the OPC server not conforming
to the OPC specification.

Cim-IO OPC Unsolicited I/O


Unsolicited I/O is implemented in Cim-IO for OPC DA by subscribing to group
callbacks on the created group. Because Cim-IO Unsolicited traffic occurs no
faster than the update rate, on a point-by-point basis, points will be sent no
faster than the update rate even if they change values once, or even multiple
times, in the meantime. If a point changes multiple times before an update
gets sent, only the last value is sent; any data spikes are lost.
OPC callbacks come no faster than the subscribed update rate on a group-by-
group basis. Even if a point has not changed in a time greater than the
update rate, it must still wait the update rate after the most recent
transmission before it can send its value. If a value changes multiple times in
the requested OPC update rate, only the last value is sent; any data spikes
are lost.
Cim-IO for OPC DA sends a group update rate equal to the Cim-IO record
update rate. By OPC specification, the OPC server should try to ensure that
data from the device is at least this fresh. Since an update rate of 0
(instantaneous) not possible (there is always some delay when accessing the
device), and can result in the OPC server using up nearly 100% of the CPU
time trying to scan the device every 0ms (and additional problems if the
server is not well written), a Cim-IO update rate of 0 is not supported. Note
also that according to the OPC specification, an OPC server can “override” an
OPC client’s update rate if it, or the device, cannot support polling at that fast
a rate. Thus, even if a value of, say, 500ms is sent as the requested group
update rate, the OPC server may reset this to, say, 1000ms when the group
is created.
For value that change very infrequently, Cim-IO for OPC DA forces an update
every time the “Force Update” number of seconds specified in the Cim-IO
Interface Manager.

Reading and Writing OPC Array Data


Array data is returned into a record as a structure data type. Structure data
types are available in versions 4.7 and higher of Cim-IO.
Each element of an array is returned to IP21 as individual fields. To read the
data, a custom record must be created with at least the number of value
fields to match the size of the array. The records must be of the same or
equivalent data type as their IP.21 counterparts (Analog=Real or
Discrete=Integer) and the IP.21 size (FIELD_LENGTH) of each data item, in
bytes, must match the size of the OPC item. The following array types are
supported:

6 Configuring the Cim-IO Client for InfoPlus.21 33


 Integer type arrays (VT_I1, VT_I2, VT_I4, VT_UI1,VT_UI2,VT_UI4).
 Real Arrays (VT_R4 and VT_R8)
The following array types are not supported:
 Error arrays (VT_ERROR)
 Timestamp arrays (VT_DATE)
 Currency arrays (VT_CY)
 String Arrays (VT_BSTR)
1. Create new records defined by FieldNameDef or FieldLongNameDef, one
for each data element in the array. For example; if the all array tags
contain ‘n’ elements or less, then create n value records with non
repeating id values (value_1….value_n).
The name for this record is arbitrary.
2. Create a new custom definition record from DefinitionDef. Use the
FieldName records created above as the element receiving fields. Below is
an example of a custom record that can be used to read an array of 10
elements.
DATA FIELDS

OPC Array Test IP_DESCRIPTION


opc_array_tag NAME
04-JUN-03 15:22:14.0 IP_INPUT_TIME
F10. 7 IP_VALUE_FORMAT
Initial IP_VALUE_QUALITY
1368.2087 value_1
10907.975 value_2
4931.8676 value_3
4704.1724 value_4
2340.1157 value_5
15861.237 value_6
5881.3616 value_7
3099.6090 value_8
7625.3897 value_9
7625.4912 value_10

3. Create an IOGetDef record to receive the data from the Cim-IO for OPC DA
client using the information at the start of this chapter. For
IO_DEFAULT_DATA_TYPE select “Structure” if all tags in the get record
are of array data types. Select “default” as the IO_DEFAULT_DATA_TYPE
when tags of different data types are used in the same get record.
In the repeat area choose “Structure” as the IO_DATA_TYPE for all array
tags.

34 6 Configuring the Cim-IO Client for InfoPlus.21


4. For IO_VALUE_RECORD&FLD enter the name of the custom record and the
name of the first value field in the record separated by a space.
In the above example the string used is: opc_array_tag value_1
The structure data type begins by placing the first array element values in the
starting location specified by the IO_VALUE_RECORD&FLD string and
subsequent values are placed in the remaining fields.
The number of value fields must match or exceed the elements in the array.
The data read will fail if there are more elements than available fields.

Note: For an example array definition file for IP.21, see SampleArrayDef.rld
located in %CIMIOROOT%\io\cio_opc_api
When IO_DATA_PROCESSING for all tags is set to ‘ON’ and
IO_RECORD_PROCESSING and IO_DEVICE_PROCESSING are ‘ON’ the value
data fields in the custom record will populate with array values.

6 Configuring the Cim-IO Client for InfoPlus.21 35


36 6 Configuring the Cim-IO Client for InfoPlus.21
7 Features for OPC DA 3.0
Servers

Introduction
Cim-IO for OPC DA 3.0.0 contains extra features for OPC servers that support
the OPC DA 3.0 specification. This chapter covers these new features and how
to access them using InfoPlus.21. Please note that these features are only
useful if the OPC DA server you are using is DA 3.0 compliant.

Deadbanding
InfoPlus.21 unsolicited records feature a point-by-point device deadband.
Because OPC DA 3.0 supports relative deadbanding, any percent deadband
will be passed on to the OPC server. Since OPC DA 3.0 does not support
absolute deadbands, an absolute deadband will not be passed on to the OPC
server.
Because our Cim-IO for OPC DA client supports both specification DA 2.0 and
3.0, the handling of deadbands acquires the following characteristics in order
to specify them for OPC compliant servers:
 For OPC servers that comply with the DA 2.0 specification, the group
deadband is specified in the field IO_DEVICE_DEADBAND of InfoPlus.21
CIM-IO group or transfer records for the first valid occurrence in the
group. The same deadband value will then be applied or will be in effect
for all the occurrences in the group. Technically speaking, the user only
needs to specify the deadband value of the first occurrence in the group.
However, AspenTech recommends that the same deadband value be
specified for all occurrences to avoid the situation in which any number of
leading occurrences become temporarily ‘invalid’ and therefore the first
valid deadband value will then prevail whether defined or not.
 For OPC servers that comply with the DA 3.0 specification, the individual
point deadband is specified in the field IO_DEVICE_DEADBAND of
InfoPlus.21 CIM-IO group or transfer records for each and every
occurrence in the group. Each occurrence, therefore, can have its own
deadband value.

7 Features for OPC DA 3.0 Servers 37


 DA 2.0 and DA 3.0 compliant servers receive both Cim-IO group and
individual deadbands. Aspen Cim-IO for OPC DA does not know or control
how the vendor’s OPC server applies them.
 Device deadband values defined in selector record Io-Dev-Deadbands,
field IO_DEV_DEADBAND_VALU must be entered as a percent value, not
as a percent value divided by 100, e.g.: 1.000 instead of 0.01 to express
a 1% deadband.

DA 3.0 Data Access


An OPC server’s DA 3.0 Data Access interface (IOPCSyncIO2 and
IOPCAsyncIO3) will be used if available. Using this interface does not support
any additional features over DA 2.0 at this time.

38 7 Features for OPC DA 3.0 Servers


8 Troubleshooting

This chapter then describes troubleshooting for specific problems and defines
the error messages that the interface processes.

Troubleshooting
Troubleshooting helps to isolate a problem with either the interface or its
client. When a problem occurs, such as a database point having an invalid
status or having an incorrect value, the investigation starts at the device level
and moves upward to the application. This section describes the general steps
used to determine which part of the interface is causing a problem.

Connectivity Issues
If Cim-IO OPC cannot connect to the OPC server, you are likely having issues
with Microsoft Distributed COM (DCOM) permissions or with application IDs.
Call AspenTech Support for assistance.

DCOM UDP on Windows


When running on a Windows operating system, the computer may be in a
configuration which does not enforce reliable DCOM communications between
two computers. To check this, click Start | Run and enter dcomcnfg

8 Troubleshooting 39
The DCOM configuration panel will appear. Select the Default Protocols tab
as shown below.

If the protocol “Connectionless UDP” appears at the top of the list, select it,
select Remove, select OK, and reboot your computer. This protocol is not
generally beneficial for good DCOM communications and was removed from
the default list in Windows 2000 and later operating systems.

Isolating a Fault to the Device Level


Use any device utilities that are available to determine if a point exists on the
device, and is available to be accessed. If a device utility shows the value of a
point to be incorrect or the status of the point to be bad, the problem resides
on the device level. This is not an interface problem.

40 8 Troubleshooting
Isolating a Fault to the OPC Server Level
Use an OPC client tool, such as Matrikon’s OPC Explorer, to create OPC groups
similar to what you are creating using Cim-IO for OPC DA, and observer the
OPC server’s behavior. If the server is not returning the data correctly or is
not behaving properly, the problem resides with the OPC server. Further
information on what both Cim-IO for OPC DA and the OPC server are doing
can be obtained by using Matrikon’s OPC Sniffer. Matrikon OPC Explorer and
Matrikon OPC Sniffer are available as free downloads from
www.matrikon.com.

Isolating a Fault to the Cim-IO Components


If the point exists on the device, and your OPC client tool shows the point
working correctly, observe the behavior of Cim-IO for OPC DA and the Cim-IO
client. Using Cim-IO Kernel Diagnostics, create a log file logging the
appropriate requests and replies (Get, Put, Unsol). Also check your
CIMIO_MSG.LOG file to see if the messages are getting through, or if there
are network connectivity problems.
Alternatively, you can use the Cim-IO test utility (cimio_t_api) to determine if
the point is being correctly obtained from the device.
Following is an example of using the cimio_t_api test program for using
option 9 to read a point from the device:
1 At the "Logical device name for the Cim-IO for OPC DA interface" prompt,
enter the default logical device name.
2 Now you are presented with several more prompts. Respond to these as
indicated in the following table.
Test Utility Information to Enter
Prompt

Unit number Default number, because this parameter is


not used by the interface.
Number of tags Number of tags to read.
Priority "1" for the highest priority.
Timeout At least "10", for 10 seconds.
Access type CIMIO_AT_SYNC for synchronous.
Frequency "0" for demand read.
List ID "-1".
Tag names Tag names, either manually or through a
file.
Data type Data type with which the point is returned.
Set this field if manual entry is used.
Device data Device data type for point, if manual entry
type is used.
3 Now the request is processed. Note the following returned information:

8 Troubleshooting 41
value Value of the return code.
timestamp Timestamp of the return code.
status One of the valid Cim-IO status codes,
discussed in "Error Messages."
facility number 77.
driver status Raw status returned by the interface,
described in "Error Messages."

If the error is with Cim-IO for OPC DA, contact AspenTech support. Please
retain any logs produced to assist AspenTech support in quickly locating your
problem.

Isolating a Fault to the Client Level


If the Cim-IO test utility (cimio_t_api) shows a point to be correct and the
application shows the point information to be incorrect, then the problem
resides in the application. If using InfoPlus.21 or InfoPlus-X, the Get or Put
transfer records need to be checked for status information about the
particular point. If these are correctly configured, there may be a problem
with the Cim-IO client. Contact AspenTech for assistance.

Failover and Redundancy


If a redundant server is specified, Cim-IO for OPC DA will fail over to the
redundant server when the primary goes down, and will fail back to the
primary server when the redundant server goes down.
Failover is not immediate. It only occurs after a break in the OPC connection
is detected. Because OPC depends on Microsoft DCOM for communications, an
OPC call times out only if its DCOM call times out. This only occurs if:
 The OPC server goes down but the computer on which it was running
stays up, and an OPC call is done, or
 The computer on which the OPC server is running goes down, or the
network connection between the two is broken, and up to 6 minutes (the
DCOM timeout hard-coded in Microsoft operating systems and not user or
program settable) elapses.
A timeout will not occur if the server, for whatever reason, hangs or stops
functioning while an OPC call is being made to it, but does not crash or
otherwise go down.

Frequently Asked Questions


Below is a list of common questions about the Cim-IO for OPC DA Interface:
 I have trouble using cimio_t_api to check the connection to the Cim-IO for
OPC DA Interface. The AsyncDlgp process dies, and I get
CIMIO_USR_GET_CONNECT and "OPC Server Not Installed, - exiting"
messages in the CIMIO_MSG.LOG file.
Some OPC servers require DCOM settings different from those established by
default during installation. Click "Start|Run" and type in "dcomcnfg". Select

42 8 Troubleshooting
the OPC server from the list and click on "Properties". Click on the "Identity"
tab and make sure "The interactive user" is selected rather than "The
launching user". DCOM settings connecting a client and server on different
domains or on a workgroup may involve further difficulties.

Error Codes
The following table lists the error codes and text that the interface may log in
the Cim-IO log file:
Code Description

0 Operation Succeeded
77001 Operation Failed
77002 Unsupported Data Type
77003 Unknown Data Type
77004 Failed to Allocate Memory
77005 Unsupported Output Type
77006 The AddGroup Method Failed
77007 The AddItems Method Failed
77008 The OPC QueryInterface Method Failed
77009 The Register function Failed
77010 Invalid Transaction Type
77011 The NewList function Failed
77012 The SyncRead function Failed
77013 The SyncWrite Function Failed
77014 The GetList Function Failed
77015 The BuildReply Function Failed
77016 The ServerTag Function Failed
77017 The ServerTemplate Function Failed
77018 The SeverIntID function Failed
77020 Unsupported Device Data Type
77021 Unsupported Data Type
77022 No OPC Server running
77023 The AsyncRead Function Failed
77024 The AsyncWrite Function Failed
77025 Failed to Connect Sink
77026 No callback was registered
77027 One of the arguments passed to the function was invalid
77028 Item Was Not Found in Internal List
77029 The BuildDummyResults Function Failed
77030 Output Type and Data Type Mismatched
77031 Invalid Item
77032 No Access Right
77033 The passed item handle was invalid
77034 The Item is no longer available in the Server Address Space

8 Troubleshooting 43
Code Description

77035 The value was out of range


77036 The passed data type cannot be accepted for this item
77037 The item's access path is not known to the server
77038 Dadvise is not implemented on the data object
77039 Dadvise failed: Invalid value for lindex; currently only 1 is
supported
77040 Dadvise failed: Invalid value for pFormatetc
77041 Dadvise Failed: The data object does not support change
notification
77042 Invalid array size returned for array data type
77101 Invalid Tag
77103 Tag was skipped because output type was set to NOSTORE
77104 The AddItems method failed
77105 Status pattern not used by OPC
77106 No specific reason is known
77107 Last Usable Value
77108 Sensor Not Accurate
77109 Engineering Units Exceeded
77110 Sub-Normal
77111 Configuration Error
77112 Not Connected
77113 Device Failure
77114 Sensor Failure
77115 Last Known Value
77116 Communication Failure
77117 Out of Service
77118 Local Override

44 8 Troubleshooting
9 Glossary

Client
A program capable of initiating communications with a service program. Cim-
IO clients talk to Cim-IO servers.

DIOP
Device Input/Output Process. A DIOP is a Cim-IO interface task that performs
low-level communications with external hardware devices or other databases.

DLGP
Device Logical Gateway Process. A DLGP is a Cim-IO interface task that
communicates with client tasks, forwards messages to DIOPs in the interface,
and returns messages to the client tasks that initiated the requests.

Logical Device
Representation of the interface supported by the Cim-IO interface platform.
Cim-IO can support several different interfaces at the same time.

Logical Device Name


Name representing a Cim-IO logical device. Each interface must be identified
by a unique logical device name.

OPC
Microsoft Object Linking and Embedding for Process Control. OPC is a
standard in the process control industry. Standards are set by the OPC
Foundation.

OPC Group
A collection of points to be read or written, similar to a Cim-IO Transfer
Record.

9 Glossary 45
OPC Cache
OPC Specification requires that an OPC server obtain data regularly if
requested, and store this in an internal cache. Reads requesting the cache as
the data source, and all unsolicited callbacks, come from data stored in this
cache.

OPC Device
An OPC Client may request that its data be directly read from the device. This
bypasses the OPC cache (see above). Writes are always to the device.

OPC Update Rate


The maximum rate at which requested data is expected to flow from the OPC
Server to CimIO for OPC.

Service
A program that provides services to other programs. A service has a defined,
constant, TCP port number that it listens on for incoming connections. The
service’s name and port number must be defined in the operating systems’
Services file.

Service Name
A name for a particular service.

46 9 Glossary

You might also like