Skip to content
This SDK only works with devices released within the past 3 years. We regularly optimize and update the SDK to ensure compatibility and performance. We do not guarantee compatibility or provide technical support for devices older than 3 years.

# PTZ_CMD_TYPE

### Enum Definition

C++C#

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    typedef enum _ptz_com_type
    {
        PTZ_CMD_STOP = 0,
        PTZ_CMD_LEFT,
        PTZ_CMD_RIGHT,
        PTZ_CMD_UP,
        PTZ_CMD_DOWN,
        PTZ_CMD_LEFT_UP,
        PTZ_CMD_LEFT_DOWN,
        PTZ_CMD_RIGHT_UP,
        PTZ_CMD_RIGHT_DOWN,
        PTZ_CMD_NEAR,
        PTZ_CMD_FAR,
        PTZ_CMD_ZOOM_OUT,
        PTZ_CMD_ZOOM_IN,
        PTZ_CMD_IRIS_OPEN,
        PTZ_CMD_IRIS_CLOSE,
        PTZ_CMD_PRESET_SET,
        PTZ_CMD_PRESET_GO,
        PTZ_CMD_PRESET_DEL,
        PTZ_CMD_CRUISE_CFG,
        PTZ_CMD_ENTER_CURISE_MODE,
        PTZ_CMD_CRUISE_SET,
        PTZ_CMD_LEAVE_CURISE_MODE,
        PTZ_CMD_CRUISE_RUN,
        PTZ_CMD_CRUISE_STOP,
        PTZ_CMD_CRUISE_DEL,
        PTZ_CMD_TRACK_START,
        PTZ_CMD_TRACK_STOP,
        PTZ_CMD_TRACK_START_RECORD,
        PTZ_CMD_TRACK_STOP_RECORD,
        PTZ_CMD_AUTO_SCAN_START,
        PTZ_CMD_AUTO_SCAN_STOP,
        PTZ_CMD_RESET = 0xF0,
    } PTZ_CMD_TYPE;

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    public enum PTZ_CMD_TYPE
    {
        PTZ_CMD_STOP = 0,
        PTZ_CMD_LEFT,
        PTZ_CMD_RIGHT,
        PTZ_CMD_UP,
        PTZ_CMD_DOWN,
        PTZ_CMD_LEFT_UP,
        PTZ_CMD_LEFT_DOWN,
        PTZ_CMD_RIGHT_UP,
        PTZ_CMD_RIGHT_DOWN,
        PTZ_CMD_NEAR,
        PTZ_CMD_FAR,
        PTZ_CMD_ZOOM_OUT,
        PTZ_CMD_ZOOM_IN,
        PTZ_CMD_IRIS_OPEN,
        PTZ_CMD_IRIS_CLOSE,
        PTZ_CMD_PRESET_SET,
        PTZ_CMD_PRESET_GO,
        PTZ_CMD_PRESET_DEL,
        PTZ_CMD_CRUISE_CFG,
        PTZ_CMD_ENTER_CURISE_MODE,
        PTZ_CMD_CRUISE_SET,
        PTZ_CMD_LEAVE_CURISE_MODE,
        PTZ_CMD_CRUISE_RUN,
        PTZ_CMD_CRUISE_STOP,
        PTZ_CMD_CRUISE_DEL,
        PTZ_CMD_TRACK_START,
        PTZ_CMD_TRACK_STOP,
        PTZ_CMD_TRACK_START_RECORD,
        PTZ_CMD_TRACK_STOP_RECORD,
        PTZ_CMD_AUTO_SCAN_START,
        PTZ_CMD_AUTO_SCAN_STOP,
        PTZ_CMD_RESET = 0xF0,
    }

### Function Description

PTZ control commands.

### Member Description

Enum name | Value | Remark
--- | --- | ---
PTZ_CMD_STOP | 0 | Stop.
PTZ_CMD_LEFT | 1 | Left.
PTZ_CMD_RIGHT | 2 | Right.
PTZ_CMD_UP | 3 | Superior.
PTZ_CMD_DOWN | 4 | Down.
PTZ_CMD_LEFT_UP | 5 | Top left.
PTZ_CMD_LEFT_DOWN | 6 | Lower left.
PTZ_CMD_RIGHT_UP | 7 | Top right.
PTZ_CMD_RIGHT_DOWN | 8 | Lower right.
PTZ_CMD_NEAR | 9 | Zoom in.
PTZ_CMD_FAR | 10 | Adjust far.
PTZ_CMD_ZOOM_OUT | 11 | Zoom out.
PTZ_CMD_ZOOM_IN | 12 | Enlarge.
PTZ_CMD_IRIS_OPEN | 13 | Open the aperture.
PTZ_CMD_IRIS_CLOSE | 14 | Close the aperture.
PTZ_CMD_PRESET_SET | 15 | Set preset points.
PTZ_CMD_PRESET_GO | 16 | To the preset point.
PTZ_CMD_PRESET_DEL | 17 | Delete preset point.
PTZ_CMD_CRUISE_CFG | 18 | Setting the cruise line is equivalent to executing the Enter, Set, and Leave commands.
PTZ_CMD_ENTER_CURISE_MODE | 19 | Enter the cruise mode, after which you can set the cruise preset points.
PTZ_CMD_CRUISE_SET | 20 | Set the preset points of the cruise line.
PTZ_CMD_LEAVE_CURISE_MODE | 21 | Exit the settings cruise.
PTZ_CMD_CRUISE_RUN | 22 | Choose a cruise line to cruise on.
PTZ_CMD_CRUISE_STOP | 23 | Stop cruising.
PTZ_CMD_CRUISE_DEL | 24 | Remove the cruise line.
PTZ_CMD_TRACK_START | 25 | Start the track.
PTZ_CMD_TRACK_STOP | 26 | Stop the track.
PTZ_CMD_TRACK_START_RECORD | 27 | Start saving the track.
PTZ_CMD_TRACK_STOP_RECORD | 28 | Stop saving tracks.
PTZ_CMD_AUTO_SCAN_START | 29 | Start automatic scanning.
PTZ_CMD_AUTO_SCAN_STOP | 30 | Stop automatic scanning.
PTZ_CMD_RESET | 0xF0 | Reset the gimbal status.

Error Code