close
OpenRTLS
OpenRTLS
Search

Software:JsonCommands

Contents

API Interface (version 16040600)

There are two network channels which is used for interfacing with the high level application

  • Service (SVC) - the communication is over TCP or UDP port 8784 in JSON format. The master responds to the requests from the client applications or sends statistics data when this function is enabled
  • Location (LS) - the communication is over UDP and is sent only from the master to LS listener address at UDP port 8787 in JSON or TLV formats

Service data

A basic JSON command without parameters

{"command":"commandName"}

A JSON command with parameter

{"command":"commandName","attribute":"value"}

Response to a command

{"response":"commandName","status":"ok","attribute":"value"}

Status can have the following values

  • ok
  • in progress
  • error

If an error occured, the response will contain an error description.

Service commands, their parameters and return values are described later in this documentation.

Location data

The data sent out can be in the following formats

  • JSON (default) - readable format - easier for human but is not convenient when the system is running at higher refresh rate
  • TLV - binary format - necessary when high density and/or high refresh rate is used

JSON output data (UDP)

A basic JSON output location message

{"id":"0xDECA343036200653","timestamp":1459890647.818,"msgid":6364}

TWR JSON message

A message containing coordinates and measurements of a Tag in TWR mode
Examples

{
  "id": "0xDECA343036200653",
  "timestamp": 1459933834.145,
  "msgid": 1638,
  "coordinates": {
    "x": 4.481,
    "y": 1.868,
    "z": 0.831,
    "heading": 0,
    "pqf": 95
  },
  "meas": [
    {
      "anchor": "0xDECA313032602090",
      "dist": 1.152,
      "tqf": 1,
      "rssi": -78
    },
    {
      "anchor": "0xDECA303033300BFA",
      "dist": 2.384,
      "tqf": 1,
      "rssi": -76.5
    },
    {
      "anchor": "0xDECA343034900C23",
      "dist": 2.581,
      "tqf": 1,
      "rssi": -77
    },
    {
      "anchor": "0xDECA353030600AE0",
      "dist": 3.391,
      "tqf": 1,
      "rssi": -78.5
    },
    {
      "anchor": "0xDECA343034500C48",
      "dist": 4.788,
      "tqf": 1,
      "rssi": -80
    }
  ]
}

TDOA JSON message

A message containing coordinates and measurements of a Tag in TDOA mode
Examples

{
  "id": "0xDECA343036200653",
  "timestamp": 1459890901.268,
  "msgid": 11430,
  "coordinates": {
    "x": 3.582,
    "y": 6.048,
    "z": 1.031,
    "heading": 0,
    "pqf": 95
  },
  "meas": [
    {
      "anchor": "0xDECA333033902063",
      "toa": 15.539390696161,
      "tqf": 1,
      "rssi": -79.5
    },
    {
      "anchor": "0xDECA303033300BFA",
      "toa": 15.539390720794,
      "tqf": 1,
      "rssi": -77
    },
    {
      "anchor": "0xDECA353033500C1E",
      "toa": 15.539390718212,
      "tqf": 1,
      "rssi": -77
    },
    {
      "anchor": "0xDECA313034114368",
      "toa": 15.539390732187,
      "tqf": 1,
      "rssi": -79
    }
  ]
}

User data JSON message

A message containing user data uploads from a Tag

User data contain the following fields:

  • type - user specific type
  • raw - hex string with user data payload

Maximum user data payload is limited to 32 bytes.


Examples

{
    ...
    "userData":{"type":0,"raw":"0x1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F1F"}
    ...
}

Sensor data JSON message

A message containing sensor data upload from a Tag

Sensor data contain the following fields:

  • nodeStatus
    • activity - Tag specific activity code
    • match - TBD
    • io - IO pins status
    • vbat - Battery voltage
  • quaternion - IMU quaternion status
  • temperature - Tag temperature


Examples

