I'm Trying to call a method from a OPC UA server device. this is the method: StartScan Method
It contains Two Arguments: InputArguments OutputArguments
I'm not able with my code:
from opcua import Client, ua
url = "opc.tcp://10.239.37.236:4840"
client = Client(url)
#client.set_user = "user"
#client.set_password = "pw"
client.connect()
print("client connected")
while True:
lsd = client.get_node("ns=4; i=6013")
LastScanData = lsd.get_value()
print(LastScanData)
start = client.get_node("ns=3; i=7009")
input_Arg = client.get_node("ns=3, i=6051")
res = start.call_method(input_Arg, ua.Variant(5, ua.VariantType.UInt32), ua.Variant(99, ua.VariantType.UInt32))
time.sleep(1)
Can someone help me? I'm new in OPC UA. Thanks.