Difference between revisions of "SmartRobotinoMasterRPCBridge"

From RobotinoWiki
(/data/mclayout)
(/data/mclayout)
Line 30: Line 30:
 
====/data/status====
 
====/data/status====
 
====/data/mclayout====
 
====/data/mclayout====
 +
The example shows e path network with two pathes (path 1 and path 2). Each path contains 3 nodes. id 0,1,2 are the nodes of path 1 and id 3,4,5 the nodes of path 2.
 
<pre>
 
<pre>
 
{
 
{
  "path" :
+
    "DATA": [
  {
+
        {
  }
+
            "id": 0,
 +
            "path": 1,
 +
            "pose": 0,
 +
            "x": -1.77,
 +
            "y": 2.22
 +
        },
 +
        {
 +
            "id": 1,
 +
            "path": 1,
 +
            "pose": 0,
 +
            "x": -0.03,
 +
            "y": 1.65
 +
        },
 +
        {
 +
            "id": 2,
 +
            "path": 1,
 +
            "pose": 0,
 +
            "x": 1.64,
 +
            "y": 0.2
 +
        },
 +
        {
 +
            "id": 3,
 +
            "path": 2,
 +
            "pose": 0,
 +
            "x": -2.39,
 +
            "y": -1.73
 +
        },
 +
        {
 +
            "id": 4,
 +
            "path": 2,
 +
            "pose": 0,
 +
            "x": -1.11,
 +
            "y": -1.88
 +
        },
 +
        {
 +
            "id": 5,
 +
            "path": 2,
 +
            "pose": 0,
 +
            "x": 0.34,
 +
            "y": -1.65
 +
        }
 +
    ]
 
}
 
}
 
</pre>
 
</pre>

Revision as of 09:46, 20 July 2020

REST API

SmartRobotinoMasterRPCBridge listens at port 8153 for incoming connections to its REST API.

GET methods

/localizationMap

Returns the current localization map as PNG image with resolution information.

PNG Header | PNG Data | 00 | JSON Data

JSON Data:
rootObj["datasize"] = mapData.size();
rootObj["width"] = width;
rootObj["height"] = height;
rootObj["resolution"] = resolution;
rootObj["offsetx"] = offsetx;
rootObj["offsety"] = offsety;

/navigationMap

Returns the current navigation map as PNG image with resolution information. See localizationMap.

/map-preview

Returns a preview image as PNG of map file name.

http://127.0.0.1:8153/map-preview?name:NewMap

/data/station-types

/data/status

/data/mclayout

The example shows e path network with two pathes (path 1 and path 2). Each path contains 3 nodes. id 0,1,2 are the nodes of path 1 and id 3,4,5 the nodes of path 2.

{
    "DATA": [
        {
            "id": 0,
            "path": 1,
            "pose": 0,
            "x": -1.77,
            "y": 2.22
        },
        {
            "id": 1,
            "path": 1,
            "pose": 0,
            "x": -0.03,
            "y": 1.65
        },
        {
            "id": 2,
            "path": 1,
            "pose": 0,
            "x": 1.64,
            "y": 0.2
        },
        {
            "id": 3,
            "path": 2,
            "pose": 0,
            "x": -2.39,
            "y": -1.73
        },
        {
            "id": 4,
            "path": 2,
            "pose": 0,
            "x": -1.11,
            "y": -1.88
        },
        {
            "id": 5,
            "path": 2,
            "pose": 0,
            "x": 0.34,
            "y": -1.65
        }
    ]
}

/data/mcstatus

/data/localizationMode

/data/smartnavigationplan

/data/smartlocations

/data/smartstations

/data/smartrobotinfo

/data/pathnetwork

/data/smartjoblist

/data/fleetcomResponse

/data/mapDirInfo

PUT methods

/data/navigationMap

/data/fleetcomRequest

/data/SetDefaultMap

/data/DeleteMap