Class used to interact with the payload device mounted on DJI aircraft. Note: In the MSDK V4 version, the PSDK payload device cannot be used with Zenmuse L1 and Zenmuse P1 at the same time. If you need to use them at the same time, please upgrade to MSDK V5.
The pipelines to transmit data between DJI Payload device and DJI mobile SDK. This function does not support dual controllers scenarios. It's only supported by Matrice 300 RTK.
Gets the bandwidth of the upstream (from Mobile SDK to Payload). The unit is bytes/s. The bandwidth is determined by the firmware and currently it is not larger than 500 bytes/s.
Input Parameters:
final CommonCallbacks.CompletionCallbackWith<Float> callback
The execution callback with the returned value(s).
When it returns true, video stream type on PSDK is set to DJI video streaming channel. Please use VideoDataListener in DJIVideoFeeder to receive the video data. When it returns false, video stream type on PSDK is set to custom video streaming channel. Please use onVideoDataReceived to receive custom video data.
The widget corresponding to the widget type and the index. null if the widgets are not ready or there is no widget corresponding to the widget type and the index.
Gets the full list of widgets on the payload device. A new instance of "NSArray" is returned when one of the widget is updated. Please use getConfigInterfaceWidgets instead.
Sends data to payload. - The length of the data to send cannot exceed 32 bytes for Matrice 200 series. - The length of the data to send cannot exceed 128 bytes for Matrice 200 V2 series. The throughput cannot exceed the bandwidth returned by getUpstreamBandwidth.
Gets the product feature open status. If the product's feature isn't fully opened, there are several possibilities. - Payload status is abnormal. - PSDK is not bound. - Encryption chip exception. - The aircraft doesn't support this Payload model.
Set the UDP data callback, this callback is for receiving the Non-Video data in UDP channel, the max bandwidth of this channel is 8Mbps in M200, 4Mbps in M210.
Fetches widget configuration. Mobile SDK will fetch the configuration when it first launches. Returns nil if initial fetching failed. It is only supported by DJI SKYPORT 2.0.
voidsetPayloadChannelPriority(@NonNull VideoFeedPriority priority, @NonNull PhysicalSource physicalSource, @Nullable final CommonCallbacks.CompletionCallback callback)
Package:
dji.sdk.payload
Description:
Set the channel priority of the payload. Priority will affect the bandwidth allocation if it is not UNKNOWN, which is the default value. For example, if the data that comes from the payload device mounted on left gimbal is preferred, please set the priority to HIGH, and physicalSource is LEFT_CAM. The others should be set to MEDIUM or LOW. Only supported by Matrice 300 RTK.
Development phase has more settings than product phase, including control parameters auto-tuning, coaxiality detection, balance detection, stiffness adjustment. Please note that this phase should be used with DJI Assistant 2, which has bound with Payload SDK developer account. Product phase means that the product is in the stage ready to sell. During this stage, development settings, i.e., control parameters auto-tuning, coaxiality detection, balance detection, stiffness adjustment, should be hidden from user interface.
Returns the component index. Index is zero based. A component will have an index greater than zero when there are multiple components of the same type on the DJI product, and one of the components already has the index 0. For instance, M210 can have two gimbal mounted cameras, and will therefore have two gimbal components with indices 0 and 1, and two camera components with indices 0 and 1. For Matrice 600, there are printed numbers on the battery boxes. The Battery component instance with index 0 corresponds to battery compartment number 1. For Inspire 2 and M200 series, Battery with index 0 corresponds to the battery on the port (left hand) side of the aircraft. For M210, M210 RTK, M300 RTK and M350 RTK, Camera and Gimbal with index 0 corresponds to the camera and gimbal on the port (left hand) side of the aircraft. Lidar with index 0 corresponds to the lidar(Zenmuse L1) on the port (left hand) side of the aircraft.
Gets the serial number of the component. Depending on the component, this serial number might not match the serial number found on the physical component.
Returns the firmware version of the component. Each component will have a different firmware version, the combination of which will form the package firmware version getFirmwarePackageVersion found in BaseProduct.
Input Parameters:
@NonNull CompletionCallbackWith<String> callback
The execution callback with the value(s) returned.