My name is Martin Boers and I work in
Technical Customer Services at Phoenix Contact.
This video shows how to set up and
connect the OPC UA server in a PLCnext Control.
Open your project in PLCnext Engineer.
In the "PLANT" view double-click on "OPC UA".
In the basic settings choose the
visibility of variables.
By default no variables will be visible through the OPC UA server.
Check the Security settings.
The OPC UA server requires a security
certificate.
This can be provided by the user...
...or generated automatically by the PLC...
...or obtained from a "Global Discovery Server" (GDS).
In this case select the second
option.
Further security certificate configuration 
can be made below.
Various security policies can also be
set here.
Note that it is the users responsibility to select the appropriate security configuration for each application.
Now open the PLC data list.
Double-click on the controller.
Unhide the columns related to the PLC variables.
The variable window can be expanded if needed.
Select which variables should be accessible through the OPC server.
Write the project to the controller.
We will now test the OPC UA server function 
using "UaExpert" software from Unified Automation.
In UaExpert add a new server.
Enter the IP address of the connected PLC.
Use the Discovery Service
to select one of the available security policies.
Confirm the hostname change
when prompted.
Authenticate with the "admin" user.
Now connect to the server.
The default password is printed on the
PLC housing.
Available OPC variables will appear in the address space.
Drag system variables and program variables into the data access view.
Check that the values are updating.
