Report Progress and Status

2022-06-23
No Rating

Device report the flight task progress and status

Topic:

thing/product/{pid}/events

Parameter Explanation:

ParameterRequiredTypeIllustration
tidYstring
bidYstring
methodYstringmessage Type
timestampYint13-bit timestamp
dataYobject
» outputYobject
»» statusYstringTask status
»» extYobject
»»» current_waypoint_indexYintWaypoint numbers of current execution
»»» media_countYintMedia file number produced in current task, only exit in the last finished task information.
»»» track_idYstringwayline ID
»» progressYobjectProgress struct
»»» current_stepYintStep enumeration value:
* 1:Download kmz waypoint task
* 2:KMZ loading
* 3:waypoint execution
»»» percentYintProgress:0-100

Example:

// topic thing/product/{pid}/events
{
  "bid": "000f3949-01fe-4778-9b75-76a9ac5c4ed6",
  "data": {
    "output": {
      "ext": {
        "current_waypoint_index": 3,
        "media_count": 6,
        "track_id": "track_id"
      },
      "progress": {
        "current_step": 19,
        "percent": 100
      },
      "status": "ok"
    },
    "result": 0
  },
  "method": "flighttask_progress",
  "tid": "da927f3a-b408-4b2a-9ce8-f4d57c913909",
  "timestamp": 1654065677966
}

Server reply: Device report the flight task progress and status

Topic:

// topic thing/product/{pid}/events_reply
{
  "method":"flighttask_progress",
  "tid":"12345",
  "bid":"456",
  "timestamp": "1234567890123",
  "data":{
    "result": 0
  }
}

Parameter Explanation:

ParameterRequiredTypeIllustration
tidYstring
bidYstring
methodYstringmessage Type
timestampYint13-bit timestamp
dataYobject
» resultYintThe response result of 0 means normal