70.remote-debug

Functional Overview

Remote debugging is to achieve unattended operation in the debugging process, that is, the operator can issue commands to the device on the cloud without going to the site to perform remote troubleshooting of the device. Remote debugging commands can be divided into commands (cmd) and tasks (job). Command (cmd) generally refers to the behavior that the device can reply to immediately after the command is issued, and the task (job) is the behavior that the device needs to continue to act on after the task is issued.

Remote Debug Instruction

The command to be sent is specified by the "method" field in the 'Send Control Command' protocol transmitted between the cloud and the device. For the detailed protocol content, please view it in the 'Cloud API ' according to the 'Interface Detailed Implementation'.

command(cmd)
task(job)

Debug mode on/off Fill light on/off 4G image transmission function on/off One key return

Dock restart Aircraft power on/off One Key Troubleshooting (One Key Takeoff Self-Check) Aircraft Data Format Dock Data Format Open/Close Canopy Pusher Expand/Close Charge Open /close

Task (job) Execution Process

After the task (job) is issued, the device will return to the execution state. The status is defined in the "status" field of the transport protocol. The status is listed as follows:

  • issued

  • in progress

  • Executed successfully

  • pause

  • rejected

  • failure

  • Cancellation or termination

  • timeout

The execution flow is as follows:

Interaction Sequence Diagram

sequenceDiagram

participant client as DJI Dock
participant app_server as Cloud Server

app_server ->> client : issue command (cmd) <br/>Topic: thing/product/{gateway_sn}/services<br/>Method:{cmd_method}
client -->> app_server : Reply whether to start executing <br/>Topic: thing/product/{gateway_sn}/services_reply

app_server ->> client : send task (job)<br/>Topic: thing/product/{gateway_sn}/services<br/>Method:{cmd_method}
client -->> app_server : Reply whether to start executing <br/>Topic: thing/product/{gateway_sn}/services_reply


activate client

client ->> app_server : report task progress<br/>Topic: thing/product/{gateway_sn}/events<br/>Method:{cmd_method}

deactivate client

Detailed API Realization

Remote Debugging

  • Open the debug mode

  • Close the debug mode

  • Open the supplement light

  • ...

Last updated