Universal Robots Forum

Using packetstream with xmlrpc

Hello everybody,
I will briefly explain my problem.

I a trying to setup a xmlrpc client using packetstream (and not http) protocol. My server is written in C++ and is using the pStream version, according to this library http://xmlrpc-c.sourceforge.net/.
I need to use remote procedure calls both in URscript directly and in Java.
In Java I have created a class that set up the connection and handles the different functions that I need to use:

public XMLRPCInterface(String host, int port) {

    XmlRpcClientConfigImpl config = new XmlRpcClientConfigImpl();
    config.setEnabledForExceptions(true);

    try {
         config.setServerURL(new URL(host  + ":" + port));  // NO HTTP SINCE WE ARE GOING TO USE UPSTREAM SERVER
    }  catch (MalformedURLException e) {
         e.printStackTrace();
   }

   config.setConnectionTimeout(1000);
   client = new XmlRpcClient();
  client.setConfig(config);
}

With this code I get MalformedUrlException :no protocol 10.0.2.2:1237
Cannot say if also in URscript part I have a problem since my program stops here, anyway I really think so.

I have found an other user claiming that using pstream server is possible and complaining about this kind of errors some years ago but unfortunately nobody found a solution.

Many thanks for your help

1 Like

Any idea?
I tested with http and abyss server and everything is working properly.