From 56189d78e0198f219e2ec00e48bc6a203f47581a Mon Sep 17 00:00:00 2001 From: Kimdiego2098 <2248356998@qq.com> Date: Wed, 4 Oct 2023 17:12:47 +0800 Subject: [PATCH] update opcuaclient --- .../OPCUAClient/OPCUAClient.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/framework/Foundation/ThingsGateway.Foundation.Adapter.OPCUA/OPCUAClient/OPCUAClient.cs b/framework/Foundation/ThingsGateway.Foundation.Adapter.OPCUA/OPCUAClient/OPCUAClient.cs index 9f7249c08..ec256c8df 100644 --- a/framework/Foundation/ThingsGateway.Foundation.Adapter.OPCUA/OPCUAClient/OPCUAClient.cs +++ b/framework/Foundation/ThingsGateway.Foundation.Adapter.OPCUA/OPCUAClient/OPCUAClient.cs @@ -682,7 +682,7 @@ public class OPCUAClient : IDisposable } NodeId nodeToRead = new(nodeIdStr); - var node = (VariableNode)await ReadNodeAsync(nodeToRead, NodeClass.Variable, false, cancellationToken); + var node = (VariableNode)await ReadNodeAsync(nodeToRead, NodeClass.Unspecified, false, cancellationToken); await typeSystem.LoadType(node.DataType, true, false); _variableDicts.AddOrUpdate(nodeIdStr, node); return node; @@ -784,6 +784,8 @@ public class OPCUAClient : IDisposable attributeId == Attributes.Description || attributeId == Attributes.RolePermissions || attributeId == Attributes.UserRolePermissions || + attributeId == Attributes.DataTypeDefinition || + attributeId == Attributes.AccessLevelEx || attributeId == Attributes.UserWriteMask || attributeId == Attributes.WriteMask) {