{
    ...
    "sensors":{
        "nodeStatus":{
            "activity":2,
            "match":0,
            "io":"0xFF",
            "vbat":54
        },
    "quaternion":[0.123000,0.123000,0.123000,0.123000],
    "temperature":23.1
    ...
}

Maximum sensor data payload is limited to 32 bytes.

TLV output data (UDP)

TLV stands for "Type Length Value" and it is a binary alternative to JSON. The Type and Length fields are of fixed size while the Value is of variable size. The Value can contain arbitrary data or stream of other TLV elements.

  • Type - contains data type and has fixed size of 1 Byte
  • Length - contains length of the following data and has fixed size of 1 Byte
  • Value - contains data of the size described by the Length field (in little-endian format)

TLV messages

TLV stands for "Type Length Value" and it is binary alternative to JSON. Type and length fields are fixed size, and value is variable size. Value can contain arbitrary data or stream of other TLV elements.

  • Type - contain data type code number, and has fixed size of 1 Byte
  • Length - contain length of following data field or stream, and has fixed size of 1 Byte
  • Value - contains data field of Type, and has variable size

RTLS TLV types

Generic
Type Data type Data length (Bytes) Description
1 uint64 8 Node ID
2 double 8 Timestamp
3 uint32 4 Message ID
4 variable N Measurements
5 variable N User data
6 variable N Sensor data
7 variable N Sensor raw data
8 variable N Coordinates
Measurements
Type Data type Data length (Bytes) Description
40 uint64 8 Anchor ID
41 float 4 Measured distance
42 uint8 1 Time Quality Factor (TQF)
43 int16 2 Received Signal Strength Indicator (RSSI)
44 double 8 Measured Time of Arrival (TOA)
User data
Type Data type Data length (Bytes) Description
50 uint8 1 User data type
51 variable N User data raw
Sensor data
Type Data type Data length (Bytes) Description
60 uint8 1 Activity
61 uint8 1 Matching
62 uint8 1 IO
63 float 4 Vbat
64 float 4 Quaternion 0
65 float 4 Quaternion 1
66 float 4 Quaternion 2
67 float 4 Quaternion 3
68 float 4 Temperature
Sensor raw data
Type Data type Data length (Bytes) Description
70 int16 2 Accel. X
71 int16 2 Accel. Y
72 int16 2 Accel. Z
73 int16 2 Gyro X
74 int16 2 Gyro Y
75 int16 2 Gyro Z
76 int16 2 Magnetometer X
77 int16 2 Magnetometer Y
78 int16 2 Magnetometer Z
Coordinates
Type Data type Data length (Bytes) Description
80 float 4 X coordinate
81 float 4 Y coordinate
82 float 4 Z coordinate
83 float 4 Heading
84 uint8 1 Position Quality Factor (PQF)

Examples

The following TLV stream contains data from

  • 5 anchors
  • 2 tags
01 08 53 06 20 36 30 34 CA DE 02 08 AE 47 39 E6 34 C1 D5 41 03 04 B6 17 00 00 08 1B 50 04 F3 EE
93 40 51 04 22 95 D2 3F 52 04 00 00 00 00 53 04 00 00 00 00 54 01 61 04 19 28 08 90 20 60 32 30
31 CA DE 29 04 E6 B8 97 3F 2A 01 02 2B 04 00 00 9B C2 04 19 28 08 FA 0B 30 33 30 30 CA DE 29 04
20 60 02 40 2A 01 01 2B 04 00 00 9A C2 04 19 28 08 23 0C 90 34 30 34 CA DE 29 04 C1 F5 29 40 2A
01 01 2B 04 00 00 9B C2 04 19 28 08 E0 0A 60 30 30 35 CA DE 29 04 40 A6 59 40 2A 01 01 2B 04 00
00 9F C2 04 19 28 08 48 0C 50 34 30 34 CA DE 29 04 27 83 99 40 2A 01 01 2B 04 00 00 9F C2 01 08
57 06 20 36 30 39 CA DE 02 08 10 58 39 E6 34 C1 D5 41 03 04 B7 17 00 00 08 1B 50 04 2C 38 AF 40
51 04 AA AC AB 3F 52 04 00 00 00 00 53 04 00 00 00 00 54 01 61 04 19 28 08 90 20 60 32 30 31 CA
DE 29 04 3C FC BA 3F 2A 01 01 2B 04 00 00 A0 C2 04 19 28 08 FA 0B 30 33 30 30 CA DE 29 04 1B FE
C6 3F 2A 01 01 2B 04 00 00 99 C2 04 19 28 08 23 0C 90 34 30 34 CA DE 29 04 29 F7 32 40 2A 01 01
2B 04 00 00 9F C2 04 19 28 08 E0 0A 60 30 30 35 CA DE 29 04 29 ED 74 40 2A 01 02 2B 04 00 00 A0
C2 04 19 28 08 63 20 90 33 30 33 CA DE 29 04 70 C4 A1 40 2A 01 01 2B 04 00 00 9F C2 

The decomposition of the stream into TLV elements.

  • Location data of the first tag:
Type[1] len: 8  = 0xDECA343036200653
Type[2] len: 8  = 1459934104.895000
Type[3] len: 4  = 6070
Type[8] len: 27  = 50 04 F3 EE 93 40 51 04 22 95 D2 3F 52 04 00 00 00 00 53 04 00 00 00 00 54 01 61 
	x:4.622919	y:1.645176	z:0.000000	heading:0.000000	pqf:97
Type[4] len: 25  = 28 08 90 20 60 32 30 31 CA DE 29 04 E6 B8 97 3F 2A 01 02 2B 04 00 00 9B C2 
	anchor:0xDECA313032602090	dist:1.185330	TQF:2	RSSI:-77.5
Type[4] len: 25  = 28 08 FA 0B 30 33 30 30 CA DE 29 04 20 60 02 40 2A 01 01 2B 04 00 00 9A C2 
	anchor:0xDECA303033300BFA	dist:2.037117	TQF:1	RSSI:-77.0
Type[4] len: 25  = 28 08 23 0C 90 34 30 34 CA DE 29 04 C1 F5 29 40 2A 01 01 2B 04 00 00 9B C2 
	anchor:0xDECA343034900C23	dist:2.655625	TQF:1	RSSI:-77.5
Type[4] len: 25  = 28 08 E0 0A 60 30 30 35 CA DE 29 04 40 A6 59 40 2A 01 01 2B 04 00 00 9F C2 
	anchor:0xDECA353030600AE0	dist:3.400772	TQF:1	RSSI:-79.5
Type[4] len: 25  = 28 08 48 0C 50 34 30 34 CA DE 29 04 27 83 99 40 2A 01 01 2B 04 00 00 9F C2 
	anchor:0xDECA343034500C48	dist:4.797260	TQF:1	RSSI:-79.5
  • Location data of the second tag:
Type[1] len: 8  = 0xDECA393036200657
Type[2] len: 8  = 1459934104.896000
Type[3] len: 4  = 6071
Type[8] len: 27  = 50 04 2C 38 AF 40 51 04 AA AC AB 3F 52 04 00 00 00 00 53 04 00 00 00 00 54 01 61 
	x:5.475607	y:1.341207	z:0.000000	heading:0.000000	pqf:97
Type[4] len: 25  = 28 08 90 20 60 32 30 31 CA DE 29 04 3C FC BA 3F 2A 01 01 2B 04 00 00 A0 C2 
	anchor:0xDECA313032602090	dist:1.460823	TQF:1	RSSI:-80.0
Type[4] len: 25  = 28 08 FA 0B 30 33 30 30 CA DE 29 04 1B FE C6 3F 2A 01 01 2B 04 00 00 99 C2 
	anchor:0xDECA303033300BFA	dist:1.554630	TQF:1	RSSI:-76.5
Type[4] len: 25  = 28 08 23 0C 90 34 30 34 CA DE 29 04 29 F7 32 40 2A 01 01 2B 04 00 00 9F C2 
	anchor:0xDECA343034900C23	dist:2.796335	TQF:1	RSSI:-79.5
Type[4] len: 25  = 28 08 E0 0A 60 30 30 35 CA DE 29 04 29 ED 74 40 2A 01 02 2B 04 00 00 A0 C2 
	anchor:0xDECA353030600AE0	dist:3.826975	TQF:2	RSSI:-80.0
Type[4] len: 25  = 28 08 63 20 90 33 30 33 CA DE 29 04 70 C4 A1 40 2A 01 01 2B 04 00 00 9F C2 
	anchor:0xDECA333033902063	dist:5.055229	TQF:1	RSSI:-79.5

JSON service commands

checkFwUpdate

Force the master to restart and check for new firmware. After a successful update, all anchors and tags will be updated automatically.
Parameters
None
Return value
Status of the command.
Examples

{"command":"checkFwUpdate"}

returns

{"response":"checkFwUpdate","status":"in progress"}

discoverLegacy

Run discovery of legacy nodes. Please use this command in case the node did not connect and contains either FW loader or FW older than 16040600. The legacy discovery is done also automatically during the start of the master.
Parameters
None
Return value
Status of the command.
Examples

{"command":"discoverLegacy"}

returns

{"response":"discoverLegacy","status":"in progress"}

forceFwUpdate

Force a node (master, anchor or tag) to run firmware update, even if the node's FW version is already up-to-date.
Parameters

  • id (mandatory) - ID of a node (0xDECAXXXXXXXXXXXX)


Return value
Status of the command.
Examples

{"command":"forceFwUpdate", "id":"0XFFFFFFFFFFFFFFFF"}

returns

{"response":"forceFwUpdate","status":"in progress"}

getClusterPool

Get cluster pool.
Parameters
None
Return value
Cluster pool of the system.
Examples

{"command":"getClusterPool"}

returns

{"response":"getClusterPool","status":"ok","frames":1,"seats":16,"seatsize":3,"free":"0x00007FFF","mask":"0x0000FFFF"}

getDetails

Obtain details of a node identified by ID.
Parameters

  • id (mandatory) - ID of a node (0xDECAXXXXXXXXXXXX)


Return value
Node details.
Examples

{"command":"getDetails", "id":"0xDECA313034114368"}

returns

{
  "response": "getDetails",
  "status": "ok",
  "id": "0xDECA313034114368",
  "nodeDetails": {
    "hwVersion": "0xA3CC0CE0",
    "ldrfwVersion": "0x15022400",
    "fwVersion": "0x16040600",
    "nodeOptions": "0x1F01360F"
  },
  "coordinates": {
    "x": 1,
    "y": 2,
    "z": 3,
    "heading": 0,
    "pqf": 0
  }
}

getDist

Obtain distances between the given anchor and other anchors in its range.
Parameters

  • id (mandatory) - ID of an Anchor (0xDECAXXXXXXXXXXXX)


Return value
Distances between the given anchor and other anchors in its range:

  • dist - distance from the anchor in meters
  • tqf - time quality factor
  • rssi - receive signal strength indicator in dB


Examples

{"command":"getDist", "id":"0xDECA313034114368"}

returns

{
  "response": "getDist",
  "status": "ok",
  "id": "0xDECA313034114368",
  "distances": [
    {
      "anchor": "0xDECA303033300BFA",
      "dist": 4.892,
      "tqf": 1,
      "rssi": -79.5
    },
    {
      "anchor": "0xDECA333033902063",
      "dist": 8.015,
      "tqf": 2,
      "rssi": -83
    },
    {
      "anchor": "0xDECA353033500C1E",
      "dist": 3.472,
      "tqf": 1,
      "rssi": -79
    }
  ]
}

getDnsConfig

Get DNS server address used by the master.
Parameters
None
Return value
DNS server address used by the master.
Examples

{"command":"getDnsConfig"}

returns

{"response":"getDnsConfig","status":"ok","serverIpAddr":"8.8.8.8"}

getIpConfig

Get current IP configuration of the master.
Parameters
None
Return value
IP configuration of the master.
Examples

{"command":"getIpConfig"}

returns

{"response":"getIpConfig","status":"ok","ip":"10.0.0.46","gw":"10.0.0.138","mask":"255.255.255.0"}

getNtpConfig

Get NTP server address used by the master.
Parameters
None
Return value
NTP server address used by the master.
Examples

{"command":"getNtpConfig"}

returns

{"response":"getNtpConfig","status":"ok","serverIpAddr":"216.239.32.15"}

getLsListener

Obtain type and address of the current Location Server listener (RTLS client application).
Parameters
None
Return value
Listener's address to which the Location Server publish the data to.
Examples

{"command":"getLsListener"}

returns

{"response":"getLsListener","status":"ok","mode":"unicast","ip":"10.0.0.3"}

getOutDataFormat

Obtain output data format of messages pushed by Location Server.
Parameters
None
Return value
Output data format pushed by the Location Server. Currently supported formats:

  • json
  • tlv


Examples

{"command":"getOutDataFormat"}

returns

{"response":"getOutDataFormat","status":"ok","outDataFormat":"tlv"}

getPos

Obtain actual position of a node identified by ID.
Parameters

  • id (mandatory) - ID of a node (0xDECAXXXXXXXXXXXX)


Return value
Actual position of the node.
Examples

{
  "command": "getPos",
  "id": "0xDECA313034114368"
}

returns

{
  "response": "getPos",
  "status": "ok",
  "id": "0xDECA313034114368",
  "coordinates": {
    "x": 1,
    "y": 2,
    "z": 3,
    "heading": 0,
    "pqf": 0
  }
}

getStats

Get statistics of a node.
Parameters

  • id (optional) - ID of a node (0xDECAXXXXXXXXXXXX). If no parameter is given, statistics of the master will be returned.
  • period (optional) - period of statistics collection from the node(s) in micro-seconds.


Return value
Statistics of the node(s) are returned one time or periodically depend on the period value.
Examples

{"command":"getStats","id":"0xffffffffffffffff","period":"1000000"}

returns

{"response":"getStats","status":"ok","id":"DECA333033902063","uptime":338,"memFree":65940,"cpuLoad":0.320,
"tdoaCnt":0,"twrCnt":6703,"twrErrCnt":0,"reportsSent":6503,"tsyncCnt":6704,"dwVbat":3.258,"dwTemp":48.590}

getSyslogLevel

Get syslog level of the master.
Parameters
None
Return value
Syslog level of the master.
Examples

{"command":"getSyslogLevel"}

returns

{"response":"getSyslogLevel","status":"ok","level":0}

getTdmaScheme

Get TDMA scheme.
Parameters
None
Return value
TDMA scheme of the system.
Examples

{"command":"getTdmaScheme"}

returns

{"response":"getTdmaScheme","status":"ok","scheme":0}

getTdmaPools

Get TDMA pools.
Parameters
None
Return value
TDMA pools of the system.
Examples

{"command":"getTdmaPools"}

returns

{
  "response": "getTdmaPools",
  "status": "ok",
  "pools": [
    {
      "frames": 1,
      "slotOff": 1,
      "slots": 62,
      "slotsHead": 1,
      "framesHead": 0,
      "slotSize": 400,
      "msecRefreshInterval": 50
    },
    {
      "frames": 20,
      "slotOff": 0,
      "slots": 1,
      "slotsHead": 0,
      "framesHead": 0,
      "slotSize": 400,
      "msecRefreshInterval": 1000
    }
  ]
}

getUwbAntConfig

Get antenna configuration for UWB radio.
Parameters

  • id (optional) - ID of a node (0xDECAXXXXXXXXXXXX). If no parameter is given, the configuration of the master will be returned.


Return value
Current antenna configuration.
Examples

{"command":"getUwbAntConfig"}

returns

{"response":"getUwbAntConfig","status":"ok","id":"DECA313034114368","txDelay":16471,"rxDelay":16471}

listAnchors

Obtain the current list of all anchors connected to the system (including the masters).
Parameters
None
Return value
List of anchors
Examples

{"command":"listAnchors"}

returns

{
  "response": "listAnchors",
  "status": "ok",
  "anchors": [
    {
      "id": "0xDECA313034114368",
      "coordinates": {
        "x": 1,
        "y": 2,
        "z": 3,
        "heading": 0,
        "pqf": 0
      }
    },
    {
      "id": "0xDECA333033902063",
      "coordinates": {
        "x": 5.117,
        "y": 6.382,
        "z": 0.184,
        "heading": 0,
        "pqf": 0
      }
    }
  ]
}

listNodeConfig

List all node configurations stored in the master.
Parameters
None
Return value
A list of node configurations
Examples

{"command":"listNodeConfig"}

Returns

{
  "response": "listNodeConfig",
  "status": "ok",
  "nodeConfig": [
    {
      "id": 0,
      "mode": "twr",
      "nodeMask": "0xDECAFFFFFFFFFFFF",
      "msecRefreshInterval": 50,
      "msecTsync": 120000,
      "secExpiration": 3600,
      "maxNodes": 200,
      "locEngine": "1",
      "posFilter": "ma",
      "posFilterArg": 3,
      "downloadRate": 0
    },
    {
      "id": 1,
      "mode": "tdoa",
      "nodeMask": "0xBB00FFFFFFFFFFFF",
      "msecRefreshInterval": 1000,
      "msecTsync": 120000,
      "secExpiration": 3600,
      "maxNodes": 200,
      "locEngine": "none",
      "posFilter": "ma",
      "posFilterArg": 3,
      "downloadRate": 0
    }
  ]
}

listTags

Obtain the current list of all tags connected to the system.
Parameters
None
Return value
List of all Tags.
Examples

{"command":"listTags"}

returns

{
  "response": "listTags",
  "status": "ok",
  "tags": [
    {
      "id": "0xDECA343036200653",
      "nodeDetails": {
        "hwVersion": "0x289A0760",
        "ldrfwVersion": "0x16040100",
        "fwVersion": "0x16040600",
        "nodeOptions": "0x30411"
      },
      "coordinates": {
        "x": 1.214,
        "y": 1.421,
        "z": 1.543,
        "heading": 0,
        "pqf": 0
      }
    },
    {
      "id": "0xDECA3430362001A2",
      "nodeDetails": {
        "hwVersion": "0x289A0760",
        "ldrfwVersion": "0x16040100",
        "fwVersion": "0x16040600",
        "nodeOptions": "0x30411"
      },
      "coordinates": {
        "x": 4.618,
        "y": 5.272,
        "z": 0.543,
        "heading": 0,
        "pqf": 0
      }
    }
  ]
}

reinit

Reinitialize the radio network.
Parameters
None
Return value
Status of the command.
Examples

{"command":"reinit"}

returns

{"response":"reinit","status":"in progress"}

removeAnchors

Remove all anchor configuration stored in the master.
Parameters
None
Return value
Status of the command.
Examples

{"command":"removeAnchors"}

returns

{"response":"removeAnchors","status":"ok"}

removeNodeConfig

Remove all node configuration stored in the master.
Parameters
None
Return value
Status of the command.
Examples

{"command":"removeNodeConfig"}

returns

{"response":"removeNodeConfig","status":"ok"}

reset

Reset a node.
Parameters

  • id (optional) - ID of a node (0xDECAXXXXXXXXXXXX). If no parameter is given, the master is reseted.


Return value
Status of the command.
Examples

{"command":"reset","id":"0XFFFFFFFFFFFFFFFF"}

returns

{"response":"reset","status":"in progress"}

scanInfra

Run infrastructure scan in order to measure distances between the anchors. The anchor distances can be used for calculation of anchor positions using the auto-positioning function. Please see setAutoPos
Parameters
None
Return value
Status of the command.
Examples

{"command":"scanInfra"}

returns

{"response":"scanInfra","status":"in progress"}

setAutoPos

Calculate anchor position from the measured distances between them and apply the positions for the anchors.

Please use scanInfra before applying auto-positioning function and use listAnchors to reload the anchor list after the auto-positioning application.


Parameters

  • coordinates (mandatory) - auto to enable auto-positioning function or manual to ignore auto-position.


Return value
Status of the command.
Examples

{"command":"setAutoPos","coordinates":"auto"}

returns

{"response":"setAutoPos","status":"ok"}

setDio8

Set 8-bit Digital I/O on a node identified by ID.
Parameters

  • id (mandatory) - ID of an Anchor (0xDECAXXXXXXXXXXXX)
  • clearMask (optional) - selects I/O to clear (set to Low level state). Mask: 1 - select the I/O, 0 - do not touch.
  • setMask (optional) - selects I/O to set (set to High level state). Mask: 1 - select the I/O, 0 - do not touch.
  • toggleCount (optional) - number of times to set/clear the I/O selected by toggleMask
  • toggleMask (optional) - the mask selects I/O to toggle. Mask: 1 - select the I/O, 0 - do not touch.
  • toggleWait (optional) - time to wait between each toggle, it is multiple of 100 mili-seconds

The order of actions is

  • Toggle
  • Set
  • Clear

Using this sequence it is possible to use one command to toggle and then set and clear the IO to a defined final state.
Return value
Status of the command.
Examples

{"command":"setDio8","id":"0xDECA313033400FAF","clearMask":"0x00","setMask":"0x04","toggleMask":"0x04","toggleCount":"50","toggleWait":"2"}

returns

{"response":"setDio8","status":"in progress"}

setDnsConfig

Set DNS server address used by the master.
Parameters

  • serverIpaddr (mandatory) - DNS server address


Return value
DNS server address used by the master
Examples
Set DNS server address used by the master.

{"command":"setDnsConfig","serverIpAddr":"8.8.8.8"}

returns

{"response":"setDnsConfig","status":"ok","serverIpAddr":"8.8.8.8"}

setNtpConfig

Set NTP server address used by the master.
Parameters

  • serverIpAddr (mandatory) - NTP server address


Return value
NTP server address used by the master.
Examples
Set NTP server address used by the master.

{"command":"setNtpConfig","serverIpAddr":"216.239.32.15"}

returns

{"response":"setNtpConfig","status":"ok","serverIpAddr":"216.239.32.15"}

setIpConfig

Set IP configuration for the master.
Parameters

  • ip (optional) - IP address of the master or auto for DHCP
  • gw (optional) - IP address of the gateway
  • mask (optional) - network mask


Return value
IP configuration of the master (if the IP configuration has changed, the connection will need to be reestablished using the new settings).
Examples
Use DHCP to obtain IP address for the master.

{"command":"setIpConfig","ip":"auto"}

returns

{"response":"ipConfig","ip":"auto"}

Set static address configuration for the master.

{"command":"setIpConfig","ip":"10.0.0.145","gw":"10.0.0.138","mask":"255.255.255.0"}

returns

{"response":"setIpConfig","status":"ok","ip":"10.0.0.145","gw":"10.0.0.138","mask":"255.255.255.0"}

setLsListener

Set type and address of the current Location Server listener (RTLS client application).
Parameters

  • mode (mandatory) - required address routing scheme. Available values are: unicast, broadcast or multicast
  • ip (mandatory) - IP address of the LS listener


Return value
Status of the command.
Examples

{"command":"setLsListener","mode":"unicast","ip":"10.0.0.3"}

returns

{"response":"setLsListener","status":"ok"}

setMode

Set operating mode for a node identified by ID.
Parameters

  • id (mandatory) - ID of an Anchor (0xDECAXXXXXXXXXXXX)
  • mode (mandatory) - required mode. Available values are: anchor, master, tag, offline

Modes

  • anchor - node will be operating as an anchor
  • master - node will be operating as a secondary master
  • tag - node will be operating as a tag
  • offline - node will not participate on communication but will listen and react to these commands: FW update, reset, setMode


Return value
Status of the command.
Examples

{"command":"setMode","id":"0xDECA3430326141A4","mode":"tag"}

returns

{"response":"setMode","status":"ok"}

setNodeConfig

Set or create configuration for the nodes.
Parameters

  • cfgId (mandatory) - Id of configuration. If the ID does not exist, it will be created if the ID is in permitted range. If it exists, the new parameters will overwrite the existing settings. In the current version, the cfgID can be in the range of <0; 1>. The master will test nodeMask with the node address using configuration with lowest cfgId number. The first configuration which matches will be used.
  • nodeOptions - twr (Two-Way Ranging), tdoa (Time Difference of Arrival)
  • nodeMask - the configurator will check if the node address fits the nodeMask. If not matched, the configuration will be skipped. If matched, the configuration will be sent to the node and the other configurations will be ignored. I.e. (0xDECAFFFFFFFFFFFF & <node_id> == <node_id>) will result in applying the configuration rule, (0xDECAFFFFFFFFFFFF & <node_id> != <node_id>) will result in skipping the rule
  • msecRefreshInterval - refresh interval of the node in mili-seconds
  • msecTsync - required time synchronization interval in mili-seconds
  • secExpiration - expiration of the configuration in seconds
  • locEngine - none (do not use internal Location Engine), 1 (internal Location Engine)
  • posFilter - none (disable all filtering), ma (Moving Average)
  • posFilterArg - argument for posFilter, e.g. for posFilter=ma, posFilterArg=3 meaning moving average coefficient is set to 3.
  • downloadRate - number of refresh intervals after which node/tag, will ask master for user data download.


Return value
Status of the command.
Examples
Set/Create configuration with ID=0, which would set the node 0xDECA3130339143A9 with the parameters: TDOA, 1000 mili-seconds refresh interval, 120000 mili-seconds time synchronization interval, configuration expiration in 3600s from the lease, use internal Location Engine with position filter using moving average of coefficient 3, asking for data download once per 20*1000 ms interval.

{
  "command": "setNodeConfig",
  "cfgId": "0",
  "nodeOptions": "tdoa",
  "nodeMask": "0xDECA3130339143A9",
  "msecRefreshInterval": "1000",
  "msecTsync": "120000",
  "secExpiration": "3600",
  "locEngine": "1",
  "posFilter": "ma",
  "posFilterArg": "3",
  "downloadRate": "20"
}

Set/Create configuration with ID=1, which would set the nodes matching given mask (0xDECAFFFFFFFFFFFF & <node_id> == <node_id>) with the parameters: Two-way Ranging, 50 mili-seconds refresh interval, 120000 mili-seconds time synchronization interval, configuration expiration in 3600s from the lease, use internal Location Engine with no position filter, asking for data download once per 100*50 ms interval.

{
  "command": "setNodeConfig",
  "cfgId": "1",
  "nodeOptions": "twr",
  "nodeMask": "0xDECAFFFFFFFFFFFF",
  "msecRefreshInterval": "50",
  "msecTsync": "120000",
  "secExpiration": "3600",
  "locEngine": "1",
  "posFilter": "none",
  "downloadRate": "100"
}

returns

{
  "response": "setNodeConfig",
  "status": "ok",
  "nodeConfig": [
    {
      "id": 0,
      "mode": "tdoa",
      "nodeMask": "0xDECA3130339143A9",
      "msecRefreshInterval": 1000,
      "msecTsync": 120000,
      "secExpiration": 3600,
      "maxNodes": 1000,
      "locEngine": 1,
      "posFilter": "ma",
      "posFilterArg": 3,
      "downloadRate": 20
    },
    {
      "id": 1,
      "mode": "twr",
      "nodeMask": "0xDECAFFFFFFFFFFFF",
      "msecRefreshInterval": 50,
      "msecTsync": 120000,
      "secExpiration": 3600,
      "maxNodes": 100,
      "locEngine": 1,
      "posFilter": "none",
      "posFilterArg": 0,
      "downloadRate": 100
    }
  ]
}

setOutDataFormat

Set output data format of messages pushed by the Location Server.
Parameters

  • outDataFormat (mandatory) - json for JSON readable format or tlv for binary data format


Return value
Output data format pushed by the Location Server.
Examples

{"command":"setOutDataFormat","outDataFormat":"json"}

returns

{"response":"setOutDataFormat","status":"ok","outDataFormat":"json"}

setPos

Set position of an anchor identified by ID.
Parameters

  • id (mandatory) - ID of a node (0xDECAXXXXXXXXXXXX)
  • x, y, z (optional) - coordinates of an anchor in meters or auto to clear the manual values.


Return value
Actual position of the node.
Examples

{
  "command": "setPos",
  "id": "0xDECA313034114368",
  "x": 3,
  "y": 4,
  "z": 2
}

returns

{
  "response": "setPos",
  "status": "ok",
  "id": "0xDECA313034114368",
  "coordinates": {
    "x": 3,
    "y": 4,
    "z": 2,
    "heading": 0,
    "pqf": 0
  }
}

setSyslogLevel

Set syslog level of the master (not implemented yet).
Parameters

  • level (mandatory) - syslog level


Return value
Syslog level of the master.
Examples

{"command":"setSyslogLevel","level":"0"}

returns

{"response":"setSyslogLevel","status":"ok","level":0}

setTdmaScheme

Set TDMA scheme.
Parameters

  • scheme (mandatory) - TDMA scheme
TDMA Schemes
Scheme Description
0 maximum 63 tags at 20 Hz ~ 1260 Hz, 50 ms latency
1 maximum 88 tags at 20 Hz ~ 1760 Hz, 50 ms latency
2 maximum 49 tags at 20 Hz ~ 980 Hz, 100 ms latency
3 maximum 93 tags at 10 Hz ~ 930 Hz, 100 ms latency


Return value
Returns TDMA scheme set to the master.
Examples

{"command":"setTdmaScheme","scheme":"0"}

returns

{"response":"setTdmaScheme","status":"ok","scheme":0}

setUserData

Set user data for the node identified by ID.
Parameters

  • id (mandatory) - ID of a Tag (0xDECAXXXXXXXXXXXX)
  • type (mandatory) - User data type
  • raw (mandatory) - Data payload in hex coded string

Data download payload size is limited to 32 bytes.


Return value

  • ok - Data are accepted and waiting to be downloaded
  • unsupported - Download rate is not specified or is '0' in current configuration.


Examples

{
  "command":"setUserData",
  "id":"0xDECA363032401561",
  "type":"255",
  "raw":"0123456789abcdef00112233445566778899aabbccddeeff"
}

returns

{"response":"setUserData","status":"ok"}

setUwbAntConfig

Set antenna configuration for UWB radio.
Parameters

  • id (optional) - ID of a node (0xDECAXXXXXXXXXXXX). If no parameter is given, the settings will apply to the master.
  • txDelay (optional) - transmission delay of the antenna in ~15.65e-12 seconds units or default for reseting to default values.
  • rxDelay (optional) - reception delay of the antenna in ~15.65e-12 seconds units or default for reseting to default values.


Return value
Current antenna configuration.
Examples

{"command":"setUwbAntConfig","txDelay":"default","rxDelay":"default"}

returns

{"response":"setUwbAntConfig","status":"ok","id":"DECA313034114368","txDelay":16471,"rxDelay":16471}

version

Read ID, firmware and API version of the master.
Parameters
None
Return value
ID of the master, EAN number of master communicating with provisioning server, firmware and API version in decimal pattern of YYMMDDNV (Year, Month, Day, ID of changes in a day and Variant number)
Examples

{"command":"version"}

returns

{"response":"version","status":"ok","id":"DECA313034114368","ean":"8102842400023","fwVersion":"16040600","apiVersion":"16040600"}