Using the "simple" TCP interface
In this section, we will allow you to have a simple text-based access to the repository, using a TCP connection. The first you have to do is to add the module
You can use this module also if you need basic access to a running RAgent or RConsole from an external program.
This module allows bare-bone access to the repository: the client can read or set property values by specifying their path.
Running the agent will start the simple TCP interface server, that will listen on port 9876 (the port can be changed using a property of the module). Only one client can connect at a time. When the client closes the connection, the module starts waiting for the next one.
|list of supported commands||prints the list of supported commands|
|returns the value of the specified property|
|sets the value of the specified property|
|returns a list of all the properties, each on a single line|
|returns a list of all the properties starting with prefix, each on a single line|
|retrieves an image (format can be jpeg, jpg, rdk); image data follows|
|retrieves a map image (format can be jpeg, jpg, rdk); image data follows|
All commands may return an error message. All error messages start with the word "
As an alternative to
telnet you can use the
rdk-simpletcpclient, provided by OpenRDK. It works basically like telnet, but when you ask for an image or a map, it will show it using ImageMagick (that need to be installed for this feature to work).