Medialon MxMs' Help
Name: Medialon OPC Client
Version: 6.7.2
Available for: Manager V7 and Manager V6 (Lite & Pro)
Limitation In:
Device Brand: OPC
Positrack Compatible: Yes
Resources type: None

Overview

OPC - OLE for Process Control - was created as a vendor-independent standard aimed at the definition of data exchange between Microsoft Windows application as well as applications and vendor specific hardware in the realm of automation and industry. Many industrial hardware vendors provide OPC servers for their products like data acquisition boards, PLCs, fieldbus controllers, etc.

OPC is maintained by an independent association - the OPC Foundation -.

OPC defines a series of standard specifications. This MxM acts as a client for both “OPC Data Access” server and/or “OPC Alarms & Events” server.

MxM Installation

No installation is required if the OPC Server runs on the same machine as Manager and this section can be skipped.

If the OPC Server runs on another machine the following steps must be done:

  1. Install OPC Core Components: Unzip the attached “OPC Core Components Redistributable 3.00.102.zip” file in a temporary location and and execute “Setup.exe”.

  2. Setup COM/DCOM: This MxM uses OPC to communicate with OPC servers. OPC itself is based upon the Microsoft COM/DCOM technology. Thus the MxM requires that COM/DCOM is properly configured on both the server and the client machines in order to work correctly, in particular DCOM security settings and firewall settings must be carefully set when the MxM (which acts as an OPC Client) must communicate with an OPC Server on a remote machine. Please refer to “Using OPC via DCOM” document for detailed instructions.

Device Setup

Device Creation Window:

IP or Hostname: IP Address or Hostname of the PC which hosts the OPC server. The local machine is used if this entry is left blank.

Browse OPC Server: This button allows browsing the OPC Servers installed on the specified machine and populates the “Select Server” combo box with the names of the found OPC servers.

Select Server: This combo box lists all of the OPC Servers installed on the specified machine (after the “Browse OPC Server” button has been pressed).

Server GUID: This edit box shows the GUID (Global Unique Identifier) of the selected OPC server. This field is normally used for information purpose only and must not be modified.

However the GUID of the OPC server can be specified manually in special cases where the OPC server would not be registered correctly in the target host Windows registry.

Enable OPC Data Access: When checked an OPC Data Access connection to the specified OPC server will be established when the device is started. Otherwise OPC Data Access is not enabled.

Configure OPC Items and Monitoring: Pressing this button opens a dialog box which displays all of the OPC Data Access Items found on the specified OPC server.

For each found OPC Data Access Item the user can specify: whether the selected items should be monitored by a System Variable (by checking the item check box or choosing “Set Monitor On/Set Monitor Off” menu item or the popup menu) the type of the monitoring variable if the selected items are monitored (a default variable type is computed from information obtained from the OPC Server). whether the selected items are “active” (that is processed by the OPC Client). Note that an item must be “active” for the “Read Item Value” and “Write Item Value” commands to work.

The “Get OPC Item” button can be used to refresh the list of OPC Data Access items.

Enable OPC Alarm & Event: When checked an OPC Alarm & Event connection to the specified OPC server will be established when the device is started. Otherwise OPC Alram & Event is not enabled.

Device Commands

Read Item Value

Reads the value of an OPC Item.

Usage: This command works only if “OPC Data Access” is enabled.

Write Item Value

Writes the value of an OPC Item.

Usage: This command is positrack compatible.

This command works only if “OPC Data Access” is enabled.

Read Next Event

Reads the next event stored in the event queue and stores event information in specified return parameters.

Usage: This commands pulls out the least recently received event from the event queue (if any) and decrements the count of pending event. Return parameters are optional, for example, there’s no need to specify a “Severity” return parameter if there’s no use of this information in the Manager project.

The type of return parameter is not mandatory and the programmer can use the type of parameter which best suits his needs. For example a user defined enum variable can be used as a return parameter for “Event Type”.
This command works only if “OPC Alarm & Event” is enabled.

Acknowledge Event

Sends an acknowledge to the OPC Server for the last event retrieved by the “Read Next Event” command.

Usage: This command acknowledges the last retrieved event only if the “Ack Required” parameter of the event is true. Otherwise it does nothing. This command works only if “OPC Alarm & Event” is enabled.

Area Condition

Enables or disables events for an OPC Alarm & Event area.

Usage: This command only enables or disables events due to a condition change in the specified area. Simple events and tracking events wil be still be received is the area is disabled. This command works only if “OPC Alarm & Event” is enabled.

Source Condition

Enables or disables events for an OPC Alarm & Event source.

Usage: This command only enables or disables events due to a condition change in the specified source. Simple events and tracking events wil be still be received if the source is disabled. This command works only if “OPC Alarm & Event” is enabled.

Device Variables

Connection_Status

[Enum] Current connection status of the device.

Command_Status

[Enum] Status of the last command.

Error_Message

[String] Detailed description of the last error.

AlarmEvent_Status

[Enum] Current status of the Alarm and Event connection.

AlarmEvent_PendingCount

[Integer] Number of Alarm and Event messages which were received and queued in the pending message queue.

Usage: a task can be triggered when this variable changes is greater than 0 in order to retrieve messages from the pending message queue and display them. This variable is decremented each time a message is retrieved by the “Get Next Event” command.

Revisions

V 1.0.1

V 1.0.2

V 1.0.3

V 1.0.4

V 6.0.0

V 6.0.1

V 6.0.2

V 6.0.3

V 6.0.4

V 6.1.0

V 6.7.0