您的当前位置:首页正文

施耐德IA的OPC安装指导

2020-04-03 来源:好走旅游网
Getting Started with the Niagara opcClient Driver

Getting Started with the OPC Client Driver

Note: This document applies to the following Niagara modules:

󰂃 opcClient 󰂃 opcClientWS

Introduction........................................................................................................................................................3 Supported OPC Data Types...........................................................................................................................3 Module and Niagara Licensing Requirements...............................................................................................4 JACE and/or Engineering PC....................................................................................................................4 OPC Supervisor.........................................................................................................................................4 Creating the OpcClientService...........................................................................................................................5 Adding the OpcClientService using the Niagara New Station Wizard..........................................................5 Adding the OpcClientService Using Copy-and-Paste...................................................................................7 OPC Windows Component Installation.............................................................................................................8 Client-Side (Niagara).....................................................................................................................................8 OPC Server-Side............................................................................................................................................8 Verifying Communications................................................................................................................................9 Building the Server Tree in Niagara............................................................................................................10 Object Information Overview......................................................................................................................12 OpcClientService.............................................................................................................................................13 OpcClientService ServerListManager View................................................................................................13 OpcServer Object.............................................................................................................................................14 Adding an OpcServer to the Station............................................................................................................14 OpcServer properties...................................................................................................................................14 OpcServer Commands.................................................................................................................................17 GroupListManager View.............................................................................................................................18 ItemListManager..........................................................................................................................................18 OpcGroup Object.............................................................................................................................................19 Adding an OpcGroup to Station...................................................................................................................19 OpcGroup properties....................................................................................................................................19 OpcGroup Commands.................................................................................................................................20 All OPCClient Items........................................................................................................................................21 Properties.....................................................................................................................................................21 Commands...................................................................................................................................................21 OpcClientAIObject..........................................................................................................................................22 OpcClientAIObject Properties.....................................................................................................................22 OpcClientAOObject.........................................................................................................................................22 OpcClientAOObject Properties....................................................................................................................22 OpcClientBIObject..........................................................................................................................................23 OpcClientBIObject Properties.....................................................................................................................23 OpcClientBOObject.........................................................................................................................................23 OpcClientBOObject Properties....................................................................................................................23 OpcClientDTInputObject.................................................................................................................................23 OpcClientDTInputObject Properties............................................................................................................23 OpcClientDTOutputObject..............................................................................................................................24 OpcClientDTOutputObject Properties.........................................................................................................24 OpcClientStringInputObject............................................................................................................................24 OpcClientStringOutputObject..........................................................................................................................24 OpcClientStringOutputObject Properties.....................................................................................................24 Appendix A: DCOM Configuration...............................................................................................................25 Windows Tools Used...................................................................................................................................25 Client (Niagara host) Configuration............................................................................................................26 OPC Server Configuration...........................................................................................................................26 Applications.............................................................................................................................................26

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 1 of 28

Getting Started with the Niagara opcClient Driver

Default Properties....................................................................................................................................27 Default Security.......................................................................................................................................27 For More Information..................................................................................................................................27 Appendix B: Window XP Service Pack 2.......................................................................................................28 Windows Firewall........................................................................................................................................28 DCOM Enhancements.................................................................................................................................28

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 2 of 28

Getting Started with the Niagara opcClient Driver

Introduction

Supported OPC Data Types

Introduction

The OPC Client driver provides the components necessary to integrate OPC 1-2.0x Data Access Servers into the Niagara environment.

The driver will operate on any of the following platforms:

• JACE-NP (either Full NT or NT Embedded) • JACE-NX (either Full XP or XP Embedded)

• OPC Supervisor PC or Niagara engineering PC with operating system:

1. Windows NT

2. Windows 2000 with Service Pack 3 or later

http://www.microsoft.com/windows2000/downloads/servicepacks/sp3/default.asp 3. Windows XP Professional

Note: This driver is not supported on any embedded (JACE-4/5) platform.

Supported OPC Data Types

1 2 3 4 5 6 7 8 9 10 11 12 13

OPC Item Type and value VT_I2 = 2

OPC Server Item Type Description

Niagara Shadow Object Type OpcClientAIObject (read only) OpcClientAOObject (read/write)

A 2-byte integer value.

VT_I4 = 3 A 4-byte integer value.

VT_R4 = 4 An IEEE 4-byte real value.

