PmOpcUaClient - Driver for communication with OPC UA server

Before using this driver in the PROMOTIC application it is highly recommended to read the chapter: Communication using the PROMOTIC drivers.

Basic properties of the driver:
- Usage of this driver requires purchase of the PmOPC licence. When developing the application in the freeware mode PmFree, or with development environment and while testing it in runtime, this component is always functional.
- The communication is done for Ethernet (PROMOTIC application is client).
- The driver is incorporated into the PROMOTIC system by means of the PmaComm object.
The driver supports to usage of the PmaCommGroup object. The PmaCommMsg object cannot be used.
For easy integration of this driver into the application it is handy to use: Preconfigurations in group "OPC UA"
- This driver is available since version Pm9.0.9.
- This driver so far does not support UA Security (UA Security consists of authentication, authorization, encryption and data integrity via signatures).

Recommended parameters values of the PmaComm object:

Recommended values for the Ethernet-client parameters:
Network addressOPC-UA server URL address.
TCP/UDP port numberOPC-UA server port (usually the 4840 value).
See: A list of TCP and UDP port numbers used by protocols to run network applications.
Ethernet transfer typeTCP
Not connect until first transferNOT checked (mandatory)
Close connection after every transferNOT checked (mandatory). After each connection, it is necessary to transfer several initialization messages and if the connection is closed repeatedly, the communication speed would be decreased significantly.
Description and recommended values for the Protocol parameters:
Server Endpoint URLOPC-UA server endpoint URL address is entered here.
This is used if the server allows redirecting to other servers, otherwise just enter an empty string.
The value form is "opc.tcp://URL:Port".
AuthenticationThe client authentization type is defined here.
(Authentication type "2=Certificate" is currently not supported by this driver.)
0=Anonymous - Anonymous authentication, i.e. the client is not authenticated.
1=UserName - Authentication by name and password.
NameUser name of the client.
PasswordPassword for corresponding client name.
Additional parametersLeave the value empty.

The communication description by means of the PmaCommGroup object

The PmaCommGroup objects can be used for this driver.
The variables in the PmaCommGroup object (or even better the variables in the PmaData object with ExtComm data extension) can be of arbitrary number, type and order. The driver uses optimalised internal communication messages for reading the data from the device.
All variables are read (if the "Data refresh enabled" configurator is checked). When writing into the variable, only the single variable is sent (if the "Auto send when writing to item" configurator is checked).

Refresh of values of variables registered in the PmaCommGroup object:
While being initialized, the driver registers all its variables to the OPC server (OPC system message CreateMonitoredItems) and informs the server about the requested update rate based on the settings of the "Communication refresh rate [ms]" configurator.
The the driver sends request to be updated when the values of these variables change (OPC system message PublishRequest). The OPC server than, on change of the variable, (or if there is no change, the rate defined in the "Communication refresh rate [ms]" configurator is used) sends a message containing information regarding all changed variables (OPC system message PublishResponse).
After receipt of this message, the driver immediately sends the PublishRequest message again. This way the values of the variables of the PmaCommGroup object are being updated with defined period Communication refresh rate [ms].

Description of the "ItemID" configurator:
ItemId is the text identifier of the item that is used for addressing the value in the device. The "ItemID" configurator tells the driver how to receive or send the item value.
The text can be written manually, or it can be assembled in the window opened by the button to the right of the configurator.
Macro expression can be used for input (it is evaluated after starting the application).
The ItemId identifier may look like for example "ns2,str,xxxx", where:
- ns2: Specifies the ns=namespace of the OPC-UA server where the variable belongs (0, 1, 2 ...).
- str: Specifies the type of variable identifier.
str = The identifier of the variable is a text string.
nmb = The identifier of the variable is a number.
- xxxx: Variable identifier. This text depends only on the OPC-UA server.

Description of the "PmaCommGroup > Parameters > Special Parameters" configurator:
Time reading typeSpecifies whether the value time is also read along with the variable value from the OPC-UA server.
If the time is read then this time is saved into the PmVar.TimeSource property.
No - The time value will not be read.
Source - The source time will be read, i.e. the time that the OPC-UA server read from the connected device (if the server is able to read such time).
Server - The time of the value reading by the OPC-UA server will be read.

- New authentication option of the UserName type, (i.e. name and password must be entered).
- Fixed bug: After some time (e.g. after 5 minutes) this driver was restarted.
Pm9.00.15: Fixed bug: (Revision 2) Establishing connection with some types of OPC UA servers failed
Pm9.00.15: Fixed bug: Malfunction accured when the received communication message was divided into multiple submessages.
Pm9.00.13: Fixed bug: When writing into the variables in the PmaCommGroup object the communication was sometimes terminated.
Pm9.00.09: Created
PROMOTIC 9.0.18 SCADA system documentation - MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r. o.