Trouble with system.opc.readValue reading values from folders (Kymera SNMP Driver)

Hello, I’m trying to read a value from OPC with this simple script:

server = “Ignition OPC UA Server”
path = “[0430-NET-0113]ifType[10101]”
value = system.opc.readValue(server, path)
print value

The tag has data in it:
image
But every time the script throws a “GatewayException: Read timed out” after executing for a while.
I can read OPC values from this device that are not in a folder, but not these.

Is there something wrong with my syntax?

Our OPC-UA server name is Ignition OPC-UA Server (note the hyphen). In our case that name is the result of several years worth of upgrades, but you might check that the name matches.

I tired it with the hyphen, but it came back with “Error_Configuration”.
When I search for a tag that is not within a folder:

server = “Ignition OPC UA Server”
path = “[0430-NET-0113]sysUpTime”
value = system.opc.readValue(server, path)
print value

It has no problem reading the value, but it times out when trying to read the other tag.

Try adding the ns=1;s= prefix to your path.

One other note your print value should be print value.value

I tired that, and it still times out…

However it works fine with the other tag: “ns=1;s=[0430-NET-0113]sysUpTime”, still reads the value…

Can you try to browse for this tag in the OPC server and then drag that element into your tag folder. Then compare the path in that tag to your script?

Just did it:
image
As far as I can tell, it’s the same path…

Is this PLC an Allen Bradley? Is that array’s External Access set to none?

This is a Cisco 2960-XR switch. The tags are coming from Kymera’s “SNMP Driver”.

I do have an Allen Bradley though. I tried reading a value within a folder from it and had no problem doing so with this path (copy/pasted from OPC browse):

path = “[Allen Bradley PLC]Program:MainProgram.TEST_PLC_CLK_SECOND.VALUE”

The syntax within OPC seems to be different depending on the driver.
Perhaps it is an issue with Kymera’s module…

I would lean towards this being a Kymera issue as well… contact them and see if there are any loggers you can enable to that would show what’s happening when the driver receives the read call.