VT_R8 = 5 An IEEE 8-byte real value.

VT_I1 = 16 A 1-byte character value VT_UI1 = 17 An unsigned 1-byte character VT_UI2 = 18 An unsigned 2-byte integer value VT_UI4 = 19 An unsigned 4-byte integer value VT_INT = 22 An integer value

VT_UINT = 23 An unsigned integer value VT_DATE = 7 A value denoting a date and time

was specified.

VT_BSTR = 8 A string value.

VT_BOOL = 11 A 16-bit Boolean value (true/false)

was specified.

OpcClientDTInputObject (read only) OpcClientDTOutputObject (read/write) OpcClientStringInputObject (read only) OpcClientStringOutputObject (read/write) OpcClientBIObject (read only) OpcClientBOObject (read/write)

Note: The client does not support array type. If you want to create a array of item objects, you have

to create it by adding the individual element one by one. This driver does not support write only items.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 3 of 28

Getting Started with the Niagara opcClient Driver

Introduction

Module and Niagara Licensing Requirements

Module and Niagara Licensing Requirements JACE and/or Engineering PC

If a JACE-NP, JACE-NX, or Niagara engineering PC, ensure that the following module is installed: opcClient(opcClient-2.301.xxx.jar), for example: opcClient-2.302.428.v1.jar.

Verify that the Niagara license.properties file includes an “opcClient” entry in the features line. For example, this line in a JACE license file may look similar to:

features=coreRuntime;webUi;bacnet;lonworks;;opcClient;;

OPC Supervisor

If an OPC Supervisor, that is a Web Supervisor licensed for direct OPC client operation (no JACEs), ensure that both of these modules are in that PC’s niagara\\\\nre\\modules directory: opcClient(opcClient-2.301.xxx.jar), for example: opcClient-2.302.428.v1.jar.

opcClientWS(opcClientWS-2.301.xxx.jar), for example: opcClientWS-2.302.428.v1.jar. Verify that the Niagara license.properties file includes both:

1. an “opcClientWS” entry in the features line, for example:

features=coreRuntime;coreUi;database;webUi;;opcClientWS;

2. one (or more) additional lines in license.properties that specify the licensed number of OPC points

(shadow objects) that can be created in the OPC Supervisor station, using format:

n.opcClientWSObjects=x

where: n = OpcClientWSService number, and is from 0 to 3

x = number of licensed points, in blocks of 100

Note: In almost all cases, there is only one OpcClientWSService, and n = 0.

For example, an OPC Supervisor licensed for 500 OPC points would include these two lines in license.properties:

features=coreRuntime;coreUi;database;webUi;opcClientWS; 0.opcClientWSObjects=500

Note: Do not edit the license file. If you make any changes to it, your Niagara station will not operate!

Contact Tridium if you need any license changes, so that you may be sent a proper license.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 4 of 28

Getting Started with the Niagara opcClient Driver

Creating the OpcClientService

Adding the OpcClientService using the Niagara New Station Wizard

Creating the OpcClientService

The OpcClientService is most conveniently added during creation of a new station using the “New Station” wizard. As an alternate method, you may add the service to an existing station use a copy-and-paste operation.

Adding the OpcClientService using the Niagara New Station Wizard

If you are adding this service and have not yet created your station, use the new station wizard to

incorporate the OpcClient Service. In the Niagara user interface (Workplace Pro), go to the Menu Bar, click on File, then select New Station from the drop down menu. This will bring up the following screen.

Enter the new station’s name (“OpcClientStation”, in this example) and click \"Next>\".

On the next screen enter your Administrator User name and Password and click “Next>”.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 5 of 28

Getting Started with the Niagara opcClient Driver

Creating the OpcClientService

Adding the OpcClientService using the Niagara New Station Wizard

The next screen is the services selection screen, similar to that shown below:

Using the scroll bar, scroll the display and click on the line “Opc Client Service”. A red check mark should appear next to the Service.

Click \"Next>\" to bring up the “Notification Service Setup” screen. Make sure “Create Notification Class 0” is selected, and click Finish to complete creation of the new station.

On the last pop-up screen, click OK.

The new station is now created with the OpcClient Service.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 6 of 28

Getting Started with the Niagara opcClient Driver

Creating the OpcClientService

Adding the OpcClientService Using Copy-and-Paste

