UWB Q1

MQTT Data Format for the UWB Gateway

This guide lists the types and formats of data received through MQTT-Studio, to help you check device status and connect to a positioning system.

MQTT data format, Start data screen 1

About this article

This article lists in detail the types and formats of data received through MQTT-Studio, so you can use them to check device status or connect to a positioning system.


How do you check MQTT data?

Data sent from the gateway can be checked through the topics you subscribed to in MQTT-Studio.

When you click a message in MQTT-Studio, you can see the detailed JSON data.
Click the copy button on the right to copy it as text and analyze it easily in Notepad or a similar tool.


Data types with examples and descriptions

The main data sent from the GrowSpace gateway falls into the following 4 types.


Start data

When the gateway receives power and boots normally, it sends a start message that reports the initial state of the system.
From this message, you can check the ID, Pan ID and current IP address of the gateway.

MQTT data format, Start data screen 1

{
  "uwbID": "GR21BA",
  "panID": "0001",
  "ip": "172.30.1.177"
}

Use cases:


Config data

This is status data sent periodically to report that the gateway keeps running.
The format is the same as the start data, but it is distinguished as a continuous alive signal.

By default, Config data is sent once every 10 seconds.

MQTT data format, Config data screen 2

{
  "uwbID": "GR21BA",
  "panID": "0001",
  "ip": "172.30.1.177"
}

Use cases:


Anchor information (devices – anchors)

This message includes the ID, coordinates, Pan ID and initiator status of the UWB anchors recognized by the gateway.
This information is used to build the anchor data that serves as the reference for position calculation.

The send interval of anchor data cannot be changed. It is sent automatically when an anchor is detected or according to the internal logic of the system.

{
  "gatewayID": "GR21BA",
  "anchors": [
    {
      "id": "GR365d",
      "panID": "0001",
      "initiator": true,
      "x": -2.92,
      "y": 0.35,
      "z": 0.00
    }
  ]
}

Use cases:


Tag position information (devices – tags)

The gateway calculates the current position coordinates (x, y, z) of the UWB tags and sends them in one message.
A single message can include several tags. It consists of gatewayID, panID, the tag ID and the coordinate values.

You can change the send interval of tag data yourself by using the aurs command on the tag device.

MQTT data format, Tag position information (devices – tags) screen 3

{
  "gatewayID": "GR21BA",
  "tags": [
    {"id":"GR2c3c", "panID":"0001", "x": -3.95, "y": 0.23, "z": -2.48},
    {"id":"GR1012", "panID":"0001", "x": -1.48, "y": 3.42, "z":  0.66},
    {"id":"GR2eba", "panID":"0001", "x": -4.27, "y": 0.20, "z": -2.36}
  ]
}

Use cases:


Summary and tips

Data typeMQTT TopicPurpose
Startuwb/gateway/start/#Check the gateway boot status
Configuwb/gateway/config/#Check that the device is running (alive signal)
Anchorsuwb/gateway/devices/#Provide anchor information
Tagsuwb/gateway/devices/#Send tag position data