使用Prosys的OPCUA服务器的过程中,
node = root.get_child(["0:Objects", "3:ServerInterfaces", "4:Server_Interface", "4:LifeBeat_PLC"])
var = True
node.set_value(var)
报错:opcua.ua.uaerrors._auto.BadWriteNotSupported: "The server does not support writing the combination of value, status and timestamps provided."(BadWriteNotSupported)
在github找到了解决方法:
node = root.get_child(["0:Objects", "3:ServerInterfaces", "4:Server_Interface", "4:LifeBeat_PLC"])
var = ua.DataValue(ua.Variant(True, ua.VariantType.Boolean))
hbnode.set_value(var)
github链接:https://github.com/FreeOpcUa/opcua-asyncio/issues/30