Adding the OpcClientService Using Copy-and-Paste

If adding the OpcClientService to an existing station, use the Copy-and-Paste method.

In the Niagara interface console, if a library is not available on the station tree, add a library by

clicking on the File>Open Local Library menu item or the File>Add Remote Library menu item:

Click on the library you just opened, and expand tridiumx/opcClient/services.

Right click on OpcClientService, and select Copy.

Expand the station you wish to add the service to by clicking on the Station. Right click the Services container, and select Paste from the pop-up menu.

The OpcClient Service is now added, and should appear in the list of station services.

Note: After you add the opcClientService through copy-paste method, you need to restart the station to start the service.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 7 of 28

Getting Started with the Niagara opcClient Driver

OPC Windows Component Installation

Client-Side (Niagara)

OPC Windows Component Installation

Client-Side (Niagara)

The OpcClientService object (or OpcClientWSService object, if an OPC Supervisor) must already be in the station’s services folder to proceed.

1. Start the Niagara OPC client station.

2. Using the JDE, go to the properties of the OPC Client Service Object. 3. Invoke the “Install” command.

This launches a batch file to install needed Win32 components on the Niagara host. If desired, you can view the results in a Standard Output window for that station.

Unless directed otherwise by Systems Engineering, issue this command only once for that particular host (this command is not specific to the currently running station). It is also not necessary to issue this command after upgrading the Niagara host with a subsequent build of Niagara (again, unless you have been otherwise directed).

4. Reboot the Niagara client machine (note if an Engineering PC or OPC Supervisor, this means you

have to reboot that PC).

Note:

OPC Server-Side

It is likely that the target OPC server(s) may require additional configuration to allow communications with Niagara. However, you should attempt communications from the station on the newly-configured Niagara host before making any changes. Please see the next section, “Verifying Communications.”

See “Appendix A: DCOM Configuration,” at the end of this document for some DCOM configuration guidelines.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 8 of 28

Getting Started with the Niagara opcClient Driver

Verifying Communications

OPC Server-Side

Verifying Communications

When the Niagara host reboots after install the OPC Windows components, open its running station.

1. Expand the services folder to reveal the OPC Client Service. 2. Right-click on the service, and select ServerListManager.

3. In the “Server List for:” field, enter the IP address or host name of the known target OPC server,

and then click on GetServer.

The Status changes to “Busy” while the station attempts communications with the OPC server. If successful, you will see information about any OPC server(s) in this view, as shown below. Skip ahead to the next section, “Building the Server Tree in Niagara.”

If not successful, you will see an “Are You Sure…” entry in the serverName field of this view. This means additional DCOM configuration on either (or both) the Niagara client host or the OPC server is likely needed. Please see “Appendix A: DCOM Configuration” for more details.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 9 of 28

Getting Started with the Niagara opcClient Driver

Verifying Communications

Building the Server Tree in Niagara

Building the Server Tree in Niagara

After verifying communications with an OPC server, you can start to build the shadow objects in the

station that represent that server and its contained (subordinate) OPC groups and items. Follow the general steps given below for any OPC server.

Note: In this procedure, after issuing a “Create” command, you may find it necessary to issue a “Refresh”

command in the JDE Tree View (left-side) in order to see newly-created objects in the tree.

1. In the Server List Manager view of the OPC Client Service, click an OPC server to highlight it,

then click Create.

This makes a top-level “OpcServer” object in the root of the station. This object serves as the container for all OPC groups and items obtained from that server.

2. In the JDE Tree View, right-click the OpcServer object and select GroupListManager.

The Group List Manager queries the server and returns a list of available OPC groups.

Note: You can drag the columns for “Name” and “Full Name” to be wider, if necessary. 3. In the Group List Manager, click to select (highlight) one or more groups, or click SelectAll

button to select all groups listed, then click Create.

This creates one OpcGroup object for each group selected.

Each OpcGroup is a container for either/both more (subordinate) OPC groups or perhaps OPC (data) items, depending on the structure of the OPC server. 4. In the JDE Tree View, right-click any created OpcGroup and select (again) GroupListManager,

and/or try ItemListManager.

Note: It is possible for an OPC group to contain both subordinate groups and items.

The Item List Manager works like the Group List Manager, click to select (highlight) one or more items, or click SelectAll button to select all items listed, then click Create.

This creates one OpcClientXx (data) object for each selected item (if a supported type).

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 10 of 28

