DJI Windows SDK Documentation

class ProductHandler

sealed class ProductHandler
Declaration:DJI.WindowsSDK.Components
Description:

This class includes the overall information of a product.

Class Members:
struct ProductTypeMsg
struct ProductTypeMsg
Declaration:DJI.WindowsSDK
Description:

A class contains a product type of DJI products.

Struct Members:
ProductType valueThe actual value of the class.
enum ProductType
enum ProductType
Declaration:DJI.WindowsSDK
Description:

The enums that describe differnt DJI products.

Enum Members:
UNRECOGNIZEDNone. No DJI product is recognized.
OSMOOsmo.
P4Phantom 4.
MAVIC_PROMavic Pro.
OSMO_PROOsmo Pro.
OSMO_RAWOsmo RAW.
OSMO_PLUSOsmo Plus.
P4PPhantom 4 Pro.
P4APhantom 4 Advanced.
P4RPhantom 4 RTK.
MAVIC_AIRMavic Air.
MAVIC_2Mavic 2.
P4P_V2Phantom 4 Pro V2.
UNKNOWNUnknown.
property
property ProductIndex
uint ProductIndex { get; }
Declaration:DJI.WindowsSDK.Components
Description:

The index of the product to which this product handler refers. The default product index is 0.

property ComponentIndex
uint ComponentIndex { get; }
Declaration:DJI.WindowsSDK.Components
Description:

The index of the component. It is unique for a type of components inside a product. For ProductHandler, it is always 0.

method ~ProductHandler
~ProductHandler()
Declaration:DJI.WindowsSDK.Components
Description:

The destructor. It should not be called explicitly.

delegate ProductTypeMsgChangedEventHandler
delegate void ProductTypeMsgChangedEventHandler(object sender, ProductTypeMsg? value)
Declaration:DJI.WindowsSDK
Description:

A delegate type used to subscribe the updated values in type ProductTypeMsg.

Methods
method
method GetProductTypeAsync
async Task<ResultValue<ProductTypeMsg?>> GetProductTypeAsync()
Declaration:DJI.WindowsSDK.Components
Description:

Gets the detail product type of the connected aircraft. Returns UNKNOWN if connected aircraft is not recognized by SDK yet.

Return:
async Task<ResultValue<ProductTypeMsg?>>A Task<ResultValue<ProductTypeMsg?>> object.
method GetConnectionAsync
async Task<ResultValue<BoolMsg?>> GetConnectionAsync()
Declaration:DJI.WindowsSDK.Components
Description:

Determines if the product is connected or not.

Return:
async Task<ResultValue<BoolMsg?>>A Task<ResultValue<BoolMsg?>> object.
method GetSerialNumberAsync
async Task<ResultValue<StringMsg?>> GetSerialNumberAsync()
Declaration:DJI.WindowsSDK.Components
Description:

This interface is invalid for a product handler.

Return:
async Task<ResultValue<StringMsg?>>A Task<ResultValue<StringMsg?>> object.
event ProductTypeChanged
event ProductTypeMsgChangedEventHandler ProductTypeChanged
Declaration:DJI.WindowsSDK.Components
Description:

Subscribe the event to receive changes of the product type. Returns UNKNOWN if connected aircraft is not recognized by SDK yet.

event ConnectionChanged
event BoolMsgChangedEventHandler ConnectionChanged
Declaration:DJI.WindowsSDK.Components
Description:

Subscribe the event to receive the product's connection change.

event SerialNumberChanged
event StringMsgChangedEventHandler SerialNumberChanged
Declaration:DJI.WindowsSDK.Components
Description:

This interface is invalid for a product handler.