From b25556a9773f30089d69a71e41b44bde49fafd43 Mon Sep 17 00:00:00 2001 From: Vincent Date: Wed, 5 Jun 2024 14:36:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E6=96=B0=E5=A2=9E?= =?UTF-8?q?=E7=9A=84psdk=E6=8E=A5=E5=8F=A3=E6=97=A0=E6=B3=95=E8=B0=83?= =?UTF-8?q?=E7=94=A8=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../control/PayloadControlMethodEnum.java | 12 ++++- .../control/PsdkInputBoxTextSetRequest.java | 19 ++++++++ .../control/PsdkWidgetValueSetRequest.java | 45 +++++++++++++++++++ .../control/SpeakerPlayVolumeSetRequest.java | 19 +++++++- 4 files changed, 93 insertions(+), 2 deletions(-) create mode 100644 cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkInputBoxTextSetRequest.java create mode 100644 cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkWidgetValueSetRequest.java diff --git a/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PayloadControlMethodEnum.java b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PayloadControlMethodEnum.java index b39f3ad..e252149 100644 --- a/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PayloadControlMethodEnum.java +++ b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PayloadControlMethodEnum.java @@ -52,7 +52,17 @@ public enum PayloadControlMethodEnum { CAMERA_POINT_FOCUS_ACTION(ControlMethodEnum.CAMERA_POINT_FOCUS_ACTION, CameraPointFocusActionRequest.class), - CAMERA_FRAME_ZOOM(ControlMethodEnum.CAMERA_FRAME_ZOOM, CameraFrameZoomRequest.class) + CAMERA_FRAME_ZOOM(ControlMethodEnum.CAMERA_FRAME_ZOOM, CameraFrameZoomRequest.class), + + SPEAKER_AUDIO_PLAY_START(ControlMethodEnum.SPEAKER_AUDIO_PLAY_START,SpeakerAudioPlayStartRequest.class), + SPEAKER_TTS_PLAY_START(ControlMethodEnum.SPEAKER_TTS_PLAY_START,SpeakerTTSPlayStartRequest.class), + SPEAKER_REPLAY(ControlMethodEnum.SPEAKER_REPLAY,PsdkRequest.class), + SPEAKER_PLAY_STOP(ControlMethodEnum.SPEAKER_PLAY_STOP,PsdkRequest.class), + SPEAKER_PLAY_MODE_SET(ControlMethodEnum.SPEAKER_PLAY_MODE_SET, SpeakerPlayModeSetRequest.class), + SPEAKER_PLAY_VOLUME_SET(ControlMethodEnum.SPEAKER_PLAY_VOLUME_SET, SpeakerPlayVolumeSetRequest.class), + + PSDK_WIDGET_VALUE_SET(ControlMethodEnum.PSDK_WIDGET_VALUE_SET,PsdkWidgetValueSetRequest.class), + PSDK_INPUT_BOX_TEXT_SET(ControlMethodEnum.PSDK_INPUT_BOX_TEXT_SET, PsdkInputBoxTextSetRequest.class), ; private final ControlMethodEnum payloadMethod; diff --git a/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkInputBoxTextSetRequest.java b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkInputBoxTextSetRequest.java new file mode 100644 index 0000000..8f6509d --- /dev/null +++ b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkInputBoxTextSetRequest.java @@ -0,0 +1,19 @@ +/************************************************* + * @copyright 2017 Flision Corporation Inc. + * @author: Vincent Chan @ Canton + * @date: 2024年06月04日 + * @version: 1.0.0 + * @description: + **************************************************/ +package com.dji.sdk.cloudapi.control; + +import com.dji.sdk.common.BaseModel; +import jakarta.validation.constraints.NotNull; + +public class PsdkInputBoxTextSetRequest extends BaseModel { + + @NotNull + Integer psdkIndex; + + String value; +} diff --git a/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkWidgetValueSetRequest.java b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkWidgetValueSetRequest.java new file mode 100644 index 0000000..bc7aa76 --- /dev/null +++ b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/PsdkWidgetValueSetRequest.java @@ -0,0 +1,45 @@ +/************************************************* + * @copyright 2017 Flision Corporation Inc. + * @author: Vincent Chan @ Canton + * @date: 2024年06月04日 + * @version: 1.0.0 + * @description: + **************************************************/ +package com.dji.sdk.cloudapi.control; + +import com.dji.sdk.common.BaseModel; +import jakarta.validation.constraints.NotNull; + +public class PsdkWidgetValueSetRequest extends BaseModel { + + @NotNull + Integer index; + + @NotNull + Integer psdkIndex; + Integer value; + + public Integer getIndex() { + return index; + } + + public void setIndex(Integer index) { + this.index = index; + } + + public Integer getPsdkIndex() { + return psdkIndex; + } + + public void setPsdkIndex(Integer psdkIndex) { + this.psdkIndex = psdkIndex; + } + + public Integer getValue() { + return value; + } + + public void setValue(Integer value) { + this.value = value; + } +} diff --git a/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/SpeakerPlayVolumeSetRequest.java b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/SpeakerPlayVolumeSetRequest.java index 185035c..b423af7 100644 --- a/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/SpeakerPlayVolumeSetRequest.java +++ b/cloud-sdk/src/main/java/com/dji/sdk/cloudapi/control/SpeakerPlayVolumeSetRequest.java @@ -7,11 +7,12 @@ **************************************************/ package com.dji.sdk.cloudapi.control; +import com.dji.sdk.common.BaseModel; import jakarta.validation.constraints.Max; import jakarta.validation.constraints.Min; import jakarta.validation.constraints.NotNull; -public class SpeakerPlayVolumeSetRequest { +public class SpeakerPlayVolumeSetRequest extends BaseModel { @NotNull Integer psdkIndex; @@ -20,4 +21,20 @@ public class SpeakerPlayVolumeSetRequest { @Min(0) @Max(100) Integer playVolume; + + public Integer getPsdkIndex() { + return psdkIndex; + } + + public void setPsdkIndex(Integer psdkIndex) { + this.psdkIndex = psdkIndex; + } + + public Integer getPlayVolume() { + return playVolume; + } + + public void setPlayVolume(Integer playVolume) { + this.playVolume = playVolume; + } }