Getting Started with the Niagara opcClient Driver

Verifying Communications

Building the Server Tree in Niagara

Note that in Tree View, OpcGroups appear as containers and OPC items appear as objects .

• •

If you double-click an OpcGroup, you see its Workspace of contained subordinate groups or data items.

If you double-click an OpcClientXx data object (item), you see its Niagara property sheet. OpcGroup default view is Workspace. Data item default view is Property Sheet.

Notes:

If you encounter any of the following problems, additional DCOM configuration may be necessary on either the Niagara (client) host, or possibly even the OPC server itself: • •

You can see groups listed in the Group List Manager, but the Create command does not work for any of them.

You can see items listed in Item List Manager, but the Create command does not work for any of them. (Note that in some cases, an item may be a type not supported by the opcClient driver, such as “VT_Empty,” in which case an object is never created for it.)

Items are successfully created in the station, but values remain at “0.0” or “False” and the “lastUpdateTime” remains frozen at a set time. Observe the “Status” tab properties of various items to verify that values and update times are changing.

For DCOM configuration details, please see “Appendix A: DCOM Configuration.”

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 11 of 28

Getting Started with the Niagara opcClient Driver

Verifying Communications

Object Information Overview

Object Information Overview

OpcClientXx item objects must reside directly in an OpcGroup container—you cannot move or “cut and paste” them into ordinary “Container” containers for them under an OpcGroup. However, if necessary, you can create a new “virtual” OpcGroup within another OpcGroup and then “Move” item objects (one at a time) using the JDE Tree View.

To do this, copy an OpcGroup from the Local Library and paste it into the Workspace of the “real” shadowed OpcGroup (this does not affect configuration of the OPC server). In the property sheet of the copied OpcGroup object, on its config tab, enter a unique name for the “OpcGroupName” property. You should also rename the object in Niagara (right-click it in Tree View or Workspace, then select “Rename”). You can link OpcClientXx item objects to other Niagara objects as needed. Most types have a linkable output as well as least one linkable input.

In the Niagara (runtime) Workspace, both the OpcServer and OpcGroup objects have right-click “Activate All” and “Deactivate All” commands. In addition, each OpcClientXx item object has an “Activate” and “Deactivate” command. The meaning of these commands is explained ahead.

Reference information for all OPC Client objects is provided in the remainder of this document, including properties, views, and commands. Included are the following types: • • • •

OpcClientService OpcServer Object OpcGroup Object

All OPCClient Items (OpcClientXx types) o OpcClientAIObject o OpcClientAOObject o OpcClientBIObject o OpcClientBOObject o OpcClientDTInputObject o OpcClientDTOutputObject o OpcClientStringInputObject o OpcClientStringOutputObject

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 12 of 28

Getting Started with the Niagara opcClient Driver

OpcClientService

OpcClientService ServerListManager View

OpcClientService

This service is composed of the following sub-services:

1. The poll service is used to read values in groups who are configured for synchronous IO. 2. The device service is used to query the status of the OPC server.

OpcClientService ServerListManager View

The OpcClientService ServerListManager is used to learn OPC servers.

Status

ServerListFor

GetServers

Create

Idle if the Learn process has been completed. Busy if it is in progress. The host name or address that you want to get server list from. Query the host for servers.

Create OPC Server objects for the selected rows.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 13 of 28

Getting Started with the Niagara opcClient Driver

OpcServer Object

Adding an OpcServer to the Station

OpcServer Object

OpcServer object is a shadow object for the real OPC Server. It contains OpcGroup objects.

Adding an OpcServer to the Station

Each OpcServer Object represents one OPC SERVER the station will talk with. There are two ways to add OpcServer object to station. One way is using the ServerListManager Create button, let system create the server shadow object and connect to the it. Another way is using Copy-Paste.

Copy-Paste method:

1. Open local or remote library.

2. Expand the library to show tridiumx\\OpcClient\\containers\\OpcServer 3. Right-click on the OpcServer and select copy.

4. Right-click on the station in Tree View and select paste. This should add an opcServer container under

the station.

OpcServer properties

1. Status tab

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 14 of 28

Getting Started with the Niagara opcClient Driver

OpcServer Object

OpcServer properties

ServerAddress

serverStatus

If the connection to server is successful, the value of this property should be greater than 0. Otherwise this value is 0 or Down.

