Difficulty with Methods #1654
jeff-latray
started this conversation in
General
Replies: 1 comment
-
|
Double check your NodeIds or set a breakpoint in This is the only place |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Using milo 1.6 I have a server that is successfully publishing values. I have a client I am using to test with that can successfully read values.
I am now trying to get some methods working and am having trouble. Scaled it down to just a ping so that I can call a method on the server with out parameters.
The client can see the method nodes by browsing through the nodes but if I try to call the method I am getting this
error:StatusCode[name=Bad_MethodInvalid, value=0x80750000, quality=bad]Logging from Browsing:
16:42:25.456 [main] io.elexity.opcuaclient.EbcOpcUaClient - Connected to opc.tcp://192.168.64.6:12686/EbcRoot 16:42:25.457 [main] io.elexity.opcuaclient.EbcOpcUaClient - Found namespace 'urn:io:elexity:ebc' at index 1 16:42:25.466 [main] io.elexity.opcuaclient.EbcOpcUaClient - Top node browse name: EbcRoot 16:42:25.468 [main] io.elexity.opcuaclient.EbcOpcUaClient - Ping (Method) 16:42:25.468 [main] io.elexity.opcuaclient.EbcOpcUaClient - balanceString (Method)This is the client code I have for calling the method:
`
NodeId objectId = new NodeId(namespaceIndex, "EbcRoot"); // parent folder of method
NodeId methodId = new NodeId(namespaceIndex, "PingMethod");
// Build the CallMethodRequest
CallMethodRequest request = new CallMethodRequest(
objectId,
methodId,
new Variant[0]
);
`
This is the server side code I have for the method:
`
public class OpcUaPingCommand {
private static Logger logger = LogManager.getLogger();
private final UaNodeContext cNodeContext;
private final UaFolderNode cParentFolder;
private final int cNamespaceIndex;
}
`
Beta Was this translation helpful? Give feedback.
All reactions