Missions client
Use IMissionClient when you need direct mission protocol operations from a client device.
Basic download flow (same idea as show-mission CLI command):
Set current item:
Clear remote mission:
MissionClientConfig
Property | Type | Default | Description |
|---|---|---|---|
|
|
| Timeout for request/response mission calls. |
|
|
| Retry count for request/response calls. |
IMissionClient
Represents a client for interacting with missions.
Property | Type | Description |
|---|---|---|
|
| Current mission item index from remote side. |
|
| Last reached mission item index. |
|
| Gets an observable stream of mission request payloads. |
|
| Gets the observable sequence that emits MissionAckPayload when a mission acknowledgement is received. |
Method | Return Type | Description |
|---|---|---|
|
| Drone receives message and attempts to update the current mission sequence number. |
|
| Requests a mission item of the specified index. |
|
| Initiate mission download from a system by requesting the list of mission items. |
|
| Sets the count for the mission and returns a task that represents the asynchronous operation. |
|
| Writes a mission item to the vehicle's mission list. |
|
| Writes a mission item to a target. |
|
| Writes a mission item with an integer payload. |
|
| Clears all mission items of the specified type. |
|
| Sends a mission acknowledgment message to the specified target system and component IDs. |
IMissionClient.MissionSetCurrent
Parameter | Type | Description |
|---|---|---|
|
| Index of the mission item within the mission sequence. |
|
| Optional cancel token argument. |
IMissionClient.MissionRequestItem
Parameter | Type | Description |
|---|---|---|
|
| The index of the mission item to request. |
|
| Optional cancel token argument. |
IMissionClient.MissionRequestCount
Parameter | Type | Description |
|---|---|---|
|
| Optional cancel token argument. |
IMissionClient.MissionSetCount
Parameter | Type | Description |
|---|---|---|
|
| The count to set for the mission. |
|
| Optional cancel token argument. |
IMissionClient.WriteMissionItem(...)
Parameter | Type | Description |
|---|---|---|
|
| The sequence number of the mission item. |
|
| The coordinate system in which the mission item's position is specified. |
|
| The scheduled action for the mission item. |
|
| True if this mission item is the currently active one. |
|
| True to automatically continue to the next waypoint after this mission item. |
|
| PARAM1 for the scheduled action (refer to MAV_CMD enum for details). |
|
| PARAM2 for the scheduled action (refer to MAV_CMD enum for details). |
|
| PARAM3 for the scheduled action (refer to MAV_CMD enum for details). |
|
| PARAM4 for the scheduled action (refer to MAV_CMD enum for details). |
|
| The x-coordinate of the mission item's position. |
|
| The y-coordinate of the mission item's position. |
|
| The z-coordinate of the mission item's position. |
|
| The type of mission item. |
|
| Optional cancel token argument. |
IMissionClient.WriteMissionItem(MissionItem missionItem)
Parameter | Type | Description |
|---|---|---|
|
| The mission item to write. |
|
| Optional cancel token argument. |
IMissionClient.WriteMissionIntItem
Parameter | Type | Description |
|---|---|---|
|
| A callback function that fills the mission item payload. |
|
| Optional cancel token argument. |
IMissionClient.ClearAll
Parameter | Type | Description |
|---|---|---|
|
| The type of mission items to clear. Default value is MavMissionType.MavMissionTypeAll. |
|
| Optional cancel token argument. |
IMissionClient.SendMissionAck
Parameter | Type | Description |
|---|---|---|
|
| The result of the mission. |
|
| The target system ID. Default value is 0. |
|
| The target component ID. Default value is 0. |
|
| The mission type. Default value is null. |
|
| Optional cancel token argument. |