Last updated on April 10, 2022
Use an OPC UA client to connect to the server and verify successful application of the UANodeSet.
This Post is part of the OPC UA Information Model Tutorial.
Determine the OPC UA server’s IP address
Determine the IP address of the OPC UA server (i.e. the Debian machine) with ifconfig
sudo ifconfig [sudo] password for user: eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 172.17.79.121 netmask 255.255.255.240 broadcast 172.17.79.127 [...]
The OPC UA client will connect to that IP address in the following steps. Alternatively you can also use opc.tcp://localhost:4840
if the server is running locally, or you can use the corresponding hostname instead of localhost.
Connecting to a server with UAExpert
As a final result, the OPC UA client UAExpert should display the model in the server’s address space like so:

UA Expert is an OPC UA client developed by Unified Automation.
Download (free account required): https://www.unified-automation.com/downloads/opc-ua-clients.html

Select Custom Discovery and add the IP address of the Debian server.

The new server will be listed at Custom Discovery. Click/Expand it.
Note: You may see a dialog pop-up

Click Yes
and move on.
You will now see the server and the different communication modes it supports. Select None – None (no encryption, no authentication) and press OK
.

Note: You may be presented with a pop-up dialog regarding Recently Used servers.

Click OK
.
You are now connected to the OPC UA server and can browse or monitor its object. UAExpert allows to individually (dis-)connect to multiple servers at the same time.

The top area of the follwoing image shows UAExpert connected to the open62541 server on Debian. At the bottom, you can see the PowerShell SSH session to the Debian server running the OCP UA server ./myServer
. The log of pane of UAExpert and the console output of the open62541 server should corelate.

Hi,
I am writing a custom Client program to access data from a custom Information Model of a robot defined in SiOME software. I have a OPC UA server up and running .
And within UAExpert I can see that the Nodes I wish to READ/WRITE have the following access levels. I understand this status is the default for all the nodes defined in my Server.
AccessLevel = CurrentRead
UserAccessLevel = CurrentRead
I wanted to know how to change the accesslevel to READ and WRITE. Any suggestions on this would be helpful.
I would eventually like to link my Information Model with data from Robot simulator.
Thanks in advance.
Hi,
it may be an issue with the model that you generated with SiOME, which seems to be a proprietary product. Utilize the appropriate forums and support channels to get help.
Hello audupi,
from server side the why to change accessLevel and userAccessLevel is use appropriate mask when define attribute for a Variable node. For example;
attr = UA_VariableAttributes_default;
UA_Variant_setScalarCopy(&attr.value, &myInt16Min, &UA_TYPES[UA_TYPES_INT16]);
strcpy(varString, “the.answer”);
strcat(varString, “.Int16Min”);
attr.description = UA_LOCALIZEDTEXT_ALLOC(“en-US”,varString);
attr.displayName = UA_LOCALIZEDTEXT_ALLOC(“en-US”,varString);
attr.accessLevel = UA_ACCESSLEVELMASK_READ | UA_ACCESSLEVELMASK_WRITE;
attr.userAccessLevel = UA_ACCESSLEVELMASK_READ | UA_ACCESSLEVELMASK_WRITE;
myNodeId = UA_NODEID_STRING_ALLOC(1, varString);
myName = UA_QUALIFIEDNAME_ALLOC(1, varString);
parentNodeId = UA_NODEID_NUMERIC(0, UA_NS0ID_OBJECTSFOLDER);
parentReferenceNodeId = UA_NODEID_NUMERIC(0, UA_NS0ID_ORGANIZES);
UA_Server_addVariableNode(server, myNodeId, parentNodeId,
parentReferenceNodeId, myName,
UA_NODEID_NULL, attr, NULL, NULL);
Hi,
I am trying to connect B&R 3.09 OPC server with UAExpert. But it is showing “Bad Communication” while trying to connect. OPC server is enable in program, along with also check IP address, subnet etc but still not able to connect.
This PLC is already sharing data with kepserver opc ua configuration manager but able to connect with UAExpert.
Kindly support to resolve the same.
Hi,
if you use B&R 3.09 I assume [1] it is running an OPC Server, which is _NOT_ an OPC UA server [2]. Read more here [3]. Please verify this assumption on your own or with B&R.
Based on this assumption, I think you will not be able to connect with UaExpert, because this client can only communicate with OPC UA servers, not OPC servers.
You need an OPC client instead. Try to use one from this list here maybe:
https://www.opcconnect.com/freecli.php
If you already use kepware servers, you should have access to an OPC Testclient as well.
Good luck!
[1] https://www.br-automation.com/downloads_br_productcatalogue/BRP44400000000000000317870/AR_SG4_R3.09_RevInfoE.pdf
[2] Automation Runtime 3.09 is quite old! If possible, try to upgrade to a 4.x version
[3] https://opcfoundation.org/about/opc-technologies/opc-classic/