Show the current status of the server. Below is the detail info.

startTime

Time the server was started. This is constant for the server instance and is not reset when the server changes states. Each instance of a server should keep the time when the process started.

lastUpdateTime The time the server sent the last data value update to this client. This value is

maintained on an instance basis.

State The current status of the server. Its value can be one of the following:

RUNNING: The server is running normally. This is the usual state for a server. FAILED: A vendor specific fatal error has occurred within the server. The

server is no longer functioning. The recovery procedure from this situation is vendor specific.

NOCONFIG: The server is running but has no configuration information

loaded and thus cannot function normally. Note this state implies that the server needs configuration information in order to function. Servers that do not require configuration information should not return this state.

SUSPENDED: The server has been temporarily suspended via some vendor

specific method and is not getting or sending data.

TEST: The server is in Test Mode. The outputs are disconnected

from the real hardware but the server will otherwise behave normally. Inputs may be real or may be simulated depending on the vendor implementation.

UNKNOWN STATUS: A vendor unspecific error has occurred within the

server.

groupCount The total number of groups being managed by the server. This is mainly for

diagnostic purpose.

Bandwidth The behavior of this field is server specific. A suggested use is that it return the

approximate percent of bandwidth currently in use by server. If multiple links are in use it could return the “worst case” link. Note that any value over 100%

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 15 of 28

Getting Started with the Niagara opcClient Driver

OpcServer Object

OpcServer properties

indicates that the aggregate combination of items and UpdateRate is too high. The server may also return 0xFFFFFFFF if this value is unknown.

MajorVersion The major version of the server software.

MinorVersion The minor version of the server software.

BuildNumber The “build number “ of the server software.

VendorInfo Vendor specifies string. It provides additional information about the server. It is

recommended that this mention the name of the company and the type of devices supported.

itemCount

serverInterface

The number of OPC client objects when the client connected to the server. This is not a real time count. To update this number, use the OPC Server commands to disconnect then reconnect to the server.

Tell client which interface the OPC Server support, which interface the OPC Server does not support.

2. Config tab.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 16 of 28

Getting Started with the Niagara opcClient Driver

OpcServer Object

OpcServer Commands

description The description of this object.

serverEnable You can set serverEnable to false to persistently disconnect from the server.

The client will not reconnect to the server until this property is set to true.

serverName This field is required if the OPC Server is at LOCAL. There are two ways to get

the progID. One way is getting the progID from Vendor Documentation. The other way is invoking ServerListManager command on opcClientService object. If the serverName is not a valid name, the client can’t connect to the OPC Server

local Select the local connection or remote connection to OPC Server.

hostAddress The host address of the node where the OPC Server is.

serverClassId The class ID that OPC Server uses to register the server in system registry. If the

serverClassId is not valid, the client cannot connect to the OPCServer. This field is required if the OPC server is REMOTE.

serverDelimiter The OPC Server vendor specifies delimiter to provide a way to assemble a

“fully qualified “ item name in a hierarchical space. During connecting to server, the driver tries to get delimiter info and fill in to serverDelimiter property. If you see unknown delimiter in serverDelimiter property, change it to “.”

retryWriteInterval If writing a value to the server fails, this is the period of time in seconds before

the write is retried.

writeMethod This allows you choose the OPC mechanism for writing to the server.

Synchronous IO is the preferred method and should only be changed if you are experience performance issues.

OpcServer Commands

Activate All

Deactivate All

Disconnect

Connect

Subscribe all groups and items with the server. Unsubscribe all groups and items with the server.

Disconnect with the server if it was connected before. Otherwise do nothing.

Connect to the server. If it was connected before, do nothing. If you modify OpcServer Object and then want to reconnect it, you can just disconnect it first and then connect it without restarting the station.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 17 of 28

Getting Started with the Niagara opcClient Driver

OpcServer Object

GroupListManager View

GroupListManager View

This view is common to OpcServer and OpcGroup objects. It lists all child groups of the current object.

Status

GetGroups

SelectAll

Create

Idle if the Learn process has been completed. Busy if it is in progress. Refresh the table

Select all groups in the list. Create the selected groups.

ItemListManager

This view is common to OpcServer and OpcGroup objects. It lists all child items of the current object.

GetItems

SelectAll

Create

Refresh the table Select all items in the list. Create the selected items.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 18 of 28

