The OPC Classic Connection Tag provides a connection to an external OPC Classic DA Server. The data in the external OPC Classic Server can be read at a fixed interval, or on demand, or both.
The OPC Classic Connection Tag supports the configuration properties of the Alarm Tag plus these properties:
Property | Type | Version | Description |
---|---|---|---|
ScanInterval | TIME | 1.3 | The interval between each read. An interval value of zero (T#0s) disables periodic query execution. See Interval and Offset for information on how timed activities are scheduled. |
ScanOffset | TIME | 1.3 | The offset added to the ScanInterval to get the actual read time. See Interval and Offset for information on how timed activities are scheduled. |
ProgID | WSTRING | 1.3 | The programmatic identifier of the external OPC Classic Server. |
RemoteNode | WSTRING | 3.0 |
The node name of the computer running the OPC Classic Server. This can be any of the following:
|
AlarmSeverity | UINT | 1.5 | The severity of the alarm raised when the OPC server fails. |
The ProgID property tells Fernhill SCADA which external OPC Classic Server to connect to.
Depending on the external OPC Classic Server you want to connect to, Fernhill SCADA may need to authenticate itself with the external OPC Server. In a default installation, Fernhill SCADA runs under the System account reserved for system services. If the OPC Classic Server does not allow access from the System account, you can change Fernhill SCADA to use a different user account. See Fernhill SCADA Server for information about changing the user account used by Fernhill SCADA.
The OPC Client Connection Tag supports the data properties of the Alarm Tag plus these properties:
Property | Type | Description |
---|---|---|
ServerState | UINT | A code indicating the state of the connection to the external OPC Classic Server. The value 15 shows successful operation. Other values indicate an error. The FailedFunction and ErrorMessage properties may give additional information. |
FailedFunction | WSTRING | The function call that failed if there is an error communicating the external OPC Classic Server. |
ErrorMessage | WSTRING | The error message returned from the external OPC data source. |
OPCServerStartTime | DATE_AND_TIME | The time the OPC server started (from the GetStatus request). |
OPCServerState | UINT | The state reported by the GetStatus request. |
OPCMajorVersion | UINT | The Major version of the OPC Classic Server reported by the GetStatus request. |
OPCMinorVersion | UINT | The Minor version of the OPC Classic Server reported by the GetStatus request. |
OPCBuildNumber | UINT | The Build number of the OPC Classic Server reported by the GetStatus request. |
OPCVendorInfo | WSTRING[80] | The vendor information string reported by the GetStatus request. |
ScanTimer | TimerStatus | The status of the scan timer. |
The ServerState property can be used to diagnose problems with the OPC data source:
ServerState | Description |
---|---|
0 | Initial state before the driver has started |
1 | There is an error in the OPC Client Connection Tag configuration |
2 | The driver has disconnected from the OPC Classic Server |
3 | The ProgID is invalid |
4 | The CoCreateInstanceEx call to create an instance of the external OPC server failed. |
5 | The IOPCServer::GetStatus function call failed |
6 | The IOPCServer::AddGroup function call failed |
7 | The IOPCItemMgt::AddItems function call failed |
8 | The external OPC Classic Server does not support the IOPCSyncIO interface |
9 | The IOPCSyncIO::Read function call failed |
15 | The connection to the external OPC server is working normally |
The OPC Client Connection Tag supports the tag commands of the Alarm Tag, plus these tag commands:
Tag Command | Version | Description |
---|---|---|
Refresh | 1.3 | Requests an immediate read of the tags associated with this OPC Classic Connection Tag. |
Note: Event triggered data reads (from the Refresh Tag Command) and periodic data reads (defined by the ScanInterval property) are independent. You can use the Refresh Tag Command, or the ScanInterval property, or both to determine when the tags are read.
The OPC Classic Connection Tag builds on the features of these tag types:
To learn how activities are scheduled using Interval and Offset.
To learn about the I/O Analog Data Point Tag that can be associated with the OPC Classic Connection Tag.
To learn about the I/O Digital Data Point Tag that can be associated with the OPC Classic Connection Tag.
To learn about the I/O String Data Point Tag that can be associated with the OPC Classic Connection Tag.
To learn about the I/O Word Data Point Tag that can be associated with the OPC Classic Connection Tag.
I/O Double Word Data Point Tag
To learn about the I/O Double Word Data Point Tag that can be associated with the OPC Classic Connection Tag.
To learn about the I/O Long Word Data Point Tag that can be associated with the OPC Classic Connection Tag.
OPC Client DriverFor an overview of the OPC Client Driver.
For the meaning of terms used in Fernhill SCADA.