I need call a load a job method on a cognex camera OPCUA server that ignition is a client of to load a job named Final.Jobx
I am trying to use the system.opcua.callMethod() to load a job on a Camera.
Cognex documentation and screen shot from an example using a different opcua client below.
It is not clear on what the object id or method id are how would I find this.
I haven't done this specifically, but here's what I would look for...
You should be able to browse the OPC UA Server on the camera once you add the server to ignition using the OPC Quick Client in the Ignition Config. You should see 'Method' in the table.
You also might be able to pull in the OPC into the tags and grab the shortcut from there.
"Your Congex Server",
"ns=0;s=12341", #camera number or group that the camera is in
"ns=0;i=LoadJob", #might be an integer instead of 'LoadJob' look at the OPC client
Thank you for your reply. The confusing part is that the camera is the the server so not sure what the object node ID means in this case.
Below is what what can be seen when browsing in OPCUA server
Looks like all methods are showing as folders and have an OPC tag to read the InputArguments.
Don't really unders
If you don't have the NodeIds via some kind of documentation the easiest way to figure it out, unfortunately, is to connect to the server using UaExpert and go find the method, then make note of its parent Object's NodeId as well.
UaExpert was helpful thank you @Kevin.Herron
To load a job on an insight camera the following works.
system.opcua.callMethod("OPC UA server name","ns=2;s=System","ns=2;s=LoadJob", ['NameOfJob.jobx'] )