Getting Started with the Niagara opcClient Driver

OpcGroup Object

Adding an OpcGroup to Station

OpcGroup Object

Adding an OpcGroup to Station

There are two ways to add OpcGroup object to station. One way is using the GroupListManager Create button, let system create the group shadow object. Another way is using Copy-Paste.

Copy-Paste method:

1. Open local or remote library. Expand the library to show tridiumx\\OpcClient\\containers\\OpcGroup 2. Right click on the OpcGroup and click copy.

3. Right click on the station in Tree View and click paste.

OpcGroup properties

1. Status tab

clientHandle

serverHandle

revisedUpdateRate

inServer

activeStatus

2. Config tab

OPCGroupName

dataAcquisition

A unique value client assigns.

A unique value server assigns across the server and must be assigned when the group is created.

The server returns the value it will actually use for the UpdateRate which may differ from the RequestedUpdateRate.

If the group is successful added to server, this property will be true. If the group is active in server, this property is true, otherwise it’s false. To activate, invoke the “Activate All” command, only if inServer is true.

The unique name of the group. Required for the “Add Group” command. The OPC mechanism by which values are “read” from the server. ASYNC IO 2 is the preferred mechanism and should not be changed unless the server does not support it. Async IO means the server sends unsolicited change of value messages and is therefore the most scalable solution. Performance drops dramatically when synchronous IO is selected.

Client Specifies the fastest rate at which data changes may be sent to client for items in this group. Passing 0 indicates the server should use the fastest practical rate. The rate is specified in milliseconds.

The range of the deadband from 0.0 to 100.0 Percent. Deadband will only apply to analog items in the group.

Prevents the group from writing child objects faster than the given value (seconds).

User can setup the group either POLLALWAYS or POLLONDEMAND. If the group is POLLALWAYS, the group is always active in the server. If the group is POLLONDEMAND, the group is only active when there is at least one child is in viewed.

requestedUpdateRate

percentDeadBand

minimumWriteInterval

groupPollOnDemand

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 19 of 28

Getting Started with the Niagara opcClient Driver

OpcGroup Object

OpcGroup Commands

OpcGroup Commands

Activate All

Deactivate All

Add Group

Subscribe the group and all descendent objects (sub groups and items). Unsubscribe the group and all descendent objects (sub groups and items).

If you add an OpcGroup object by pasting it to the station. You need to use this command to add it to the server. Before you can add it to the server, you need to give a unique OPCGroupName

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 20 of 28

Getting Started with the Niagara opcClient Driver

All OPCClient Items

Properties

All OPCClient Items

The following properties and commands are common to all client items include the following:

o OpcClientAIObject o OpcClientAOObject o OpcClientBIObject o OpcClientBOObject o OpcClientDTInputObject o OpcClientDTOutputObject o OpcClientStringInputObject o OpcClientStringOutputObject

Properties

Status Tab

• ClientHandle – Unique handle assigned to the item by the client driver. • ServerHandle – Unique handle assigned to the item by the OPC Server • AccessRightsEnum – read/write/readWrite • DataTypeEnum – Data type of the server item.

• LastUpdateTime – Last time the value was updated from the server. • InServer – True if the item exists in the server. • ActiveStatus – True it the value can be updated.

• Quality – This is the status of the object reported by the server. If the object is in fault, be sure to

check this property.

Config Tab

• OPCItemFullName – The full name of the item in the server.

Commands

Activate – Subscribe the item with the server. Deactivate – Unsubscribe the item with the server.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 21 of 28

Getting Started with the Niagara opcClient Driver

OpcClientAIObject

OpcClientAIObject Properties

OpcClientAIObject

A read only float or integer item.

OpcClientAIObject Properties

1. Status tab.

anaValue

2. Visual tab:

decimalFormat

the current value the item read from server.

Select the decimal places of precision for this point. This value should be set to match the precision returned for this object.

OpcClientAOObject

A read/write float or integer item.

OpcClientAOObject Properties

1. Status tab:

anaInValue

2. Config tab:

writeCovOverride

The value to write to the OPC server.

The default write policy of the driver is to write whenever the input changes. However, if the output of the point can change on the server by other means and you want the value to stay at that of the input, set this property to true.

3. Engineering tab:

inOutDiffTolerance: The difference between the input and output must exceed this amount for the

input to be written to the server.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 22 of 28

