EZOpenSDK  v4.7.1
 All Classes Functions Properties
EZConstants.h
1 //
2 // EZConstants.h
3 // EzvizOpenSDK
4 //
5 // Created by DeJohn Dong on 16/7/20.
6 // Copyright © 2016Ezviz.. All rights reserved.
7 //
8 
9 #import <Foundation/Foundation.h>
10 
11 /* EZOpenSDK error code */
12 typedef NS_ENUM(NSInteger, EZErrorCode) {
16  EZ_DEVICE_TTS_REQUEST_TIMEOUT = 360001, //Request time out.
17  EZ_DEVICE_TTS_TALKING_TIMEOUT = 360002, //Starting two-way audio timed out.
18  EZ_DEVICE_TTS_DEVICE_CONNECT_ERROR = 360003, //Device error.
19  EZ_DEVICE_TTS_INTER_ERROR = 360004, //Internal error.
20  EZ_DEVICE_TTS_SEND_ERROR = 360005, //Message error sent by the client.
21  EZ_DEVICE_TTS_RECEIVE_ERROR = 360006, //Client receiving error.
22  EZ_DEVICE_TTS_CLOSE_CONNECT = 360007, //Connection closed by TTS.
23  EZ_DEVICE_TTS_TALKING = 360010, //Device is in the two-way audio.
24  EZ_DEVICE_TTS_PRIVACY_PROTECT = 360013, //The device opens the privacy protection.
25 
29  EZ_DEVICE_IS_PRIVACY_PROTECTING = 380011, //The smart mask of the device is enabled.
30  EZ_DEVICE_CONNECT_COUNT_LIMIT = 380045, //No more devices can be connected directly for streaming.
31  EZ_DEVICE_COMMAND_NOT_SUPPORT = 380047, //Not supported by the device.
32  EZ_DEVICE_CAS_TALKING = 380077, //Device is in the two-way audio.
33  EZ_DEVICE_CAS_PARSE_ERROR = 380205, //Incorrect inputted parameter
34  EZ_PLAY_TIMEOUT = 380209, //Network connection timed out
35  EZ_DEVICE_TIMEOUT = 380212, //Connecting device to network timed out.
36  EZ_STREAM_CLIENT_TIMEOUT = 390038, //Streaming timed out
37  EZ_STREAM_CLIENT_NOT_FIND_FILE = 395402, //No video found. Check if the imported video is valid.
38  EZ_STREAM_CLIENT_OFFLINE = 395404, //Device offline.
39  EZ_STREAM_CLIENT_TOKEN_INVALID = 395406, //Streaming token verification failed.
40  EZ_STREAM_CLIENT_PRIVACY_PROTECT = 395409, //The smart mask of the device is enabled.
41  EZ_STREAM_CLIENT_DEVICE_COUNT_LIMIT = 395410, //Excessive number of equipment connections.
42  EZ_STREAM_CLIENT_TOKEN_LIMIT = 395411, //Token no authority.
43  EZ_STREAM_CLIENT_CAMERANO_ERROR = 395415, //Incorrect camera.
44  EZ_STREAM_CLIENT_TYPE_UNSUPPORT = 395451, //The type of bit stream that is not supported by the device.
45  EZ_STREAM_CLIENT_CONNECT_SERVER_ERROR = 395452, //Connect preview streaming media server failure
46  EZ_STREAM_CLIENT_SESSION_NOT_EXIST = 395454, //Session does not exist.
47  EZ_STREAM_CLIENT_SAME_REQUEST = 395491, //The same request is being processed, refusing this processing.
48  EZ_STREAM_CLIENT_INNER_ERROR = 395500, //Internal processing error of streaming media server.
49  EZ_STREAM_CLIENT_NO_SOURCE = 395544, //Device returns without video source.
50  EZ_STREAM_CLIENT_VIDEO_OUT_SHARE_TIME = 395545, //Video sharing time has come to an end.
51  EZ_STREAM_CLIENT_LIMIT = 395546, //Device streaming is limited.
52  EZ_STREAM_CLIENT_DEVICE_OUT_SHARE_TIME = 395600, //Sharing equipment is not in sharing time.
53 
57  EZ_HTTPS_PARAM_ERROR = 110001, //Request parameter error
58  EZ_HTTPS_ACCESS_TOKEN_INVALID = 110002, //Invalid AccessToken
59  EZ_HTTPS_ACCESS_TOKEN_EXPIRE = 110003, //expired AccessToken
60  EZ_HTTPS_REGIST_USER_NOT_EXSIT = 110004, //The user does not exist
61  EZ_HTTPS_APPKEY_ERROR = 110005, //AppKey exception
62  EZ_HTTPS_IP_LIMIT = 110006, //ip limited
63  EZ_HTTPS_INVOKE_LIMIT = 110007, //The number of calls reached the upper limit.
64  EZ_HTTPS_USER_BINDED = 110012, //The third-party account already linked with Hik-Connect.
65  EZ_HTTPS_APPKEY_IS_NULL = 110017, //AppKey does not exist
66  EZ_HTTPS_APPKEY_NOT_MATCHED = 110018, //Mismatched.Check if the configured server appKey and SDK appKey are same.
67  EZ_HTTPS_CAMERA_NOT_EXISTS = 120001, //The camera does not exist. Check if the camera is re-added.
68  EZ_HTTPS_DEVICE_NOT_EXISTS = 120002, //The device does not exist.
69  EZ_HTTPS_DEVICE_NETWORK_ANOMALY = 120006, //Network exception.
70  EZ_HTTPS_DEVICE_OFFLINE = 120007, //The device is offline.
71  EZ_HTTPS_DEIVCE_RESPONSE_TIMEOUT = 120008, //Response timed out.
72  EZ_HTTPS_DEVICE_VALICATECODE_ERROR = 120010, //Device verification code error
73  EZ_HTTPS_ILLEGAL_DEVICE_SERIAL = 120014, //Invalid serial No.
74  EZ_HTTPS_DEVICE_STORAGE_FORMATTING = 120016, //The device HDD is formatting.
75  EZ_HTTPS_DEVICE_ADDED_MYSELF = 120017, //The device is already added.
76  EZ_HTTPS_USER_NOT_OWN_THIS_DEVICE = 120018, //The user has no permission of the device.
77  EZ_HTTPS_DEVICE_UNSUPPORT_CLOUD = 120019, //Device does not support cloud storage services.
78  EZ_HTTPS_DEVICE_ONLINE_ADDED = 120020, //The device is already added.
79  EZ_HTTPS_DEVICE_ONLINE_NOT_ADDED = 120021, //The device is online. But it is not added.
80  EZ_HTTPS_DEVICE_ONLINE_IS_ADDED = 120022, //The device is online. But it is added by other user.
81  EZ_HTTPS_DEVICE_OFFLINE_NOT_ADDED = 120023, //The device is offline. But it is not added.
82  EZ_HTTPS_DEVICE_OFFLINE_IS_ADDED = 120024, //The device is offline. But it is added by other user.
83  EZ_HTTPS_DEVICE_OFFLINE_IS_ADDED_MYSELF = 120029, //The device is offline. But it is already added.
84  EZ_HTTPS_DEVICE_BUNDEL_STATUS_ON = 120031, //The access configuration is enabled. Disable it via Hik-Connect Client.
85  EZ_HTTPS_OPERATE_LEAVE_MSG_FAIL = 120202, //Failed to handle the leave message.
86  EZ_HTTPS_SERVER_DATA_ERROR = 149999, //Data exception
87  EZ_HTTPS_SERVER_ERROR = 150000, //Server exception
88  EZ_HTTPS_DEVICE_PTZ_NOT_SUPPORT = 160000, //PTZ control is not supported by the device
89  EZ_HTTPS_DEVICE_PTZ_NO_PERMISSION = 160001, //No permission
90  EZ_HTTPS_DEVICE_PTZ_UPPER_LIMIT = 160002, //PTZ reaches the up limit.
91  EZ_HTTPS_DEVICE_PTZ_FLOOR_LIMIT = 160003, //PTZ reaches the bottom limit.
92  EZ_HTTPS_DEVICE_PTZ_LEFT_LIMIT = 160004, //PTZ reaches the left limit.
93  EZ_HTTPS_DEVICE_PTZ_RIGHT_LIMIT = 160005, //PTZ reaches the right limit.
94  EZ_HTTPS_DEVICE_PTZ_FAILED = 160006, //PTZ control failed.
95  EZ_HTTPS_DEVICE_PTZ_RESETING = 160009, //PTZ is calling presets.
96  EZ_HTTPS_DEVICE_COMMAND_NOT_SUPPORT = 160020, //Not supported by the device
97 
101  EZ_SDK_PARAM_ERROR = 400002, //API parameter error
102  EZ_SDK_NOT_SUPPORT_TALK = 400025, //Two-way audio is not supported by the device
103  EZ_SDK_TIMEOUT = 400034, //No play token. Restart the player.
104  EZ_SDK_NEED_VALIDATECODE = 400035, //Required device verification code
105  EZ_SDK_VALIDATECODE_NOT_MATCH = 400036, //Device verification code mismatched
106  EZ_SDK_DECODE_TIMEOUT = 400041, //Decoding timed out. Incorrect verification code
107  EZ_SDK_STREAM_TIMEOUT = 400015, //Streaming timed out. Check the mobile phone network.
108  EZ_SDK_PLAYBACK_STREAM_TIMEOUT = 400409, //Playback streaming timed out. Check the mobile phone network.
109 };
110 
111 /* Wi-Fi status */
112 typedef NS_ENUM(NSInteger, EZWifiConfigStatus) {
113  DEVICE_WIFI_CONNECTING = 1, //Connecting the device to Wi-Fi
114  DEVICE_WIFI_CONNECTED = 2, //The device is connected to Wi-Fi
115  DEVICE_PLATFORM_REGISTED = 3, //The device is registered
116  DEVICE_ACCOUNT_BINDED = 4 //The device is linked to the user
117 };
118 
119 /* PTZ command */
120 typedef NS_OPTIONS(NSUInteger, EZPTZCommand) {
121  EZPTZCommandLeft = 1 << 0, //Pan left
122  EZPTZCommandRight = 1 << 1, //Pan right
123  EZPTZCommandUp = 1 << 2, //Tilt up
124  EZPTZCommandDown = 1 << 3, //Tilt down
125  EZPTZCommandZoomIn = 1 << 4, //Zoom in
126  EZPTZCommandZoomOut = 1 << 5, //Zoom out
127 };
128 
129 /*
130  * Display command
131  */
132 typedef NS_OPTIONS(NSUInteger, EZDisplayCommand) {
133  EZDisplayCommandCenter = 1 << 0, //Display the live view screen center
134 };
135 
139 typedef NS_ENUM(NSInteger, EZPTZAction) {
140  EZPTZActionStart = 1, //Start
141  EZPTZActionStop = 2 //Stop
142 };
143 
144 /* Message status */
145 typedef NS_ENUM(NSInteger, EZMessageStatus) {
146  EZMessageStatusRead = 1, //Has been read
147 };
148 
149 /* Message type */
150 typedef NS_ENUM(NSInteger, EZMessageType)
151 {
152  EZMessageTypeAlarm = 1, //Alarm type
153  EZMessageTypeLeave, //Leave message type
154 };
155 
156 /* Leave message type */
157 typedef NS_ENUM(NSInteger, EZLeaveMessageType)
158 {
159  EZLeaveMessageTypeAll, //All
160  EZLeaveMessageTypeVoice, //Voice message
161  EZLeaveMessageTypeVideo, //Video message
162 };
163 
164 /* Device arming status enumeration */
165 typedef NS_ENUM(NSInteger, EZDefenceStatus) {
166  EZDefenceStatusOffOrSleep = 0, //Security control panel sleeping mode or disarming status of non-security control panel device
167  EZDefenceStatusOn = 1, //Arming status of non-security control panel device
168  EZDefenceStatusAtHome = 8, //Security control panel at-home mode
169  EZDefenceStatusOuter = 16, //Security control panel leaving-home mode
170 };
171 
172 /* Video quality. Not all the devices video has such quality, please choose the device according to actual situation.*/
173 typedef NS_ENUM(NSInteger, EZVideoLevelType)
174 {
175  EZVideoLevelLow = 0, //Fluent
176  EZVideoLevelMiddle = 1, //SD
177  EZVideoLevelHigh = 2, //HD
178  EZVideoLevelSuperHigh = 3 //Ultra HD
179 };
180 
182 @interface EZConstants : NSObject
183 
184 @end
Open Hik-Connect system constant.
Definition: EZConstants.h:182