Device Network SDK (Video Intercom) - Developer Guide - V6.1.7.X - 20230330
Device Network SDK (Video Intercom) - Developer Guide - V6.1.7.X - 20230330
Developer Guide
Device Network SDK (Video Intercom) Developer Guide
Legal Information
TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THE DOCUMENT IS PROVIDED "AS IS"
AND "WITH ALL FAULTS AND ERRORS". OUR COMPANY MAKES NO REPRESENTATIONS OR
WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. IN NO EVENT
WILL OUR COMPANY BE LIABLE FOR ANY SPECIAL, CONSEQUENTIAL, INCIDENTAL, OR INDIRECT
DAMAGES, INCLUDING, AMONG OTHERS, DAMAGES FOR LOSS OF BUSINESS PROFITS, BUSINESS
INTERRUPTION OR LOSS OF DATA, CORRUPTION OF SYSTEMS, OR LOSS OF DOCUMENTATION,
WHETHER BASED ON BREACH OF CONTRACT, TORT (INCLUDING NEGLIGENCE), OR OTHERWISE, IN
CONNECTION WITH THE USE OF THE DOCUMENT, EVEN IF OUR COMPANY HAS BEEN ADVISED OF
THE POSSIBILITY OF SUCH DAMAGES OR LOSS.
i
Device Network SDK (Video Intercom) Developer Guide
Contents
Chapter 1 Overview .................................................................................................................... 1
1.1 Introduction ........................................................................................................................... 1
1.2 Update History ....................................................................................................................... 1
Chapter 2 Start Video Intercom .................................................................................................. 4
Chapter 3 Manage Ring .............................................................................................................. 7
Chapter 4 Get Registration Information of Door Station ............................................................. 9
Chapter 5 Configure Video Intercom Alarm or Event ................................................................. 11
Chapter 6 Alarm/Event Receiving ............................................................................................. 14
6.1 Receive Alarm/Event in Arming Mode ................................................................................. 14
6.2 Receive Alarm/Event in Listening Mode .............................................................................. 17
Chapter 7 Remote Configuration .............................................................................................. 21
Chapter 8 Module Configuration ............................................................................................... 25
Chapter 9 Maintenance ............................................................................................................ 26
Chapter 10 API Reference ......................................................................................................... 27
10.1 NET_DVR_Cleanup ............................................................................................................. 27
10.2 NET_DVR_GetDeviceAbility ............................................................................................... 27
10.3 NET_DVR_GetDeviceConfig ............................................................................................... 28
10.4 NET_DVR_GetDVRConfig ................................................................................................... 29
10.5 NET_DVR_GetErrorMsg ..................................................................................................... 30
10.6 NET_DVR_GetLastError ...................................................................................................... 31
10.7 NET_DVR_GetNextRemoteConfig ...................................................................................... 31
10.8 NET_DVR_GetUploadState ................................................................................................ 32
10.9 NET_DVR_Init ..................................................................................................................... 34
10.10 NET_DVR_Login_V40 ....................................................................................................... 35
10.10.1 fLoginResultCallBack ............................................................................................... 35
10.11 NET_DVR_Logout ............................................................................................................. 36
ii
Device Network SDK (Video Intercom) Developer Guide
iii
Device Network SDK (Video Intercom) Developer Guide
iv
Device Network SDK (Video Intercom) Developer Guide
v
Device Network SDK (Video Intercom) Developer Guide
vi
Device Network SDK (Video Intercom) Developer Guide
vii
Device Network SDK (Video Intercom) Developer Guide
viii
Device Network SDK (Video Intercom) Developer Guide
Chapter 1 Overview
1.1 Introduction
The video intercom is a stand-alone intercom system used to manage calls made at the entrance to
a building (e.g., residential complex, detached family home, workplace, etc.) with access controlled
by audiovisual communication between the inside and outside. This manual introduces the typical
applications (e.g., starting video intercom, ring management, and so on) and video intercom APIs
of device network SDK (hereafter referred to as "HCNetSDK").
1
Device Network SDK (Video Intercom) Developer Guide
2
Device Network SDK (Video Intercom) Developer Guide
added two nodes, i.e., <isSupportSubModules> (whether to support sub module management)
and <isSupportSubModulesCfg> (whether to support configuring sub module).
3
Device Network SDK (Video Intercom) Developer Guide
4
Device Network SDK (Video Intercom) Developer Guide
Steps
5
Device Network SDK (Video Intercom) Developer Guide
The macro definition value of connection status (i.e., 0, 1, or 2) and related data (i.e., status
value (1000, 1001, 1002), progress value, or data structure NET_DVR_VIDEO_CALL_PARAM ) are
returned by dwType and lpBuffer, respectively, in the callback function.
3. Call NET_DVR_SendRemoteConfig , set dwDataType to "0", and set pSendBuf to
NET_DVR_VIDEO_CALL_PARAM for transmitting video intercom data.
4. Call NET_DVR_StopRemoteConfig to disable the persistent connection and stop video intercom.
What to do next
Call NET_DVR_Logout and NET_DVR_Cleanup to log out of the device and release the
development resources.
6
Device Network SDK (Video Intercom) Developer Guide
Steps
7
Device Network SDK (Video Intercom) Developer Guide
Note
The macro definition value of connection status (i.e., 0 or 2) and related data
(i.e., status value (1000, 1001, 1002) or search result structure
( NET_DVR_RING_SEARCH_CFG )) are returned by dwType and lpBuffer,
respectively, in the callback function.
b. Call NET_DVR_StopRemoteConfig to disable the persistent connection and
stop ring search when the called back status value is "1000".
Delete Call NET_DVR_STDXMLConfig to pass through the request URL: DELETE /ISAPI/
Ring by VideoIntercom/ring/ringID/<ID> .
Ring ID
Delete All Call NET_DVR_STDXMLConfig to pass through the request URL: DELETE /ISAPI/
Rings VideoIntercom/ring .
Upload a. Call NET_DVR_UploadFile_V40 , set dwUploadType to "UPLOAD_RING_FILE"
Ring File (macro definition value: 20), and set lpOutBuffer to
NET_DVR_RING_UPLOAD_CFG for uploading ring file.
b. Call NET_DVR_GetUploadState to get file uploading progress.
c. Call NET_DVR_UploadClose to stop uploading ring file when the returned
uploading progress is "100".
What to do next
Call NET_DVR_Logout and NET_DVR_Cleanup to log out of the device and release the
development resources.
8
Device Network SDK (Video Intercom) Developer Guide
Steps
9
Device Network SDK (Video Intercom) Developer Guide
10
Device Network SDK (Video Intercom) Developer Guide
11
Device Network SDK (Video Intercom) Developer Guide
Steps
12
Device Network SDK (Video Intercom) Developer Guide
13
Device Network SDK (Video Intercom) Developer Guide
● Make sure you have configured the alarm/event parameters, refer to the typical alarm/event
14
Device Network SDK (Video Intercom) Developer Guide
Steps
Note
● If the configured alarm is triggered or event occurred, the alarm/event information will be
uploaded by device and returned in the callback function. You can view the alarm/event and
do some processing operations.
● For the integration via device network SDK (HCNetSDK), to receive different types of alarm/
event information, the parameter lCommand (data type to be uploaded) in the configured
callback function should be different (refer to the typical alarm/event configurations). For the
integration via text protocol, the lCommand should be set to "COMM_ISAPI_ALARM"
(command No.: 0x6009) and the input parameter pAlarmInfo in the callback function
MSGCallBack should be set to NET_DVR_ALARM_ISAPI_INFO .
2. Call NET_DVR_SetupAlarmChan_V50 to set up uploading channel.
3. Call NET_DVR_CloseAlarmChan_V30 to close uploading channel and stop receiving alarm or
event information.
Example
Sample Code of Receiving Alarm or Event in Arming Mode
15
Device Network SDK (Video Intercom) Developer Guide
#include <stdio.h>
#include <iostream>
#include "Windows.h"
#include "HCNetSDK.h"
using namespace std;
void main() {
//---------------------------------------
// Initialize
NET_DVR_Init();
//Set connection time and reconnection time
NET_DVR_SetConnectTime(2000, 1);
NET_DVR_SetReconnect(10000, true);
//---------------------------------------
// Log in to device
LONG lUserID;
//Login parameters, including device IP address, user name, password, and so on.
NET_DVR_USER_LOGIN_INFO struLoginInfo = {0};
struLoginInfo.bUseAsynLogin = 0; //Synchronous login mode
strcpy(struLoginInfo.sDeviceAddress, "192.0.0.64"); //Device IP address
struLoginInfo.wPort = 8000; //Service port No.
strcpy(struLoginInfo.sUserName, "admin"); //User name
strcpy(struLoginInfo.sPassword, "abcd1234"); //Password
//Device information, output parameter
NET_DVR_DEVICEINFO_V40 struDeviceInfoV40 = {0};
lUserID = NET_DVR_Login_V40(&struLoginInfo, &struDeviceInfoV40);
if (lUserID < 0)
{
printf("Login failed, error code: %d\n", NET_DVR_GetLastError());
NET_DVR_Cleanup();
return;
}
//Enable arming
NET_DVR_SETUPALARM_PARAM_V50 struSetupParamV50={0};
struSetupParamV50.dwSize=sizeof(NET_DVR_SETUPALARM_PARAM_V50);
//Alarm category to be uploaded
struSetupParamV50.byAlarmInfoType=1;
//Arming level
struSetupParamV50.byLevel=1;
16
Device Network SDK (Video Intercom) Developer Guide
//Arm
lHandle = NET_DVR_SetupAlarmChan_V50(lUserID, &struSetupParamV50, NULL, strlen(szSubscribe));
}
else
{
//Subscribe
LlHandle = NET_DVR_SetupAlarmChan_V50(lUserID, &struSetupParamV50, szSubscribe, strlen(szSubscribe));
}
if (lHandle < 0)
{
printf("NET_DVR_SetupAlarmChan_V50 error, %d\n", NET_DVR_GetLastError());
NET_DVR_Logout(lUserID);
NET_DVR_Cleanup();
return;
}
Sleep(20000);
//Disarm the uploading channel
if (!NET_DVR_CloseAlarmChan_V30(lHandle))
{
printf("NET_DVR_CloseAlarmChan_V30 error, %d\n", NET_DVR_GetLastError());
NET_DVR_Logout(lUserID);
NET_DVR_Cleanup();
return;
}
//Log out
NET_DVR_Logout(lUserID);
//Release resources
NET_DVR_Cleanup();
return;
}
What to do next
Call NET_DVR_Logout and NET_DVR_Cleanup to log out and release resources.
● Make sure you have configured the alarm/event parameters, refer to the typical alarm/event
17
Device Network SDK (Video Intercom) Developer Guide
Steps
18
Device Network SDK (Video Intercom) Developer Guide
Note
For the integration via device network SDK (HCNetSDK), to receive different types of alarm/
event information, the parameter lCommand (data type to be uploaded) in the configured
callback function should be different (refer to the typical alarm/event configurations). For the
integration via text protocol, the lCommand should be set to "COMM_ISAPI_ALARM" and the
input parameter pAlarmInfo in the callback function MSGCallBack should be set to
NET_DVR_ALARM_ISAPI_INFO .
The alarm/event information is automatically uploaded by the device when the configured
alarm is triggered or event occurred, and the third-party platform or system gets the alarm/
event information from the configured callback function.
5. Call NET_DVR_StopListen_V30 to stop listening and receiving alarm or event information.
Example
Sample Code of Receiving Alarm/Event in Listening Mode
#include <stdio.h>
#include <iostream>
#include "Windows.h"
#include "HCNetSDK.h"
using namespace std;
void main() {
//---------------------------------------
// Initialize
NET_DVR_Init();
//Set connection time and reconnection time
NET_DVR_SetConnectTime(2000, 1);
NET_DVR_SetReconnect(10000, true);
//---------------------------------------
// Log in to device
LONG lUserID;
NET_DVR_DEVICEINFO_V30 struDeviceInfo;
lUserID = NET_DVR_Login_V30("172.0.0.100", 8000, "admin", "12345", &struDeviceInfo);
if (lUserID < 0)
{
printf("Login error, %d\n", NET_DVR_GetLastError());
NET_DVR_Cleanup();
return;
}
//Enable listening
LONG lHandle;
lHandle = NET_DVR_StartListen_V30(NULL,7200, MessageCallback, NULL);
if (lHandle < 0)
{
printf("NET_DVR_StartListen_V30 error, %d\n", NET_DVR_GetLastError());
NET_DVR_Logout(lUserID);
NET_DVR_Cleanup();
return;
}
Sleep(5000);
19
Device Network SDK (Video Intercom) Developer Guide
//Disable listening
if (!NET_DVR_StopListen_V30(lHandle))
{
printf("NET_DVR_StopListen_V30 error, %d\n", NET_DVR_GetLastError());
NET_DVR_Logout(lUserID);
NET_DVR_Cleanup();
return;
}
//Log out
NET_DVR_Logout(lUserID);
//Release SDK resource
NET_DVR_Cleanup();
return;
}
What to do next
Call NET_DVR_Logout (if logged in) and NET_DVR_Cleanup to log out and release resources.
20
Device Network SDK (Video Intercom) Developer Guide
Device Settings
● Get video intercom device parameters, such as device No., type, registration type, and so on.
Call NET_DVR_GetDVRConfig with "NET_DVR_GET_VIDEO_INTERCOM_DEVICEID_CFG"
(command No.: 16001) and set lChannel to "0xFFFFFFFF".
The video intercom device parameters are returned in the structure
NET_DVR_VIDEO_INTERCOM_DEVICEID_CFG by lpOutBuffer.
● Set video intercom device No.
Call NET_DVR_SetDVRConfig with "NET_DVR_SET_VIDEO_INTERCOM_DEVICEID_CFG"
(command No.: 16002), set lChannel to "0xFFFFFFFF", and set lpInBuffer to the structure
NET_DVR_VIDEO_INTERCOM_DEVICEID_CFG .
Network Settings
● Get network parameters of video intercom device
Call NET_DVR_GetDVRConfig with "NET_DVR_GET_VIDEO_INTERCOM_RELATEDEV_CFG"
(command No.: 16006) and set lChannel to "0xFFFFFFFF".
The network parameters of video intercom device are returned in the structure
NET_DVR_VIDEO_INTERCOM_RELATEDEV_CFG by lpOutBuffer.
● Set network parameters of video intercom device
Call NET_DVR_SetDVRConfig with "NET_DVR_SET_VIDEO_INTERCOM_RELATEDEV_CFG"
(command No.: 16007), set lChannel to "0xFFFFFFFF", and set lpInBuffer to the structure
NET_DVR_VIDEO_INTERCOM_RELATEDEV_CFG .
Security Settings
● Set passwords for different permissions of video intercom device
Call NET_DVR_SetDVRConfig with "NET_DVR_SET_PRIVILEGE_PASSWORD" (command No.:
16003), set lChannel to "0xFFFFFFFF", and set lpInBuffer to the structure
NET_DVR_PRIVILEGE_PASSWORD_CFG .
● Get encryption verification capability of video intercom
Call NET_DVR_STDXMLConfig to transmit the request URI: GET /ISAPI/VideoIntercom/
passwordAuthentication/capabilities .
The capability is returned in the message XML_Cap_PasswordAuthenticationCfg by
lpOutBuffer.
● Verify video intercom encryption
Call NET_DVR_STDXMLConfig to transmit the request URI: PUT /ISAPI/VideoIntercom/
passwordAuthentication and set lpInBuffer to the message XML_PasswordAuthenticationCfg .
21
Device Network SDK (Video Intercom) Developer Guide
I/O Settings
● Get alarm input parameters of video intercom
Call NET_DVR_GetDVRConfig with "NET_DVR_GET_VIDEO_INTERCOM_IOIN_CFG" (command
No.: 16016) and set lChannel to the alarm input No.
The alarm input parameters of video intercom are returned in the structure
NET_DVR_VIDEO_INTERCOM_IOIN_CFG by lpOutBuffer.
● Set alarm input parameters of video intercom
Call NET_DVR_SetDVRConfig with "NET_DVR_SET_VIDEO_INTERCOM_IOIN_CFG" (command
No.: 16017), set lChannel to the alarm input No., and set lpInBuffer to the structure
NET_DVR_VIDEO_INTERCOM_IOIN_CFG .
● Get alarm output parameters of video intercom
Call NET_DVR_GetDVRConfig with "NET_DVR_GET_VIDEO_INTERCOM_IOOUT_CFG" (command
No.: 16018) and set lChannel to the alarm output No.
The alarm output parameters of video intercom are returned in the structure
NET_DVR_VIDEO_INTERCOM_IOOUT_CFG by lpOutBuffer.
● Set alarm output parameters of video intercom
Call NET_DVR_SetDVRConfig with "NET_DVR_SET_VIDEO_INTERCOM_IOOUT_CFG" (command
No.: 16019), set lChannel to the alarm output No., and set lpInBuffer to the structure
NET_DVR_VIDEO_INTERCOM_IOOUT_CFG .
22
Device Network SDK (Video Intercom) Developer Guide
Scene Settings
● Get scene configuration capability of video intercom
Call NET_DVR_STDXMLConfig to transmit the request URI: GET /ISAPI/VideoIntercom/scene/
nowMode/capabilities .
The scene capability is returned in the message XML_Cap_SceneNowMode by lpOutBuffer.
● Get scene parameters of video intercom
Call NET_DVR_STDXMLConfig to transmit the request URI: GET /ISAPI/VideoIntercom/scene/
nowMode .
The scene parameters are returned in the message XML_SceneNowMode by lpOutBuffer.
● Set scene parameters of video intercom
Call NET_DVR_STDXMLConfig to transmit the request URI: PUT /ISAPI/VideoIntercom/scene/
nowMode and set lpInBuffer to the message XML_SceneNowMode .
Protocol Switching
● Get Configuration Capability for Switching Between Private Video Intercom Protocol and SIP
(Session Initiation Protocol)
Call NET_DVR_STDXMLConfig to transmit the request URI: GET /ISAPI/VideoIntercom/
IntercomProtocolType/capabilities .
23
Device Network SDK (Video Intercom) Developer Guide
24
Device Network SDK (Video Intercom) Developer Guide
25
Device Network SDK (Video Intercom) Developer Guide
Chapter 9 Maintenance
Caller Information
● Get capability of getting caller information
Call NET_DVR_STDXMLConfig to transmit the request URI: GET /ISAPI/VideoIntercom/
callerInfo/capabilities?format=json .
The capability is returned in the message JSON_Cap_CallerInfo by lpOutBuffer.
● Get caller information
Call NET_DVR_STDXMLConfig to transmit the request URI: GET /ISAPI/VideoIntercom/
callerInfo?format=json .
The information is returned in the message JSON_CallerInfo by lpOutBuffer.
26
Device Network SDK (Video Intercom) Developer Guide
10.1 NET_DVR_Cleanup
Release the resources after the program is ended.
API Definition
BOOL NET_DVR_Cleanup(
);
Return Values
Returns TURE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The available error codes may be returned by this API are 0 and 3. See details in Device Network
SDK Errors .
Remarks
● When calling this API, you cannot call other APIs at the same time.
● NET_DVR_Init and this API should be called by pair. That is, once the NET_DVR_Init is called, you
should call NET_DVR_Cleanup to release the resources when exiting the program.
10.2 NET_DVR_GetDeviceAbility
Get the device capabilities.
API Definition
BOOL NET_DVR_GetDeviceAbility(
LONG lUserID,
DWORD dwAbilityType,
char *pInBuf,
DWORD dwInLength,
char *pOutBuf,
DWORD dwOutLength
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwAbilityType
[IN] Capability types, which are different according to different devices and functions.
27
Device Network SDK (Video Intercom) Developer Guide
pInBuf
[IN] Input parameter buffer pointer, which are different according to different devices and
functions, and they are returned in the structure or messages.
dwInLength
[IN] Size of input buffer.
pOutBuf
[OUT] Output parameter buffer pointer, which are different according to different devices and
functions, and they are returned in the structure or messages.
dwOutLength
[OUT] Size of buffer for receiving data.
Return Values
Returns TRUE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
10.3 NET_DVR_GetDeviceConfig
Get device configuration information in batch (with sending data).
API Definition
BOOL NET_DVR_GetDeviceConfig(
LONG lUserID,
DWORD dwCommand,
DWORD dwCount,
LPVOID lpInBuffer,
DWORD dwInBufferSize,
LPVOID lpStatusList,
LPVOID lpOutBuffer,
DWORD dwOutBufferSize
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Device getting commands. The commands are different for different getting functions.
dwCount
[IN] Number of configurations (cameras) to get at a time. 0, 1-one camera, 2-two cameras, 3-
three cameras, and so on. Up to 64 cameras' configuration information can be obtained at a
time.
28
Device Network SDK (Video Intercom) Developer Guide
lpInBuffer
[IN] Pointer of configuration condition buffer, which specifies the number (dwCount) of
configurations to get, and relates to the getting commands.
dwInBufferSize
[IN] Size of configuration condition buffer, which saves the obtained configuration information
(the number is dwCount).
lpStatusList
[OUT] Error information list, and its memory is allocated by user, each error information
contains 4 bytes (a unsigned 32-bit integer).
There is a one-to-one correspondence between the errors in the list and the cameras need to
search, e.g., lpStatusList[2] corresponds to lpInBuffer[2].
If the parameter value is 0 or 1, it refers to getting succeeded, otherwise, this parameter value is
the error code.
lpOutBuffer
[OUT] Parameters returned by device, which relates to the getting commands. And there is a
one-to-one correspondence between the parameters and the cameras need to search.
If the lpStatusList of one camera is larger than 1, the corresponding lpOutBuffer is invalid.
dwOutBufferSize
[IN] Total size of returned results (the number is dwCount).
Return Values
Returns TRUE for success, and returns FALSE for failure. If returns TRUE, it does not mean that all
configurations are obtained, you can check the value of lpStatusList[n] to judge which one is
succeeded.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
See Also
NET_DVR_SetDeviceConfig
10.4 NET_DVR_GetDVRConfig
Get the device configuration information.
API Definition
BOOL NET_DVR_GetDVRConfig(
LONG lUserID,
DWORD dwCommand,
LONG lRuleID,
LONG lChannel,
LPVOID lpOutBuffer,
29
Device Network SDK (Video Intercom) Developer Guide
DWORD dwOutBufferSize,
LPDWORD lpBytesReturned
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Device getting commands, which are different according to different getting functions.
lRuleID
[IN] Rule ID.
lChannel
[IN] Channel No. (NIC No.), which varies with different commands. 0xffffffff-invalid or all
channels, 1-main NIC, 2-extended NIC.
lpOutBuffer
[OUT] Pointer of buffer to receive data. For different getting functions, the structures of this
parameter are different.
dwOutBufferSize
[IN] Size of buffer to receive data (unit: byte). It cannot be 0.
lpBytesReturned
[OUT] Pointer of actually received data size. It cannot be NULL.
Return Values
Returns TRUE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The following error codes may be returned by this API: 0, 3, 6, 7, 8, 9, 10, 12, 17, 41, 43, 44, 47, 72,
73, and 76. See the corresponding error types and descriptions in the Device Network SDK Errors .
See Also
NET_DVR_SetDVRConfig
10.5 NET_DVR_GetErrorMsg
Return the error information of the last operation.
API Definition
char *NET_DVR_GetErrorMsg(
LONG *pErrorNo
);
30
Device Network SDK (Video Intercom) Developer Guide
Parameters
pErrorNo
[OUT] Error code pointer.
Return Values
The return values are the pointers of error information, see Device Network SDK Errors for details.
Remarks
You can call NET_DVR_GetLastError to get the error codes.
10.6 NET_DVR_GetLastError
Return the error code of the last operation.
API Definition
DWORD NET_DVR_GetLastError(
);
Return Values
The return values are error codes, see Device Network SDK Errors for details.
Remarks
You can also call NET_DVR_GetErrorMsg to directly get the error information.
10.7 NET_DVR_GetNextRemoteConfig
Get the next search result.
API Definition
LONG NET_DVR_GetNextRemoteConfig(
LONG lHandle,
void *lpOutBuff,
DWORD dwOutBuffSize
);
Parameters
lHandle
[IN] Search handle, which is the value returned by NET_DVR_StartRemoteConfig .
lpOutBuff
31
Device Network SDK (Video Intercom) Developer Guide
[OUT] Output parameter buffer pointer, which relates to the commands (dwCommand) of
NET_DVR_StartRemoteConfig .
dwOutBuffSize
[IN] Buffer size.
Return Values
Returns -1 for failure, and returns other values for the current statuses, see details in the following
table.
10.8 NET_DVR_GetUploadState
Get the file uploading progress and status.
API Definition
LONG NET_DVR_GetUploadState(
LONG lUploadHandle,
DWORD *pProgress
);
Parameters
lUploadHandle
[IN] Handling for uploading files, which is returned by NET_DVR_UploadFile_V40 .
pProgress
32
Device Network SDK (Video Intercom) Developer Guide
Return Values
Return -1 for failure, and return other values as the uploading status codes, see details in the
following table.
33
Device Network SDK (Video Intercom) Developer Guide
10.9 NET_DVR_Init
Initialize the programming environment before calling other APIs.
API Definition
BOOL NET_DVR_Init(
);
Return Values
Returns TURE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The available error codes of this API are 0, 41, and 53. See details in Device Network SDK Errors .
Remarks
Before initializing, you can call NET_DVR_SetSDKInitCfg to set the initialization parameters, such as
supported capabilities, loading path of component libraries (only supported by Linux system), and
so on.
34
Device Network SDK (Video Intercom) Developer Guide
See Also
NET_DVR_Cleanup
10.10 NET_DVR_Login_V40
Log in to the device (supports asynchronous login).
API Definition
LONG NET_DVR_Login_V40(
NET_DVR_USER_LOGIN_INFO pLoginInfo,
NET_DVR_DEVICEINFO_V40 lpDeviceInfo
);
Parameters
pLoginInfo
[IN] Login parameters, including device address, user name, password, and so on. See details in
the structure NET_DVR_USER_LOGIN_INFO .
lpDeviceInfo
[OUT] Device information. See details in the structure NET_DVR_DEVICEINFO_V40 .
Return Values
● For asynchronous login, the callback function ( fLoginResultCallBack ) configured in the
structure ( NET_DVR_USER_LOGIN_INFO ) returns the asynchronous login status, user ID and
device information.
● For synchronous login, this API returns -1 for logging failed, and returns other values for the
returned user IDs. The user ID is unique, and it helps to realize the further device operations.
● If -1 is returned, you can call NET_DVR_GetLastError to get the error code.
Remarks
● When bUseAsynLogin in pLoginInfo is 0, it indicates that login is in synchronous mode; when
bUseAsynLogin in pLoginInfo is 1, it indicates that login is in asynchronous mode.
● Up to 2048 users are allowed to log in to HCNetSDK at same time, and the values of returned
UserID are ranging from 0 to 2047.
See Also
NET_DVR_Logout
10.10.1 fLoginResultCallBack
35
Device Network SDK (Video Intercom) Developer Guide
10.11 NET_DVR_Logout
Log out from devices.
API Definitions
BOOL NET_DVR_Logout(
LONG lUserID
);
Parameters
lUserID
[IN] User ID, which is returned by NET_DVR_Login_V40 .
Return Values
Returns TURE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The available error codes may be returned by this API are 0, 3, 7, 8, 9, 10, 14, 17, 41, 44, 47, 72,
and 73. See details in Device Network SDK Errors .
10.12 NET_DVR_SendRemoteConfig
Send data via the persistent connection.
API Definition
BOOL NET_DVR_SendRemoteConfig(
LONG lHandle,
DWORD dwDataType,
36
Device Network SDK (Video Intercom) Developer Guide
char *pSendBuf,
DWORD dwBufSize
);
Parameters
lHandle
Persistent configuration handle, which is returned by NET_DVR_StartRemoteConfig .
dwDataType
[IN] Data type, which relates to the commands of NET_DVR_StartRemoteConfig .
pSendBuf
[IN] Buffer for saving data to be sent, which relates to dwDataType.
dwBufSize
[IN] Size of data to be sent.
Return Values
Returns TRUE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
Remarks
Before calling this API, you must call NET_DVR_StartRemoteConfig to get the persistent
connection handle.
10.13 NET_DVR_SetDeviceConfig
Set device parameters in batch (sending data is supported).
API Definition
BOOL NET_DVR_SetDeviceConfig(
LONG lUserID,
DWORD dwCommand,
DWORD dwCount,
LPVOID lpInBuffer,
DWORD dwInBufferSize,
LPVOID lpStatusList,
LPVOID lpInParamBuffer,
DWORD dwInParamBufferSize
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
37
Device Network SDK (Video Intercom) Developer Guide
dwCommand
[IN] Device configuration commands, which are different according to different configurations.
dwCount
[IN] Number of cameras to be set at a time. 0,1-one camera, 2-two cameras, 3-three cameras,
and so on. Up to 256 cameras can be configured at a time.
lpInBuffer
[IN] Pointer of configuration condition buffer, e.g., stream ID, which specifies the number
(dwCount) of cameras to set, and relates to the configuration commands.
dwInBufferSize
[IN] Size of configuration condition buffer, which saves the configured information of cameras
with the number of dwCount.
lpStatusList
[OUT] Error information list, and its memory is allocated by user, each error information
contains 4 bytes (a unsigned 32-bit integer).
There is a one-to-one correspondence between the errors in the list and the cameras that need
to be searched, e.g., lpStatusList[2] corresponds to lpInBuffer[2].
If the parameter value is 0, it refers to setting succeeded, otherwise, this parameter value is the
error code.
lpInParamBuffer
[IN] Device parameters to set, which relates to the configuration commands. And there is a one-
to-one correspondence between the parameters and the cameras that need to be searched.
dwInParamBufferSize
[IN] Set the size of content buffer.
Return Values
Returns TRUE for success, and returns FALSE for all failed. If returns TRUE, it does not indicate that
all settings are succeeded, you can get the value of lpStatusList[n] to check which one is
succeeded.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
See Also
NET_DVR_GetDeviceConfig
10.14 NET_DVR_SetDVRConfig
Set the device parameters.
38
Device Network SDK (Video Intercom) Developer Guide
API Definition
BOOL NET_DVR_SetDVRConfig(
LONG lUserID,
DWORD dwCommand,
LONG lChannel,
LPVOID lpInBuffer,
DWORD dwInBufferSize
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Device configuration commands, which are different according to different configuration
functions.
lChannel
[IN] Channel No. (NIC No.), which varies with different commands. 0xFFFFFFFF-invalid, 1-main
NIC, 2-extended NIC.
lpInBuffer
[IN] Pointer of input data buffer. For different configuration functions, the structures of this
parameter are different.
dwInBufferSize
[IN] Size of input data buffer (unit: byte).
Return Values
Returns TRUE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The following error codes may be returned by this API: 0, 3, 6, 7, 8, 9, 10, 12, 17, 41, 43, 44, 47, 72,
73, and 76. See the corresponding error types and descriptions in the Device Network SDK Errors .
See Also
NET_DVR_GetDVRConfig
10.15 NET_DVR_SetSDKInitCfg
Set initialization parameters.
API Parameters
BOOL NET_DVR_SetSDKInitCfg(
NET_SDK_INIT_CFG_TYPE enumType,
39
Device Network SDK (Video Intercom) Developer Guide
Parameters
enumType
[IN] Initialization parameter type. Different type values correspond to different parameters, see
details in the table below.
Return Values
Returns TURE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
40
Device Network SDK (Video Intercom) Developer Guide
Remarks
This API should be called before calling NET_DVR_Init to initialize and check the dependent
libraries or capabilities.
10.16 NET_DVR_StartRemoteConfig
Enable remote configuration.
API Definition
LONG NET_DVR_StartRemoteConfig(
LONG lUserID,
DWORD dwCommand,
LPVOID lpInBuffer,
DWORD dwInBufferLen,
fRemoteConfigCallback cbStateCallback,
LPVOID pUserData
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Configuration commands. For different functions, the commands and lpInBuffer are
different, see the detailed relation in the table below:
41
Device Network SDK (Video Intercom) Developer Guide
pUserData
[OUT] User data.
Return Values
Returns -1 for failure, and returns other values for the handles of NET_DVR_GetNextRemoteConfig
and NET_DVR_StopRemoteConfig .
If -1 is returned, you can call NET_DVR_GetLastError to get the error code.
Remarks
This API specifies the information to search. After calling this API, you can call
NET_DVR_GetNextRemoteConfig to get the information one by one.
10.16.1 fRemoteConfigCallback
Function for calling back the persistent connection status and data to be transmitted.
Parameters
dwType
[OUT] Connection statuses, see the macro definitions below:
enum _NET_SDK_CALLBACK_TYPE_{
NET_SDK_CALLBACK_TYPE_STATUS = 0,
NET_SDK_CALLBACK_TYPE_PROGRESS = 1,
NET_SDK_CALLBACK_TYPE_DATA = 2
}NET_SDK_CALLBACK_TYPE
NET_SDK_CALLBACK_TYPE_STATUS
Connection status.
NET_SDK_CALLBACK_TYPE_PROGRESS
Connection progress.
NET_SDK_CALLBACK_TYPE_DATA
Related data to be called back.
lpBuffer
42
Device Network SDK (Video Intercom) Developer Guide
[OUT] Pointer of buffer for saving progress, status, and related data to be called back, which
relates to dwType, see details in the following table.
dwType lpBuffer
NET_SDK_CALLBACK_TYPE_STATUS If dwBufLen is 4, lpBuffer is 4-byte connection
status; if dwBufLen is 8, lpBuffer consists of 4-
byte connection status and 4-byte error code.
The connection status is enumerated in
NET_SDK_CALLBACK_STATUS_NORMAL
NET_SDK_CALLBACK_TYPE_PROGRESS Connection progress value.
NET_SDK_CALLBACK_TYPE_DATA Data structures to be returned, which are
different according to different commands
(dwCommand) in
NET_DVR_StartRemoteConfig .
dwBufLen
[OUT] Buffer size.
pUserData
[OUT] User data.
10.17 NET_DVR_STDXMLConfig
Transmit request URL with XML or JSON format to implement some typical functions.
API Definition
BOOL NET_DVR_STDXMLConfig(
LONG lUserID,
const NET_DVR_XML_CONFIG_INPUT *lpInputParam,
NET_DVR_XML_CONFIG_OUTPUT *lpOutputParam
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
lpInputParam
[IN] Input parameters, refer to the structure NET_DVR_XML_CONFIG_INPUT for details.
lpOutputParam
43
Device Network SDK (Video Intercom) Developer Guide
Return Values
Return TRUE for success, and return FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
Remarks
The input parameter lpInputParam and output parameter lpOutputParam are different when
transmitting text protocol for implementing different functions, and each parameter corresponds
to a component of text protocol, see the relations below:
10.18 NET_DVR_StopRemoteConfig
Disconnect the persistent connection to stop remote configuration, and release resources.
API Definition
BOOL NET_DVR_StopRemoteConfig(
LONG lHandle
);
Parameters
lHandle
[IN] Handle, which is returned by NET_DVR_StartRemoteConfig .
44
Device Network SDK (Video Intercom) Developer Guide
Return Values
Returns TRUE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
10.19 NET_DVR_UploadClose
Stop uploading files.
API Definition
BOOL NET_DVR_UploadClose(
LONG lUploadHandle
);
Parameters
lUploadHandle
[IN] Handle for uploading files, which is returned by NET_DVR_UploadFile_V40 .
Return Values
Return TRUE for success, and return FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
10.20 NET_DVR_UploadFile_V40
Upload file.
API Definition
LONG NET_DVR_UploadFile_V40(
LONG lUserID,
DWORD dwUploadType,
LPVOID lpInBuffer,
DWORD dwInBufferSize,
char *sFileName,
LPVOID lpOutBuffer,
DWORD dwOutBufferSize
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwUploadType
45
Device Network SDK (Video Intercom) Developer Guide
[IN] Uploading commands, which specify the file type to upload, see details in the enumeration
NET_SDK_UPLOAD_TYPE .
lpInBuffer
[IN] Input parameters, which are different according to different uploading commands.
dwInBufferSize
[IN] Input buffer size.
sFileName
[IN] Name of the file to be uploaded. For the complete file path (including the file name), the
maximum size is 128 bytes, and the maximum size of the file name is 32 bytes.
lpOutBuffer
[OUT] Output parameters, which are different according to different uploading commands.
dwOutBufferSize
[OUT] Output buffer size.
Return Values
Return -1 for failure, and return other values as the parameter of NET_DVR_UploadClose and
NET_DVR_GetUploadState .
If -1 is returned, you can call NET_DVR_GetLastError to get the error code.
10.21 NET_DVR_CloseAlarmChan_V30
Close alarm uploading channel.
API Definition
BOOL NET_DVR_CloseAlarmChan_V30(
LONG lAlarmHandle
);
Parameters
lAlarmHandle
Value returned by NET_DVR_SetupAlarmChan_V50 .
Return Values
Return TURE for success, and return FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The available error codes of this API are 0, 3, 6, 12, 17, 41, and 47. See details in the Device
Network SDK Errors .
46
Device Network SDK (Video Intercom) Developer Guide
10.22 NET_DVR_GetDVRConfig
Get the device configuration information.
API Definition
BOOL NET_DVR_GetDVRConfig(
LONG lUserID,
DWORD dwCommand,
LONG lRuleID,
LONG lChannel,
LPVOID lpOutBuffer,
DWORD dwOutBufferSize,
LPDWORD lpBytesReturned
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Device getting commands, which are different according to different getting functions.
lRuleID
[IN] Rule ID.
lChannel
[IN] Channel No. (NIC No.), which varies with different commands. 0xffffffff-invalid or all
channels, 1-main NIC, 2-extended NIC.
lpOutBuffer
[OUT] Pointer of buffer to receive data. For different getting functions, the structures of this
parameter are different.
dwOutBufferSize
[IN] Size of buffer to receive data (unit: byte). It cannot be 0.
lpBytesReturned
[OUT] Pointer of actually received data size. It cannot be NULL.
Return Values
Returns TRUE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The following error codes may be returned by this API: 0, 3, 6, 7, 8, 9, 10, 12, 17, 41, 43, 44, 47, 72,
73, and 76. See the corresponding error types and descriptions in the Device Network SDK Errors .
47
Device Network SDK (Video Intercom) Developer Guide
See Also
NET_DVR_SetDVRConfig
10.23 NET_DVR_SetDVRConfig
Set the device parameters.
API Definition
BOOL NET_DVR_SetDVRConfig(
LONG lUserID,
DWORD dwCommand,
LONG lChannel,
LPVOID lpInBuffer,
DWORD dwInBufferSize
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Device configuration commands, which are different according to different configuration
functions.
lChannel
[IN] Channel No. (NIC No.), which varies with different commands. 0xFFFFFFFF-invalid, 1-main
NIC, 2-extended NIC.
lpInBuffer
[IN] Pointer of input data buffer. For different configuration functions, the structures of this
parameter are different.
dwInBufferSize
[IN] Size of input data buffer (unit: byte).
Return Values
Returns TRUE for success, and returns FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The following error codes may be returned by this API: 0, 3, 6, 7, 8, 9, 10, 12, 17, 41, 43, 44, 47, 72,
73, and 76. See the corresponding error types and descriptions in the Device Network SDK Errors .
See Also
NET_DVR_GetDVRConfig
48
Device Network SDK (Video Intercom) Developer Guide
10.24 NET_DVR_SetDVRMessageCallBack_V50
Set callback functions for getting the video data.
API Definition
BOOL NET_DVR_SetDVRMessageCallBack_V50(
int iIndex,
MSGCallBack fMessageCallBack,
void *pUser
);
Parameters
iIndex
[IN] Callback function index No., which ranges from 0 to 15.
fMessageCallBack
[IN] Callback function, see details in MSGCallBack .
pUser
[IN] User data.
Return Values
Return TRUE for success, and return FALSE for failure.
If FALSE returned, call NET_DVR_GetLastError to get the error code.
Remarks
● This API supports setting multiple callback functions for different channels (up to 16 channels are
supported) at same time, and the configured callback functions are distinguished by the index
No.
● All alarm/event information will be returned in each configured callback function, and you can
distinguish the devices via the pAlarmInfo in the callback function ( MSGCallBack ).
Example
Sample Code of Setting Multiple Callback Functions to Receive Different Alarms/Events in Arming
Mode
#include <stdio.h>
#include <iostream>
#include "Windows.h"
#include "HCNetSDK.h"
using namespace std;
int iNum=0;
void CALLBACK MessageCallbackNo1(LONG lCommand, NET_DVR_ALARMER *pAlarmer, char *pAlarmInfo, DWORD
dwBufLen, void* pUser)
{
49
Device Network SDK (Video Intercom) Developer Guide
int i=0;
char filename[100];
FILE *fSnapPic=NULL;
FILE *fSnapPicPlate=NULL;
//This sample code is for reference only. Actually, it is not recommended to process the data and save file in the
callback function directly.
//You'd better process the data in the message response funcion via message mode (PostMessage).
switch(lCommand)
{
case COMM_ALARM:
{
NET_DVR_ALARMINFO struAlarmInfo;
memcpy(&struAlarmInfo, pAlarmInfo, sizeof(NET_DVR_ALARMINFO));
switch (struAlarmInfo.dwAlarmType)
{
case 3: //Motion detection alarm
for (i=0; i<16; i++) //#define MAX_CHANNUM 16 //The maximum number of channels
{
if (struAlarmInfo.dwChannel[i] == 1)
{
printf("Channel Number with Motion Detection Alarm %d\n", i+1);
}
}
break;
default:
break;
}
break;
}
case COMM_UPLOAD_PLATE_RESULT:
{
NET_DVR_PLATE_RESULT struPlateResult={0};
memcpy(&struPlateResult, pAlarmInfo, sizeof(struPlateResult));
printf("License Plate Number: %s\n", struPlateResult.struPlateInfo.sLicense);//License plate number
50
Device Network SDK (Video Intercom) Developer Guide
break;
}
//Scene picture
if (struPlateResult.dwPicLen != 0 && struPlateResult.byResultType == 1 )
{
sprintf(filename,"testpic_%d.jpg",iNum);
fSnapPic=fopen(filename,"wb");
fwrite(struPlateResult.pBuffer1,struPlateResult.dwPicLen,1,fSnapPic);
iNum++;
fclose(fSnapPic);
}
//License plate picture
if (struPlateResult.dwPicPlateLen != 0 && struPlateResult.byResultType == 1)
{
sprintf(filename,"testPicPlate_%d.jpg",iNum);
fSnapPicPlate=fopen(filename,"wb");
fwrite(struPlateResult.pBuffer1,struPlateResult.dwPicLen,1,fSnapPicPlate);
iNum++;
fclose(fSnapPicPlate);
}
//Processing other data...
break;
}
case COMM_ITS_PLATE_RESULT:
{
NET_ITS_PLATE_RESULT struITSPlateResult={0};
memcpy(&struITSPlateResult, pAlarmInfo, sizeof(struITSPlateResult));
for (i=0;i<struITSPlateResult.dwPicNum;i++)
{
printf("License Plate Number: %s\n", struITSPlateResult.struPlateInfo.sLicense);//License plate number
switch(struITSPlateResult.struPlateInfo.byColor)//License plate color
{
case VCA_BLUE_PLATE:
printf("Vehicle Color: Blue\n");
break;
case VCA_YELLOW_PLATE:
printf("Vehicle Color: Yellow\n");
break;
case VCA_WHITE_PLATE:
printf("Vehicle Color: White\n");
break;
case VCA_BLACK_PLATE:
printf("Vehicle Color: Black\n");
break;
default:
break;
}
//Save scene picture
if ((struITSPlateResult.struPicInfo[i].dwDataLen != 0)&&(struITSPlateResult.struPicInfo[i].byType== 1)||
(struITSPlateResult.struPicInfo[i].byType == 2))
{
51
Device Network SDK (Video Intercom) Developer Guide
sprintf(filename,"testITSpic%d_%d.jpg",iNum,i);
fSnapPic=fopen(filename,"wb");
fwrite(struITSPlateResult.struPicInfo[i].pBuffer, struITSPlateResult.struPicInfo[i].dwDataLen,1,fSnapPic);
iNum++;
fclose(fSnapPic);
}
//License plate thumbnails
if ((struITSPlateResult.struPicInfo[i].dwDataLen != 0)&&(struITSPlateResult.struPicInfo[i].byType == 0))
{
sprintf(filename,"testPicPlate%d_%d.jpg",iNum,i);
fSnapPicPlate=fopen(filename,"wb");
fwrite(struITSPlateResult.struPicInfo[i].pBuffer, struITSPlateResult.struPicInfo[i].dwDataLen, 1, \
fSnapPicPlate);
iNum++;
fclose(fSnapPicPlate);
}
//Processing other data...
}
break;
}
default:
break;
}
}
//This sample code is for reference only. Actually, it is not recommended to process the data and save file in the
callback function directly.
//You'd better process the data in the message response funcion via message mode (PostMessage).
switch(lCommand)
{
case COMM_ALARM:
{
NET_DVR_ALARMINFO struAlarmInfo;
memcpy(&struAlarmInfo, pAlarmInfo, sizeof(NET_DVR_ALARMINFO));
switch (struAlarmInfo.dwAlarmType)
{
case 3: //Motion detection alarm
for (i=0; i<16; i++) //#define MAX_CHANNUM 16 //The maximum number of channel
{
if (struAlarmInfo.dwChannel[i] == 1)
{
printf("Channel No. with Motion Detection Alarm %d\n", i+1);
}
52
Device Network SDK (Video Intercom) Developer Guide
}
break;
default:
break;
}
break;
}
case COMM_UPLOAD_PLATE_RESULT:
{
NET_DVR_PLATE_RESULT struPlateResult={0};
memcpy(&struPlateResult, pAlarmInfo, sizeof(struPlateResult));
printf("License Plate Number: %s\n", struPlateResult.struPlateInfo.sLicense);//License plate number
53
Device Network SDK (Video Intercom) Developer Guide
{
NET_ITS_PLATE_RESULT struITSPlateResult={0};
memcpy(&struITSPlateResult, pAlarmInfo, sizeof(struITSPlateResult));
for (i=0;i<struITSPlateResult.dwPicNum;i++)
{
printf("License Plate Number: %s\n", struITSPlateResult.struPlateInfo.sLicense);//License plate number
switch(struITSPlateResult.struPlateInfo.byColor)//License plate color
{
case VCA_BLUE_PLATE:
printf("Vehicle Color: Blue\n");
break;
case VCA_YELLOW_PLATE:
printf("Vehicle Color: Yellow\n");
break;
case VCA_WHITE_PLATE:
printf("Vehicle Color: White\n");
break;
case VCA_BLACK_PLATE:
printf("Vehicle Color: Black\n");
break;
default:
break;
}
//Save scene picture
if ((struITSPlateResult.struPicInfo[i].dwDataLen != 0)&&(struITSPlateResult.struPicInfo[i].byType== 1)||
(struITSPlateResult.struPicInfo[i].byType == 2))
{
sprintf(filename,"testITSpic%d_%d.jpg",iNum,i);
fSnapPic=fopen(filename,"wb");
fwrite(struITSPlateResult.struPicInfo[i].pBuffer, struITSPlateResult.struPicInfo[i].dwDataLen,1,fSnapPic);
iNum++;
fclose(fSnapPic);
}
//License plate thumbnails
if ((struITSPlateResult.struPicInfo[i].dwDataLen != 0)&&(struITSPlateResult.struPicInfo[i].byType == 0))
{
sprintf(filename,"testPicPlate%d_%d.jpg",iNum,i);
fSnapPicPlate=fopen(filename,"wb");
fwrite(struITSPlateResult.struPicInfo[i].pBuffer, struITSPlateResult.struPicInfo[i].dwDataLen, 1, \
fSnapPicPlate);
iNum++;
fclose(fSnapPicPlate);
}
//Processing other data...
}
break;
}
default:
break;
}
}
54
Device Network SDK (Video Intercom) Developer Guide
void main() {
//---------------------------------------
//Initialize
NET_DVR_Init();
//Set the connection time and reconnection time
NET_DVR_SetConnectTime(2000, 1);
NET_DVR_SetReconnect(10000, true);
//---------------------------------------
//Log in to device
LONG lUserID;
NET_DVR_DEVICEINFO_V30 struDeviceInfo;
lUserID = NET_DVR_Login_V30("172.0.0.100", 8000, "admin", "12345", &struDeviceInfo);
if (lUserID < 0)
{
printf("Login error, %d\n", NET_DVR_GetLastError());
NET_DVR_Cleanup();
return;
}
//Enable arming
NET_DVR_SETUPALARM_PARAM struSetupParam={0};
struSetupParam.dwSize=sizeof(NET_DVR_SETUPALARM_PARAM);
Sleep(20000);
//Disarm uploading channel
if (!NET_DVR_CloseAlarmChan_V30(lHandle))
{
printf("NET_DVR_CloseAlarmChan_V30 error, %d\n", NET_DVR_GetLastError());
NET_DVR_Logout(lUserID);
NET_DVR_Cleanup();
55
Device Network SDK (Video Intercom) Developer Guide
return;
}
//User logout
NET_DVR_Logout(lUserID);
//Release SDK resource
NET_DVR_Cleanup();
return;
}
See Also
NET_DVR_SetupAlarmChan_V50
10.24.1 MSGCallBack
Alarm/event information callback function.
Parameters
lCommand
[OUT] Uploaded message type. You can distinguish the alarm/event information via the type.
pAlarmer
[OUT] Alarm device information, including serial No., IP address, login handle, and so on, see
details in NET_DVR_ALARMER .
pAlarmInfo
[OUT] Alarm/event information, the details are returned in different structures according to
lCommand.
dwBufLen
[OUT] Size of alarm/event information buffer.
pUser
[OUT] User data.
56
Device Network SDK (Video Intercom) Developer Guide
10.25 NET_DVR_SetupAlarmChan_V50
Set up persistent connection to receive alarm/event information (supports alarm/event
subscription).
API Definition
LONG NET_DVR_SetupAlarmChan_V50(
LONG lUserID,
NET_DVR_SETUPALARM_PARAM_V50 lpSetupParam,
char *pData,
DWORD dwDataLen,
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
lpSetupParam
[IN] Arming parameters, refer to the structure NET_DVR_SETUPALARM_PARAM_V50 for
details.
pData
[IN] Alarm/event subscription conditions.
dwDataLen
[IN] Length of alarm/event subscription conditions.
Return Values
Return -1 for failure, and return other values as the handles of NET_DVR_CloseAlarmChan_V30 .
If -1 is returned, you can call NET_DVR_GetLastError to get the error code.
Remarks
This API supports alarm/event subscription, you can specify the types of alarm or event to be
uploaded by device by setting pData and dwDataLen.
10.26 NET_DVR_StartListen_V30
Register callback function for receiving alarm/event information and start listening (supports
multiple threads).
API Definition
LONG NET_DVR_StartListen_V30(
char *sLocalIP,
57
Device Network SDK (Video Intercom) Developer Guide
WORD wLocalPort,
MSGCallBack DataCallback,
void *pUserData
);
Parameters
sLocalIP
[IN] IP address of local PC. It can be set to null.
wLocalPort
[IN] Listening port No. of local PC. It is configured by user, and it should be the same with that of
device.
DataCallback
[IN] Alarm/event information callback function, see details in MSGCallBack .
pUserData
[IN] User data.
Return Values
Return -1 for failure, and return other values for the handle parameters of
NET_DVR_StopListen_V30 .
If -1 is returned, you can call NET_DVR_GetLastError to get the error code.
The available error codes of this API are 0, 3, 6, 12, 17, 41, 44, 47, 72, and 75. See details in the
Device Network SDK Errors .
Remarks
● To receive the alarm/event information sent by device, you should set the management host
server address or listening host server address of device to the IP address of PC (which is same
with the sLocalIP), or set the management host server port or listening host server port to the
listening port No. of PC (which is same with the wLocalPort).
● The callback function in this API is prior to other callback functions, that is, if the callback
function is configured in this API, other callback functions will not receive the alarm information.
All the device alarm information is returned in same callback function, and you can distinguish
the devices via the alarm device information (pAlarmInfo).
10.27 NET_DVR_StopListen_V30
Stop listening (supports multiple threads).
API Definition
BOOL NET_DVR_StopListen_V30(
LONG lListenHandle
);
58
Device Network SDK (Video Intercom) Developer Guide
Parameters
lListenHandle
Listening handle, which is returned by NET_DVR_StartListen_V30 .
Return Values
Return TRUE for success, and return FALSE for failure.
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
The available error codes of this API are 0, 3, 12, and 17. See details in the Device Network SDK
Errors .
59
Device Network SDK (Video Intercom) Developer Guide
Appendix A. Appendixes
A.1.1 NET_DVR_AGAIN_RELATEDEV
Parameter structure of linked network device of doorphone
Structure Definition
struct{
NET_DVR_IPADDR struSIPServer;
NET_DVR_IPADDR struCenterAddr;
WORD wCenterPort;
BYTE byRes1[2];
NET_DVR_IPADDR struIndoorUnit;
NET_DVR_IPADDR struAgainAddr;
BYTE byRes[444];
}NET_DVR_AGAIN_RELATEDEV,*LPNET_DVR_AGAIN_RELATEDEV;
Members
struSIPServer
IP address of SIP server, refer to the structure NET_DVR_IPADDR_UNION for details.
struCenterAddr
IP address of platform or system, refer to the structure NET_DVR_IPADDR_UNION for details.
byRes
Reserved, set to 0.
struIndoorUnit
IP address of indoor station, refer to the structure NET_DVR_IPADDR_UNION for details.
struAgainAddr
IP address of main doorphone, refer to the structure NET_DVR_IPADDR_UNION for details.
byRes
Reserved, set to 0.
See Also
60
Device Network SDK (Video Intercom) Developer Guide
A.1.2 NET_DVR_AUTH_INFO
Authentication information structure
Structure Definition
struct{
BYTE byAuthResult;
BYTE byAuthType;
BYTE byRes1[2];
BYTE byCardNo[ACS_CARD_NO_LEN/*32*/];
DWORD dwPicDataLen;
BYTE *pImage;
BYTE byRes[212];
}NET_DVR_AUTH_INFO, *LPNET_DVR_AUTH_INFO;
Members
byAuthResult
Authentication result: 0-invalid, 1-authenticated, 2-failed.
byAuthType
Authentication mode: 0- invalid, 1-fingerprint, 2-face.
byRes1
Reserved, set to 0.
byCardNo
Card No.
dwPicDataLen
Picture data size, it is valid when byAuthType equals to 2.
pImage
Picture pointer, it is valid when byAuthType equals to 2.
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON
A.1.3 NET_DVR_CALL_ROOM_CFG
Configuration structure for calling resident by pressing button.
61
Device Network SDK (Video Intercom) Developer Guide
Structure Definition
struct{
DWORD dwSize;
SHORT nFloorNumber;
WORD wRoomNumber;
BYTE byManageCenter;
BYTE byRes1[3];
BYTE byCalledName[64];
BYTE byRes[60];
}NET_DVR_CALL_ROOM_CFG,*LPNET_DVR_CALL_ROOM_CFG;
Members
dwSize
Structure size.
nFloorNumber
Floor No.
wRoomNumber
Room No.
byManageCenter
Whether to set as call management center: 0-no, 1-yes.
byRes1
Reserved, set to 0.
byCalledName
Resident name to be called, it can contain digits, letters, @, and dots. This member is valid in
standard SIP mode.
byRes
Reserved, set to 0.
A.1.4 NET_DVR_DEVICEINFO_V30
Device parameter structure (V30).
62
Device Network SDK (Video Intercom) Developer Guide
search.
● bySupport&0x2: whether supports backup.
encoding parameters.
● bySupport&0x8: whether supports dual-NIC.
SADP.
● bySupport&0x20: whether supports RAID
card.
● bySupport&0x40: whether supports
RTSP.
bySupport1 BYTE Extended capabilities, if the result of bitwise
operation is 0, it refers that the capability is not
63
Device Network SDK (Video Intercom) Developer Guide
over RTSP.
● bySupport1&0x80: whether supports license
version 40.
● bySupport2&0x4: whether supports ANR.
device status.
● bySupport2&0x40: whether supports
encrypting stream.
wDevType WORD Device model
bySupport3 BYTE Extended capabilities, if the result of bitwise
operation is 0, it refers that the capability is not
supported, while, if the result is 1, it indicates
that the capability is supported.
● bySupport3&0x1: whether supports multi-
stream.
● bySupport3&0x4: whether supports
64
Device Network SDK (Video Intercom) Developer Guide
third-stream.
● byMultiStreamProto&0x2: whether supports
fourth-stream.
● byMultiStreamProto&0x40: whether
supports sub-stream.
byStartDChan BYTE Start No. of digital channel, 0-no digital channel
(e.g., DVR, network camera).
byStartDTalkChan BYTE Start No. of two-way audio channel, 0-no two-
way audio channel.
byHighDChanNum BYTE Number of digital channels, high 8-bit.
bySupport4 BYTE Extended capabilities, if the result of bitwise
operation is 0, it refers that the capability is not
supported, if the result is 1, it indicates that the
capability is supported.
● bySupport4&0x01: whether all stream types
65
Device Network SDK (Video Intercom) Developer Guide
Remarks
● The maximum number of digital channels equal to byIPChanNum+byHighDChanNum*256.
● For login via text protocol, the following parameters are not supported: byMainProto,
bySubProto, bySupport, bySupport1, bySupport2, bySupport3, bySupport4, bySupport5,
bySupport6, bySupport7, byMultiStreamProto, byStartDTalkChan, byVoiceInChanNum,
byStartVoiceInChanNo, byMirrorChanNum, and wStartMirrorChanNo.
See Also
NET_DVR_DEVICEINFO_V40
A.1.5 NET_DVR_DEVICEINFO_V40
66
Device Network SDK (Video Intercom) Developer Guide
67
Device Network SDK (Video Intercom) Developer Guide
68
Device Network SDK (Video Intercom) Developer Guide
Remarks
● Four character types are allowed in the password, including digits, lowercase letters, uppercase
letters and symbols. The maximum password length is 16 bits, and there are four password
strength levels, see details below:
○ Level 0 (Risky Password): The password length is less than 8 bits, or only contains one kind of
the character types. Or the password is the same with the user name, or is the mirror writing
of the user name.
○ Level 1 (Weak Password): The password length is more than or equal to 8 bits, and contains
two kinds of the character types. Meanwhile, the combination should be (digits + lowercase
letters) or (digits + uppercase letters).
○ Level 2 (Medium Password): The password length is more than or equal to 8 bits, and contains
two kinds of the character types. Meanwhile, the combination cannot be (digits + lowercase
letters) and (digits + uppercase letters).
○ Level 3 (Strong Password): The password length is more than or equal to 8 bits, and at least
A.1.6 NET_DVR_DIRECT_CONNECT_CHAN_INFO
Digital channel information structure
Structure Definition
struct{
BYTE byEnable;
BYTE byProType;
BYTE byZeroChan;
BYTE byPriority;
BYTE sUserName[NAME_LEN/*32*/];
BYTE sPassword[PASSWD_LEN/*16*/];
BYTE byDomain[MAX_DOMAIN_NAME/*64*/];
NET_DVR_IPADDR struIP;
WORD wDVRPort;
BYTE byStreamType;
BYTE byOnline;
DWORD dwChannel;
69
Device Network SDK (Video Intercom) Developer Guide
BYTE byTransProtocol;
BYTE byLocalBackUp;
WORD wDirectLastTime;
BYTE byChanNo[CHAN_NO_LEN/*24*/];
}NET_DVR_DIRECT_CONNECT_CHAN_INFO, *LPNET_DVR_DIRECT_CONNECT_CHAN_INFO;
Members
byEnable
Whether to enable: 0-no, 1-yes.
byProType
Protocol type, refer to the structure NET_DVR_PROTO_TYPE for details, by default, the protocol
type is 0-private protocol.
byZeroChan
Whether it is channel-zero: 0-no, 1-yes.
byPriority
Priority, whose value is between 1 and 5.
sUserName
User name.
sPassword
Password.
byDomain
Device domain name.
struIP
Device IP address, refer to the structure NET_DVR_IPADDR_UNION for details.
wDVRPort
Device port No.
byStreamType
Stream type: 0-main stream, 1-sub-stream
byOnline
Online status (read-only): 0-offline, 1-online.
dwChannel
Channel No.
byTransProtocol
Transport protocol type: 0-TCP, 1-UDP, 2-multi-slot
byLocalBackUp
Whether to enable local backup: 0-no, 1-yes.
70
Device Network SDK (Video Intercom) Developer Guide
wDirectLastTime
Broadcast time duration, unit: second, the value range should be obtained via capability.
byChanNo
Channel No. for getting stream via VAG.
A.1.7 NET_DVR_INDOOR_UNIT_DEVICEID
Parameter structure of indoor station No.
Structure Definition
struct{
SHORT wFloorNumber;
WORD wRoomNumber;
WORD wDevIndex;
BYTE byRes[122];
}NET_DVR_INDOOR_UNIT_DEVICEID, *LPNET_DVR_INDOOR_UNIT_DEVICEID;
Members
wFloorNumber
Floor No.
wRoomNumber
Room No.
wDevIndex
Indoor station No., which is between 0 and 10.
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION
A.1.8 NET_DVR_INDOOR_UNIT_RELATEDEV
Parameter structure of linked network device of indoor station.
Structure Definition
struct{
NET_DVR_IPADDR struOutdoorUnit;
NET_DVR_IPADDR struManageUnit;
NET_DVR_IPADDR struSIPServer;
NET_DVR_IPADDR struAgainUnit;
71
Device Network SDK (Video Intercom) Developer Guide
BYTE byOutDoorType;
BYTE byOutInConnectMode;
BYTE byIndoorConnectMode;
BYTE byRes1;
NET_DVR_IPADDR struIndoorUnit;
BYTE byRes[300];
}NET_DVR_INDOOR_UNIT_RELATEDEV,*LPNET_DVR_INDOOR_UNIT_RELATEDEV;
Members
struOutdoorUnit
IP address of main door station, refer to the structure NET_DVR_IPADDR_UNION for details.
struManageUnit
IP address of main station, refer to the structure NET_DVR_IPADDR_UNION for details.
struSIPServer
IP address of SIP server, refer to the structure NET_DVR_IPADDR_UNION for details.
struAgainUnit
Doorphone IP address, refer to the structure NET_DVR_IPADDR_UNION for details.
byOutDoorType
Main door station type: 0-reserved, 1-main door station, 2-villa door station
byOutInConnectMode
Network connection mode of door station and indoor station: 1-in same LAN, 2-in different LAN.
byIndoorConnectMode
Network connection mode of indoor station and sub indoor station: 1-by wireless NIC, 2-by
wired NIC
byRes1
Reserved, set to 0.
struIndoorUnit
IP address of indoor station, refer to the structure NET_DVR_IPADDR_UNION for details.
byRes
Reserved, set to 0.
See Also
A.1.9 NET_DVR_INDOOR_UNIT_OPERATION_TIME_CFG
Operation time parameter structure of indoor station
72
Device Network SDK (Video Intercom) Developer Guide
Structure Definition
struct{
DWORD dwMaxMonitoringTime;
DWORD dwMaxRingTime;
DWORD dwCallForwardingTime;
DWORD dwRingDurationTime;
BYTE byRes[112];
}NET_DVR_INDOOR_UNIT_OPERATION_TIME_CFG,*LPNET_DVR_INDOOR_UNIT_OPERATION_TIME_CFG;
Members
dwMaxMonitoringTime
Maximum time duration of video intercom, range: [10, 60], unit: second.
dwMaxRingTime
Maximum ringing time duration, range: [15, 60], unit: second.
dwCallForwardingTime
Timeout of call forwarding, range: [0, 20], unit: second.
dwRingDurationTime
Ringing timeout, range: [30, 60], unit: second.
byRes
Reserved.
A.1.10 NET_DVR_INIT_CFG_ABILITY
73
Device Network SDK (Video Intercom) Developer Guide
enum _INIT_CFG_MAX_NUM_{
INIT_CFG_NUM_2048 = 2048,
INIT_CFG_NUM_5120 = 5120,
INIT_CFG_NUM_10240 = 10240,
INIT_CFG_NUM_15360 = 15360,
INIT_CFG_NUM_20480 = 20480
}INIT_CFG_MAX_NUM
Remarks
By default, up to 2048 channels are supported. More channels require higher computer
performance and network bandwidth.
See Also
NET_DVR_SetSDKInitCfg
A.1.11 NET_DVR_IPADDR_UNION
IP Address Union
A.1.12 NET_DVR_LOCAL_SDK_PATH
74
Device Network SDK (Video Intercom) Developer Guide
Remarks
If the path of HCNetSDKCom folder and HCNetSDK libraries are same, but the path of executable
programs are different, you can call NET_DVR_SetSDKInitCfg to specify the path of HCNetSDKCom
folder to make sure the component libraries are loaded normally.
A.1.13 NET_DVR_MANAGE_UNIT_DEVICEID
Parameter structure of main station No.
Structure Definition
struct{
DWORD wPeriod;
DWORD wDevIndex;
BYTE byRes[124];
}NET_DVR_MANAGE_UNIT_DEVICEID, *LPNET_DVR_MANAGE_UNIT_DEVICEID;
Members
wPeriod
Community No., range: [0,9].
wDevIndex
Outer door station No., which is unique in each floor, and it starts from 0.
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION
A.1.14 NET_DVR_MANAGE_UNIT_RELATEDEV
Parameter structure of linked network device of main station.
Structure Definition
struct{
NET_DVR_IPADDR struSIPServer;
BYTE byRes[880];
}NET_DVR_MANAGE_UNIT_RELATEDEV,*LPNET_DVR_MANAGE_UNIT_RELATEDEV;
Members
struSIPServer
75
Device Network SDK (Video Intercom) Developer Guide
See Also
A.1.15 NET_DVR_MANAGE_UNIT_OPERATION_TIME_CFG
Operation time parameter structure of main station
Structure Definition
struct{
DWORD dwMaxMonitoringTime;
DWORD dwMaxRingTime;
DWORD dwMaxTalkTime;
BYTE byRes[116];
}NET_DVR_MANAGE_UNIT_OPERATION_TIME_CFG,*LPNET_DVR_MANAGE_UNIT_OPERATION_TIME_CFG;
Members
dwMaxMonitoringTime
Maximum video intercom time duration, range: [10,60], unit: second.
dwMaxRingTime
Maximum ringing time duration, range: [15,60], unit: second.
dwMaxTalkTime
Maximum talking time duration, unit: second
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_UNION
A.1.16 NET_DVR_MIME_UNIT
76
Device Network SDK (Video Intercom) Developer Guide
See Also
NET_DVR_XML_CONFIG_INPUT
A.1.17 NET_DVR_NOTICEDATA_RECEIPT_INFO
Announcement reading receipt information structure
Structure Definition
struct{
BYTE byNoticeNumber[MAX_NOTICE_NUMBER_LEN/*32*/];
BYTE byRes[224];
}NET_DVR_NOTICEDATA_RECEIPT_INFO, *LPNET_DVR_NOTICEDATA_RECEIPT_INFO;
Members
byNoticeNumber
Announcement No.
byRes
77
Device Network SDK (Video Intercom) Developer Guide
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON
A.1.18 NET_DVR_OUTDOOR_FENCE_DEVICEID
Parameter structure of outer door station No.
Structure Definition
struct{
DWORD wPeriod;
DWORD wDevIndex;
BYTE byRes[124];
}NET_DVR_OUTDOOR_FENCE_DEVICEID, *LPNET_DVR_OUTDOOR_FENCE_DEVICEID;
Members
wPeriod
Community No., range: [0,9].
wDevIndex
Outer door station No., which starts from 0.
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION
A.1.19 NET_DVR_OUTDOOR_UNIT_DEVICEID
Parameter structure of door station (or intelligent access control device) No.
Structure Definition
struct{
DWORD wPeriod;
DWORD wBuildingNumber;
DWORD wUnitNumber
DWORD wFloorNumber
DWORD wDevIndex
DWORD byRes[118];
}NET_DVR_OUTDOOR_UNIT_DEVICEID, *LPNET_DVR_OUTDOOR_UNIT_DEVICEID;
78
Device Network SDK (Video Intercom) Developer Guide
Members
wPeriod
Project No., range: [0,9].
wBuildingNumber
Building No.
wUnitNumber
Unit No.
wFloorNumber
Floor No.
wDevIndex
Door station No., which is unique in each floor, and it starts from 0.
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION
A.1.20 NET_DVR_OUTDOOR_UNIT_RELATEDEV
Parameter structure of linked network device of door station, villa door station, or intelligent
access control device.
Structure Definition
struct{
NET_DVR_IPADDR struMainOutdoorUnit;
NET_DVR_IPADDR struManageUnit;
NET_DVR_IPADDR struSIPServer;
BYTE byManageCenterID[32];
BYTE byRes[560];
}NET_DVR_OUTDOOR_UNIT_RELATEDEV,*LPNET_DVR_OUTDOOR_UNIT_RELATEDEV;
Members
struMainOutdoorUnit
IP address of door station, it is valid when sub door station exists, refer to the structure
NET_DVR_IPADDR_UNION for details.
struManageUnit
IP address of master station, refer to the structure NET_DVR_IPADDR_UNION for details.
struSIPServer
79
Device Network SDK (Video Intercom) Developer Guide
IP address of SIP server, it is valid when the sub door station exits, refer to the structure
NET_DVR_IPADDR_UNION for details.
byManageCenterID
Management center ID, which is valid in SIP mode, and it should contains digits, letters, @, and
dots.
byRes
Reserved, set to 0.
See Also
A.1.21 NET_DVR_OUTDOOR_UNIT_OPERATION_TIME_CFG
Operation time parameter structure of door station, outer door station, villa door station, and
doorphone
Structure Definition
struct{
DWORD dwMaxMessageTime;
DWORD dwMaxTalkTime;
BYTE byRes[120];
}NET_DVR_OUTDOOR_UNIT_OPERATION_TIME_CFG,*LPNET_DVR_OUTDOOR_UNIT_OPERATION_TIME_CFG;
Members
dwMaxMessageTime
Maximum messaging time duration, range: [30,60], unit: second.
dwMaxTalkTime
Maximum talking time duration, range: [90,120], unit: second.
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_UNION
A.1.22 NET_DVR_PRIVILEGE_PASSWORD_CFG
Structure for configuring permission password.
80
Device Network SDK (Video Intercom) Developer Guide
Structure Definition
struct{
DWORD dwSize;
BYTE byPwdType;
BYTE byRes1[3];
BYTE byOldPassword[PASSWD_LEN/*16*/];
BYTE byNewPassword[PASSWD_LEN/*16*/];
BYTE byRes2[128];
}NET_DVR_PRIVILEGE_PASSWORD_CFG, *LPNET_DVR_PRIVILEGE_PASSWORD_CFG;
Members
dwSize
Structure size.
byPwdType
Password type, see the definition below:
enum _PRIVILEGE_PASSWORD_TYPE_ENUM_{
ENUM_PRIVILEGE_PASSWORD_ENGINEERING = 1,
ENUM_PRIVILEGE_PASSWORD_SETUPALARM = 2,
ENUM_PRIVILEGE_PASSWORD_HOUSEHOLDER_UNLOCK = 3,
ENUM_PRIVILEGE_PASSWORD_ANTI_HIJACKING = 4,
ENUM_PRIVILEGE_PASSWORD_PUBLIC1 = 5,
ENUM_PRIVILEGE_PASSWORD_PUBLIC2 = 6,
ENUM_PRIVILEGE_PASSWORD_PUBLIC3 = 7,
ENUM_PRIVILEGE_PASSWORD_SENDCARD =8
}PRIVILEGE_PASSWORD_TYPE_ENUM
ENUM_PRIVILEGE_PASSWORD_ENGINEERING
Configuration Password
ENUM_PRIVILEGE_PASSWORD_SETUPALARM
Arming/Disarming Password
ENUM_PRIVILEGE_PASSWORD_HOUSEHOLDER_UNLOCK
Unlocking Password
ENUM_PRIVILEGE_PASSWORD_ANTI_HIJACKING
Duress Code
ENUM_PRIVILEGE_PASSWORD_PUBLIC1
Public Password 1
ENUM_PRIVILEGE_PASSWORD_PUBLIC2
Public Password 2
ENUM_PRIVILEGE_PASSWORD_PUBLIC3
Public Password 3
81
Device Network SDK (Video Intercom) Developer Guide
ENUM_PRIVILEGE_PASSWORD_SENDCARD
Card Activation Password
byRes1
Reserved, set to 0.
byOldPassword
Old password.
byNewPassword
New password.
byRes2
Reserved, set to 0.
A.1.23 NET_DVR_PROTO_TYPE
Structure about protocol parameters.
Structure Definition
struct{
DWORD dwType;
BYTE byDescribe[DESC_LEN/*16*/];
}NET_DVR_PROTO_TYPE,*LPNET_DVR_PROTO_TYPE;
Members
dwType
Protocol value
byDescribe
Protocol description
Remarks
● The descriptions (byDescribe) of different protocol types (dwType) are shown in the table below.
enum tagNET_DVR_IPC_ENUM_UNIFY{
ENUM_IPC_PROTOCOL_INVALID = -1,
ENUM_IPC_PROTOCOL_HIKVISION = 0, //HIKVISION
ENUM_IPC_PROTOCOL_PANASONIC = 1, //PANASONIC
ENUM_IPC_PROTOCOL_SONY = 2, //SONY
ENUM_IPC_PROTOCOL_AXIS = 4, //AXIS
ENUM_IPC_PROTOCOL_SANYO = 5, //SANYO
ENUM_IPC_PROTOCOL_BOSCH = 6, //BOSCH
ENUM_IPC_PROTOCOL_ZAVIO = 7, //ZAVIO
ENUM_IPC_PROTOCOL_GRANDEYE, //GRANDEYE
ENUM_IPC_PROTOCOL_PROVIDEO = 16, //PROVIDEO
ENUM_IPC_PROTOCOL_ARECONT = 10, //ARECONT
82
Device Network SDK (Video Intercom) Developer Guide
83
Device Network SDK (Video Intercom) Developer Guide
enum _NET_DVR_IPC_ENUM_{
ENUM_BUSINESS_INVALID = -1,
ENUM_BUSINESS_HIKVISION = 0,
ENUM_BUSINESS_PANASONIC,
ENUM_BUSINESS_SONY,
ENUM_BUSINESS_AXIS,
ENUM_BUSINESS_SANYO,
ENUM_BUSINESS_BOSCH,
ENUM_BUSINESS_ZAVIO,
ENUM_BUSINESS_GRANDEYE,
ENUM_BUSINESS_PROVIDEO,
ENUM_BUSINESS_ARECONT, //9
ENUM_BUSINESS_ACTI,
ENUM_BUSINESS_PELCO,
ENUM_BUSINESS_VIVOTEK,
ENUM_BUSINESS_INFINOVA,
ENUM_BUSINESS_DAHUA, //14
ENUM_BUSINESS_HIK_STD_H264 = 0x20,
ENUM_BUSINESS_HIK_STD_MPEG4,
ENUM_BUSINESS_SUNELL, //SUNELL
ENUM_BUSINESS_ATEME,
ENUM_BUSINESS_LAUNCH, //LAUNCH
84
Device Network SDK (Video Intercom) Developer Guide
ENUM_BUSINESS_YAAN, //YAAN
ENUM_BUSINESS_BLUESKY, //BLUESKY
ENUM_BUSINESS_BLUESKYLIMIT, //BLUESKYLIMIT
ENUM_BUSINESS_TDWY, //TIANDY
ENUM_BUSINESS_HBGK, //HBGK
ENUM_BUSINESS_SANTACHI, //SANTACHI
ENUM_BUSINESS_HIGHEASY, //HIGHEASY
ENUM_BUSINESS_SAMSUNG,
ENUM_BUSINESS_URL_RTSP = 0x40,//Streaming via URL
ENUM_BUSINESS_ONVIF,
ENUM_MAX_BUSINESS_TYPE, //Maximum manufacturer type
}NET_DVR_IPC_ENUM
● If the device supports unified network camera protocol, the supported protocol types are
enumerated in NET_DVR_IPC_ENUM_UNIFY; otherwise, the supported protocol types are
enumerated in NET_DVR_IPC_ENUM.
A.1.24 NET_DVR_PU_STREAM_URL
Configuration parameter structure about getting stream by URL.
Structure Definition
struct{
BYTE byEnable;
BYTE strURL[240];
BYTE byTransPortocol;
WORD wIPID;
BYTE byChannel;
BYTE byRes[7];
}NET_DVR_PU_STREAM_URL,*LPNET_DVR_PU_STREAM_URL;
Members
byEnable
Enable/disable getting stream by URL: 0-disable, 1-enable.
strURL
Stream URL
byTransPortocol
Transfer protocol type: 0-TCP, 1-UDP
wIPID
Device ID= iDevInfoIndex + iGroupNO*64 +1
byChannel
Device channel No.
byRes
85
Device Network SDK (Video Intercom) Developer Guide
Reserved, set to 0.
Remarks
The stream URL format is {rtsp://ip[:port]/urlExtension}[?username=username][?
password=password][?linkmode=linkmode]. You can also customize the URL format if the network
camera supports custom URL.
A.1.25 NET_DVR_PU_STREAM_URL_CFG
Streaming URL structure
Structure Definition
struct{
BYTE byEnable;
BYTE byRes[3];
BYTE byStreamMediaIP[64];
WORD wStreamMediaPort;
BYTE byTransmitType;
BYTE byRes1[33];
BYTE byDevIP[64];
WORD wDevPort;
BYTE byChannel;
BYTE byTransMode;
BYTE byProType;
BYTE byTransProtocol;
BYTE byRes3[2];
BYTE sUserName[NAME_LEN/*32*/];
BYTE sPassWord[PASSWD_LEN/*16*/];
BYTE byRes2[28];
}NET_DVR_PU_STREAM_URL_CFG,*LPNET_DVR_PU_STREAM_URL_CFG;
Members
byEnable
Whether to enable: 0-no, 1-yes.
byRes
Reserved, set to 0.
byStreamMediaIP
IP address of stream media server.
wStreamMediaPort
Port No. of stream media server.
byTransmitType
Transport protocol of steam media server: 0-TCP, 1-UDP, 2-RTSP
86
Device Network SDK (Video Intercom) Developer Guide
byRes1
Reserved, set to 0.
byDevIP
Device IP address.
wDevPort
Device port No.
byChannel
Device channel No.
byTransMode
Transmission mode: 0-main stream, 1-sub-stream
byProType
Manufacturer protocol type, refer to the structure NET_DVR_PROTO_TYPE for details.
byTransProtocol
Transport protocol type: 0-TCP, 1-UDP, 2-multicast, 3-RTP
byRes3
Reserved, set to 0.
sUserName
User name for logging in to device.
sPassWord
Password for logging in to device.
byRes
Reserved, set to 0.
A.1.26 NET_DVR_RECORD_PASSBACK_MANUAL_COND
87
Device Network SDK (Video Intercom) Developer Guide
A.1.27 NET_DVR_RECORD_PASSBACK_MANUAL_TASK_RET
88
Device Network SDK (Video Intercom) Developer Guide
A.1.28 NET_DVR_RING_SEARCH_CFG
Result structure of ring search.
Structure Definition
struct{
DWORD dwSize;
DWORD dwRingID;
BYTE byRingName[MAX_RING_NAME_LEN_128/*128*/];
DWORD dwRingSize;
BYTE byRingType;
BYTE byRes[303];
}NET_DVR_RING_SEARCH_CFG,*LPNET_DVR_RING_SEARCH_CFG;
Members
dwSize
Structure size.
dwRingID
Ring ID, value range: [1,8].
byRingName
Ring name.
dwRingSize
Ring file size.
byRingType
Ring file format: 0-WAV
byRes
Reserved, set to 0.
A.1.29 NET_DVR_RING_SEARCH_COND
Condition structure for ring search.
Structure Definition
struct{
DWORD dwSize;
DWORD dwRingID;
BYTE byRes[300];
}NET_DVR_RING_SEARCH_COND,*LPNET_DVR_RING_SEARCH_COND;
89
Device Network SDK (Video Intercom) Developer Guide
Members
dwSize
Structure size.
dwRingID
Ring ID, if this member is set to 0, all rings will be searched.
byRes
Reserved. set to 0.
A.1.30 NET_DVR_RING_UPLOAD_CFG
Parameter structure for uploading ring file.
Structure Definition
struct{
DWORD dwSize;
DWORD dwRingID;
BYTE byRingName[MAX_RING_NAME_LEN_128/*128*/];
DWORD dwRingSize;
BYTE byRingType;
BYTE byRes[363];
}NET_DVR_RING_UPLOAD_CFG,*LPNET_DVR_RING_UPLOAD_CFG;
Members
dwSize
Structure size.
dwRingID
Ring ID, value range: [1,8].
byRingName
Ring name.
dwRingSize
Ring file size, unit: byte.
byRingType
Ring file format: 0-WAV
byRes
Reserved, set to 0.
90
Device Network SDK (Video Intercom) Developer Guide
A.1.31 NET_DVR_SEND_CARD_INFO
Card issuing event information structure of video intercom
Structure Definition
struct{
BYTE byCardNo[ACS_CARD_NO_LEN/*32*/];
BYTE byRes[224];
}NET_DVR_SEND_CARD_INFO, *LPNET_DVR_SEND_CARD_INFO;
Members
byCardNo
Card No.
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON
A.1.32 NET_DVR_STREAM_INFO
Stream information structure.
Structure Definition
struct{
DWORD dwSize;
BYTE byID[STREAM_ID_LEN/*32*/];
DWORD dwChannel;
BYTE byRes[32];
}NET_DVR_STREAM_INFO,*LPNET_DVR_STREAM_INFO;
Members
dwSize
Structure size.
byID
Stream ID, which consists of letters, digits, and dashes, 0-invalid.
dwChannel
Linked device channel. When it is 0xffffffff, if setting the stream source, this parameter indicates
that no device channel is linked; if setting configuration condition, this parameter is invalid.
91
Device Network SDK (Video Intercom) Developer Guide
byRes
Reserved, set to 0.
Remarks
● If the device does not support marking stream ID, e.g., DVR, the parameter byID should be set to
0.
● For transcoder, when setting the stream source, only one of byID and dwChannel can be valid;
when transcoding, both the byID and dwChannel can be invalid, the transcoding channel or
stream ID is automatically allocated by device.
● For other devices (e.g., CVR), when this structure is inputted as configuration condition, if both
the byID and dwChannel are invalid, error code (17) will be returned, if they are valid, but
mismatched, error may also be returned, so only setting one of these two parameters is
suggested.
A.1.33 NET_DVR_STREAM_MODE_TYPE
Streaming mode structure
Structure Definition
struct{
DWORD byGetStreamType;
BYTE byRes[3];
NET_DVR_STREAM_TYPE_UNION uGetStream;
}NET_DVR_STREAM_MODE_TYPE,*LPNET_DVR_STREAM_MODE_TYPE;
Members
byGetStreamType
Streaming mode: 0-get stream from device directly; 1-get stream from stream media server; 2-
get stream from device after getting the IP address by IP server; 3-get the device IP address by
IP server, and then get stream from stream media server; 4-get stream from stream media
server by URL; 6-get stream via URL combined by data structure (contains user name and
password).
byRes
Reserved, set to 0.
uGetStream
Streaming mode, refer to the union NET_DVR_STREAM_TYPE_UNION for details.
See Also
NET_DVR_STREAM_SRC_INFO
92
Device Network SDK (Video Intercom) Developer Guide
A.1.34 NET_DVR_STREAM_SRC_CFG
Stream source information structure.
Structure Definition
struct{
DWORD dwSize;
NET_DVR_STREAM_INFO struStreamID;
NET_DVR_STREAM_SRC_INFO struStreamSrcInfo;
}NET_DVR_STREAM_SRC_CFG,*LPNET_DVR_STREAM_SRC_CFG;
Members
dwSize
Structure size.
struStreamInfo
Stream source information, refer to the structure NET_DVR_STREAM_INFO for details.
struStreamSrcInfo
Stream source information, refer to the structure NET_DVR_STREAM_SRC_INFO for details.
A.1.35 NET_DVR_STREAM_SRC_INFO
Structure of stream source information
Structure Definition
struct{
DWORD dwSize;
NET_DVR_STREAM_INFO struStreamInfo;
NET_DVR_STREAM_MODE_TYPE struStreamSrcInfo;
}NET_DVR_STREAM_SRC_INFO,*LPNET_DVR_STREAM_SRC_INFO;
Members
dwSize
Structure size.
struStreamInfo
Stream information, refer to the structure NET_DVR_STREAM_INFO for details.
struStreamSrcInfo
Stream source information, refer to the structure NET_DVR_STREAM_MODE_TYPE for details.
93
Device Network SDK (Video Intercom) Developer Guide
A.1.36 NET_DVR_STREAM_TYPE_UNION
Streaming mode union
Structure Definition
union{
NET_DVR_DIRECT_CONNECT_CHAN_INFO struChanInfo;
NET_DVR_PU_STREAM_URL struStreamUrl;
NET_DVR_PU_STREAM_URL_CFG struStreamUrlCfg;
}NET_DVR_STREAM_TYPE_UNION,*LPNET_DVR_STREAM_TYPE_UNION;
Members
struChanInfo
Digital channel information, refer to the structure NET_DVR_DIRECT_CONNECT_CHAN_INFO for
details.
struStreamUrl
Parameters for getting steam by URL, refer to the structure NET_DVR_PU_STREAM_URL for
details.
struStreamUrlCfg
Parameters for getting stream by URL structure, refer to the structure
NET_DVR_PU_STREAM_URL_CFG for details.
A.1.37 NET_DVR_TIME_EX
94
Device Network SDK (Video Intercom) Developer Guide
A.1.38 NET_DVR_UNLOCK_RECORD_INFO
Unlocking event information structure of video intercom
Structure Definition
struct{
BYTE byUnlockType;
BYTE byRes1[3];
BYTE byControlSrc[NAME_LEN/*32*/];
DWORD dwPicDataLen;
BYTE *pImage;
DWORD dwCardUserID;
SHORT nFloorNumber;
WORD wRoomNumber;
WORD wLockID;
BYTE byRes2[2];
BYTE byLockName[LOCK_NAME_LEN/*32*/];
BYTE byRes[168];
}NET_DVR_UNLOCK_RECORD_INFO, *LPNET_DVR_UNLOCK_RECORD_INFO;
Members
byUnlockType
Mode to open door
enum _UNLOCK_TYPE_ENUM_{
ENUM_UNLOCK_PASSWORD = 1,
ENUM_UNLOCK_HIJACKING = 2,
ENUM_UNLOCK_CARD = 3,
ENUM_UNLOCK_HOUSEHOLDER = 4,
ENUM_UNLOCK_CENTER_PLATFORM = 5,
ENUM_UNLOCK_BLUETOOTH = 6,
ENUM_UNLOCK_QR_CODE = 7,
ENUM_UNLOCK_FACE = 8,
ENUM_UNLOCK_FINGERPRINT = 9
}UNLOCK_TYPE_ENUM
ENUM_UNLOCK_PASSWORD
Open door by password
ENUM_UNLOCK_HIJACKING
Open door by duress code
ENUM_UNLOCK_CARD
Open door by card
ENUM_UNLOCK_HOUSEHOLDER
Open door by household
95
Device Network SDK (Video Intercom) Developer Guide
ENUM_UNLOCK_CENTER_PLATFORM
Open door by central platform
ENUM_UNLOCK_BLUETOOTH
Open door by bluetooth
ENUM_UNLOCK_QR_CODE
Open door by QR code
ENUM_UNLOCK_FACE
Open door by face
ENUM_UNLOCK_FINGERPRINT
Open door by fingerprint
byRes1
Reserved, set to 0.
byControlSrc
Operation source information, when unlock by card, it represents the card No., otherwise, it
represents the device No.
dwPicDataLen
Picture data size.
pImage
Buffer pointer, which is used to save picture data, and the default picture format is JPEG.
dwCardUserID
Card holder ID.
nFloorNumber
Floor No., it is valid when opening door by card.
wRoomNumber
Room No., it is valid when opening door by card.
wLockID
Lock ID, for door station: 0-lock of door station, 1-locak of external access control module.
byRes2
Reserved, set to 0.
byLockName
Lock name, it is valid when opening door by card.
byRes
Reserved, set to 0.
96
Device Network SDK (Video Intercom) Developer Guide
See Also
NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON
A.1.39 NET_DVR_USER_LOGIN_INFO
97
Device Network SDK (Video Intercom) Developer Guide
A.1.40 NET_DVR_VIDEO_CALL_COND
Condition structure for starting video intercom.
Structure Definition
struct{
DWORD dwSize;
BYTE byRes[128];
}NET_DVR_VIDEO_CALL_COND, *LPNET_DVR_VIDEO_CALL_COND;
Members
dwSize
Structure size.
byRes
Reserved, set to 0.
A.1.41 NET_DVR_VIDEO_CALL_PARAM
Parameter structure for video intercom interaction.
Structure Definition
struct{
DWORD dwSize;
DWORD dwCmdType;
WORD wPeriod;
98
Device Network SDK (Video Intercom) Developer Guide
WORD wBuildingNumber;
WORD wUnitNumber;
SHORT wFloorNumber;
WORD wRoomNumber;
BYTE byRes[118];
}NET_DVR_VIDEO_CALL_PARAM, *LPNET_DVR_VIDEO_CALL_PARAM;
Members
dwSize
Structure size.
dwCmdType
Command type: 0-request for call, 1-cancel the call, 2-answer, 3-decline, 4-time out, 5-end the
call, 6-device is in call, 7-client is in call.
wPeriod
Community No., value range: [0,9].
wBuildingNumber
Building No.
wUnitNumber
Unit No.
wFloorNumber
Floor No.
wRoomNumber
Room No.
byRes
Reserved, set to 0.
A.1.42 NET_DVR_VIDEOINTERCOM_STREAM
Stream channel parameter structure of video intercom
Structure Definition
struct{
DWORD dwSize;
BYTE byVisDevID[MAX_NAMELEN/*16*/];
DWORD byDeviceName[NAME_LEN/*32*/];
BYTE bySourceType;
BYTE byRes[255];
}NET_DVR_VIDEOINTERCOM_STREAM, *LPNET_DVR_VIDEOINTERCOM_STREAM;
99
Device Network SDK (Video Intercom) Developer Guide
Members
dwSize
Structure size.
byVisDevID
Video intercom device No., and all digits in the No. are 0 when the video source type is network
camera.
byDeviceName
Device name.
bySourceType
Video source type: 0-invalid, 1-network camera, 2-DVR/DVS/NVR, 3-door station, 4-outer door
station, 5-doorphone.
byRes
Reserved, set to 0.
A.1.43 NET_DVR_VIDEO_INTERCOM_ALARM
Video intercom alarm information structure
Structure Definition
struct{
DWORD dwSize;
NET_DVR_TIME_EX struTime;
BYTE byDevNumber[MAX_DEV_NUMBER_LEN/*32*/];
BYTE byAlarmType;
BYTE byRes1[3];
NET_DVR_VIDEO_INTERCOM_ALARM_INFO_UNION uAlarmInfo;
BYTE wLockID
BYTE byRes2[254];
}NET_DVR_VIDEO_INTERCOM_ALARM, *LPNET_DVR_VIDEO_INTERCOM_ALARM;
Members
dwSize
Structure size.
struTime
Alarm time, refer to the structure NET_DVR_TIME_EX for time format.
byDevNumber
Device No.
byAlarmType
100
Device Network SDK (Video Intercom) Developer Guide
Alarm type: 1-zone alarm, 2-tampering alarm, 3-duress alarm, 4-opening door by password
failed for multiple times, 5-opening door failed, 6-closing door failed, 7-panic alarm), 8-intercom
alarm, 9-smart lock: fingerprint duress alarm, 10-smart lock: password duress alarm, 11-smart
lock: tampering alarm, 12-smart lock: locked alarm, 13-smart lock: low battery alarm, 14-
blocklist alarm, 15-smart lock disconnected, 16-access control module: anti-tampering alarm,
17-video intercom started, 18-video intercom stopped.
byRes1
Reserved, set to 0.
uAlarmInfo
Alarm information, it is valid when byAlarmType equals to 1. Refer to the union
NET_DVR_VIDEO_INTERCOM_ALARM_INFO_UNION for details.
wLockID
Lock ID, it is valid when alarm type is 5 or 6. When the ID is 0, it represents the lock of door
station, when the ID is 1, it represents the lock of external access control module.
byRes2
Reserved, set to 0.
A.1.44 NET_DVR_VIDEO_INTERCOM_ALARM_CFG
Alarm or event parameter structure of video intercom
Structure Definition
struct{
DWORD dwSize;
BYTE byDoorNotCloseAlarm;
BYTE byRes[603];
}NET_DVR_VIDEO_INTERCOM_ALARM_CFG, *LPNET_DVR_VIDEO_INTERCOM_ALARM_CFG;
Members
dwSize
Structure size.
byDoorNotCloseAlarm
Whether to upload door open alarm: 0-no, 1-yes.
byRes
Reserved, set to 0.
101
Device Network SDK (Video Intercom) Developer Guide
A.1.45 NET_DVR_VIDEO_INTERCOM_ALARM_INFO_UNION
Video intercom alarm information union
Structure Definition
union{
BYTE byLen[256];
NET_DVR_ZONE_ALARM_INFO struZoneAlarm;
}NET_DVR_VIDEO_INTERCOM_ALARM_INFO_UNION, *LPNET_DVR_VIDEO_INTERCOM_ALARM_INFO_UNION;
Members
byLen
Union size, which is 256 bytes.
struZoneAlarm
Zone alarm information, it is valid when the byAlarmType equals to 1. Refer to the structure
NET_DVR_ZONE_ALARM_INFO for details.
See Also
NET_DVR_VIDEO_INTERCOM_ALARM
A.1.46 NET_DVR_VIDEO_INTERCOM_DEVICEID_CFG
Parameter structure for configuring video intercom device No.
Structure Definition
struct{
DWORD bySize;
BYTE byUnitType;;
BYTE byIsAutoReg;
BYTE byRes1[2];
NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION uVideoIntercomUnit;
BYTE byRes2[128];
}NET_DVR_VIDEO_INTERCOM_DEVICEID_CFG, *LPNET_DVR_VIDEO_INTERCOM_DEVICEID_CFG;
Members
dwSize
Structure size.
byUnitType
Device type: 1-door station, 2-master station, 4-outer station, 5-villa door station, 6-doorphone,
7-intelligent access control device.
102
Device Network SDK (Video Intercom) Developer Guide
byIsAutoReg
Whether to enable auto registration: 0-no, 1-yes.
byRes1
Reserved, set to 0.
uVideoIntercomUnit
Device No., refer to the data union NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION for
details.
byRes2
Reserved, set to 0.
Remarks
Configuring No. for doorphone is not required.
A.1.47 NET_DVR_VIDEO_INTERCOM_EVENT
Video intercom event information structure
Structure Definition
struct{
DWORD dwSize;
NET_DVR_TIME_EX struTime;
BYTE byDevNumber[MAX_DEV_NUMBER_LEN/*32*/];
BYTE byEventType;
BYTE byRes1[3];
NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON uEventInfo;
BYTE byRes2[256];
}NET_DVR_VIDEO_INTERCOM_EVENT, *LPNET_DVR_VIDEO_INTERCOM_EVENT;
Members
dwSize
Structure size.
struTime
Event occurred time, refer to the structure NET_DVR_TIME_EX for time format.
byDevNumber
Device No.
byEventType
Event type: 1-unlocking, 2-announcement reading receipt, 3-authentication, 5-illegal card
swiping, 6-card issuing of door station.
byRes1
103
Device Network SDK (Video Intercom) Developer Guide
Reserved, set to 0.
uEventInfo
Event information, and different types correspond to different data structures. Refer to the
union NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON for details.
byRes2
Reserved, set to 0.
A.1.48 NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON
Video intercom event information union
Union Definition
union{
BYTE byLen[256];
NET_DVR_UNLOCK_RECORD_INFO struUnlockRecord;
NET_DVR_NOTICEDATA_RECEIPT_INFO struNoticedataReceipt;
NET_DVR_SEND_CARD_INFO struSendCardInfo;
NET_DVR_AUTH_INFO struAuthInfo;
}NET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON, *LPNET_DVR_VIDEO_INTERCOM_EVENT_INFO_UINON;
Members
byLen
Union size, which is 256 bytes.
struUnlockRecord
Unlocking event information, refer to the structure NET_DVR_UNLOCK_RECORD_INFO for
details.
struNoticedataReceipt
Announcement reading receipt information, refer to the structure
NET_DVR_NOTICEDATA_RECEIPT_INFO for details.
struSendCardInfo
Card issuing event information, it is valid when byEventType equals to 5 or 6. Refer to the
structure NET_DVR_SEND_CARD_INFO for details.
struAuthInfo
Authentication information, refer to the structure NET_DVR_AUTH_INFO for details.
A.1.49 NET_DVR_VIDEO_INTERCOM_IOIN_CFG
Alarm input parameter structure of video intercom
104
Device Network SDK (Video Intercom) Developer Guide
Structure Definition
struct{
DWORD dwSize;
BYTE byIOUseType;
BYTE byRes[63];
}NET_DVR_VIDEO_INTERCOM_IOIN_CFG, *LPNET_DVR_VIDEO_INTERCOM_IOIN_CFG;
Members
dwSize
Structure size.
byIOUseType
Alarm input usage: 0-disabled, 1-for unlocking, 2-represents door status, 0xff-custom.
byRes
Reserved, set to 0.
A.1.50 NET_DVR_VIDEO_INTERCOM_IOOUT_CFG
Alarm output parameter structure of video intercom
Structure Definition
struct{
DWORD dwSize;
BYTE byIOUseType;
BYTE byRes[63];
}NET_DVR_VIDEO_INTERCOM_IOOUT_CFG, *LPNET_DVR_VIDEO_INTERCOM_IOOUT_CFG;
Members
dwSize
Structure size.
byIOUseType
Alarm output usage: 0-disabled, 1-for electronic lock, 0xff-custom.
byRes
Reserved, set to 0.
A.1.51 NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_CFG
Operation time configuration structure
105
Device Network SDK (Video Intercom) Developer Guide
Structure Definition
struct{
DWORD dwSize;
BYTE byUnitType;
BYTE byRes1[3];
NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_UNION uVideoIntercomUnit;
BYTE byRes2[128];
}NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_CFG, *LPNET_DVR_VIDEO_INTERCOM_OPERATION_TIME_CFG;
Members
dwSize
Structure size.
byUnitType
Device type: 1-door station, 2-master station, 4-outer door station, 5-villa door station, 6-
doorphone.
byRes1
Reserved, set to 0.
uVideoIntercomUnit
Operation time configuration union, which contains different structures for different devices,
refer to the union NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_UNION for details.
byRes2
Reserved, set to 0.
A.1.52 NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_UNION
Operation time configuration union of video intercom
Structure Definition
union{
BYTE byLen[128];
NET_DVR_INDOOR_UNIT_OPERATION_TIME_CFG struIndoorUnit;
NET_DVR_OUTDOOR_UNIT_OPERATION_TIME_CFG struOutdoorUnit;
NET_DVR_MANAGE_UNIT_OPERATION_TIME_CFG struManageUnit;
}NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_UNION,
*LPNET_DVR_VIDEO_INTERCOM_OPERATION_TIME_UNION;
Members
byLen
Union size, which is 128 bytes.
106
Device Network SDK (Video Intercom) Developer Guide
struIndoorUnit
Operation time parameters of indoor station, refer to the structure
NET_DVR_INDOOR_UNIT_OPERATION_TIME_CFG for details.
struOutdoorUnit
Operation time parameters of door station, outer door station, villa door station, and
doorphone, refer to the structure NET_DVR_OUTDOOR_UNIT_OPERATION_TIME_CFG for
details.
struManageUnit
Operation time parameters of main station, refer to the structure
NET_DVR_MANAGE_UNIT_OPERATION_TIME_CFG for details.
See Also
NET_DVR_VIDEO_INTERCOM_OPERATION_TIME_CFG
A.1.53 NET_DVR_VIDEO_INTERCOM_RELATEDEV_CFG
Configuration structure for linked network devices of video intercom.
Structure Definition
struct{
DWORD dwSize;
BYTE byUnitType;
BYTE byRes1[3];
NET_DVR_VIDEO_INTERCOM_UNIT_RELATEDEV_UNION uVideoIntercomUnit;
BYTE byRes2[128];
}NET_DVR_VIDEO_INTERCOM_RELATEDEV_CFG, *LPNET_DVR_VIDEO_INTERCOM_RELATEDEV_CFG;
Members
dwSize
Structure size.
byUnitType
Device type: 1-door station, 2-master station, 4-outer station, 5-villa door station, 6-doorphone,
7-intelligent access control device.
byRes1
Reserved, set to 0.
uVideoIntercomUnit
Parameter union of linked network device, refer to the union
NET_DVR_VIDEO_INTERCOM_UNIT_RELATEDEV_UNION for details.
byRes2
107
Device Network SDK (Video Intercom) Developer Guide
Reserved, set to 0.
A.1.54 NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION
Parameter union of video intercom device No.
Structure Definition
union{
BYTE byLen[128];
NET_DVR_INDOOR_UNIT_DEVICEID struIndoorUnit;
NET_DVR_OUTDOOR_UNIT_DEVICEID struOutdoorUnit;
NET_DVR_MANAGE_UNIT_DEVICEID struManageUnit;
NET_DVR_OUTDOOR_FENCE_DEVICEID struFenceUnit;
NET_DVR_OUTDOOR_UNIT_DEVICEID struVillaOutdoorUnit;
NET_DVR_OUTDOOR_UNIT_DEVICEID struAgainConfirmUnit;
}NET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION, *LPNET_DVR_VIDEO_INTERCOM_UNIT_DEVICEID_UNION;
Members
byLen
Union size, which is 128 bytes.
struIndoorUnit
Indoor station No., refer to the structure NET_DVR_INDOOR_UNIT_DEVICEID for details.
struOutdoorUnit
Door station (or intelligent access control device) No., refer to the structure
NET_DVR_OUTDOOR_UNIT_DEVICEID for details.
struManageUnit
Main station No., refer to the structure NET_DVR_MANAGE_UNIT_DEVICEID for details.
struFenceUnit
Outer door station No., refer to the structure NET_DVR_OUTDOOR_FENCE_DEVICEID for
details.
struVillaOutdoorUnit
Villa door station No., refer to the structure NET_DVR_OUTDOOR_UNIT_DEVICEID for details.
struAgainConfirmUnit
Doorphone No., refer to the structure NET_DVR_OUTDOOR_UNIT_DEVICEID for details.
Remarks
● The rules to generate device No. are as the follows:
108
Device Network SDK (Video Intercom) Developer Guide
○ The long No. of main station is "*00000001XX": "*"-project No., "001"-main station, "XX"-
main station No. (01, 02, …, increased by 1).
○ The long No. of door station, villa door station, or doorphone is "*XXXXX000$$": "*"-project
No.; "XXX"-building No.; "XX"-unit No.; "000"-door station; "$$"-door station No. ("00"-main
door station, other values-sub door station).
○ The long No. of indoor station is "*XXXXX$$$$$": "*"-project No.; "XXX"-building No.; "XX"-
A.1.55 NET_DVR_VIDEO_INTERCOM_UNIT_RELATEDEV_UNION
Configuration union of the network device linked with video intercom.
Structure Definition
union{
DWORD dwRes[256];
NET_DVR_INDOOR_UNIT_RELATEDEV struIndoorUnit;
NET_DVR_OUTDOOR_UNIT_RELATEDEV struOutdoorUnit;
NET_DVR_MANAGE_UNIT_RELATEDEV struManageUnit;
NET_DVR_OUTDOOR_UNIT_RELATEDEV struVillaUnit;
NET_DVR_AGAIN_RELATEDEV struAgainUnit;
}NET_DVR_VIDEO_INTERCOM_UNIT_RELATEDEV_UNION,*LPNET_DVR_VIDEO_INTERCOM_UNIT_RELATEDEV_UNION;
Members
dwRes
Union size, which is 1024 bytes (256 × 4).
struIndoorUnit
Linked network device parameters of indoor station, refer to the structure
NET_DVR_INDOOR_UNIT_RELATEDEV for details.
struOutdoorUnit
Linked network device parameters of door station, outer door station, or intelligent access
control device, refer to the structure NET_DVR_OUTDOOR_UNIT_RELATEDEV for details.
struManageUnit
Linked network device parameters of master station, refer to the structure
NET_DVR_MANAGE_UNIT_RELATEDEV for details.
struVillaUnit
109
Device Network SDK (Video Intercom) Developer Guide
Linked network device parameters of villa door station, refer to the structure
NET_DVR_OUTDOOR_UNIT_RELATEDEV for details.
struAgainUnit
Linked network device parameters of doorphone, refer to the structure
NET_DVR_AGAIN_RELATEDEV for details.
See Also
NET_DVR_VIDEO_INTERCOM_RELATEDEV_CFG
A.1.56 NET_DVR_VIS_REGISTER_INFO
Registration information structure of door station.
Structure Definition
struct{
DWORD dwSize;
DWORD dwID;
BYTE szDevNumber[MAX_DEV_NUMBER_LEN/*328*/];
DWORD byMACAddr[MACADDR_LEN/*6*/];
BYTE byRes1[2];
DWORD sSerialNumber[SERIALNO_LEN/*48*/];
NET_DVR_IPADDR struDevIP;
NET_DVR_TIME_EX struRegisterTime;
BYTE byRegisterType;
BYTE byRes[127];
}NET_DVR_VIS_REGISTER_INFO, *LPNET_DVR_VIS_REGISTER_INFO;
Members
dwSize
Structure size.
dwID
Registration ID.
szDevNumber
Device No.
byMACAddr
MAC address.
byRes1
Reserved, set to 0.
sSerialNumber
Device serial No.
110
Device Network SDK (Video Intercom) Developer Guide
struDevIP
Device IP address, refer to the structure NET_DVR_IPADDR_UNION for details.
struRegisterTime
Registration time, for time format, refer to the structure NET_DVR_TIME_EX .
byRegisterType
Registration type: 0-reserved, 1-door station, 2-master station, 4-outer door station, 5-villa door
station, 6-doorphone, 7-Infosight Client Software, 8-iVMS-4200 Client Software.
byRes
Reserved, set to 0.
A.1.57 NET_DVR_XML_CONFIG_INPUT
Related API
NET_DVR_STDXMLConfig
111
Device Network SDK (Video Intercom) Developer Guide
A.1.58 NET_DVR_XML_CONFIG_OUTPUT
Related API
NET_DVR_STDXMLConfig
A.1.59 NET_DVR_ZONE_ALARM_INFO
Zone alarm information structure
Structure Definition
struct{
BYTE byZoneName[NAME_LEN/*32*/];
DWORD dwZonendex;
BYTE byZoneType;
112
Device Network SDK (Video Intercom) Developer Guide
BYTE byRes[219];
}NET_DVR_ZONE_ALARM_INFO, *LPNET_DVR_ZONE_ALARM_INFO;
Members
byZoneName
Zone name.
dwZonendex
Zone No.
byZoneType
Zone types, which are enumerated below.
enum _ALARM_ZONE_TYPE_ENUM_{
ENUM_ALARM_ZONE_TYPE_MANUAL = 0,
ENUM_ALARM_ZONE_TYPE_MAGNETIC = 1,
ENUM_ALARM_ZONE_TYPE_SMOKE = 2,
ENUM_ALARM_ZONE_TYPE_ACTIVE_INFRARED = 3,
ENUM_ALARM_ZONE_TYPE_PASSIVE_INFRARED = 4,
ENUM_ALARM_ZONE_TYPE_GAS = 11
}ALARM_ZONE_TYPE_ENUM
ENUM_ALARM_ZONE_TYPE_MANUAL
Panic alarm
ENUM_ALARM_ZONE_TYPE_MAGNETIC
Door magnetic alarm
ENUM_ALARM_ZONE_TYPE_SMOKE
Smoke detection alarm
ENUM_ALARM_ZONE_TYPE_ACTIVE_INFRARED
Active IR alarm
ENUM_ALARM_ZONE_TYPE_PASSIVE_INFRARED
Passive IR alarm
ENUM_ALARM_ZONE_TYPE_GAS
Gas detection alarm
byRes
Reserved, set to 0.
See Also
NET_DVR_VIDEO_INTERCOM_ALARM_INFO_UNION
A.1.60 NET_SDK_CALLBACK_STATUS_NORMAL
113
Device Network SDK (Video Intercom) Developer Guide
A.1.61 NET_SDK_UPLOAD_TYPE
114
Device Network SDK (Video Intercom) Developer Guide
115
Device Network SDK (Video Intercom) Developer Guide
116
Device Network SDK (Video Intercom) Developer Guide
A.1.62 NET_ALARM_CVR_SUBINFO_UNION
A.1.63 NET_ALARM_RECORD_EXCEPTION
117
Device Network SDK (Video Intercom) Developer Guide
A.1.64 NET_ALARM_RECORDFILE_LOSS
118
Device Network SDK (Video Intercom) Developer Guide
A.1.65 NET_ALARM_RESOURCE_USAGE
A.1.66 NET_ALARM_STREAM_EXCEPTION
A.1.67 NET_DVR_ALARMER
119
Device Network SDK (Video Intercom) Developer Guide
A.1.68 NET_DVR_ALARMINFO_DEV
120
Device Network SDK (Video Intercom) Developer Guide
Remarks
For pNO: if dwAlarmType is 0, 3, 6, or 7, it may be channel No.; if dwAlarmType is 5, it may be disk
No.
A.1.69 NET_DVR_ALARMINFO_DEV_V40
121
Device Network SDK (Video Intercom) Developer Guide
Remarks
For pNO: if dwAlarmType is 0, 3, 6, or 7, it may be channel No.; if dwAlarmType is 5, it may be disk
No.
A.1.70 NET_DVR_ALARMINFO_V30
122
Device Network SDK (Video Intercom) Developer Guide
Remarks
The time interval to upload the alarm of face picture library changed is 1 hour; for other alarm
type, the alarm information is uploaded in real-time, and the time interval is 1s. Currently, editing
the time interval is not supported.
A.1.71 NET_DVR_ALARMINFO_V40
Remarks
● The time interval to upload the alarm of face picture library changed is 1 hour; for other alarm
type, the alarm information is uploaded in real-time, and the time interval is 1s. Currently,
editing the time interval is not supported.
● The content of pAlarmData varies with the value of dwAlarmType in the structure
NET_DVR_ALRAM_FIXED_HEADER , see details in the table below:
123
Device Network SDK (Video Intercom) Developer Guide
A.1.72 NET_DVR_ALRAM_FIXED_HEADER
124
Device Network SDK (Video Intercom) Developer Guide
125
Device Network SDK (Video Intercom) Developer Guide
126
Device Network SDK (Video Intercom) Developer Guide
Table A-6 Structure about Alarm Parameters of Education Sharing System (struRecordingHost)
Member Data Type Description
bySubAlarmType BYTE Alarm minor type: 1-one-touch post-record
byRes1 Array of BYTE Reserved, set to 0. The maximum size is 3 bytes.
struRecordEndTime NET_DVR_TIME_EX Recording end time.
Table A-7 Structure about Alarm Parameters of Supply Voltage Exception (struVoltageInstable)
Member Data Type Description
fVoltageValue float Supply voltage, unit: V, corrects to one decimal
place.
byVoltageAlarmType BYTE Supply voltage exception type: 0-high supply
voltage, 1-low supply voltage
byRes1 Array of BYTE Reserved, set to 0. The maximum size is 3 bytes.
Remarks
dwAlarmType==0, 23 corresponds to the structure struIOAlarm; dwAlarmType==
2/3/6/9/10/11/13/15/16/28 corresponds to the structure struAlarmChannel; dwAlarmType==
127
Device Network SDK (Video Intercom) Developer Guide
A.1.73 NET_DVR_ALARM_ISAPI_INFO
Remarks
When enabling the listening mode, you should call the network configuration API based on text
protocol to set the IP address for the listening service.
128
Device Network SDK (Video Intercom) Developer Guide
A.1.74 NET_DVR_ALARM_ISAPI_PICDATA
A.1.75 NET_DVR_ETHERNET_V30
129
Device Network SDK (Video Intercom) Developer Guide
A.1.76 NET_DVR_IPADDR_UNION
IP Address Union
A.1.77 NET_DVR_NETCFG_V50
130
Device Network SDK (Video Intercom) Developer Guide
Remarks
● For device only supports the private protocol with version 3.0 or lower, when the parameter
byUseDhcp="0xff", you should set the device IP address to null, and then the device will
automatically get the DHCP information.
● When the parameter byIPv6Mode is set to 0 or 2, setting IPv6 address in the parameter
struEtherNet is not required, it will be obtained automatically by the device; when byIPv6Mode
is set to 1, you should set IPv6 address. As there are multiple IPv6 addresses, the IPv6 address of
current logged-in device may be different with that in struEtherNet.
A.1.78 NET_DVR_PPPOECFG
131
Device Network SDK (Video Intercom) Developer Guide
A.1.79 NET_DVR_SETUPALARM_PARAM_V50
132
Device Network SDK (Video Intercom) Developer Guide
1-yes.
● bit1-whether to enable ANR for people
no, 1-yes.
● bit3-whether to enable ANR for face capture:
0-no, 1-yes.
● bit4-whether to enable ANR for face picture
133
Device Network SDK (Video Intercom) Developer Guide
data, 1-URL
● bit1-type of picture uploaded in message: 0-
binary, 1-URL
● bit2-type of picture uploaded for face picture
134
Device Network SDK (Video Intercom) Developer Guide
Remarks
● The parameters byLevel and byAlarmInfoType are available for traffic cameras. Up to 1 cameras
can be armed in the priority of level 0, up to 3 cameras can be armed in the priority of level 1,
and up to 5 cameras can be armed in the priority of level 3, the alarm/event information from
the camera in highest priority will be uploaded first.
● For arming via client software, only supports arming one channel, and supports uploading the
alarm/event when device is offline; for real-time arming, up to four channels can be armed at
same time, but uploading alarm/event when device is offline is not supported.
● The parameter wTaskNo is used to distinguish different arming connections. If the value of this
parameter in different arming connections is same, error will be returned.
A.1.80 NET_DVR_TIME
A.1.81 NET_DVR_TIME_EX
135
Device Network SDK (Video Intercom) Developer Guide
A.2.1 /ISAPI/VideoIntercom/callerInfo/capabilities?format=json
Get the capability of getting the caller information.
A.2.2 /ISAPI/VideoIntercom/callerInfo?format=json
Get the caller information.
136
Device Network SDK (Video Intercom) Developer Guide
Request None.
Response Succeeded: JSON_CallerInfo
Failed: JSON_ResponseStatus
A.2.3 /ISAPI/VideoIntercom/capabilities
Get video intercom capability.
A.2.4 /ISAPI/VideoIntercom/IntercomProtocolType
Get or set parameters for switching between the private video intercom protocol and the standard
SIP (Session Initiation Protocol).
137
Device Network SDK (Video Intercom) Developer Guide
A.2.5 /ISAPI/VideoIntercom/IntercomProtocolType/capabilities
Get the configuration capability for switching between the private protocol and the standard SIP
(Session Initiation Protocol).
A.2.6 /ISAPI/VideoIntercom/keyCfg?readerID=<readerID>&type=virtualKey
Get the parameters of pressing the button to call of multiple buttons.
138
Device Network SDK (Video Intercom) Developer Guide
Query readerID: optional, string, reader ID. When there are multiple
readers, the device needs to support configuring parameters by
reader ID. If this query parameter is not configured, it indicates
configuring parameters of the controller and all readers.
Request None.
Response Succeeded: XML_KeyCfgList
Failed: XML_ResponseStatus
A.2.7 /ISAPI/VideoIntercom/keyCfg/<keyID>?
readerID=<readerID>&moduleId=<subModuleID>
Get or set the parameters of pressing the button to call for a specific button.
139
Device Network SDK (Video Intercom) Developer Guide
Query readerID: optional, string, reader ID. When there are multiple
readers, the device needs to support configuring parameters by
reader ID. If this query parameter is not configured, it indicates
configuring parameters of the controller and all readers.
subModuleID: optional, string, sub module ID, which is obtained
from the corresponding sub module list. If this query parameter is
not configured, it indicates configuring the main module.
Request XML_KeyCfg
Response XML_ResponseStatus
Remarks
The <keyID> in the request URI refers to the button No.
A.2.8 /ISAPI/VideoIntercom/keyCfg/<keyID>/capabilities?
moduleId=<subModuleID>
Get the configuration capability of pressing the button to call.
A.2.9 /ISAPI/VideoIntercom/passwordAuthentication
Verify video intercom encryption.
140
Device Network SDK (Video Intercom) Developer Guide
A.2.10 /ISAPI/VideoIntercom/passwordAuthentication/capabilities
Get encryption verification capability of video intercom.
A.2.11 /ISAPI/VideoIntercom/ring
Delete all rings.
141
Device Network SDK (Video Intercom) Developer Guide
Request None.
Response XML_ResponseStatus
A.2.12 /ISAPI/VideoIntercom/ring/capabilities
Get ring configuration capability.
A.2.13 /ISAPI/VideoIntercom/ring/ringID/<ID>
Delete ring by ring ID.
Remarks
The <ID> in the request URI refers to the ring ID.
142
Device Network SDK (Video Intercom) Developer Guide
A.2.14 /ISAPI/VideoIntercom/scene/nowMode
Get or set scene parameters of video intercom.
A.2.15 /ISAPI/VideoIntercom/scene/nowMode/capabilities
Get scene configuration capability of video intercom.
143
Device Network SDK (Video Intercom) Developer Guide
Failed: XML_ResponseStatus
A.2.16 /ISAPI/VideoIntercom/SubModules/<ID>/CallCfg/capabilities?format=json
Get configuration capability of nametag module.
Remarks
The <ID> in the request URI refers to the sub module ID or DIP switch address, which should be
larger than 0.
A.2.17 /ISAPI/VideoIntercom/SubModules/<ID>/CallCfg?format=json
Get or set nametag module parameters.
144
Device Network SDK (Video Intercom) Developer Guide
Remarks
The <ID> in the request URI refers to the sub module ID or DIP switch address, which should be
larger than 0.
A.2.18 /ISAPI/VideoIntercom/SubModules/<ID>/Configurations/capabilities?
format=json
Get configuration capability of sub module.
Remarks
The <ID> in the request URI refers to the sub module ID or DIP switch address, which should be
larger than 0.
A.2.19 /ISAPI/VideoIntercom/SubModules/<ID>/Configurations?format=json
Get or set sub module parameters.
145
Device Network SDK (Video Intercom) Developer Guide
Remarks
The <ID> in the request URI refers to the sub module ID or DIP switch address, which should be
larger than 0.
A.2.20 /ISAPI/VideoIntercom/SubModules/capabilities?format=json
Get capability of getting sub module status.
146
Device Network SDK (Video Intercom) Developer Guide
Failed: JSON_ResponseStatus
A.2.21 /ISAPI/VideoIntercom/SubModules?format=json
Get sub module status.
A.2.22 /ISAPI/VideoIntercom/WorkStatus
Get working status of door station.
147
Device Network SDK (Video Intercom) Developer Guide
A.3.1 JSON_CallCfg
JSON message about nametag module parameters
{
"CallCfg": {
"KeyBindings": [{
/*this node is valid for the nametag module*/
"buttonNumber": ,
/*optional, integer type, button No. which is valid for nametag module only*/
"roomNumber": ,
/*optional, integer type, room No. which is valid for nametag module only*/
"callNumber": ""
/*optional, string type, call number which is valid for nametag module only*/
}]
}
}
A.3.2 JSON_CallerInfo
Message about the caller information in JSON format.
{
"CallerInfo":{
"buildingNo": ,
/*optional, int, building No.*/
"floorNo": ,
/*optional, int, floor No.*/
"zoneNo": ,
/*optional, int, project No.*/
"unitNo": ,
/*optional, int, unit No.*/
"devNo": ,
/*optional, int, device serial No.*/
"devType": ,
/*required, int, device type: 1-door station, 2-main station, 3-indoor station, 4-outer door station, 5-villa door station,
6-doorphone, 7-Infosight Client Software, 8-iVMS-4200 Client Software, 9-APP, 10-doorbell, 11-VOIP Client Software,
12-network camera, 13-access control device*/
"lockNum": ,
/*optional, int, number of locks*/
"voipNo": ,
/*optional, string, VOIP Client Software number, this field is valid when devType is 11*/
"status":
/*required, string, status: "idle", "ring", "ring"-the call is in progress*/
}
}
148
Device Network SDK (Video Intercom) Developer Guide
A.3.3 JSON_Cap_CallCfg
JSON message about the configuration capability of the nametag module
{
"CallCfg": {
"KeyBindings": {
"maxSize": 20,
/*maximum number of buttons, which can be same as the maximum number of nametag modules*/
"roomNumber": {
/*required, integer type, room No., which is valid only for nametag module*/
"@min": 1,
"@max": 65535
},
"buttonNumber": {
/*required, integer type, button No., which is valid only for nametag module*/
"@min": 1,
"@max": 16
},
"callNumber": {
/*optional, string type, call number, which is valid only for nametag module; if this node is not supported, it will not
be returned*/
"@min": ,
"@max":
}
}
}
}
A.3.4 JSON_Cap_CallerInfo
Message about the capability of getting the caller information in JSON format.
{
"CallerInfo":{
"buildingNo":{
/*optional, int, building No.*/
"@min":0,
"@max":16
},
"floorNo":{
/*optional, int, floor No.*/
"@min":0,
"@max":16
},
"zoneNo":{
/*optional, int, project No.*/
"@min":0,
"@max":16
149
Device Network SDK (Video Intercom) Developer Guide
},
"unitNo":{
/*optional, int, unit No.*/
"@min":0,
"@max":16
},
"devNo":{
/*optional, int, device serial No.*/
"@min":0,
"@max":16
},
"devType":{
/*required, int, device type: 1-door station, 2-main station, 3-indoor station, 4-outer door station, 5-villa door station,
6-doorphone, 7-Infosight Client Software, 8-iVMS-4200 Client Software, 9-APP, 10-doorbell, 11-VOIP Client Software,
12-network camera, 13-access control device*/
"@opt":"1,2,3,4,5,6,7,8,9,10,11,12,13"
},
"lockNum":{
/*optional, int, number of locks*/
"@min":0,
"@max":16
},
"voipNo":{
/*optional, string, VOIP Client Software number, this field is valid when devType is 11*/
"@min":0,
"@max":16
},
"status":{
/*required, string, status: "idle", "ring", "ring"-the call is in progress*/
"@opt":"idle,ring,onCall"
}
}
}
A.3.5 JSON_Cap_SubModules
JSON message about the capability of getting the sub module status
{
"SubModules": {
"maxSize": 20,
/*maximum number of sub modules*/
"id": {
/*required, integer type, sub module ID (or DIP switch address)*/
"@min": 1,
"@max": 10000
},
"moduleType": {
/*required, string type, "DS-KD-KK": nametag module, "DS-KD-KP": keypad module, "DS-KD-M": card swiping module
(13.56MHz), "DS-KD-E": card swiping module (125KHz), "DS-KD-SG": indicator module, "DS-KD-DIS": display module,
"DS-1101M, DS-1102M, DS-1103M, DS-1104M, DS-1107M, DS-1108M, DS-1101MK, DS-1102MK, DS-1103MK,
150
Device Network SDK (Video Intercom) Developer Guide
A.3.6 JSON_Cap_SubModulesCfg
JSON message about the configuration capability of the sub module
{
"SubModulesCfg": {
"Backlight": {
"brightness": {
/*optional, integer, backlight brightness whose value is between 0 and 100*/
"@min": 0,
"@max": 100
}
},
"enableKeypadTone":"true,false",
/*optional, boolean, whether to enable tough sound*/
"infoMode": "on,off,auto"
/*optional, string, indicator mode: "on"-remain on, "off"-remain off, "auto"*/
}
}
A.3.7 JSON_EventNotificationAlert_Alarm/EventInfo
EventNotificationAlert message with alarm or event information in JSON format.
{
"ipAddress": "",
/*required, device IPv4 address , string, the maximum size is 32 bytes*/
151
Device Network SDK (Video Intercom) Developer Guide
"ipv6Address": "",
/*optional, device IPv6 address, string, the maximum size is 128 bytes*/
"portNo": ,
/*optional, device port No., integer32*/
"protocol": "",
/*optional, protocol type, "HTTP, HTTPS", string, the maximum size is 32 bytes*/
"macAddress": "",
/*optional, MAC address, string, the maximum size is 32 bytes, e.g., 01:17:24:45:D9:F4*/
"channelID": "",
/*optional, device channel No., integer32*/
"dateTime": "",
/*optional, string, alarm/event triggered or occurred time based on ISO8601, the maximum size is 32 bytes, e.g.,
2009-11-14T15:27Z*/
"activePostCount": "",
/*required, alarm/event frequency, integer32*/
"eventType": "",
/*required, alarm/event type, "captureResult, faceCapture,...", string, the maximum size is 128 bytes*/
"eventState": "",
/*required, string, the maximum size is 32 bytes, durative alarm/event status: "active"-valid, "inactive"-invalid*/
"eventDescription": "",
/*required, event description, string, the maximum size is 128 bytes*/
"deviceID":"",
/*string type, device ID*/
"uuid":"",
/*string type, event UUID, which is used to uniquely identify an event, the standard UUID format is xxxxxxxx-xxxx-xxxx-
xxxx-xxxxxxxxxxxx*/
...
/*optional, for different alarm/event types, the nodes are different, see the message examples in different
applications*/
}
A.3.8 JSON_EventNotificationAlert_VideoIntercomEventMsg
The information about the video intercom event is uploaded in JSON format of
EventNotificationAlert message.
{
"ipAddress":172.6.64.7,
/*required, string, IPv4 address of the alarm device, the maximum size is 32 bytes*/
"ipv6Address":"",
/*optional, string, IPv6 address of the alarm device, the maximum size is 128 bytes*/
"portNo":80,
/*optional, integer32, port No. of the alarm device*/
"protocol":"HTTP",
/*optional, string, protocol type: "HTTP", "HTTPS", the maximum size is 32 bytes*/
"macAddress":"01:17:24:45:D9:F4",
/*optional, string, MAC address, the maximum size is 32 bytes*/
"channelID":"1",
/*optional, integer32, device channel No. that triggered alarm*/
"dateTime":"2016-12-12T17:30:08+08:00",
152
Device Network SDK (Video Intercom) Developer Guide
/*required, string, time when the alarm is triggered (UTC time, e.g., "2017-04-22T15:39:01+08:00"), the maximum
size is 32 bytes*/
"activePostCount":1,
/*required, integer32, times that the same alarm has been uploaded*/
"eventType":"voiceTalkEvent",
/*required, string, triggered event type, here it should be set to "voiceTalkEvent", the maximum size is 128 bytes*/
"eventState":"active",
/*required, string, event triggering status: "active"-triggered, "inactive"-not triggered, the maximum size is 32 bytes.
For continuous events, this field is used to check whether uploading the continuous events is ended. For example,
when the motion detection event occurs, it will be uploaded continuously until an message with eventType "inactive"
is uploaded ("invalid" indicates an invalid event)*/
"eventDescription":"Voice Talk Interactive Event",
/*required, event description*/
"deviceID":"",
/*optional, string ,device ID, this field is required for devices using ISUP*/
"VoiceTalkEvent":{
"deviceName":"",
/*optional, string, device name*/
"deviceId": ,
/*optional, string, device No. which consists of 0 to 32 characters*/
"cmdType":"",
/*required, string, operation type: "request"-request for calling, "cancel"-cancel this calling, "answer"-answer this
calling, "reject"-reject this calling, "bellTimeout"-the bell ringing of the callee timed out, "hangUp"-end this calling,
"deviceOnCall"-the calling is in progress*/
"src":{
/*optional*/
"periodNumber": ,
/*optional, int, project No.*/
"buildingNumber": ,
/*optional, int, building No.*/
"unitNumber": ,
/*optional, int, unit No.*/
"floorNumber": ,
/*optional, int, floor No.*/
"roomNumber": ,
/*optional, int, room No.*/
"devIndex": ,
/*optional, int, device serial No.*/
"communityNumber":"",
/*optional, string, community No.*/
"unitType":""
/*optional, string, unit type: "indoor"-indoor station, "villa"-villa door station, "confirm"-doorphone, "outdoor"-door
station, "fence"-outer door station, "doorbell"-doorbell, "manage"-main station, "acs"-access control device*/
},
"target":{
/*optional*/
"periodNumber": ,
/*optional, int, project No.*/
"buildingNumber": ,
/*optional, int, building No.*/
"unitNumber": ,
/*optional, int, unit No.*/
153
Device Network SDK (Video Intercom) Developer Guide
"floorNumber": ,
/*optional, int, floor No.*/
"roomNumber": ,
/*optional, int, room No.*/
"devIndex": ,
/*optional, int, device serial No.*/
"communityNumber":"",
/*optional, string, community No.*/
"unitType":""
/*optional, string, unit type: "indoor"-indoor station, "villa"-villa door station, "confirm"-doorphone, "outdoor"-door
station, "fence"-outer door station, "doorbell"-doorbell, "manage"-main station, "acs"-access control device*/
},
"serialNo": ,
/*optional, int, event serial No.*/
"currentEvent": ,
/*optional, boolean, whether it is a real-time event: true-yes (real-time event), false-no (offline event)*/
"frontSerialNo": ,
/*optional, int, serial No. of the previous event. If this field is not returned, the device will check whether event loss
occurs by serialNo; if this field is returned, the device will check whether event loss occurs by this field and serialNo
together. This field is mainly used to solve the problem that the serialNo is noncontinuous after subscribing alarms*/
"pictureURL":"",
/*optional, string, picture URL*/
"picturesNumber":
/*optional, int, number of pictures. If there is no picture or the picture is uploaded by picture URL, this field is 0 or not
returned*/
}
}
A.3.9 JSON_ResponseStatus
JSON message about response status
{
"requestURL":"",
/*optional, string, request URL*/
"statusCode": ,
/*optional, int, status code*/
"statusString":"",
/*optional, string, status description*/
"subStatusCode":"",
/*optional, string, sub status code*/
"errorCode": ,
/*required, int, error code, which corresponds to subStatusCode, this field is required when statusCode is not 1. The
returned value is the transformed decimal number*/
"errorMsg":"",
/*required, string, error details, this field is required when statusCode is not 1*/
"MErrCode": "0xFFFFFFFF",
/*optional, string, error code categorized by functional modules*/
"MErrDevSelfEx": "0xFFFFFFFF"
/*optional, string, extension of MErrCode. It is used to define the custom error code, which is categorized by
154
Device Network SDK (Video Intercom) Developer Guide
functional modules*/
}
A.3.10 JSON_SubModules
JSON message about the sub module status
{
"SubModules": [{
"id": ,
/*required, integer type, sub module ID (or DIP switch address)*/
"moduleType": "",
/*required, string type, "DS-KD-KK": nametag module, "DS-KD-KP": keypad module, "DS-KD-M": card swiping module
(13.56MHz), "DS-KD-E": card swiping module (125KHz), "DS-KD-SG": indicator module, "DS-KD-DIS": display module,
"DS-1101M, DS-1102M, DS-1103M, DS-1104M, DS-1107M, DS-1108M, DS-1101MK, DS-1102MK, DS-1103MK,
DS-1104MK, DS-1107MK, DS-1108MK": card reader*/
"status": "",
/*required, string type, status: "online", "offline", "fault"*/
"numOfButtons": ,
/*optional, integer type, number of buttons, this node is valid for nametag module only*/
"version":""
/*optional, string type, software version*/
}]
}
A.3.11 JSON_SubModulesCfg
JSON message about sub module parameters
{
"SubModulesCfg": {
"Backlight": {
"brightness":
/*optional, integer type, backlight brightness whose value is between 0 and 100, this node is valid only for display
module*/
},
"enableKeypadTone": ,
/*optional, boolean type, whether to enable touch sound: true-yes, false-no, this node is valid only for display
module*/
"infoMode": ""
/*optional, string type, indicator mode: "on"-remain on, "off"-remain off, "auto"*/
}
}
155
Device Network SDK (Video Intercom) Developer Guide
A.3.12 XML_Cap_IntercomProtocolType
Message about the configuration capability for switching between the private protocol and the
standard SIP in XML format.
<IntercomProtocolType version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<protocolType opt="Private, StandardSIP"><!--required, xs:string, protocol type: "Private"-private video intercom
protocol, "StandardSIP"-standard SIP protocol--></protocolType>
</IntercomProtocolType>
A.3.13 XML_Cap_KeyCfg
Message about the configuration capability of pressing the button to call in XML format.
<KeyCfg version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<id min="" max=""><!--required, xs:integer, button No. which corresponds to the <ID> in the request URI /ISAPI/
VideoIntercom/keyCfg/<ID>/capabilities--></id>
<module opt="main,sub"><!--optional, xs:string, module to be configured: "main"-main module (default), "sub"-sub
module--></module>
<moduleId min="" max=""><!--dependent, xs:integer, sub module ID, this node is valid when <module> is "sub" and
is used to specify that the button information of which module will be configured--></moduleId>
<callNumber min="" max=""><!--optional, xs:string, called number--></callNumber>
<enableCallCenter opt="true,false"><!--optional, xs:boolean, whether to call the management center--></
enableCallCenter>
<callMethod opt=" callNumber,manageCenter,app"><!--optional, xs:string, calling method: "callNumber"-call by
number, "manageCenter"-call the management center, "app"-call APP, "manualCallNumber"-manually call by number.
The empty string is invalid, and if this node is configured, the node <enableCallCenter> is not required--></
callMethod>
</KeyCfg>
A.3.14 XML_Cap_PasswordAuthenticationCfg
XML message about the encryption verification capability of video intercom
<PasswordAuthenticationCfg version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<password min="" max="">
<!--required, xs:string, password-->
</password>
</PasswordAuthenticationCfg>
A.3.15 XML_Cap_RingParam
XML message about the ring configuration capability
<RingParam version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<ringID min="" max=""><!--required, xs:integer, ring ID--></ringID>
156
Device Network SDK (Video Intercom) Developer Guide
A.3.16 XML_Cap_SceneNowMode
XML message about the scene configuration capability of video intercom
<SceneNowMode version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<nowMode opt="atHome,goOut,goToBed,custom">
<!--required, xs:string, current scene mode-->
</nowMode>
</SceneNowMode>
A.3.17 XML_EventNotificationAlert_AlarmEventInfo
EventNotificationAlert message with alarm/event information in XML format.
<EventNotificationAlert version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<ipAddress><!--dep, xs:string, device IPv4 address--></ipAddress>
<ipv6Address><!--dep, xs:string, device IPv6 address--></ipv6Address>
<portNo><!--opt, xs:integer, device port number--></portNo>
<protocol><!--opt, xs:string, protocol type for uploading alarm/event information, "HTTP,HTTPS"--></protocol>
<macAddress><!--opt, xs:string, MAC address--></macAddress>
<channelID><!--dep, xs:string, device channel No., starts from 1--></channelID>
<dateTime><!--req, alarm/event triggered or occurred time, format: 2017-07-19T10:06:41+08:00--></dateTime>
<activePostCount><!--req, xs:integer, alarm/event frequency, starts from 1--></activePostCount>
<eventType><!--req, xs:string, alarm/event type, "peopleCounting, ANPR,..."--></eventType>
<eventState>
<!--req, xs:string, durative alarm/event status: "active"-valid, "inactive"-invalid, e.g., when a moving target is
detected,
the alarm/event information will be uploaded continuously unit the status is set to "inactive"-->
</eventState>
<eventDescription><!--req, xs:string, alarm/event description--></eventDescription>
<...><!--opt, for different alarm/event types, the nodes are different, see the message examples in different
applications--></...>
</EventNotificationAlert>
A.3.18 XML_IntercomProtocolType
Message about the parameters for switching between the private video intercom protocol and the
standard SIP in XML format.
<IntercomProtocolType version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<protocolType><!--required, xs:string, protocol type: "Private"-private video intercom protocol, "StandardSIP"-
157
Device Network SDK (Video Intercom) Developer Guide
A.3.19 XML_IpViewDevAbility
XML message about the video intercom device capability
<IpViewDevAbility version="2.0">
<!--video intercom device capability-->
<SipServerLogin><!--required, registration capability of SIP server-->
<AutoLogin><!--required, whether to support automatic registration-->
<enable></enable>
</AutoLogin>
<loginStatus opt="registered,unregistered"/><!--required, registration status-->
<sipLoginNameLen min="1" max="32"/><!--required, length of registered user name-->
<sipLoginPasswordLen min="1" max="16"/><!--required, length of registered password-->
<displayNameLen min="1" max="128"/><!--required, length of displayed device name-->
<localNumber min="1" max="32"/><!--required, length of local station number-->
<loginCycle min="1" max="99"/><!--required, registration period, unit: minute-->
<serverSipPort min="1024" max="65535"/>
<localPort min="1024" max="65535"><!--optional, local port No.-->
<isNotSupportLocalPort></isNotSupportLocalPort><!--optional, whether the local port is not supported: true-yes
(the local port is not supported), this field is not supported-no (the local port is supported)-->
<domainNameLen min="", max=""/><!--optional, the meaning of this field is the same as that of the field
<sipServerDomain>. For new devices, both fields need to be returned-->
<addressType opt="IP/IPV6, domain"/><!--supported address type-->
<mutexAbility opt="gbt28181"/><!--required, mutex ability, gbt28181-->
<notSupportCharacter opt=""><!--whether the domain name contains unsupported characters: true-yes (the
domain name contains unsupported characters)-->
<isNotSupportSipServerIP></isNotSupportSipServerIP><!--whether the IP address of the SIP server is not
supported: true-yes (the IP address of the SIP server is not supported), this field is not supported-no (the IP address of
the SIP server is supported). For old devices, this field will not be returned; this field is used to check whether new
devices support the IP address of the SIP server-->
<sipServerDomain min="" max=""/><!--optional, domain name of the SIP server. The meaning of this field is the
same as that of the field <domainNameLen>. For new devices, both fields need to be returned-->
<stunServerIP min="" max=""/><!--optional, IP address of the STUN server-->
<stunServerDomain min="" max=""/><!--optional, domain name of the STUN server-->
<stunServerPort min="" max=""/><!--optional, port No. of the STUN server-->
<proxyServerIP min="" max=""/><!--optional, IP address of the proxy server-->
<proxyServerDomain min="" max=""/><!--optional, domain name of the proxy server-->
<proxyServerPort min="" max=""/><!--optional, port No. of the proxy server-->
<netWork opt="0,1,2,3"/><!--optional, network type: 0-invalid, 1-wired network 1, 2-wired network 2, 3-wireless
network-->
<CalledTargetName min="" max=""/><!--optional, user name length of the called person-->
</SipServerLogin>
<LocalAbility><!--required, basic capability of video intercom extension-->
<defaultRing min="1" max="6"/><!--required, options of the default local ringtone-->
<ringVolume min="1" max="9"/><!--required, range of the local ringtone volume-->
<inputVolume min="0" max="6"/><!--required, input volume options-->
<outputVolume min="0" max="9"/><!--required, output volume options-->
<audioEncPriNum><!--required, supported number of audio encoding levels--></audioEncPriNum>
158
Device Network SDK (Video Intercom) Developer Guide
159
Device Network SDK (Video Intercom) Developer Guide
"antiHijacking"-duress password-->
<pwdLen min="6" max="16"/><!--password length-->
</PrivilegePwd>
<OperationTime><!--operation time-->
<monitoringTime min="10" max="60"/><!--maximum live view duration, unit: second-->
<ringTime min="15" max="60"/><!--maximum ringing duration, unit: second-->
<messageTime min="30" max="60"/><!--maximum messaging duration, unit: second-->
<talkTime min="90" max="120"/><!--maximum calling duration, unit: second-->
<callForwardingTime min="0" max="20"/><!--calling forwarding timeout, unit: second-->
<dwRingDurationTime min="30" max="60"/><!--ringing time duration, unit: second-->
</OperationTime>
<RelateDevice>
<outdoorUnitIP opt="ipv4,ipv6"/><!--IP address of main door station-->
<manageUnitIP opt="ipv4,ipv6"/><!--IP address of main station-->
<sipServerIP opt="ipv4,ipv6"/><!--IP address of SIP server-->
<centerIP opt="ipv4,ipv6"/><!--center IP address-->
<centerPort min="" max=""/><!--center port No.-->
<indoorUnitIP opt="ipv4,ipv6"/><!--IP address of indoor station-->
<notSupportAgainUnitIP opt="true,false"/><!--required, whether configuring doorphone IP address is not
supported: "true"-yes, "false"-no-->
<againUnitIP opt="ipv4,ipv6"/><!--doorphone IP address-->
<notSupportOutDoorType opt="true,false"/><!--required, whether configuring main door station type is not
supported: "true"-yes, "false"-no-->
<outDoorType opt="unitOutdoor,villaOutDoor"/><!--main door station type: "unitOutdoor"-main door station (D
series), "villaOutDoor"-main door station (V series)-->
<outInConnectMode opt="sameLan,diffLan"/><!--networ mode of door station and sub indoor station: "sameLan"-
in the same LAN, "diffLan"-in different LANs-->
<indoorConnectMode opt="wireless,wired"/><!--network mode of main indoor station and sub indoor station:
"wireless"-wireless NIC, "wired"-wired NIC-->
</RelateDevice>
<NoticeData>
<noticeTime><!--notice time--></noticeTime>
<noticeNumberLen min="0" max="32"/><!--notice No.-->
<noticeThemeLen min="0" max="64"/><!--notice theme-->
<noticeDetailLen min="0" max="1024"/><!--notice details-->
<noticeLevel opt="advertisement,propertyMgmt,alarm,notification"/><!--notice level: "advertisement"-
advertisement information, "propertyMgmt"-property information, "alarm"-alarm information, "notification"-notice
information-->
<maxPicNum><!--number of pictures--></maxPicNum>
<maxSinglePicSize><!--maximum size of a picture, unit: KB--></maxSinglePicSize>
</NoticeData>
<ControlGateway><!--unlock remotely-->
<gatewayIndex min="1"/><!--access control No.-->
<command opt="close,open"/><!--control command-->
<controlSrc>true</controlSrc><!--operation source information-->
<controlType opt="monitor,calling"/><!--unlocking scene type: "monitor", "calling"-->
<lockType opt="normal,smartLock"/><!--lock type-->
<lockID min="" max=""/><!--lock ID-->
<password min="" max=""/><!--password length of the smart lock-->
</ControlGateway>
<Zone><!--zone configuration-->
<ZoneConfig>
160
Device Network SDK (Video Intercom) Developer Guide
161
Device Network SDK (Video Intercom) Developer Guide
</ZoneArmDisarm>
<ZoneGroupBypass>
<enabled><!--whethe to support zone group bypass--></enabled>
</ZoneGroupBypass>
</Zone>
<IOIn>
<IOInNo attri="readonly" min="" max=""/><!--IP input No. which can only be obtained-->
<useType opt="disabled,openDoorBtn,doorStatus,custom"/><!--purpose: "disabled", "openDoorBtn"-door exit
button, "doorStatus"-door status, "custom"-->
</IOIN>
<IOOut>
<IOOutNo attri="readonly" min="" max=""/><!--IO output No. which can only be obtained-->
<useType opt="disabled,electricLock,custom"/><!--purpose: "disabled", "electricLock"-electric lock, "custom"-->
</IOOut>
<ElevatorControl>
<elevatorNo attri="readonly" min="" max=""/> <!--ro, elevator No.-->
<interfaceType opt="RS485,network"/><!--interface type: "RS485"-RS-485, "network"-->
<RS485Protocol opt="private,custom"/><!--RS-485 protocol type: "private", "custom"-->
<networkProtocol opt="private,custom"/><!--NIC protocol type: "private", "custom"-->
<serverIP opt="ipv4,ipv6"/><!--optional, IP address of the elevator control server-->
<serverPort min="" max=""/><!--optional, port No. of the elevator control server-->
</ElevatorControl>
<RS485Config>
<!--RS-485 configuration, this node will not be returned if RS-485 configuration is not supported-->
<deviceNameLength min="0" max="32"/><!--RS-485 name-->
<deviceType>true</DeviceType><!--whether to support configuring device type-->
<deviceProtocol>true</deviceProtocol><!--whether to support configuring device protocol-->
</RS485Config>
<supportDevInfo opt="true,false"/><!--required, whether to support getting complete indoor station No. This node
will not be returned if this function is not supported, and this node is valid only when the device is an indoor station-->
<supportRegisterInfo opt="true,false"/><!--required, whether the door station supports getting registration
information. This node will not be returned if this function is not supported, and this node is valid only when the
device is an door station-->
<CallRoomConfig><!--configuration of calling resident by pressing button for door station (V series)-->
<keyNo min="" max=""/><!--villa button No.-->
<floorNo min="" max=""/><!--villa floor No.-->
<roomNo min="" max=""/><!--villa room No.-->
<callManageCenter opt="true,false"/><!--required, whether to set it to the calling management center-->
<calledName min="" max=""/><!--optional, user name to be called, it supports letters, digits, @, and dot. This
node is valid in standard SIP mode-->
</CallRoomConfig>
<VideoCall><!--optional, video intercom capability-->
<enabled opt="true,false"/><!--required, whether supports starting video intercom-->
<supportCmd opt="callRequest,Cancel,Answer,Decline,Timeout,Bye,deviceCalling,clientCalling"/>
<!--required, command type supported by the device: "callRequest"-request for call, "Cancel"-cancel the call,
"Answer"-answer, "Decline"-decline, "Timeout"-time out, "Bye"-end the call, "deviceCalling"-device is in call,
"clientCalling"-client is in call-->
</VideoCall>
<CallerDevice><!--required, calling device information-->
<period min="1" max="16"/><!--required, community No.-->
<buildingNum min="1" max="16"/><!--required, building No.-->
<unitNum min="0" max="10"/><!--required, unit No.-->
162
Device Network SDK (Video Intercom) Developer Guide
163
Device Network SDK (Video Intercom) Developer Guide
24hourAudibleZone,delayZone,interiorWithDelayZone,keyswitchZone,supervisedFireZone,perimeterZone,
24hourSlientZone,disable"/><!--zone type supported by the device-->
<uploadAlarmRecoveryReport><!--whether to support report configuration of uploading alarm recovery--></
uploadAlarmRecoveryReport>
<zoneDelayTime min="" max=""/><!--delayed zone delay-->
<sensitivity opt="10ms,250ms,500ms,750ms"/><!--sensitivity-->
<arrayBypass><!--whether to support zone group bypass configuration--></arrayBypass>
<moduleStatus attri="readonly" opt="offline,online"/><!--module status-->
<moduleAddress min="" max=""/><!--module aqddress-->
<moduleChannel><!--module channel--></moduleChannel>
<moduleType opt="localZone, 1zoneExpander,2zoneExpander,8ZoneExpander,8sensorZoneExpander,
1ZoneAndTrigger"/><!--supported zone type-->
<zoneNo attri="readonly" min="" max=""/><!--zone No. which can only be obtained-->
<subsystemNo attri="readonly"><!--No. of the partition that the zone belongs to, it can only be obtained--></
subsystemNo>
<alarmType opt="open,close" default="open"/><!--required, alarm device type: "open"-remain open, "close"-
remain closed-->
<InDelayTime min="0" max="255"/><!--required, entrance delay, unit: second-->
<OutDelayTime min="0" max="255"/><!--required, exiting delay, unit: second-->
</ZoneConfig>
<GetZoneList>
<enabled><!--whether the device supports getting zone list--></enabled>
</GetZoneList>
<ZoneArmDisarm>
<enabled><!--whether the device supports arming and disarming the zone--></enabled>
</ZoneArmDisarm>
<ZoneGroupBypass>
<enabled><!--whether the device supports zone group bypass--></enabled>
</ZoneGroupBypass>
</ZoneList>
<NoNeedReboot>
<videoResolutionChange opt="true,false"/><!--optional, whether the device does not reboot after changing video
resolution-->
<videoFrameRateChange opt="true,false"/><!--optional, whether the device does not reboot after changing video
frame rate-->
</NoNeedReboot>
</IpViewDevAbility >
A.3.20 XML_KeyCfg
Message about the parameters of pressing the button to call of a specific button in XML format.
<KeyCfg version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<id><!--required, xs:integer, button No. which corresponds to the <ID> in the request URI /ISAPI/VideoIntercom/
keyCfg/<ID>--></id>
<module><!--optional, xs:string, module to be configured: "main"-main module (default), "sub"-sub module--> </
module>
<moduleId><!--dependent, xs:integer, sub module ID, this node is valid when <module> is "sub" and is used to
specify that the button information of which module will be configured--></moduleId>
<callNumber><!--dependent, xs:string, called number, this field is valid when <callMethod> is "callNumber"--></
callNumber>
164
Device Network SDK (Video Intercom) Developer Guide
A.3.21 XML_KeyCfgList
Message about the parameters of pressing the button to call of multiple buttons in XML format
<KeyCfgList version ="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<KeyCfg/><!--optional, see details in XML_KeyCfg-->
</KeyCfgList>
See Also
XML_KeyCfg
A.3.22 XML_PasswordAuthenticationCfg
XML message about the video intercom encryption parameters
<PasswordAuthenticationCfg version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<password>
<!--required, xs: string, password-->
</password>
</PasswordAuthenticationCfg>
A.3.23 XML_ResponseStatus
XML message about response status
<?xml version="1.0" encoding="utf-8"?>
<ResponseStatus version="2.0" xmlns="http://www.std-cgi.org/ver20/XMLSchema">
<requestURL>
<!--required, read-only, xs:string, request URL-->
</requestURL>
<statusCode>
<!--required, read-only, xs:integer, status code: 0,1-OK, 2-Device Busy, 3-Device Error, 4-Invalid Operation, 5-Invalid
XML Format, 6-Invalid XML Content, 7-Reboot Required, 9-Additional Error-->
</statusCode>
<statusString>
<!--required, read-only, xs:string, status description: OK, Device Busy, Device Error, Invalid Operation, Invalid XML
Format, Invalid XML Content, Reboot, Additional Error-->
</statusString>
<subStatusCode>
<!--required, read-only, xs:string, describe the error reason in detail-->
</subStatusCode>
165
Device Network SDK (Video Intercom) Developer Guide
<MErrCode>
<!--optional, xs:string, error code categorized by functional modules, e.g., 0x12345678-->
</MErrCode>
<MErrDevSelfEx>
<!--optional, xs:string, extension field of MErrCode. It is used to define the custom error code, which is categorized
by functional modules-->
</MErrDevSelfEx>
</ResponseStatus>
A.3.24 XML_SceneNowMode
XML message about scene parameters of video intercom
<SceneNowMode version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<nowMode>
<!--required, xs: string, current scene mode: "atHome", "goOut", "goToBed", "custom"-->
</nowMode>
</SceneNowMode>
A.3.25 XML_VideoIntercomCap
XML message about the video intercom capability
<VideoIntercomCap version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<isSupportDeviceId><!--optional, xs:boolean--></isSupportDeviceId>
<isSupportDeviceId><!--optional, xs:boolean--></isSupportDeviceId>
<isSupportOperationTime><!--optional, xs:boolean--></isSupportOperationTime>
<isSupportCallerInfo><!--optional, xs:boolean--></isSupportCallerInfo>
<isSupportCallSignal><!--optional, xs:boolean--></isSupportCallSignal>
<isSupportCallStatus><!--optional, xs:boolean--></isSupportCallStatus>
<isSupportRingManage><!--optional, xs: boolean, whether it supports ring management--></isSupportRingManage>
<isSupportPasswordAuthentication>
<!--required, xs: boolean, whether it supports password verification of video intercom-->
</isSupportPasswordAuthentication>
<isSupportRelatedDeviceAdress><!--optional, xs:boolean--></isSupportRelatedDeviceAdress>
<isSupportCardSectorCheck>
<!--required, xs: boolean, whether it supports section encryption verification of card-->
</isSupportCardSectorCheck>
<isSupportKeyCfg><!--optional, xs:boolean, whether it supports the configuration of pressing the button to call the
resident--></isSupportKeyCfg>
<isSupportWorkModeCfg><!--optional, xs:boolean--></isSupportWorkModeCfg>
<isSupportPrivilegePasswordStatus><!--req,xs:boolean, whether it supports getting the status of the device
permission password--></isSupportPrivilegePasswordStatus>
<isSupportElevatorControlCfg><!--optional, xs:boolean--></isSupportElevatorControlCfg>
<isSupportPrivilegePassword><!--optional, xs:boolean--></isSupportPrivilegePassword>
<isSupportAlarmControlByPhone>
<!--required, xs: boolean, whether it supports arming and control via mobile phone--></
isSupportAlarmControlByPhone>
<isSupportSceneManage><!--optional, xs: boolean, whether it supports scene management--></
166
Device Network SDK (Video Intercom) Developer Guide
isSupportSceneManage>
<isSupportZoneCfgByScene>
<!--optional, xs: boolean, whether it supports configuring zone parameters by scene-->
</isSupportZoneCfgByScene>
<isSupportCallElevator><!--required, xs: boolean, whether it supports calling elevator--></isSupportCallElevator>
<isSupportGetSmartLockParam>
<!--required, xs: boolean, whether it supports getting smart lock information-->
</isSupportGetSmartLockParam>
<isSupportAppKeyConfiguration>
<!--required, xs: boolean, whether it supports configuring APPKey-->
</isSupportAppKeyConfiguration>
<isSupportDeviceLanguageCfg>
<!--required, xs:boolean, whether it supports switching languages-->
</isSupportDeviceLanguageCfg>
<isSupportSubModules><!--optional, xs: boolean, whether it supports sub module management--></
isSupportSubModules>
<isSupportCallCfg>
<!--optional, xs: boolean, whether it supports configuring keypad of sub module-->
</isSupportCallCfg>
<isSupportSubModulesCfg>
<!--optional, xs: boolean, whether it supports configuring sub module parameters-->
</isSupportSubModulesCfg>
<isSupportIssueCards><!--optional, xs:boolean, whether it supports configuration the function of issuing main card--
></isSupportIssueCards>
<isSupportSendCardCfg><!--optional, xs:boolean, whether the door station supports configuring card issuing
function--></isSupportSendCardCfg>
<isSupportRingBackTone><!--optional, xs:boolean, whether it supports importing the ringtone for calling back--></
isSupportRingBackTone>
<isSupportCallPriority> <!--optional, xs:boolean--> </isSupportCallPriority>
<isSupportPhoneCfg><!--optional, xs:boolean, whether it supports configuring the resident's phone--></
isSupportPhoneCfg>
<isSupportDisplayRegion> <!--optional, xs:boolean --> </isSupportDisplayRegion>
<isSupportWatchPoint><!--optional, xs:boolean, related URI: /ISAPI/VideoIntercom/WatchPoint--></
isSupportWatchPoint>
<isSupportVoiceConfiguration><!--optional, xs:boolean, whether it supports enabling speech recognition and audio
prompt--></isSupportVoiceConfiguration>
<isSupportUpdateData> <!--optional, xs:boolean, whether it supports importing the upgrading file--> </
isSupportUpdateData>
<isSupportUpdateStrategy> <!--optional, xs:boolean, whether it supports upgrading configuration--> </
isSupportUpdateStrategy>
<isSupportMetaInfo> <!--optional, xs:boolean, whether it supports getting the upgrading file information--></
isSupportMetaInfo>
<platform opt="R0,R1,…"><!--optional, string, platform type. The actually supported platform types will be returned--
></platform>
<isSupportSecurityMode><!--optional, xs:boolean, whether it supports switching the security protocol version--></
isSupportSecurityMode>
<isSupportDeviceCommunication><!--optional, xs:boolean, whether it supports configuring communication
parameters of the device network--></isSupportDeviceCommunication>
<isSupportIncomingCallLinkage><!--optional, xs:boolean, whether it supports configuring the calling linkage--></
isSupportIncomingCallLinkage>
</VideoIntercomCap>
167
Device Network SDK (Video Intercom) Developer Guide
A.3.26 XML_WorkStatus
XML message about the working status of the door station
<WorkStatus version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<lockStatusList><!--for the lock of the door station, it is always online, so this node may not be returned; for the lock
of the external module, this node is required-->
<node>
<lockID>
<!--required, xs: integer, lock ID whose value may be 0 or 1-->
</lockID>
<lockStatus>
<!--required, xs: string, lock status: "online", "offline"-->
</lockStatus>
</node>
</lockStatusList>
</WorkStatus>
General Errors
168
Device Network SDK (Video Intercom) Developer Guide
169
Device Network SDK (Video Intercom) Developer Guide
170
Device Network SDK (Video Intercom) Developer Guide
171
Device Network SDK (Video Intercom) Developer Guide
172
Device Network SDK (Video Intercom) Developer Guide
173
Device Network SDK (Video Intercom) Developer Guide
174
Device Network SDK (Video Intercom) Developer Guide
175
Device Network SDK (Video Intercom) Developer Guide
176
Device Network SDK (Video Intercom) Developer Guide
177
Device Network SDK (Video Intercom) Developer Guide
178
Device Network SDK (Video Intercom) Developer Guide
179
Device Network SDK (Video Intercom) Developer Guide
180
Device Network SDK (Video Intercom) Developer Guide
181
Device Network SDK (Video Intercom) Developer Guide
182
Device Network SDK (Video Intercom) Developer Guide
183
Device Network SDK (Video Intercom) Developer Guide
184
Device Network SDK (Video Intercom) Developer Guide
185
Device Network SDK (Video Intercom) Developer Guide
186
Device Network SDK (Video Intercom) Developer Guide
187
Device Network SDK (Video Intercom) Developer Guide
188
Device Network SDK (Video Intercom) Developer Guide
189
Device Network SDK (Video Intercom) Developer Guide
190
Device Network SDK (Video Intercom) Developer Guide
191
Device Network SDK (Video Intercom) Developer Guide
192
Device Network SDK (Video Intercom) Developer Guide
193
Device Network SDK (Video Intercom) Developer Guide
194
Device Network SDK (Video Intercom) Developer Guide
195
Device Network SDK (Video Intercom) Developer Guide
196
Device Network SDK (Video Intercom) Developer Guide
197
Device Network SDK (Video Intercom) Developer Guide
198
Device Network SDK (Video Intercom) Developer Guide
199
Device Network SDK (Video Intercom) Developer Guide
200
Device Network SDK (Video Intercom) Developer Guide
201
Device Network SDK (Video Intercom) Developer Guide
202
Device Network SDK (Video Intercom) Developer Guide
203
Device Network SDK (Video Intercom) Developer Guide
204
Device Network SDK (Video Intercom) Developer Guide
205
Device Network SDK (Video Intercom) Developer Guide
206
Device Network SDK (Video Intercom) Developer Guide
207
Device Network SDK (Video Intercom) Developer Guide
208
Device Network SDK (Video Intercom) Developer Guide
209
Device Network SDK (Video Intercom) Developer Guide
210
Device Network SDK (Video Intercom) Developer Guide
211
Device Network SDK (Video Intercom) Developer Guide
StatusCode=1
StatusCode=2
212
Device Network SDK (Video Intercom) Developer Guide
StatusCode=3
213
Device Network SDK (Video Intercom) Developer Guide
214
Device Network SDK (Video Intercom) Developer Guide
215
Device Network SDK (Video Intercom) Developer Guide
StatusCode=4
216
Device Network SDK (Video Intercom) Developer Guide
217
Device Network SDK (Video Intercom) Developer Guide
218
Device Network SDK (Video Intercom) Developer Guide
219
Device Network SDK (Video Intercom) Developer Guide
220
Device Network SDK (Video Intercom) Developer Guide
221
Device Network SDK (Video Intercom) Developer Guide
222
Device Network SDK (Video Intercom) Developer Guide
223
Device Network SDK (Video Intercom) Developer Guide
224
Device Network SDK (Video Intercom) Developer Guide
225
Device Network SDK (Video Intercom) Developer Guide
226
Device Network SDK (Video Intercom) Developer Guide
227
Device Network SDK (Video Intercom) Developer Guide
228
Device Network SDK (Video Intercom) Developer Guide
229
Device Network SDK (Video Intercom) Developer Guide
230
Device Network SDK (Video Intercom) Developer Guide
231
Device Network SDK (Video Intercom) Developer Guide
232
Device Network SDK (Video Intercom) Developer Guide
233
Device Network SDK (Video Intercom) Developer Guide
234
Device Network SDK (Video Intercom) Developer Guide
235
Device Network SDK (Video Intercom) Developer Guide
236
Device Network SDK (Video Intercom) Developer Guide
237
Device Network SDK (Video Intercom) Developer Guide
238
Device Network SDK (Video Intercom) Developer Guide
239
Device Network SDK (Video Intercom) Developer Guide
240
Device Network SDK (Video Intercom) Developer Guide
241
Device Network SDK (Video Intercom) Developer Guide
242
Device Network SDK (Video Intercom) Developer Guide
StatusCode=5
StatusCode=6
243
Device Network SDK (Video Intercom) Developer Guide
244
Device Network SDK (Video Intercom) Developer Guide
245
Device Network SDK (Video Intercom) Developer Guide
246
Device Network SDK (Video Intercom) Developer Guide
247
Device Network SDK (Video Intercom) Developer Guide
248
Device Network SDK (Video Intercom) Developer Guide
249
Device Network SDK (Video Intercom) Developer Guide
StatusCode=7
250
Device Network SDK (Video Intercom) Developer Guide
251
Device Network SDK (Video Intercom) Developer Guide
is not allowed.
● Editing your own level or
252
Device Network SDK (Video Intercom) Developer Guide
253
Device Network SDK (Video Intercom) Developer Guide
254
Device Network SDK (Video Intercom) Developer Guide
255
Device Network SDK (Video Intercom) Developer Guide
256
Device Network SDK (Video Intercom) Developer Guide
257
Device Network SDK (Video Intercom) Developer Guide
258
Device Network SDK (Video Intercom) Developer Guide
259
Device Network SDK (Video Intercom) Developer Guide
260
Device Network SDK (Video Intercom) Developer Guide
261
Device Network SDK (Video Intercom) Developer Guide
262
Device Network SDK (Video Intercom) Developer Guide
263
Device Network SDK (Video Intercom) Developer Guide
264
Device Network SDK (Video Intercom) Developer Guide
configured.
● Node value exceeds the
265
Device Network SDK (Video Intercom) Developer Guide
266
Device Network SDK (Video Intercom) Developer Guide
267