Skip to main content

Interface for group-related operations.

IGroupMeshApi

Description Interface for group-related operations.

method createGroup

    fun createGroup(
nodeIds: List<Int>,
callback: CommonCallbacks.CompletionCallbackWithParam<Int>
)

Description: Creates a group for the specified list of aircraft.

Input Parameters: nodeIds:Node IDs. callback:Callback function.

Output Parameter: None.

Related Parameters: None.

method addDroneToGroup

    fun addDroneToGroup(
groupId: Int,
nodeIds: List<Int>,
callback: CommonCallbacks.CompletionCallbackWithParam<Int>
)

Description: Adds aircraft to a group.

Input Parameters: groupId:Group ID. nodeIds:Node IDs. callback:Callback function.

Output Parameter: None.

Related Parameters: None.

method delDroneFromGroup

    fun delDroneFromGroup(
groupId: Int,
nodeIds: List<Int>,
callback: CommonCallbacks.CompletionCallbackWithParam<Void>
)

Description: Removes aircraft from a group.

Input Parameters: groupId:Group ID. nodeIds:Node IDs. callback:Callback function.

Output Parameter: None.

Related Parameters: None.

method disbandGroup

    fun disbandGroup(
groupId: Int,
callback: CommonCallbacks.CompletionCallbackWithParam<Void>?
)

Description: Disbands a group.

Input Parameters: groupId:Group ID. callback:Callback function.;

Output Parameter: None.

Related Parameters: None.

method switchControlMode

    fun switchControlMode(
mode: ControlMode,
id: Int,
callback: CommonCallbacks.CompletionCallbackWithParam<Void>
)

Description: Selects either group or single aircraft control.

Input Parameters: mode:Group control mode [ControlMode]. id:For group control: groupId; for single aircraft control: NodeId; for all selected: this parameter is ignored. callback:Callback function.

Output Parameter: None.

Related Parameters: None.

method changeGroupName

    fun changeGroupName(
groupId: Int,
name: String,
callback: CommonCallbacks.CompletionCallbackWithParam<Void>
)

Description: Changes the group name.

Input Parameters: groupId:Group ID. name:Group name. callback:Callback function.

Output Parameter: None.

Related Parameters: None.

method setGroupDroneLeader

    fun setGroupDroneLeader(
groupId: Int,
deviceNodeId: Int,
callback: CommonCallbacks.CompletionCallbackWithParam<Void>
)

Description: Sets the lead aircraft in the group.

Input Parameters: groupId:Group ID. deviceNodeId:Device node ID. callback:Callback function.;

Output Parameter: None.

Related Parameters: None.