Getting Started with the Niagara opcClient Driver

OpcClientBIObject

OpcClientBIObject Properties

OpcClientBIObject

A digital read only item.

OpcClientBIObject Properties

1. Status tab:

bOutValue

2. Visual tab:

activeInactiveText

Last value read from the server.

active – this text is displayed as the point status if the input value is True. inactive – this text is displayed as the point status if the input value is False.

OpcClientBOObject

A digital read/write item.

OpcClientBOObject Properties

1. Status tab:

bInValue

2. Config tab:

writeCovOverride

The value to write to the OPC server.

The default write policy of the driver is to write whenever the input changes. However, if the output of the point can change on the server by other means and you want the value to stay at that of the input, set this property to true.

OpcClientDTInputObject

A DateTime read only item.

OpcClientDTInputObject Properties

1. Status tab:

dateTimeValue

Last value read from the server.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 23 of 28

Getting Started with the Niagara opcClient Driver

OpcClientDTOutputObject

OpcClientDTOutputObject Properties

OpcClientDTOutputObject

a DateTime read/write item.

OpcClientDTOutputObject Properties

1. Status tab:

datetimeInValue

2. Config tab:

writeCovOverride

The value to write to the OPC server.

The default write policy of the driver is to write whenever the input changes. However, if the output of the point can change on the server by other means and you want the value to stay at that of the input, set this property to true.

OpcClientStringInputObject

A read only String item.

1. Status tab:

string Last value read from the server.

OpcClientStringOutputObject

A read /write String item.

OpcClientStringOutputObject Properties

1. Status tab:

stringInValue

2. Config tab:

writeCovOverride

The value to write to the OPC server.

The default write policy of the driver is to write whenever the input changes. However, if the output of the point can change on the server by other means and you want the value to stay at that of the input, set this property to true.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 24 of 28

Getting Started with the Niagara opcClient Driver

Appendix A: DCOM Configuration

Windows Tools Used

Appendix A: DCOM Configuration

The following main sections are in this appendix: • Windows Tools Used

Client (Niagara host) Configuration

• OPC Server Configuration •

For More Information

Notes: DCOM configuration (dcomcnfg) is a complex subject with potentially far-reaching consequences. The owner’s system administrator should approve any changes made from using these (or other) guidelines, particularly on the OPC server-side, before you make them.

In addition, before running dcomconfg, you should stop both the Niagara station and the OPC server before changing anything. Then, after configuration is complete, restart both the station and the server. Finally, please note that you must disable (unassign) the IP security policy of a JACE-NX if it will run the OPC Client driver, or if a JACE-NP, you must disable any TCP or UDP port filtering in its TCP/IP

configuration. For related details, please see the engineering notes documents “JACE-NX Windows XP Security” or “JACE-NP Windows NT Security.”

Windows Tools Used

Depending on the Windows OS used on either the client (Niagara) host side or the OPC server side, you access the relevant DCOM configuration dialog(s) as follows:

A. If Windows NT (JACE-NP or perhaps a PC) or Windows 2000 (PC only), you access all DCOM setup

from the Windows desktop of the host by issuing this from the Start menu: a. Start > Run…

b. In the Run dialog, type in “dcomcnfg” and press ENTER.

This opens a “Distributed COM Configuration Properties” dialog, a multi-tabbed window.

1. Tabs of particular interest are typically:

• Default Properties • Default Security

2. If an OPC server host, then the “Applications” tab is also of interest, in particular

selections “OpcEnum” and “”. B. If Windows XP (JACE-NX or perhaps a PC), you access all DCOM setup from the Windows desktop

of the host by issuing this from the Start menu: 1. Start > Run…

2. In the Run dialog, type in “dcomcnfg” and press ENTER.

This starts the “Component Services” dialog, a “multi-paned” window. 3. On the left-side, double-click to expand:

• Component Services

󰂃 Computers

• My Computer—Right-click and select Properties

This opens a “My Computer Properties” multi-tabbed dialog that applies to DCOM configuration.

Tabs of particular interest are typically:

󰂃 Default Properties

󰂃 Default DCOM Security

DCOM Config – This is where OPCEnum and the OPC Server application can be found.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 25 of 28

Getting Started with the Niagara opcClient Driver

Appendix A: DCOM Configuration

Client (Niagara host) Configuration

