Siemens SIMATIC ET 200AL System Manual page 1401

Distributed i/o system
Hide thumbs Also See for SIMATIC ET 200AL:
Table of Contents

Advertisement

OPC UA communication
9.3 Using the S7-1500 as an OPC UA server
Implementing a server method
A program (function block) for implementing a server method is structured as follows:
1. Querying the server method call with OPC_UA_ServerMethodPre
You first call the "OPC_UA_ServerMethodPre" instruction in your user program (i.e. in your
server method).
This instruction has the following tasks:
– With this instruction you ask the OPC UA server of the CPU whether your server method
– If the method was called and the server method has input parameters, your server
2. Editing the server method
In this section of the server method, you provide the actual user program.
You have the same options as in any other user program (for example, access to other
function blocks or global data blocks).
If the server method uses input parameters, these parameters are available to you.
This section of the server method should only be executed if an OPC UA client has called
the server method.
After successful execution of the method, you set the output parameters of the server
method if the method has output parameters.
3. Responding to server method with OPC_UA_ServerMethodPost
To complete the server method, call the "OPC_UA_ServerMethodPost" instruction.
Use the parameters to notify the "OPC_UA_ServerMethodPost" instruction whether or not
the user program has been processed.
If the user program has been successfully executed, the OPC UA server is notified via the
relevant parameters. The OPC UA server then sends the output parameters of the server
method to the OPC UA client.
Always call the instructions "OPC_UA_ServerMethodPre" and "OPC_UA_ServerMethodPost" as
a pair irrespective of whether the user program is processed by both instructions or
continued in the next cycle.
You will find an example of a server method implementation in the STEP 7 online help.
280
was called from an OPC UA client.
method now receives the input parameters.
The input parameters of the server method come from the calling OPC UA client.
Function Manual, 05/2021, A5E03735815-AJ
Communication

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents