DJI Payload SDK  1.5.3
psdk_cmdset_camera.h
Go to the documentation of this file.
1 /**
2  ******************************************************************************
3  * @file psdk_cmdset_camera.h
4  * @version V1.0.0
5  * @date 2017/11/9
6  * @brief This file defines the payload SDK camera command set.
7  *
8  * @copyright (c) 2017-2018 DJI. All rights reserved.
9  *
10  * All information contained herein is, and remains, the property of DJI.
11  * The intellectual and technical concepts contained herein are proprietary
12  * to DJI and may be covered by U.S. and foreign patents, patents in process,
13  * and protected by trade secret or copyright law. Dissemination of this
14  * information, including but not limited to data and other proprietary
15  * material(s) incorporated within the information, in any form, is strictly
16  * prohibited without the express written consent of DJI.
17  *
18  * If you receive this source code without DJI’s authorization, you may not
19  * further disseminate the information, and you must immediately remove the
20  * source code and notify DJI of its removal. DJI reserves the right to pursue
21  * legal actions against you for any loss(es) or damage(s) caused by your
22  * failure to do so.
23  *
24  ******************************************************************************
25  */
26 
27 /* Define to prevent recursive inclusion -------------------------------------*/
28 #ifndef PSDK_CMD_CAMERA_H
29 #define PSDK_CMD_CAMERA_H
30 
31 /* Includes ------------------------------------------------------------------*/
32 #include <psdk_typedef.h>
33 #include <psdk_core.h>
34 
35 /** @addtogroup PSDK
36  * @{
37  */
38 
39 /** @addtogroup PSDK_Camera
40  * @{
41  */
42 
43 /* Exported constants --------------------------------------------------------*/
44 /* Exported macros -----------------------------------------------------------*/
45 /* Exported types ------------------------------------------------------------*/
46 
47 /** @defgroup Camera_Exported_Types Exported types
48  * @{
49  */
50 
51 /** @defgroup Camera_Command_Related Command Related
52  * @{
53  */
54 
55 /**
56  * @brief Camera Command ID
57  */
58 typedef enum {
59  //base command
60  PSDK_CAMERA_CMD_ID_SET_MODE = 0x01, /*!< set camera work mode command */
61  PSDK_CAMERA_CMD_ID_GET_MODE = 0x02, /*!< get camera work mode command */
62  PSDK_CAMERA_CMD_ID_SHOOT_PHOTO = 0x03, /*!< shoot photo command */
63  PSDK_CAMERA_CMD_ID_GET_SHOOT_PHOTO_STATE = 0x04, /*!< get shoot photo state command */
64  PSDK_CAMERA_CMD_ID_SET_SHOOT_PHOTO_MODE = 0x05, /*!< set shoot photo mode command */
65  PSDK_CAMERA_CMD_ID_GET_SHOOT_PHOTO_MODE = 0x06, /*!< get shoot photo mode command */
66  PSDK_CAMERA_CMD_ID_RECORD_VIDEO = 0x07, /*!< record video command */
67  PSDK_CAMERA_CMD_ID_GET_RECORD_VIDEO_STATE = 0x08, /*!< get record video state command */
68  PSDK_CAMERA_CMD_ID_GET_SDCARD_PARAM = 0x09, /*!< get SD card parameter command */
69  PSDK_CAMERA_CMD_ID_FORMAT_SDCARD = 0x0A, /*!< format SD card command */
70  PSDK_CAMERA_CMD_ID_SET_METERING_MODE = 0x20, /*!< set metering mode command */
71  PSDK_CAMERA_CMD_ID_GET_METERING_MODE = 0x21, /*!< get metering mode command */
72  PSDK_CAMERA_CMD_ID_SET_SPOT_METERING = 0x22, /*!< set spot metering zone command */
73  PSDK_CAMERA_CMD_ID_GET_SPOT_METERING = 0x23, /*!< get spot metering zone command */
74 
75  //focus command
76  PSDK_CAMERA_CMD_ID_SET_FOCUS_MODE = 0x30, /*!< set focus mode command */
77  PSDK_CAMERA_CMD_ID_GET_FOCUS_MODE = 0x31, /*!< get focus mode command */
78  PSDK_CAMERA_CMD_ID_SET_FOCUS_ZONE = 0x32, /*!< set focus zone command */
79  PSDK_CAMERA_CMD_ID_GET_FOCUS_ZONE = 0x33, /*!< get focus zone command */
80 
81  //zoom command
82  PSDK_CAMERA_CMD_ID_SET_DIGTALZOOM_FACTOR = 0x34, /*!< set digital zoom factor command */
83  PSDK_CAMERA_CMD_ID_GET_DIGTALZOOM_FACTOR = 0x35, /*!< get digital zoom factor command */
84  PSDK_CAMERA_CMD_ID_GET_OPTICALZOOM_SPEC = 0x36, /*!< get optical zoom specification command */
85  PSDK_CAMERA_CMD_ID_SET_OPTICALZOOM_FOCAL_LENGTH = 0x37, /*!< set optical zoom focal length command */
86  PSDK_CAMERA_CMD_ID_GET_OPTICALZOOM_FOCAL_LENGTH = 0x38, /*!< get optical zoom focal length command */
87  PSDK_CAMERA_CMD_ID_GET_OPTICALZOOM_FACTOR = 0x39, /*!< get optical zoom focal command */
88  PSDK_CAMERA_CMD_ID_START_CONTINUOUS_OPTICAL_ZOOM = 0x40, /*!< start continuous optical zoom command */
89  PSDK_CAMERA_CMD_ID_STOP_CONTINUOUS_OPTICAL_ZOOM = 0x41, /*!< stop continuous optical zoom command */
90 
91  //append focus command
92  PSDK_CAMERA_CMD_ID_SET_FOCUS_ASSISTANT_SETTING = 0x42, /*!< set focus assistant settings command */
93  PSDK_CAMERA_CMD_ID_GET_FOCUS_ASSISTANT_SETTING = 0x43, /*!< get focus assistant settings command */
94  PSDK_CAMERA_CMD_ID_GET_FOCUS_RING_VALUE_UPPER_BOUND = 0x44, /*!< get focus ring value upper bound command */
95  PSDK_CAMERA_CMD_ID_SET_FOCUS_RING_VALUE = 0x45, /*!< set focus ring value command */
96  PSDK_CAMERA_CMD_ID_GET_FOCUS_RING_VALUE = 0x46, /*!< get focus ring value command */
97 
98  //append zoom command
99  PSDK_CAMERA_CMD_ID_GET_DIGITALZOOM_SPEC = 0x47, /*!< get digital zoom specification command */
100 
101  //other command
102  PSDK_CAMERA_CMD_ID_SUPPORT_STATE = 0xFF, /*!< get camera function support state command */
104 
105 /**
106  * @}
107  */
108 
109 /** @defgroup Camera_Related Camera Related
110  * @{
111  */
112 
113 /**
114  * @brief Camera work mode.
115  */
116 typedef enum {
117  PSDK_CAMERA_CAMERA_MODE_SHOOT_PHOTO = 0, /*!< Shoot photo mode. */
118  PSDK_CAMERA_CAMERA_MODE_RECORD_VIDEO = 1, /*!< Record video mode. */
120 
121 /**
122  * @brief Camera shoot photo action.
123  */
124 typedef enum {
125  PSDK_CAMERA_SHOOT_PHOTO_ACTION_STOP = 0, /*!< Stop shoot photo for stopping interval photographing. */
126  PSDK_CAMERA_SHOOT_PHOTO_ACTION_START = 1, /*!< Start shoot photo. */
128 
129 /**
130  * @brief Camera shoot photo mode.
131  */
132 typedef enum {
133  PSDK_CAMERA_SHOOT_PHOTO_MODE_SINGLE = 1, /*!< Single photographing mode. */
134  PSDK_CAMERA_SHOOT_PHOTO_MODE_BURST = 4, /*!< Burst photographing mode. */
135  PSDK_CAMERA_SHOOT_PHOTO_MODE_INTERVAL = 6, /*!< Interval photographing mode. */
137 
138 /**
139  * @brief Camera record video action.
140  */
141 typedef enum {
142  PSDK_CAMERA_RECORD_VIDEO_ACTION_STOP = 0, /*!< Stop record video. */
143  PSDK_CAMERA_RECORD_VIDEO_ACTION_START = 1, /*!< Start record video. */
145 
146 /**
147  * @brief Photo number of burst photographing.
148  */
149 typedef enum {
150  PSDK_CAMERA_BURST_PARAM_2 = 2, /*!< Photo number of burst photographing: 2. */
151  PSDK_CAMERA_BURST_PARAM_3 = 3, /*!< Photo number of burst photographing: 3. */
152  PSDK_CAMERA_BURST_PARAM_5 = 5, /*!< Photo number of burst photographing: 5. */
153  PSDK_CAMERA_BURST_PARAM_7 = 7, /*!< Photo number of burst photographing: 7. */
154  PSDK_CAMERA_BURST_PARAM_10 = 10, /*!< Photo number of burst photographing: 10. */
156 
157 /**
158  * @brief Time interval of interval photographing.
159  * @details Unit: s.
160  */
161 typedef enum {
162  PSDK_CAMERA_INTERVAL_PARAM_1S = 1, /*!< Time interval of interval photographing: 1s. */
163  PSDK_CAMERA_INTERVAL_PARAM_3S = 3, /*!< Time interval of interval photographing: 3s. */
164  PSDK_CAMERA_INTERVAL_PARAM_5S = 5, /*!< Time interval of interval photographing: 5s. */
165  PSDK_CAMERA_INTERVAL_PARAM_7S = 7, /*!< Time interval of interval photographing: 7s. */
166  PSDK_CAMERA_INTERVAL_PARAM_10S = 10, /*!< Time interval of interval photographing: 10s. */
167  PSDK_CAMERA_INTERVAL_PARAM_15S = 15, /*!< Time interval of interval photographing: 15s. */
168  PSDK_CAMERA_INTERVAL_PARAM_20S = 20, /*!< Time interval of interval photographing: 20s. */
169  PSDK_CAMERA_INTERVAL_PARAM_30S = 30, /*!< Time interval of interval photographing: 30s. */
171 
172 /**
173  * @brief Camera focus mode.
174  */
175 typedef enum {
176  PSDK_CAMERA_FOCUS_MODE_MANUAL = 0, /*!< Manual focus mode. */
177  PSDK_CAMERA_FOCUS_MODE_AUTO = 1, /*!< Auto focus mode. */
179 
180 /**
181  * @brief Camera metering mode.
182  */
183 typedef enum {
184  PSDK_CAMERA_METERING_MODE_CENTER = 0, /*!< Center metering mode. */
185  PSDK_CAMERA_METERING_MODE_AVERAGE = 1, /*!< Average metering mode. */
186  PSDK_CAMERA_METERING_MODE_SPOT = 2, /*!< Spot metering mode. */
188 
189 /**
190  * @brief Camera zoom mode.
191  */
192 typedef enum {
193  PSDK_CAMERA_ZOOM_OUT = 0, /*!< Lens will zoom out. The focal length decreases,
194  and field of view becomes wider and magnification is lower. */
195  PSDK_CAMERA_ZOOM_IN = 1, /*!< Lens will zoom in. The focal length increases,
196  and field of view becomes narrower and magnification is higher. */
198 
199 /**
200  * @brief Camera zoom speed.
201  */
202 typedef enum {
203  PSDK_CAMERA_ZOOM_SPEED_SLOWEST = 72, /*!< Slowest speed zoom. */
204  PSDK_CAMERA_ZOOM_SPEED_SLOW = 73, /*!< Slow speed zoom. */
205  PSDK_CAMERA_ZOOM_SPEED_MODERATELY_SLOW = 74, /*!< Moderately slow speed zoom. */
206  PSDK_CAMERA_ZOOM_SPEED_NORMAL = 75, /*!< Normal speed zoom. */
207  PSDK_CAMERA_ZOOM_SPEED_MODERATELY_FAST = 76, /*!< Moderately fast speed zoom. */
208  PSDK_CAMERA_ZOOM_SPEED_FAST = 77, /*!< Fast speed zoom. */
209  PSDK_CAMERA_ZOOM_SPEED_FASTEST = 78, /*!< Fastest speed zoom. */
211 
212 /**
213  * @}
214  */
215 
216 /** @addtogroup Camera_Command_Related
217  * @{
218  */
219 
220 #pragma pack(1)
221 
222 //PSDK_CAMERA_CMD_ID_SET_MODE
223 /**
224  * @brief Set camera work mode command request data structure.
225  */
226 typedef struct {
227  uint8_t cameraMode; /*!< This parameter can be any value of ::E_PsdkCameraCameraMode. */
229 
230 /**
231  * @brief Set camera work mode command ack data structure.
232  */
233 typedef struct {
234  uint8_t ackCode; /*!< Specifies PSDK command ack code.
235  This parameter can be any value of ::E_PsdkCmdAckCode */
237 
238 //PSDK_CAMERA_CMD_ID_GET_MODE
239 /**
240  * @brief Get camera work mode command request data structure.
241  */
242 typedef struct {
243  PSDK_EMPTY_STRUCT
245 
246 /**
247  * @brief Get camera work mode command ack data structure.
248  */
249 typedef struct {
250  uint8_t ackCode; /*!< Specifies PSDK command ack code.
251  This parameter can be any value of ::E_PsdkCmdAckCode */
252  uint8_t cameraMode; /*!< This parameter can be any value of ::E_PsdkCameraCameraMode. */
254 
255 //PSDK_CAMERA_CMD_ID_SHOOT_PHOTO
256 /**
257  * @brief Shoot photo command request data structure.
258  */
259 typedef struct {
260  uint8_t shootPhotoAction; /*!< This parameter can be any value of ::E_PsdkCameraShootPhotoAction. */
262 
263 /**
264  * @brief Shoot photo command ack data structure.
265  */
266 typedef struct {
267  uint8_t ackCode; /*!< Specifies PSDK command ack code.
268  This parameter can be any value of ::E_PsdkCmdAckCode */
270 
271 //PSDK_CAMERA_CMD_ID_GET_SHOOT_PHOTO_STATE
272 /**
273  * @brief Get shoot photo state command request data structure.
274  */
275 typedef struct {
276  PSDK_EMPTY_STRUCT
278 
279 /**
280  * @brief Get shoot photo state command ack data structure.
281  */
282 typedef struct {
283  uint8_t ackCode; /*!< Specifies PSDK command ack code.
284  This parameter can be any value of ::E_PsdkCmdAckCode */
285  uint8_t isShootingSinglePhoto : 1; /*!< This parameter is boolean type. */
286  uint8_t isShootingIntervalPhoto : 1;/*!< This parameter is boolean type. */
287  uint8_t isShootingBurstPhoto : 1; /*!< This parameter is boolean type. */
288  uint8_t isStoringPhoto : 1; /*!< This parameter is boolean type. */
289  uint8_t reserved : 4; /*!< Reserved. */
290  uint16_t intervalPhotoCountdown; /*!< Specifies countdown of interval photography, unit: s. */
292 
293 //PSDK_CAMERA_CMD_ID_SET_SHOOT_PHOTO_MODE
294 /**
295  * @brief Set shoot photo mode command request data structure.
296  */
297 typedef struct {
298  uint8_t shootPhotoMode; /*!< This parameter can be any value of ::E_PsdkCameraShootPhotoMode. */
299  uint8_t burstCount; /*!< This parameter can be any value of ::E_PsdkCameraBurstParam. */
300  uint8_t intervalCount; /*!< Specifies photo count of interval photographing.
301  @note 255 means continue capture. */
302  uint16_t intervalTime; /*!< This parameter can be any value of ::E_PsdkCameraIntervalParam, unit: s. */
304 
305 /**
306  * @brief Set shoot photo mode command ack data structure.
307  */
308 typedef struct {
309  uint8_t ackCode; /*!< Specifies PSDK command ack code.
310  This parameter can be any value of ::E_PsdkCmdAckCode */
312 
313 //PSDK_CAMERA_CMD_ID_GET_SHOOT_PHOTO_MODE
314 /**
315  * @brief Get shoot photo mode command request data structure.
316  */
317 typedef struct {
318  PSDK_EMPTY_STRUCT
320 
321 /**
322  * @brief Get shoot photo mode command ack data structure.
323  */
324 typedef struct {
325  uint8_t ackCode; /*!< Specifies PSDK command ack code.
326  This parameter can be any value of ::E_PsdkCmdAckCode */
327  uint8_t shootPhotoMode; /*!< This parameter can be any value of ::E_PsdkCameraShootPhotoMode. */
328  uint8_t burstCount; /*!< This parameter can be any value of ::E_PsdkCameraBurstParam. */
329  uint8_t intervalCount; /*!< Specifies photo count of interval photographing.
330  @note 255 means continue capture. */
331  uint16_t intervalTime; /*!< This parameter can be any value of ::E_PsdkCameraIntervalParam, unit: s. */
333 
334 //PSDK_CAMERA_CMD_ID_RECORD_VIDEO
335 /**
336  * @brief Record video action command request data structure.
337  */
338 typedef struct {
339  uint8_t recordVideoAction; /*!< This parameter can be any value of ::E_PsdkCameraRecordVideoAction. */
341 
342 /**
343  * @brief Record video action command ack data structure.
344  */
345 typedef struct {
346  uint8_t ackCode; /*!< Specifies PSDK command ack code.
347  This parameter can be any value of ::E_PsdkCmdAckCode */
349 
350 //PSDK_CAMERA_CMD_ID_GET_RECORD_VIDEO_STATE
351 /**
352  * @brief Get record video state command request data structure.
353  */
354 typedef struct {
355  PSDK_EMPTY_STRUCT
357 
358 /**
359  * @brief Get record video state command ack data structure.
360  */
361 typedef struct {
362  uint8_t ackCode; /*!< Specifies PSDK command ack code.
363  This parameter can be any value of ::E_PsdkCmdAckCode */
364  uint8_t isRecording; /*!< This parameter is boolean type. */
365  uint16_t currentRecordingTimeInSeconds; /*!< The duration of currently recorded video, unit: s. */
367 
368 //PSDK_CAMERA_CMD_ID_GET_SDCARD_PARAM
369 /**
370  * @brief Get SD card parameter command request data structure.
371  */
372 typedef struct {
373  PSDK_EMPTY_STRUCT
375 
376 /**
377  * @brief Get SD card parameter command ack data structure.
378  */
379 typedef struct {
380  uint8_t ackCode; /*!< Specifies PSDK command ack code.
381  This parameter can be any value of ::E_PsdkCmdAckCode */
382  uint8_t isInserted : 1; /*!< Specifies if the SD card is inserted in the camera.
383  This parameter is boolean type. */
384  uint8_t isVerified : 1; /*!< Specifies if the SD card is verified as genuine.
385  This parameter is boolean type. */
386 
387  uint8_t isInitializing : 1; /*!< This parameter is boolean type. */
388  uint8_t isReadOnly : 1; /*!< This parameter is boolean type. */
389  uint8_t isFormatting : 1; /*!< This parameter is boolean type. */
390  uint8_t isFull : 1; /*!< This parameter is boolean type. */
391  uint8_t isInvalidFormat : 1;/*!< This parameter is boolean type. */
392  uint8_t hasError : 1; /*!< This parameter is boolean type. */
393  uint8_t reserved;
394 
395  uint32_t totalSpaceInMB; /*!< SD card total capacity, unit: MB. */
396  uint32_t remainSpaceInMB; /*!< SD card remaining capacity, unit: MB. */
397  uint32_t availableCaptureCount; /*!< Available shots, unit: s. */
398  uint32_t availableRecordingTimeInSeconds; /*!< Available video recording time, unit: s. */
400 
401 //PSDK_CAMERA_CMD_ID_FORMAT_SDCARD
402 /**
403  * @brief Format SD card command request data structure.
404  */
405 typedef struct {
406  PSDK_EMPTY_STRUCT
408 
409 /**
410  * @brief Get record video state command ack data structure.
411  */
412 typedef struct {
413  uint8_t ackCode; /*!< Specifies PSDK command ack code.
414  This parameter can be any value of ::E_PsdkCmdAckCode */
415  uint8_t reserved;
417 
418 //PSDK_CAMERA_CMD_ID_SET_SPOT_METERING
419 /**
420  * @brief Set spot metering zone command request data structure.
421  */
422 typedef struct {
423  uint8_t col : 4; /*!< Specifies column coordinate. This parameter is between 0 and 11. */
424  uint8_t row : 4; /*!< Specifies row coordinate. This parameter is between 0 and 7. */
426 
427 /**
428  * @brief Set spot metering zone command ack data structure.
429  */
430 typedef struct {
431  uint8_t ackCode; /*!< Specifies PSDK command ack code.
432  This parameter can be any value of ::E_PsdkCmdAckCode */
434 
435 //PSDK_CAMERA_CMD_ID_GET_SPOT_METERING
436 /**
437  * @brief Get spot metering zone command request data structure.
438  */
439 typedef struct {
440  PSDK_EMPTY_STRUCT
442 
443 /**
444  * @brief Get spot metering zone command ack data structure.
445  */
446 typedef struct {
447  uint8_t ackCode;
448  uint8_t col : 4; /*!< Specifies column coordinate. This parameter is between 0 and 11. */
449  uint8_t row : 4; /*!< Specifies row coordinate. This parameter is between 0 and 7. */
451 
452 //PSDK_CAMERA_CMD_ID_SET_METERING_MODE
453 /**
454  * @brief Set metering mode command request data structure.
455  */
456 typedef struct {
457  uint8_t meteringMode; /*!< This parameter can be any value of ::E_PsdkCameraMeteringMode. */
459 
460 /**
461  * @brief Set metering mode command ack data structure.
462  */
463 typedef struct {
464  uint8_t ackCode; /*!< Specifies PSDK command ack code.
465  This parameter can be any value of ::E_PsdkCmdAckCode */
467 
468 //PSDK_CAMERA_CMD_ID_GET_METERING_MODE
469 /**
470  * @brief Get metering mode command request data structure.
471  */
472 typedef struct {
473  PSDK_EMPTY_STRUCT
475 
476 /**
477  * @brief Get metering mode command ack data structure.
478  */
479 typedef struct {
480  uint8_t ackCode; /*!< Specifies PSDK command ack code.
481  This parameter can be any value of ::E_PsdkCmdAckCode */
482  uint8_t meteringMode; /*!< This parameter can be any value of ::E_PsdkCameraMeteringMode. */
484 
485 //PSDK_CAMERA_CMD_ID_SET_FOCUS_MODE
486 /**
487  * @brief Set focus mode command request data structure.
488  */
489 typedef struct {
490  uint8_t focusMode; /*!< This parameter can be any value of ::E_PsdkCameraFocusMode. */
492 
493 /**
494  * @brief Set focus mode command ack data structure.
495  */
496 typedef struct {
497  uint8_t ackCode; /*!< Specifies PSDK command ack code.
498  This parameter can be any value of ::E_PsdkCmdAckCode */
500 
501 //PSDK_CAMERA_CMD_ID_GET_FOCUS_MODE
502 /**
503  * @brief Get focus mode command request data structure.
504  */
505 typedef struct {
506  PSDK_EMPTY_STRUCT
508 
509 /**
510  * @brief Get focus mode command ack data structure.
511  */
512 typedef struct {
513  uint8_t ackCode; /*!< Specifies PSDK command ack code.
514  This parameter can be any value of ::E_PsdkCmdAckCode */
515  uint8_t focusMode; /*!< This parameter can be any value of ::E_PsdkCameraFocusMode. */
517 
518 //PSDK_CAMERA_CMD_ID_SET_FOCUS_ZONE
519 /**
520  * @brief Set focus zone command request data structure.
521  */
522 typedef struct {
523  psdk_f32_t focusX; /*!< Specifies horizontal zone coordinate. This parameter is between 0 and 1.
524  The point [0.0, 0.0] represents the top-left angle of the screen.*/
525  psdk_f32_t focusY; /*!< Specifies vertical zone coordinate. This parameter is between 0 and 1. */
527 
528 /**
529  * @brief Set focus zone command ack data structure.
530  */
531 typedef struct {
532  uint8_t ackCode; /*!< Specifies PSDK command ack code.
533  This parameter can be any value of ::E_PsdkCmdAckCode */
535 
536 //PSDK_CAMERA_CMD_ID_GET_FOCUS_ZONE
537 /**
538  * @brief Get focus zone command request data structure.
539  */
540 typedef struct {
541  PSDK_EMPTY_STRUCT
543 
544 /**
545  * @brief Get focus zone command ack data structure.
546  */
547 typedef struct {
548  uint8_t ackCode; /*!< Specifies PSDK command ack code.
549  This parameter can be any value of ::E_PsdkCmdAckCode */
550  psdk_f32_t focusX; /*!< Specifies horizontal zone coordinate. This parameter is between 0 and 1. */
551  psdk_f32_t focusY; /*!< Specifies vertical zone coordinate. This parameter is between 0 and 1. */
553 
554 //PSDK_CAMERA_CMD_ID_SET_DIGTALZOOM_FACTOR
555 /**
556  * @brief Set digital zone factor command request data structure.
557  */
558 typedef struct {
559  psdk_f32_t factor; /*!< This parameter is between 1.0 and T_PsdkCameraGetDigitalZoomSpecAck::maxDigitalZoomFactor. */
561 
562 /**
563  * @brief Set digital zone factor command ack data structure.
564  */
565 typedef struct {
566  uint8_t ackCode; /*!< Specifies PSDK command ack code.
567  This parameter can be any value of ::E_PsdkCmdAckCode */
569 
570 //PSDK_CAMERA_CMD_ID_GET_DIGTALZOOM_FACTOR
571 /**
572  * @brief Get digital zone factor command request data structure.
573  */
574 typedef struct {
575  PSDK_EMPTY_STRUCT
577 
578 /**
579  * @brief Get digital zone factor command ack data structure.
580  */
581 typedef struct {
582  uint8_t ackCode; /*!< Specifies PSDK command ack code.
583  This parameter can be any value of ::E_PsdkCmdAckCode */
584  psdk_f32_t factor; /*!< This parameter is between 1.0 and T_PsdkCameraGetDigitalZoomSpecAck::maxDigitalZoomFactor. */
586 
587 //PSDK_CAMERA_CMD_ID_GET_OPTICALZOOM_SPEC
588 /**
589  * @brief Get optical zoom specification command request data structure.
590  */
591 typedef struct {
592  PSDK_EMPTY_STRUCT
594 
595 /**
596  * @brief Get optical zoom specification command ack data structure.
597  */
598 typedef struct {
599  uint8_t ackCode; /*!< Specifies PSDK command ack code.
600  This parameter can be any value of ::E_PsdkCmdAckCode */
601  uint16_t maxFocalLength; /*!< The maximum focal length of the lens, unit: 0.1mm. */
602  uint16_t minFocalLength; /*!< The minimum focal length of the lens, unit: 0.1mm. */
603  uint16_t focalLengthStep; /*!< The minimum interval of focal length change, unit: 0.1mm. */
605 
606 //PSDK_CAMERA_CMD_ID_SET_OPTICALZOOM_FOCAL_LENGTH
607 /**
608  * @brief Set optical zoom focal length command request data structure.
609  */
610 typedef struct {
611  uint16_t focalLength; /*!< Focal length of zoom lens, unit: 0.1mm. */
613 
614 /**
615  * @brief Set optical zoom focal length command ack data structure.
616  */
617 typedef struct {
618  uint8_t ackCode; /*!< Specifies PSDK command ack code.
619  This parameter can be any value of ::E_PsdkCmdAckCode */
621 
622 //PSDK_CAMERA_CMD_ID_GET_OPTICALZOOM_FOCAL_LENGTH
623 /**
624  * @brief Get optical zoom focal length command request data structure.
625  */
626 typedef struct {
627  PSDK_EMPTY_STRUCT
629 
630 /**
631  * @brief Get optical zoom focal length command ack data structure.
632  */
633 typedef struct {
634  uint8_t ackCode; /*!< Specifies PSDK command ack code.
635  This parameter can be any value of ::E_PsdkCmdAckCode */
636  uint16_t focalLength; /*!< Focal length of zoom lens, unit: 0.1mm. */
638 
639 //PSDK_CAMERA_CMD_ID_GET_OPTICALZOOM_FACTOR
640 /**
641  * @brief Get optical zoom fator command request data structure.
642  */
643 typedef struct {
644  PSDK_EMPTY_STRUCT
646 
647 /**
648  * @brief Get optical zoom fator command ack data structure.
649  */
650 typedef struct {
651  uint8_t ackCode; /*!< Specifies PSDK command ack code.
652  This parameter can be any value of ::E_PsdkCmdAckCode */
653  psdk_f32_t factor; /*!< This parameter is between 1.0 and 30.0. */
655 
656 //PSDK_CAMERA_CMD_ID_START_CONTINUOUS_OPTICAL_ZOOM
657 /**
658  * @brief Start continuous optical zoom command request data structure.
659  */
660 typedef struct {
661  uint8_t zoomSpeed; /*!< This parameter can be any value of ::E_PsdkCameraZoomSpeed. */
662  uint8_t zoomDirection; /*!< This parameter can be any value of ::E_PsdkCameraZoomDirection. */
664 
665 /**
666  * @brief Start continuous optical zoom command ack data structure.
667  */
668 typedef struct {
669  uint8_t ackCode; /*!< Specifies PSDK command ack code.
670  This parameter can be any value of ::E_PsdkCmdAckCode */
672 
673 //PSDK_CAMERA_CMD_ID_STOP_CONTINUOUS_OPTICAL_ZOOM
674 /**
675  * @brief Stop continuous optical zoom command request data structure.
676  */
677 typedef struct {
678  PSDK_EMPTY_STRUCT
680 
681 /**
682  * @brief Stop continuous optical zoom command ack data structure.
683  */
684 typedef struct {
685  uint8_t ackCode; /*!< Specifies PSDK command ack code.
686  This parameter can be any value of ::E_PsdkCmdAckCode */
688 
689 //PSDK_CAMERA_CMD_ID_SET_FOCUS_ASSISTANT_SETTING
690 /**
691  * @brief Set focus assistant setting command request data structure.
692  */
693 typedef struct {
694  uint8_t isEnabledAF:1; /*!< Specifies if the lens focus assistant is enabled for auto Focusing.
695  This parameter is boolean type. */
696  uint8_t isEnabledMF:1; /*!< Specifies if the lens focus assistant is enabled for Manual Focusing.
697  This parameter is boolean type. */
698  uint8_t reserved:6;
700 
701 /**
702  * @brief Set focus assistant setting command ack data structure.
703  */
704 typedef struct {
705  uint8_t ackCode; /*!< Specifies PSDK command ack code.
706  This parameter can be any value of ::E_PsdkCmdAckCode */
708 
709 //PSDK_CAMERA_CMD_ID_GET_FOCUS_ASSISTANT_SETTING
710 /**
711  * @brief Get focus assistant setting command request data structure.
712  */
713 typedef struct {
714  PSDK_EMPTY_STRUCT
716 
717 /**
718  * @brief Get focus assistant setting command ack data structure.
719  */
720 typedef struct {
721  uint8_t ackCode; /*!< Specifies PSDK command ack code.
722  This parameter can be any value of ::E_PsdkCmdAckCode */
723  uint8_t isEnabledAF:1; /*!< Specifies if the lens focus assistant is enabled for auto Focusing.
724  This parameter is boolean type. */
725  uint8_t isEnabledMF:1; /*!< Specifies if the lens focus assistant is enabled for Manual Focusing.
726  This parameter is boolean type. */
727  uint8_t reserved:6;
729 
730 //PSDK_CAMERA_CMD_ID_GET_FOCUS_RING_VALUE_UPPER_BOUND
731 /**
732  * @brief Get focus ring value upper bound command request data structure.
733  */
734 typedef struct {
735  PSDK_EMPTY_STRUCT
737 
738 /**
739  * @brief Get focus ring value upper bound command ack data structure.
740  */
741 typedef struct {
742  uint8_t ackCode; /*!< Specifies PSDK command ack code.
743  This parameter can be any value of ::E_PsdkCmdAckCode */
744  uint16_t focusRingValueUpperBound; /*!< Specifies lens focusing ring's max value. */
746 
747 //PSDK_CAMERA_CMD_ID_SET_FOCUS_RING_VALUE
748 /**
749  * @brief Set focus ring value command request data structure.
750  */
751 typedef struct {
752  uint16_t focusRingValue;
754 
755 /**
756  * @brief Set focus ring value command ack data structure.
757  */
758 typedef struct {
759  uint8_t ackCode; /*!< Specifies PSDK command ack code.
760  This parameter can be any value of ::E_PsdkCmdAckCode */
762 
763 //PSDK_CAMERA_CMD_ID_GET_FOCUS_RING_VALUE
764 /**
765  * @brief Get focus ring value command request data structure.
766  */
767 typedef struct {
768  PSDK_EMPTY_STRUCT
770 
771 /**
772  * @brief Get focus ring value command ack data structure.
773  */
774 typedef struct {
775  uint8_t ackCode; /*!< Specifies PSDK command ack code.
776  This parameter can be any value of ::E_PsdkCmdAckCode */
777  uint16_t focusRingValue;
779 
780 //PSDK_CAMERA_CMD_ID_GET_DIGITALZOOM_SPEC
781 /**
782  * @brief Get digital zoom specification command request data structure.
783  */
784 typedef struct {
785  PSDK_EMPTY_STRUCT
787 
788 /**
789  * @brief Get digital zoom specification command ack data structure.
790  */
791 typedef struct {
792  uint8_t ackCode; /*!< Specifies PSDK command ack code.
793  This parameter can be any value of ::E_PsdkCmdAckCode */
794  psdk_f32_t maxDigitalZoomFactor; /*!< Specifies max digital zoom factor. */
796 
797 //PSDK_CAMERA_CMD_ID_SUPPORT_STATE
798 /**
799  * @brief Get camera function support state command request data structure.
800  */
801 typedef struct {
802  PSDK_EMPTY_STRUCT
804 
805 /**
806  * @brief Get camera function support state command ack data structure.
807  */
808 typedef struct {
809  uint8_t ackCode; /*!< Specifies PSDK command ack code.
810  This parameter can be any value of ::E_PsdkCmdAckCode */
811  uint8_t isCameraCmdSetSupport : 1; /*!< Specifies if camera commands is supported. */
812  uint8_t isDigitalZoomSupported : 1; /*!< Specifies if digital zoom is supported. */
813  uint8_t isOpticalZoomSupported : 1; /*!< Specifies if optical zoom is supported. */
814  uint8_t isAdjustableFocalPointSupported : 1;/*!< Specifies if camera focal is adjustable. */
815  uint8_t isExposureMeteringSupported : 1; /*!< Specifies if exposure metering is supported. */
816  uint8_t reserved : 3;
818 
819 #pragma pack()
820 
821 /**
822  * @}
823  */
824 
825 /**
826  * @}
827  */
828 
829 /* Exported variables --------------------------------------------------------*/
830 /* Exported functions --------------------------------------------------------*/
831 /* Private constants ---------------------------------------------------------*/
832 /* Private macros ------------------------------------------------------------*/
833 /* Private types -------------------------------------------------------------*/
834 /* Private variables ---------------------------------------------------------*/
835 /* Private functions ---------------------------------------------------------*/
836 
837 /**
838  * @}
839  */
840 
841 /**
842  * @}
843  */
844 
845 #endif //PSDK_CMD_CAMERA_H
Get optical zoom fator command ack data structure.
Definition: psdk_cmdset_camera.h:650
uint8_t col
Definition: psdk_cmdset_camera.h:448
Get optical zoom specification command request data structure.
Definition: psdk_cmdset_camera.h:591
Get focus ring value upper bound command request data structure.
Definition: psdk_cmdset_camera.h:734
uint8_t ackCode
Definition: psdk_cmdset_camera.h:742
Set focus assistant setting command ack data structure.
Definition: psdk_cmdset_camera.h:704
Set focus mode command ack data structure.
Definition: psdk_cmdset_camera.h:496
uint8_t isShootingBurstPhoto
Definition: psdk_cmdset_camera.h:287
uint8_t row
Definition: psdk_cmdset_camera.h:449
uint8_t cameraMode
Definition: psdk_cmdset_camera.h:227
Get SD card parameter command request data structure.
Definition: psdk_cmdset_camera.h:372
uint8_t ackCode
Definition: psdk_cmdset_camera.h:582
uint8_t ackCode
Definition: psdk_cmdset_camera.h:669
Get digital zoom specification command request data structure.
Definition: psdk_cmdset_camera.h:784
Get digital zone factor command ack data structure.
Definition: psdk_cmdset_camera.h:581
uint8_t ackCode
Definition: psdk_cmdset_camera.h:362
Get focus ring value upper bound command ack data structure.
Definition: psdk_cmdset_camera.h:741
uint8_t burstCount
Definition: psdk_cmdset_camera.h:328
Get focus ring value command request data structure.
Definition: psdk_cmdset_camera.h:767
Set digital zone factor command ack data structure.
Definition: psdk_cmdset_camera.h:565
Set focus ring value command request data structure.
Definition: psdk_cmdset_camera.h:751
uint8_t recordVideoAction
Definition: psdk_cmdset_camera.h:339
Set shoot photo mode command request data structure.
Definition: psdk_cmdset_camera.h:297
Record video action command request data structure.
Definition: psdk_cmdset_camera.h:338
uint8_t zoomSpeed
Definition: psdk_cmdset_camera.h:661
Get camera function support state command ack data structure.
Definition: psdk_cmdset_camera.h:808
uint8_t ackCode
Definition: psdk_cmdset_camera.h:809
uint8_t focusMode
Definition: psdk_cmdset_camera.h:515
uint16_t minFocalLength
Definition: psdk_cmdset_camera.h:602
uint16_t maxFocalLength
Definition: psdk_cmdset_camera.h:601
Get shoot photo mode command ack data structure.
Definition: psdk_cmdset_camera.h:324
uint8_t ackCode
Definition: psdk_cmdset_camera.h:651
psdk_f32_t factor
Definition: psdk_cmdset_camera.h:559
Get focus mode command ack data structure.
Definition: psdk_cmdset_camera.h:512
Set focus assistant setting command request data structure.
Definition: psdk_cmdset_camera.h:693
uint8_t ackCode
Definition: psdk_cmdset_camera.h:413
uint8_t ackCode
Definition: psdk_cmdset_camera.h:234
uint8_t ackCode
Definition: psdk_cmdset_camera.h:325
Shoot photo command request data structure.
Definition: psdk_cmdset_camera.h:259
Get optical zoom focal length command ack data structure.
Definition: psdk_cmdset_camera.h:633
uint8_t isShootingSinglePhoto
Definition: psdk_cmdset_camera.h:285
psdk_f32_t maxDigitalZoomFactor
Definition: psdk_cmdset_camera.h:794
Start continuous optical zoom command ack data structure.
Definition: psdk_cmdset_camera.h:668
uint8_t shootPhotoAction
Definition: psdk_cmdset_camera.h:260
uint8_t isCameraCmdSetSupport
Definition: psdk_cmdset_camera.h:811
Get record video state command ack data structure.
Definition: psdk_cmdset_camera.h:361
uint8_t burstCount
Definition: psdk_cmdset_camera.h:299
uint8_t ackCode
Definition: psdk_cmdset_camera.h:634
uint32_t remainSpaceInMB
Definition: psdk_cmdset_camera.h:396
uint8_t isEnabledMF
Definition: psdk_cmdset_camera.h:725
uint8_t isInvalidFormat
Definition: psdk_cmdset_camera.h:391
uint8_t ackCode
Definition: psdk_cmdset_camera.h:464
uint16_t currentRecordingTimeInSeconds
Definition: psdk_cmdset_camera.h:365
uint8_t reserved
Definition: psdk_cmdset_camera.h:289
Get shoot photo state command ack data structure.
Definition: psdk_cmdset_camera.h:282
uint16_t intervalPhotoCountdown
Definition: psdk_cmdset_camera.h:290
Get digital zoom specification command ack data structure.
Definition: psdk_cmdset_camera.h:791
uint8_t ackCode
Definition: psdk_cmdset_camera.h:309
uint8_t isEnabledMF
Definition: psdk_cmdset_camera.h:696
Get focus assistant setting command request data structure.
Definition: psdk_cmdset_camera.h:713
uint16_t intervalTime
Definition: psdk_cmdset_camera.h:302
uint16_t focalLength
Definition: psdk_cmdset_camera.h:636
uint8_t ackCode
Definition: psdk_cmdset_camera.h:346
Get focus zone command ack data structure.
Definition: psdk_cmdset_camera.h:547
Get camera function support state command request data structure.
Definition: psdk_cmdset_camera.h:801
Format SD card command request data structure.
Definition: psdk_cmdset_camera.h:405
Get camera work mode command ack data structure.
Definition: psdk_cmdset_camera.h:249
Stop continuous optical zoom command ack data structure.
Definition: psdk_cmdset_camera.h:684
uint8_t ackCode
Definition: psdk_cmdset_camera.h:775
uint8_t zoomDirection
Definition: psdk_cmdset_camera.h:662
Set camera work mode command request data structure.
Definition: psdk_cmdset_camera.h:226
uint8_t shootPhotoMode
Definition: psdk_cmdset_camera.h:298
Stop continuous optical zoom command request data structure.
Definition: psdk_cmdset_camera.h:677
psdk_f32_t factor
Definition: psdk_cmdset_camera.h:584
PSDK core include file.
uint8_t isDigitalZoomSupported
Definition: psdk_cmdset_camera.h:812
psdk_f32_t focusY
Definition: psdk_cmdset_camera.h:525
uint8_t isEnabledAF
Definition: psdk_cmdset_camera.h:694
uint8_t isOpticalZoomSupported
Definition: psdk_cmdset_camera.h:813
uint8_t ackCode
Definition: psdk_cmdset_camera.h:705
uint8_t ackCode
Definition: psdk_cmdset_camera.h:721
uint16_t focalLength
Definition: psdk_cmdset_camera.h:611
uint8_t intervalCount
Definition: psdk_cmdset_camera.h:300
uint8_t isRecording
Definition: psdk_cmdset_camera.h:364
uint8_t hasError
Definition: psdk_cmdset_camera.h:392
uint32_t totalSpaceInMB
Definition: psdk_cmdset_camera.h:395
Get optical zoom fator command request data structure.
Definition: psdk_cmdset_camera.h:643
uint8_t ackCode
Definition: psdk_cmdset_camera.h:283
Get optical zoom specification command ack data structure.
Definition: psdk_cmdset_camera.h:598
uint8_t isInitializing
Definition: psdk_cmdset_camera.h:387
uint16_t focusRingValueUpperBound
Definition: psdk_cmdset_camera.h:744
Get optical zoom focal length command request data structure.
Definition: psdk_cmdset_camera.h:626
Get focus ring value command ack data structure.
Definition: psdk_cmdset_camera.h:774
uint16_t focalLengthStep
Definition: psdk_cmdset_camera.h:603
uint8_t isFull
Definition: psdk_cmdset_camera.h:390
Set focus ring value command ack data structure.
Definition: psdk_cmdset_camera.h:758
Record video action command ack data structure.
Definition: psdk_cmdset_camera.h:345
uint8_t isReadOnly
Definition: psdk_cmdset_camera.h:388
Start continuous optical zoom command request data structure.
Definition: psdk_cmdset_camera.h:660
Set focus zone command request data structure.
Definition: psdk_cmdset_camera.h:522
uint8_t ackCode
Definition: psdk_cmdset_camera.h:599
Get record video state command request data structure.
Definition: psdk_cmdset_camera.h:354
Set spot metering zone command ack data structure.
Definition: psdk_cmdset_camera.h:430
Get spot metering zone command ack data structure.
Definition: psdk_cmdset_camera.h:446
uint8_t isShootingIntervalPhoto
Definition: psdk_cmdset_camera.h:286
psdk_f32_t focusX
Definition: psdk_cmdset_camera.h:550
uint8_t meteringMode
Definition: psdk_cmdset_camera.h:457
uint8_t isVerified
Definition: psdk_cmdset_camera.h:384
uint8_t ackCode
Definition: psdk_cmdset_camera.h:431
Shoot photo command ack data structure.
Definition: psdk_cmdset_camera.h:266
uint8_t ackCode
Definition: psdk_cmdset_camera.h:618
Set digital zone factor command request data structure.
Definition: psdk_cmdset_camera.h:558
uint8_t isFormatting
Definition: psdk_cmdset_camera.h:389
Get record video state command ack data structure.
Definition: psdk_cmdset_camera.h:412
uint8_t intervalCount
Definition: psdk_cmdset_camera.h:329
uint8_t ackCode
Definition: psdk_cmdset_camera.h:250
uint8_t isEnabledAF
Definition: psdk_cmdset_camera.h:723
Get shoot photo mode command request data structure.
Definition: psdk_cmdset_camera.h:317
uint8_t cameraMode
Definition: psdk_cmdset_camera.h:252
uint16_t intervalTime
Definition: psdk_cmdset_camera.h:331
Get digital zone factor command request data structure.
Definition: psdk_cmdset_camera.h:574
uint8_t ackCode
Definition: psdk_cmdset_camera.h:792
Set shoot photo mode command ack data structure.
Definition: psdk_cmdset_camera.h:308
uint8_t focusMode
Definition: psdk_cmdset_camera.h:490
uint8_t ackCode
Definition: psdk_cmdset_camera.h:532
psdk_f32_t focusX
Definition: psdk_cmdset_camera.h:523
uint8_t ackCode
Definition: psdk_cmdset_camera.h:759
Set optical zoom focal length command ack data structure.
Definition: psdk_cmdset_camera.h:617
Get spot metering zone command request data structure.
Definition: psdk_cmdset_camera.h:439
uint8_t ackCode
Definition: psdk_cmdset_camera.h:380
psdk_f32_t factor
Definition: psdk_cmdset_camera.h:653
Set spot metering zone command request data structure.
Definition: psdk_cmdset_camera.h:422
uint8_t ackCode
Definition: psdk_cmdset_camera.h:685
Get metering mode command request data structure.
Definition: psdk_cmdset_camera.h:472
Get metering mode command ack data structure.
Definition: psdk_cmdset_camera.h:479
uint8_t ackCode
Definition: psdk_cmdset_camera.h:566
Get focus assistant setting command ack data structure.
Definition: psdk_cmdset_camera.h:720
Set focus mode command request data structure.
Definition: psdk_cmdset_camera.h:489
Set camera work mode command ack data structure.
Definition: psdk_cmdset_camera.h:233
uint8_t col
Definition: psdk_cmdset_camera.h:423
uint32_t availableRecordingTimeInSeconds
Definition: psdk_cmdset_camera.h:398
Get focus mode command request data structure.
Definition: psdk_cmdset_camera.h:505
uint8_t row
Definition: psdk_cmdset_camera.h:424
uint8_t isInserted
Definition: psdk_cmdset_camera.h:382
Get shoot photo state command request data structure.
Definition: psdk_cmdset_camera.h:275
psdk_f32_t focusY
Definition: psdk_cmdset_camera.h:551
uint8_t ackCode
Definition: psdk_cmdset_camera.h:267
Get focus zone command request data structure.
Definition: psdk_cmdset_camera.h:540
Set focus zone command ack data structure.
Definition: psdk_cmdset_camera.h:531
uint8_t shootPhotoMode
Definition: psdk_cmdset_camera.h:327
uint8_t ackCode
Definition: psdk_cmdset_camera.h:548
Get camera work mode command request data structure.
Definition: psdk_cmdset_camera.h:242
Set metering mode command ack data structure.
Definition: psdk_cmdset_camera.h:463
uint8_t isExposureMeteringSupported
Definition: psdk_cmdset_camera.h:815
uint8_t ackCode
Definition: psdk_cmdset_camera.h:513
uint8_t ackCode
Definition: psdk_cmdset_camera.h:480
uint8_t meteringMode
Definition: psdk_cmdset_camera.h:482
Set metering mode command request data structure.
Definition: psdk_cmdset_camera.h:456
Get SD card parameter command ack data structure.
Definition: psdk_cmdset_camera.h:379
uint8_t isStoringPhoto
Definition: psdk_cmdset_camera.h:288
uint8_t ackCode
Definition: psdk_cmdset_camera.h:497
uint32_t availableCaptureCount
Definition: psdk_cmdset_camera.h:397
uint8_t isAdjustableFocalPointSupported
Definition: psdk_cmdset_camera.h:814
Set optical zoom focal length command request data structure.
Definition: psdk_cmdset_camera.h:610