FORUM CTRLX AUTOMATION
ctrlX World Partner Apps for ctrlX AUTOMATION
11-20-2023 04:28 PM
Hi everybody,
I want to write a (LREAL-)variable on the DataLayer via PLC-App (V2.2.0) using DL_WriteNode.
The variable is located in the OPC-UA Client part and is running on another OPC-UA Server (thats why I have no influence on the length of the path). See the DataLayer access in the picture below:
Yet the copid NodeName (sadly) has more than 255 characters (e.g. see below):
opcuaclient/OPC_UA_Server_KUKA/i=85/ns=2;i=5001/ns=7;i=5000/ns=7;i=5004/ns=8;s=ns=7%3Bi=5004??krlvar:/R1/CUSTOMER/OPCVARIABLEN/ns=8;s=ns=7%3Bi=5004??krlvar:/R1/CUSTOMER/OPCVARIABLEN#ApproachPath[]/ns=8;s=ns=7%3Bi=5004??krlvar:/R1/CUSTOMER/OPCVARIABLEN#APPROACHPATH[10]/ns=8;s=ns=7%3Bi=5004??krlvar:/R1/CUSTOMER/OPCVARIABLEN#APPROACHPATH[10].A1
Is there any chance to write the variable via PLC? Can I use another function? Is there a workaround? Am I missing sth.?
I have no issue writing the variable directly from the DataLayer.
Thx for the support 🙂
Solved! Go to Solution.
11-21-2023 01:23 PM - edited 11-21-2023 01:48 PM
It seems you are working with test versions of the OPC UA client app. Could you please confirm the version number?
How does your code look like for writing? What is the error that your DL_WriteNode is giving back when you try to write?
We did some tests with the example out of the CXA_DataLayer library using address strings up to 370 character and writing via DL_WriteNode was working fine. Beware that the data type of the value that should be written needs to fit to the target data type. Further more the address string variable needs to be big enough to be able to hold the complete string (standard string = 80 characters, string(1024) = 1024 characters). Please also do a complete download when data types are changed.
11-24-2023 07:53 AM
After a complete download it works just fine. Using online Change the string(xy) variable always was limited to 80 characters standard. Thx for the support!