Note: Other Windows XP configuration of DCOM is available, but applies only if the Windows XP host has running OPC servers.

Client (Niagara host) Configuration

The OPC client only requires DCOM configuration if the host operating system is Windows XP Service Pack 2 or later.

OPC Server Configuration

An OPC server host has the same “Default Properties” and “Default Security” settings in dcomconfg, plus additional settings for its OPC “Applications,” namely “OpcEnum” plus one application for each OPC server.

Applications OpcEnum

1. In Windows 2000 or Windows NT, from the dcomcnfg window, select Applications tab. On

Windows XP, OpcEnum is located under DCOM Config, which is under My Computer. 2. Scroll down to locate OpcEnum and click to highlight it. 3. Click the Properties button.

On the following Properties tabs set these values:

General

“Authentication Level” set to Default or (None).

Location

“Run application on this computer.” This should be the only selection.

Security

a. “Use custom access permissions”

Click Edit, and add (as needed):

Anonymous (if available), Everyone,

INTERACTIVE, NETWORK, SYSTEM

b. “Use custom launch permissions”

Click Edit, and add (as needed):

Anonymous (if available), Everyone,

INTERACTIVE, NETWORK, SYSTEM

Leave “configuration permissions” at current settings.

Identity

Select “The interactive user”. 4. Click OK to save any changes and close the dcomcnfg window.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 26 of 28

Getting Started with the Niagara opcClient Driver

Appendix A: DCOM Configuration

For More Information

OPC Server Application

In the same “Applications” tab of the dcomcnfg window of a Windows 2000 or Windows NT host, scroll to locate and select the OPC server application. On Windows XP, the OPC server application will be a sibling of OpcEnum under DCOM Config.

Perform the identical setup as for OpcEnum, starting with the previous step 3. Repeat for each OPC server application running on this host.

Default Properties

• • • • •

“Enable Distributed COM on this computer” must be enabled (checked).

Leave disabled (unchecked) “Enable COM Internet Services on this computer.”

“Default Authentication Level” set to Connect if client and server are on the same domain, otherwise set this value to None.

“Default Impersonation Level” set to Identify.

Leave disabled (unchecked) “Provide additional security for reference tracking.”

Default Security

Default Access Permissions Include the following:

• SYSTEM • NETWORK • INTERACTIVE • Everyone

• Anonymous – if available and client and server are not on the same domain. Default Launch Permissions Include the following:

• SYSTEM • NETWORK • INTERACTIVE • Everyone

• Anonymous – if available and client and server are not on the same domain. Default Configuration Permissions Leave at default settings.

For More Information

The following tutorials on using DCOMCNFG (Windows NT or Windows 2000) provides a good basic understanding of making appropriate configuration choices for OPC usage:

Dcomcnfg Overview Client Settings

http://www.opcactivex.com/Support/DCOM_Config/DCOMConfigUtility/dcomconfigutility.html http://www.opcactivex.com/Support/DCOM_Config/DCOM_ClientSettings/dcom_clientsettings.html

Server Settings

http://www.opcactivex.com/Support/DCOM_Config/DCOM_ServerSettings/dcom_serversettings.html

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 27 of 28

Getting Started with the Niagara opcClient Driver

Appendix B: Window XP Service Pack 2

Windows Firewall

Appendix B: Window XP Service Pack 2

Windows Firewall

Configuration of the windows firewall is same for both client and server.

The easiest option is to turn off the firewall. For troubleshooting, it would be best to turn off the firewall, get everything working, and then turn it back on.

If the firewall needs to be on, go to the exceptions tab:

• All OPC client and server programs on the local machine need to be added to the exceptions tab.

The program to add for the OPC client is \\nre\\bin\\niagarad.exe • Add TCP port 135.

DCOM Enhancements

Run dcomcnfg, go to the properties of My Computer. Select COM Security:

• In Access Permissions, click Edit Limits. Check the Remote Access box for the

ANONYMOUS LOGIN user.

• On the OPC server, in Launch and Activation Permissions, click Edit Limits. Check the

remote boxes for the user labeled Everyone. If client and server are not on the same domain, you must add the ANONYMOUS LOGIN user and check all Allow boxes.

All specifications subject to change without notice or liability to provide changes to prior purchasers.

01/06/2005

©

2005 Tridium, Inc. Page 28 of 28

因篇幅问题不能全部显示,请点此查看更多更全内容