Device Network SDK (People Counting) - Developer Guide - V6.1.0.X - 20230330
Device Network SDK (People Counting) - Developer Guide - V6.1.0.X - 20230330
Developer Guide
Device Network SDK (People Counting) 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 (People Counting) Developer Guide
Contents
Chapter 1 Overview .................................................................................................................... 1
1.1 Introduction ........................................................................................................................... 1
1.2 Update History ....................................................................................................................... 1
Chapter 2 Typical Applications .................................................................................................... 4
2.1 Enable People Counting ......................................................................................................... 4
2.2 Enable Counting Children ...................................................................................................... 9
2.3 Alarm and Event Receiving ................................................................................................... 12
2.3.1 Configure Reverse Entering Alarm .............................................................................. 12
2.3.2 Receive Alarm/Event in Arming Mode ........................................................................ 15
2.3.3 Receive Alarm/Event in Listening Mode ..................................................................... 18
2.4 Search Data and Report ....................................................................................................... 21
2.5 Other Configuration ............................................................................................................. 26
Chapter 3 API Reference ........................................................................................................... 28
3.1 NET_DVR_GetDeviceAbility ................................................................................................. 28
3.2 NET_DVR_GetDeviceConfig ................................................................................................. 29
3.3 NET_DVR_GetNextRemoteConfig ........................................................................................ 30
3.4 NET_DVR_GetRemoteConfigState ....................................................................................... 31
3.5 NET_DVR_GetSTDConfig ...................................................................................................... 32
3.6 NET_DVR_SetDeviceConfig .................................................................................................. 32
3.7 NET_DVR_SetSTDConfig ...................................................................................................... 34
3.8 NET_DVR_StartRemoteConfig ............................................................................................. 35
3.8.1 fRemoteConfigCallback ............................................................................................... 36
3.9 NET_DVR_StopRemoteConfig .............................................................................................. 37
3.10 NET_DVR_STDXMLConfig ................................................................................................... 37
3.11 NET_DVR_STDControl ........................................................................................................ 39
3.12 NET_DVR_CloseAlarmChan_V30 ....................................................................................... 39
ii
Device Network SDK (People Counting) Developer Guide
iii
Device Network SDK (People Counting) Developer Guide
iv
Device Network SDK (People Counting) Developer Guide
v
Device Network SDK (People Counting) Developer Guide
vi
Device Network SDK (People Counting) Developer Guide
Chapter 1 Overview
his manual provides the integration methods and processes based on Device Network SDK
(hereafter referred to as "HCNetSDK") for people counting applications.
1.1 Introduction
People counting function provides the statistics of line crossing persons or objects in a specified
time period. And there are two statistics type, i.e., real-time statistics and periodic statistics.
Real-Time Statistics
Real-time statistics (starts calculating after clearing caused by device reboot, manual clearing or
auto clearing at zero time point of each day) will be uploaded when the count changed. If the
count changed frequently, this statistics will update per second.
Periodic Statistics
Increased number in the configured statistics period. The update frequency is the configured
statistics period (the default period is 15 minutes, shortest period is 1 minute, and longest period
is 60 minutes).
1
Device Network SDK (People Counting) Developer Guide
added six nodes, i.e., <ChildFilter> (counting children), <MisinfoFilter> (false alarm filtering),
<detectionMode> (detection mode), <TrajectoryCountFilter> (pattern counting filtering),
<RegionsDirectionList> (parameter list of counting direction), and
<maintenanceModeEnabled> (whether to enable maintenance mode);
added the sub nodes <reportFormat> (email report format) and <child> (whether to enable
OSD for counting children) to the nodes <EmailReport> and <OverlayConfiguration>,
respectively;
deleted a sub node <regionID> from the node <OverlayConfiguration>.
3. Extended report capability message of people counting statistics XML_CountingSearchCap
(related API: NET_DVR_STDXMLConfig ; related URL: /ISAPI/System/Video/inputs/channels/
<ID>/counting/search/capabilities ):
added a statistics type "all" (number of entered and exited people) to the node
<statisticsType>;
added two nodes <isSupportchild> (whether supports counting children only) and
<MinTimeInterval> (minimum time interval).
4. Extended search condition structure of people counting statistics NET_DVR_PDC_QUERY_COND
(related API: NET_DVR_StartRemoteConfig ; command: 5089-NET_DVR_GET_PDC_RESULT):
added three members: byChild (whether supports counting children only), byMinTimeInterval
(minimum time interval), and byStatisticType (counting type) via three reserved bytes.
5. Extended alarm information structure of people counting NET_DVR_PDC_ALRAM_INFO :
added two members: dwChildLeaveNum (number of exited children) and dwChildEnterNum
(number of entered children) via 8 reserved bytes.
6. Added function of Configure Reverse Entering Alarm .
7. Added function of Enable Counting Children .
8. Extended arming schedule message XML_Schedule and alarm linkage parameter message
XML_EventTrigger (related API: NET_DVR_STDXMLConfig ; related URLs: /ISAPI/Event/
schedules/reverseEntrance/<ID> and /ISAPI/Event/triggers/<eventType>-<channelID> ):
added an alarm or event type "reverseEntrance" to the node <eventType>.
2
Device Network SDK (People Counting) Developer Guide
3
Device Network SDK (People Counting) Developer Guide
4
Device Network SDK (People Counting) Developer Guide
Steps
5
Device Network SDK (People Counting) Developer Guide
parameters, including detection region (line), arming schedule, linkage action, and so on, for
reference.
The people counting parameters are returned in the structure NET_DVR_PDC_RULE_CFG_V42
by lpOutBuffer.
3. Call NET_DVR_SetDeviceConfig with NET_DVR_SET_PDC_RULECFG_V42 (command No.: 3406),
specify lpInBuffer as NET_DVR_PDC_RULE_COND , and set lpInParamBuffer to
NET_DVR_PDC_RULE_CFG_V42 for enabling people counting and set parameters.
Note
● To receive alarm in platform, the linkage action must be set to "center" (upload to center).
● Setting people counting parameters is also available by logging in to device via web page.
switch(lCommand)
{
case COMM_ALARM_PDC: //People counting alarm information.
{
NET_DVR_PDC_ALRAM_INFO struPDCAlarmInfo = {0};
memcpy(&struPDCAlarmInfo, pAlarmInfo, sizeof(struPDCAlarmInfo));
if (struPDCAlarmInfo.byMode == 0) //0-Real-time statistics, real-time quantity is calculated after the latest
6
Device Network SDK (People Counting) Developer Guide
clearing (including device reboot, manual clearing or auto clearing at 00:00 of every day).
{
NET_DVR_TIME struAbsTime = {0};
struAbsTime.dwYear = GET_YEAR(struPDCAlarmInfo.uStatModeParam.struStatFrame.dwAbsTime);
struAbsTime.dwMonth = GET_MONTH(struPDCAlarmInfo.uStatModeParam.struStatFrame.dwAbsTime);
struAbsTime.dwDay = GET_DAY(struPDCAlarmInfo.uStatModeParam.struStatFrame.dwAbsTime);
struAbsTime.dwHour = GET_HOUR(struPDCAlarmInfo.uStatModeParam.struStatFrame.dwAbsTime);
struAbsTime.dwMinute = GET_MINUTE(struPDCAlarmInfo.uStatModeParam.struStatFrame.dwAbsTime);
struAbsTime.dwSecond = GET_SECOND(struPDCAlarmInfo.uStatModeParam.struStatFrame.dwAbsTime);
//Device IP address, port, channel, people exited, people entered, VCA alarm or not, absolute time
printf("DevIP:[%s]Port[%d]Channel[%d]single frame:Channel[%d]LeaveNum[%d]EnterNum[%d]Smart[%d]\
AbsTime[%4.4d%2.2d%2.2d%2.2d%2.2d%2.2d]\n", struPDCAlarmInfo.struDevInfo.struDevIP.sIpV4, \
struPDCAlarmInfo.struDevInfo.wPort, struPDCAlarmInfo.struDevInfo.byChannel, \
struPDCAlarmInfo.byChannel, struPDCAlarmInfo.dwLeaveNum, struPDCAlarmInfo.dwEnterNum,\
struPDCAlarmInfo.bySmart, struAbsTime.dwYear, struAbsTime.dwMonth, struAbsTime.dwDay,\
struAbsTime.dwHour, struAbsTime.dwMinute, struAbsTime.dwSecond);
}
if (struPDCAlarmInfo.byMode == 1) //1-Periodic statistics, increased quantity within specific statistics period,
update once per specified statistics period (default: 15 minutes, minimum: 1 minute and maximum: 60 minutes)
{
NET_DVR_TIME struStartTime = {0};
NET_DVR_TIME struEndTime = {0};
struStartTime = struPDCAlarmInfo.uStatModeParam.struStatTime.tmStart;
struEndTime = struPDCAlarmInfo.uStatModeParam.struStatTime.tmEnd;
//Device IP address, port, channel, people exited, people entered, people passed, VCA alarm or not, start
time, end time
printf("DevIP:[%s]Port[%d]Channel[%d]single
frame:Channel[%d]LeaveNum[%d]EnterNum[%d]PassingNum[%d]Smart[%d]\
StartTime[%4.4d%2.2d%2.2d%2.2d%2.2d%2.2d]EndTime[%4.4d%2.2d%2.2d%2.2d%2.2d%2.2d]\n",\
struPDCAlarmInfo.struDevInfo.struDevIP.sIpV4, struPDCAlarmInfo.struDevInfo.wPort,\
struPDCAlarmInfo.struDevInfo.byChannel, struPDCAlarmInfo.byChannel, struPDCAlarmInfo.dwLeaveNum,\
struPDCAlarmInfo.dwEnterNum, struPDCAlarmInfo.dwPassingNum, struPDCAlarmInfo.bySmart,
struStartTime.dwYear,\
struStartTime.dwMonth, struStartTime.dwDay, struStartTime.dwHour, struStartTime.dwMinute,\
struStartTime.dwSecond, struEndTime.dwYear, struEndTime.dwMonth, struEndTime.dwDay,
struEndTime.dwHour, \
struEndTime.dwMinute, struEndTime.dwSecond);
}
//Process other information
break;
}
default:
{
printf("Other alarms, alarm type: 0x%x\n", lCommand);
break;
}
}
7
Device Network SDK (People Counting) Developer Guide
return TRUE;
}
void main() {
//---------------------------------------
// Initialize
NET_DVR_Init();
//Set connected time and reconnected 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"); //IP address
struLoginInfo.wPort = 8000; //Service port
strcpy(struLoginInfo.sUserName, "admin"); //User name
strcpy(struLoginInfo.sPassword, "abcd1234"); //Password
//Enable arming
LONG lHandle;
NET_DVR_SETUPALARM_PARAM struAlarmParam={0};
struAlarmParam.dwSize=sizeof(struAlarmParam);
//Setting other arming parameters is not supported.
8
Device Network SDK (People Counting) Developer Guide
Sleep(50000); //During waiting, if the device uploaded alarm information, receive and handle the alarm information
in the alarm callback function.
//Log out
NET_DVR_Logout(lUserID);
//Release SDK resource
NET_DVR_Cleanup();
return;
}
What to do next
Call NET_DVR_Logout and NET_DVR_Cleanup to log out from device and release resources.
9
Device Network SDK (People Counting) Developer Guide
Steps
10
Device Network SDK (People Counting) Developer Guide
11
Device Network SDK (People Counting) Developer Guide
12
Device Network SDK (People Counting) Developer Guide
Steps
13
Device Network SDK (People Counting) Developer Guide
Note
To receive alarm in alarm receiving center, the linkage action must be set to "center".
6. Optional: Call NET_DVR_STDXMLConfig to pass through the request URL: GET /ISAPI/Event/
schedules/reverseEntrance/<ID> (the <ID> in the URL should be set to "reverseEntrance-
<channelID>") for getting default or configured arming schedule of reverse entering alarm for
reference.
The arming schedule is returned in the message XML_Schedule by lpOutputParam. And the
default arming schedule is "all-day".
7. Call NET_DVR_STDXMLConfig to pass through the request URL: PUT /ISAPI/Event/schedules/
reverseEntrance/<ID> (the <ID> in the URL should be set to "reverseEntrance-<channelID>") and
set lpInputParam to XML_Schedule for setting arming schedule of reverse entering alarm.
8. Optional: Set lCommand of alarm/event callback function MSGCallBack to
"COMM_VCA_ALARM" (command No.: 0x4993) for receiving reverse entering alarm in arming
mode (refer to Receive Alarm/Event in Arming Mode for details) or listening mode (refer to
Receive Alarm/Event in Listening Mode for details).
The reverse entering alarm information is called back in the message
JSON_EventNotificationAlert_reverseEntrance .
14
Device Network SDK (People Counting) Developer Guide
What to do next
Call NET_DVR_Logout and NET_DVR_Cleanup to log out from device and release the resources.
● Make sure you have configured the alarm/event parameters, refer to the typical alarm/event
15
Device Network SDK (People Counting) Developer Guide
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
#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;
}
16
Device Network SDK (People Counting) Developer Guide
//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;
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();
17
Device Network SDK (People Counting) Developer Guide
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
18
Device Network SDK (People Counting) Developer Guide
Steps
19
Device Network SDK (People Counting) 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);
20
Device Network SDK (People Counting) 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.
21
Device Network SDK (People Counting) Developer Guide
Steps
Note
● For rear-end devices, to check if searching people counting statistics of multiple channels is
supported, you can call NET_DVR_GetDeviceAbility and specify the capability type as
"DEVICE_SOFTHARDWARE_ABILITY" (macro definition value: 0x001) to get the software and
hardware capability ( XML_BasicCapability ). If supports, the node
<isSupportMultiChannelSearch> will be returned and its value is "true".
● For front-end devices, to check if searching people counting statistics of multiple channels is
supported, you can call NET_DVR_GetDeviceAbility , specify the capability type (dwAbilityType)
as "DEVICE_ABILITY_INFO" (macro definition value: 0x011), and set the input buffer pointer
22
Device Network SDK (People Counting) Developer Guide
Note
If 1000 (One result is found) and 1001 (Searching) returned, you should call this API repeatedly;
if 1002 (Ended) or 1003 (Exception) is returned, you should stop calling this API.
The search results are returned in the structure NET_DVR_PDC_RESULT by lpOutBuff.
3. Call NET_DVR_StopRemoteConfig to disconnect the persistent connection.
Example
Sample Code for Searching History Data
#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"); //IP address
struLoginInfo.wPort = 8000; //Service port
strcpy(struLoginInfo.sUserName, "admin"); //User name
strcpy(struLoginInfo.sPassword, "abcd1234"); //Password
23
Device Network SDK (People Counting) Developer Guide
NET_DVR_PDC_QUERY_COND m_struPdcResultCond={0};
m_struPdcResultCond.dwSize = sizeof(m_struPdcResultCond);//Condition for searching people counting data
m_struPdcResultCond.dwChannel = 1; //Device channel No.
//Start time
m_struPdcResultCond.struStartTime.wYear = 2016;
m_struPdcResultCond.struStartTime.byMonth = 9;
m_struPdcResultCond.struStartTime.byDay = 5;
m_struPdcResultCond.struStartTime.byHour = 00;
m_struPdcResultCond.struStartTime.byMinute = 00;
m_struPdcResultCond.struStartTime.bySecond = 00;
//End time
m_struPdcResultCond.struEndTime.wYear = 2016;
m_struPdcResultCond.struEndTime.byMonth = 9;
m_struPdcResultCond.struEndTime.byDay = 11;
m_struPdcResultCond.struEndTime.byHour = 23;
m_struPdcResultCond.struEndTime.byMinute = 59;
m_struPdcResultCond.struEndTime.bySecond = 59;
24
Device Network SDK (People Counting) Developer Guide
m_struPdcResult.struEndTime.byHour, m_struPdcResult.struEndTime.byMinute,
m_struPdcResult.struEndTime.bySecond);
}
else
{
if (iNextRet == NET_SDK_GET_NETX_STATUS_NEED_WAIT) //Wait for the device to send data
{
Sleep(5);
continue;
}
if (iNextRet == NET_SDK_GET_NEXT_STATUS_FINISH) //All data found.
{
printf("People counting data search ended.\n");
break;
}
else if(iNextRet == NET_SDK_GET_NEXT_STATUS_FAILED) //Search exception.
{
printf("Search exception.\n");
break;
}
else
{
printf("Unknown status.\n");
break;
}
}
}
}
else
{
printf("Search failed. Error code: %d\n",NET_DVR_GetLastError());
}
if (m_lHandle >= 0)
{
if (!NET_DVR_StopRemoteConfig(m_lHandle))
{
printf("Stopping searching people counting data failed.Error code: %d\n",NET_DVR_GetLastError());
}
}
//Log out
NET_DVR_Logout(lUserID);
//Release SDK resource
NET_DVR_Cleanup();
return;
}
What to do next
Call NET_DVR_Logout and NET_DVR_Cleanup to log out and release resources.
25
Device Network SDK (People Counting) Developer Guide
OSD Settings
● Get people counting information which displayed on live video
Call NET_DVR_GetSTDConfig with NET_DVR_GET_POSINFO_OVERLAY (command No.: 3961) and
set lpCondBuffer in NET_DVR_STD_CONFIG to 4-byte channel No.
The displayed people counting information is returned in NET_DVR_POSINFO_OVERLAY by
lpOutBuffer of NET_DVR_STD_CONFIG .
● Display people counting information on live video
Call NET_DVR_SetSTDConfig with NET_DVR_SET_POSINFO_OVERLAY (command No.: 3960), set
lpCondBuffer of NET_DVR_STD_CONFIG to 4-byte channel No., and specify lpInBuffer of
NET_DVR_STD_CONFIG as NET_DVR_POSINFO_OVERLAY .
Advanced Settings
● Get people counting status
Call NET_DVR_STDXMLConfig to pass through the request URL: GET /ISAPI/System/Video/
inputs/channels/<ID>/counting/status .
The status is returned in the message XML_CountingStatus by lpOutputParam.
● Clear People Counting Data
○ Clear all people counting data stored in flash storage
26
Device Network SDK (People Counting) Developer Guide
Note
To check if clearing people counting data is supported by device, you can call
NET_DVR_GetDeviceAbility , specify dwAbilityType as "DEVICE_ABILITY_INFO" (macro
definition value: 0x011), and set pInBuf to XML_Desc_VcaChanAbility for getting VCA channel
capability ( XML_VcaChanAbility ). If supports, the sub node <resetCounter> of node <PDC> will
be returned in the capability message.
27
Device Network SDK (People Counting) Developer Guide
3.1 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.
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.
28
Device Network SDK (People Counting) Developer Guide
3.2 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.
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
29
Device Network SDK (People Counting) Developer Guide
[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
3.3 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
[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.
30
Device Network SDK (People Counting) Developer Guide
3.4 NET_DVR_GetRemoteConfigState
Get the status of persistent connection.
API Definition
BOOL NET_DVR_GetRemoteConfigState(
LONG lHandle,
void *pState
);
Parameters
lHandle
[IN] Handle, which is returned by NET_DVR_StartRemoteConfig .
pState
[OUT] A 4-byte status value, the returned statuses are different according to different remote
configuration commands
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.
31
Device Network SDK (People Counting) Developer Guide
3.5 NET_DVR_GetSTDConfig
Get the device configuration information.
API Definition
BOOL NET_DVR_GetSTDConfig(
LONG lUserID,
DWORD dwCommand,
NET_DVR_STD_CONFIG lpConfigParam
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Device configuration commands, which are different according to different configuration
functions.
lpConfigParam
[IN][OUT] Set input and output parameters, which are different according to different
configuration functions. For different configuration functions, the lpCondBuffer and lpOutBuffer
in the IpConfigParam are also different. See the structure NET_DVR_STD_CONFIG for details.
Note
When getting configuration parameters, the lpInBuffer in the lpConfigParam is invalid, you can
set it to 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.
See Also
NET_DVR_SetSTDConfig
3.6 NET_DVR_SetDeviceConfig
Set device parameters in batch (sending data is supported).
API Definition
BOOL NET_DVR_SetDeviceConfig(
LONG lUserID,
32
Device Network SDK (People Counting) Developer Guide
DWORD dwCommand,
DWORD dwCount,
LPVOID lpInBuffer,
DWORD dwInBufferSize,
LPVOID lpStatusList,
LPVOID lpInParamBuffer,
DWORD dwInParamBufferSize
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
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.
33
Device Network SDK (People Counting) Developer Guide
If FALSE is returned, you can call NET_DVR_GetLastError to get the error code.
See Also
NET_DVR_GetDeviceConfig
3.7 NET_DVR_SetSTDConfig
Set the device parameters.
API Definition
BOOL NET_DVR_SetSTDConfig(
LONG lUserID,
DWORD dwCommand,
NET_DVR_STD_CONFIG lpConfigParam
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Device configuration commands, which are different according to different configuration
functions.
lpConfigParam
[IN][OUT] Set input and output parameters, which are different according to different
configuration functions. For different configuration functions, the lpCondBuffer and lpInBuffer
in the IpConfigParam are also different. See the structure NET_DVR_STD_CONFIG for details.
Note
When getting configuration parameters, the lpOutBuffer in the lpConfigParam is invalid, you
can set it to "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.
See Also
NET_DVR_GetSTDConfig
34
Device Network SDK (People Counting) Developer Guide
3.8 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:
35
Device Network SDK (People Counting) Developer Guide
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.
3.8.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
[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.
36
Device Network SDK (People Counting) Developer Guide
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.
3.9 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 .
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.
3.10 NET_DVR_STDXMLConfig
Transmit request URL with XML or JSON format to implement some typical functions.
37
Device Network SDK (People Counting) Developer Guide
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
[IN][OUT] Output parameters, refer to the structure NET_DVR_XML_CONFIG_OUTPUT for
details.
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:
38
Device Network SDK (People Counting) Developer Guide
3.11 NET_DVR_STDControl
Control remotely.
API Definition
BOOL NET_DVR_STDControl(
LONG lUserID,
DWORD dwCommand,
LPNET_DVR_STD_CONTROL lpControlParam
);
Parameters
lUserID
[IN] Value returned by NET_DVR_Login_V40 .
dwCommand
[IN] Control commands.
lpControlParam
[IN][OUT] Input parameters and output parameters of remote control. The parameters are
different according to different control commands, see details in the structure of
NET_DVR_STD_CONTROL .
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.
3.12 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 .
39
Device Network SDK (People Counting) Developer Guide
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 .
3.13 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.
40
Device Network SDK (People Counting) 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.
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
3.14 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.
41
Device Network SDK (People Counting) Developer Guide
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
3.15 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"
42
Device Network SDK (People Counting) Developer Guide
#include "HCNetSDK.h"
using namespace std;
int iNum=0;
void CALLBACK MessageCallbackNo1(LONG lCommand, NET_DVR_ALARMER *pAlarmer, char *pAlarmInfo, DWORD
dwBufLen, void* pUser)
{
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
43
Device Network SDK (People Counting) Developer Guide
case VCA_WHITE_PLATE:
printf("Vehicle Color: White\n");
break;
case VCA_BLACK_PLATE:
printf("Vehicle Color: Black\n");
break;
default:
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;
44
Device Network SDK (People Counting) Developer Guide
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;
}
}
//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)
{
45
Device Network SDK (People Counting) Developer Guide
46
Device Network SDK (People Counting) Developer Guide
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))
{
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...
47
Device Network SDK (People Counting) Developer Guide
}
break;
}
default:
break;
}
}
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);
48
Device Network SDK (People Counting) Developer Guide
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();
return;
}
//User logout
NET_DVR_Logout(lUserID);
//Release SDK resource
NET_DVR_Cleanup();
return;
}
See Also
NET_DVR_SetupAlarmChan_V50
3.15.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
49
Device Network SDK (People Counting) Developer Guide
3.16 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.
50
Device Network SDK (People Counting) Developer Guide
3.17 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,
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).
51
Device Network SDK (People Counting) Developer Guide
3.18 NET_DVR_StopListen_V30
Stop listening (supports multiple threads).
API Definition
BOOL NET_DVR_StopListen_V30(
LONG lListenHandle
);
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 .
3.19 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.
52
Device Network SDK (People Counting) Developer Guide
3.20 NET_DVR_GetErrorMsg
Return the error information of the last operation.
API Definition
char *NET_DVR_GetErrorMsg(
LONG *pErrorNo
);
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.
3.21 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.
3.22 NET_DVR_Init
Initialize the programming environment before calling other APIs.
53
Device Network SDK (People Counting) Developer Guide
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.
See Also
NET_DVR_Cleanup
3.23 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 .
54
Device Network SDK (People Counting) Developer Guide
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
3.23.1 fLoginResultCallBack
3.24 NET_DVR_Logout
Log out from devices.
55
Device Network SDK (People Counting) Developer Guide
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 .
3.25 NET_DVR_SetSDKInitCfg
Set initialization parameters.
API Parameters
BOOL NET_DVR_SetSDKInitCfg(
NET_SDK_INIT_CFG_TYPE enumType,
void* const lpInBuff
);
Parameters
enumType
[IN] Initialization parameter type. Different type values correspond to different parameters, see
details in the table below.
56
Device Network SDK (People Counting) Developer Guide
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.
Remarks
This API should be called before calling NET_DVR_Init to initialize and check the dependent
libraries or capabilities.
57
Device Network SDK (People Counting) Developer Guide
A.1 NET_DVR_FLASHSTORAGE_REMOVE
Parameter structure of clearing people counting data.
Structure Definition
struct{
DWORD dwSize;
DWORD dwChannel;
BYTE byPDCRemoveEnable;
BYTE byRes[127];
}NET_DVR_FLASHSTORAGE_REMOVE,*LPNET_DVR_FLASHSTORAGE_REMOVE;
Members
dwSize
Structure size
dwChannel
Channel No.
byPDCRemoveEnable
Whether to clear people counting data: 0-no, 1-yes
byRes
Reserved, set to 0.
Remarks
This function is mainly used to clear the people counting data stored in the device Flash.
A.2 NET_DVR_HANDLEEXCEPTION_V41
58
Device Network SDK (People Counting) Developer Guide
only)
● 0x200: capture picture and upload to FTP
detection)
● 0x800: PTZ linkage (speed dome tracks the
target)
● 0x1000: capture picture and upload to cloud
storage.
● 0x10000: message alarm
A.3 NET_DVR_MIME_UNIT
59
Device Network SDK (People Counting) Developer Guide
See Also
NET_DVR_XML_CONFIG_INPUT
A.4 NET_DVR_PDC_ALRAM_INFO
Alarm information structure of people counting statistics.
Structure Definition
struct{
DWORD dwSize;
BYTE byMode;
BYTE byChannel;
BYTE bySmart;
BYTE byRes1;
NET_VCA_DEV_INFO struDevInfo;
union{
struct{
DWORD dwRelativeTime;
DWORD dwAbsTime;
BYTE byTimeDiffFlag;
signed char cTimeDifferenceH;
signed char cTimeDifferenceM;
BYTE byRes[89];
}struStatFrame;
struct{
NET_DVR_TIME tmStart;
NET_DVR_TIME tmEnd;
60
Device Network SDK (People Counting) Developer Guide
BYTE byTimeDifferenceFlag;
signed char cStartTimeDifferenceH;
signed char cStartTimeDifferenceM;
signed char cStopTimeDifferenceH;
signed char cStopTimeDifferenceM;
BYTE byRes[87];
}struStatTime;
}uStatModeParam;
DWORD dwLeaveNum;
DWORD dwEnterNum;
BYTE byBrokenNetHttp;
BYTE byRes3;
WORD wDevInfoIvmsChannelEx;
DWORD dwPassingNum;
DWORD dwChildLeaveNum;
DWORD dwChildEnterNum;
BYTE byRes2[24];
}NET_DVR_PDC_ALRAM_INFO,*LPNET_DVR_PDC_ALRAM_INFO;
Members
dwSize
Structure size.
byMode
Statistics mode: 0-real-time people counting statistics, 1-periodic statistics, 2-statistics by sensor
byChannel
No. of alarm uploading channel.
bySmart
For intelligent device, return 0; and for smart device, return 1.
byRes1
Reserved, set to 0.
struDevInfo
Front-end device information, refer to the structure NET_VCA_DEV_INFO for details.
uStatModeParam
Statistics mode union, see details below.
struStatFrame
Real-time statistics, see details below.
dwRelativeTime
Time of UTC ± 00:00, which is valid only when the value of byTimeDiffFlag is "1".
dwAbsTime
Local time.
61
Device Network SDK (People Counting) Developer Guide
byTimeDiffFlag
Whether the time difference parameter is valid: 0-invalid, 1-valid.
cTimeDifferenceH
Time difference between time and UTC time, unit: hour, the value is between -12 and +14
("+" indicates the east time zone), it is valid when byTimeDiffFlag is "1".
cTimeDifferenceM
Time difference between time and UTC time, unit: minute, the value is -30, +30, or +45
("+" indicates the east time zone), it is valid when byTimeDiffFlag is "1".
byRes
Reserved, set to 0.
struStatTime
Start time information, see details below.
tmStart
Statistics start time, refer to the structure NET_DVR_TIME for details.
tmEnd
Statistics end time, refer to the structure NET_DVR_TIME for details.
byTimeDifferenceFlag
Whether the time difference parameter is valid: 0-invalid, 1-valid.
cStartTimeDifferenceH
Time difference between start time and UTC time, unit: hour, the value is between -12
and +14 ("+" indicates the east time zone), it is valid when byTimeDifferenceFlag is "1".
cStartTimeDifferenceM
Time difference between start time and UTC time, unit: minute, the value is -30, +30, or
+45 ("+" indicates the east time zone), it is valid when byTimeDifferenceFlag is "1".
cStopTimeDifferenceH
Time difference between end time and UTC time, unit: hour, the value is between -12 and
+14 ("+" indicates the east time zone), it is valid when byTimeDifferenceFlag is "1".
cStopTimeDifferenceM
Time difference between end time and UTC time, unit: minute, the value is -30, +30, or
+45 ("+" indicates the east time zone), it is valid when byTimeDifferenceFlag is "1".
byRes
Reserved, set to 0.
dwLeaveNum
Number of people exited.
dwEnterNum
Number of people entered
62
Device Network SDK (People Counting) Developer Guide
byBrokenNetHttp
ANR flag bit: 0-non-ANR data, 1-ANR data
byRes3
Reserved
wDevInfoIvmsChannelEx
Extended the parameter byIvmsChannel in NET_VCA_DEV_INFO , its value range is extended.
dwPassingNum
Number of people passed.
dwChildLeaveNum
Number of exited children.
dwChildEnterNum
Number of entered children.
byRes2
Reserved
Remarks
● For real-time statistics (byMode is "0"), counting starts from the last clearing action (device
reboot, manual clearing, or auto-clearing at 00:00), and the result will be updated once it
changed.
● For periodic statistics (byMode is "0"), set the added number within the statistics period, and
the update frequency is the configured statistics period (default: 15 minutes, minimum: 1
minute, maximum: 60 minutes).
● The algorithm of getting year/month/day/hour/minute/second analyzed froM the time value of
DWORD type is shown as follows.
#define GET_YEAR(_time_) (((_time_)>>26) + 2000)
#define GET_MONTH(_time_) (((_time_)>>22) & 15)
#define GET_DAY(_time_) (((_time_)>>17) & 31)
#define GET_HOUR(_time_) (((_time_)>>12) & 31)
#define GET_MINUTE(_time_) (((_time_)>>6) & 63)
#define GET_SECOND(_time_) (((_time_)>>0) & 63)
A.5 NET_DVR_PDC_ENTER_DIRECTION
Counting statistics direction structure
Structure Definition
struct{
NET_VCA_POINT struStartPoint;
63
Device Network SDK (People Counting) Developer Guide
NET_VCA_POINT struEndPoint;
}NET_DVR_PDC_ENTER_DIRECTION, *LPNET_DVR_PDC_ENTER_DIRECTION;
Members
struStartPoint
Start point parameter, refer to the structure NET_VCA_POINT for details.
struEndPoint
End point parameter, refer to the structure NET_VCA_POINT for details.
A.6 NET_DVR_PDC_QUERY_COND
Condition structure of people counting data search.
Structure Definition
struct{
DWORD dwSize;
DWORD dwChannel;
NET_DVR_TIME_EX struStartTime;
NET_DVR_TIME_EX struEndTime;
BYTE byReportType;
BYTE byEnableProgramStatistics;
BYTE byTriggerPeopleCountingData;
BYTE byMultiChannelSearch;
DWORD dwPlayScheduleNo;
BYTE byISO8601;
char cStartTimeDifferenceH;
char cStartTimeDifferenceM;
char cStopTimeDifferenceH;
char cStopTimeDifferenceM;
BYTE byRes1[3];
DWORD dwSearchChannelNum;
char pSearchChannel;
BYTE byChild;
BYTE byMinTimeInterval;
BYTE byStatisticType;
BYTE byRes[101];
}NET_DVR_PDC_QUERY_COND, *LPNET_DVR_PDC_QUERY_COND;
Members
dwSize
Structure size
dwChannel
Channel No.
64
Device Network SDK (People Counting) Developer Guide
struStartTime
Start time of search, see details in structure NET_DVR_TIME_EX .
struEndTime
End time of search, see details in structure NET_DVR_TIME_EX .
byReportType
Report type: 0-invalid, 1-daily, 2-weekly, 3-monthly, 4-anual
byEnableProgramStatistics
Whether to count by program: 0-no, 1-yes
byTriggerPeopleCountingData
Whether to enable people counting data search: 0-no, 1-yes
byMultiChannelSearch
Whether to enable searching in multiple channels: 0-no, 1-yes
dwPlayScheduleNo
Linked plan No. for statistics by program.
byISO8601
Whether the time is in ISO8601 format, i.e., whether the time difference is valid. 0-invalid, the
time is device local time, 1-valid.
cStartTimeDifferenceH
Time difference between start time and UTC time, unit: hour, the value is between -12 and +14
("+" indicates the east time zone), it is valid when byISO8601 is "1".
cStartTimeDifferenceM
Time difference between start time and UTC time, unit: minute, the value is -30, +30, or +45
("+" indicates the east time zone), it is valid when byISO8601 is "1".
cStopTimeDifferenceH
Time difference between stop time and UTC time, unit: hour, the value is between -12 and +14
("+" indicates the east time zone), it is valid when byISO8601 is "1".
cStopTimeDifferenceM
Time difference between stop time and UTC time, unit: minute, the value is -30, +30, or +45 ("+"
indicates the east time zone), it is valid when byISO8601 is "1".
byRes1
Reserved
dwSearchChannelNum
Number of channels to search
pSearchChannel
Search channel No.
65
Device Network SDK (People Counting) Developer Guide
byChild
Whether to detect children only: 0-no, 1-yes.
byMinTimeInterval
Minimum time interval: 0-invalid, 1-15 minutes, 2-30 minutes, 3-one hour, 4-one day, 5-one
week, 6-one month.
byStatisticType
Counting type: 0-invalid, 1-by entered people, 2-by exited people, 3-all.
byRes
Reserved.
Remarks
Search end time is used for simple verification such as "if the start time is earlier than end time".
The search time period is subject to start time and search mode, for example, if the start date is
July 1st and the end date is August 1st, and the search mode is weekly, then the device will search
the information between July 1st and July 7th.
A.7 NET_DVR_PDC_RESULT
Result structure of people counting data search.
Structure Definition
struct{
DWORD dwSize;
NET_DVR_TIME_EX struStartTime;
NET_DVR_TIME_EX struEndTime;
DWORD dwEnterNum;
DWORD dwLeaveNum;
NET_DVR_PROGRAM_INFO struProgramInfo;
DWORD dwPeoplePassing;
DWORD dwStruLen;
char pStruInfo;
BYTE byISO8601;
char cStartTimeDifferenceH;
char cStartTimeDifferenceM;
char cStopTimeDifferenceH;
char cStopTimeDifferenceM;
BYTE byRes[187];
}NET_DVR_PDC_RESULT, *LPNET_DVR_PDC_RESULT;
Members
dwSize
Structure size.
66
Device Network SDK (People Counting) Developer Guide
struStartTime
Start time
struEndTime
End time
dwEnterNum
Number of entered people.
dwLeaveNum
Number of exited people.
struProgramInfo
Program information, see details in the structure NET_DVR_PROGRAM_INFO .
dwPeoplePassing
Number of passed people.
dwStruLen
Data size.
pStruInfo
Information structure pointer.
byISO8601
Whether the time is in ISO8601 format, i.e., whether the time difference is valid. 0-invalid, the
time is device local time, 1-valid.
cStartTimeDifferenceH
Time difference between start time and UTC time, unit: hour, the value is between -12 and +14
("+" indicates the east time zone), it is valid when byISO8601 is "1".
cStartTimeDifferenceM
Time difference between start time and UTC time, unit: minute, the value is -30, +30, or +45
("+" indicates the east time zone), it is valid when byISO8601 is "1".
cStopTimeDifferenceH
Time difference between stop time and UTC time, unit: hour, the value is between -12 and +14
("+" indicates the east time zone), it is valid when byISO8601 is "1".
cStopTimeDifferenceM
Time difference between stop time and UTC time, unit: minute, the value is -30, +30, or +45 ("+"
indicates the east time zone), it is valid when byISO8601 is "1".
byRes
Reserved
67
Device Network SDK (People Counting) Developer Guide
A.8 NET_DVR_PDC_RULE_CFG_V42
Configuration parameter structure of people counting rule
Structure Definition
struct{
DWORD dwSize;
BYTE byEnable;
BYTE byOSDEnable;
BYTE byCurDetectType;
BYTE byInterferenceSuppression;
NET_VCA_POINT struOSDPoint;
BYTE byDataUploadCycle;
BYTE bySECUploadEnable;
BYTE byEmailDayReport;
BYTE byEmailWeekReport;
BYTE byEmailMonthReport;
BYTE byEmailYearReport;
BYTE byRes2[6];
NET_VCA_POLYGON struPolygon;
NET_DVR_PDC_ENTER_DIRECTION struEnterDirection;
NET_DVR_SCHEDTIME struAlarmTime[MAX_DAYS/*7*/][MAX_TIMESEGMENT_V30/*8*/];
NET_DVR_TIME_EX struDayStartTime;
NET_DVR_TIME_EX struNightStartTime;
NET_DVR_HANDLEEXCEPTION_V41 struAlarmHandleType;
BYTE byDetecteSensitivity;
BYTE byGenerateSpeedSpace;
BYTE byGenerateSpeedTime;
BYTE byCountSpeed;
BYTE byDetecteType;
BYTE byTargetSizeCorrect;
BYTE byStreamOverlayRuleInfos;
BYTE byRes3;
NET_VCA_LINE struLine;
BYTE byHeightFilterEnable;
BYTE byRes4[3];
float fHeightFilter;
BYTE byCalibrateType;
BYTE byCountingType;
BYTE bySignalType;
BYTE byRS485TransmissionEnabled;
float fTiltAngle;
float fHeelAngle;
float fHeight;
NET_VCA_POLYGON struCountPolygon;
NET_VCA_POLYGON struAutoCalibPolygon;
NET_DVR_TIME_EX struDailyResetTime;
NET_VCA_POLYLINE struPolyLine;
68
Device Network SDK (People Counting) Developer Guide
BYTE byRes[4];
}NET_DVR_PDC_RULE_CFG_V42,*LPNET_DVR_PDC_RULE_CFG_V42;
Members
dwSize
Structure size.
byEnable
Whether to enable people counting: 0-no, 1-yes
byOSDEnable
Whether to enable display people counting information on picture: 0- no, 1-yes, 2-display
number of entered people only, 3-display number of exited people only, 4-display number of
passed people, 5-display number of entered and passed people.
byCurDetectType
Current detection region type: 0-polygon, 1-detection line, 2-detection polyline.
byInterferenceSuppression
Jamming type and status (represented by byte): bit0-shadow, bit1-loitering, bit2-trolley, value:
0-disable, 1-enable. For example: if byInterferenceSuppression==7 (111 in binary), it indicates
shadow, loitering, and trolley jamming are all enabled.
struOSDPoint
Upper-left vertex coordinates of the information display position on people counting statistics
picture, refer to the structure NET_VCA_POINT for details.
byDataUploadCycle
Time interval for uploading people counting data: 0-15 minutes, 1-1 minute, 2-5 minutes, 3-10
minutes, 4-20 minutes, 5-30 minutes, 6-60 minutes.
bySECUploadEnable
Whether to enable uploading by second: 0-no, 1-yes.
byEmailDayReport
Whether to enable uploading people counting daily report by email: 0-no, 1-yes.
byEmailWeekReport
Whether to enable uploading people counting weekly report by email: 0-no, 1-yes.
byEmailMonthReport
Whether to enable uploading people counting monthly report by email: 0-no, 1-yes.
byEmailYearReport
Whether to enable uploading people counting annual report by email: 0-no, 1-yes.
byRes2
Reserved, set to 0.
69
Device Network SDK (People Counting) Developer Guide
struPolygon
Polyson region, it is valid when byCurDetectType is 0. Refer to the structure
NET_VCA_POLYGON for details.
struEnterDirection
Entering direction, refer to the structure NET_DVR_PDC_ENTER_DIRECTION for details.
struAlarmTime
Arming schedule, refer to the structure NET_DVR_SCHEDTIME for details.
struDayStartTime
Start time of day, unit: hour, minute, second, refer to the structure NET_DVR_TIME_EX for
details.
struNightStartTime
Start time of night, unit: hour, minute, second, refer to the structure NET_DVR_TIME_EX for
details.
struAlarmHandleType
Alarm linkage action types, refer to the structure NET_DVR_HANDLEEXCEPTION_V41 for
details. Here, only the "center" (upload to center) is supported.
byDetecteSensitivity
Detection sensitivity, whose value is between 1 and 100, the default value is 50.
byGenerateSpeedSpace
Target generation speed in space, whose value is between 1 and 100, the default value is 50.
byGenerateSpeedTime
Target generation speed in time, whose value is between 1 and 100, the default value is 50.
byCountSpeed
Counting speed, whose value is between 1 and 100, the default value is 50.
byDetecteType
Target detection type: 0-auto, 1-head, 2-head and shoulder, the default is 0.
byTargetSizeCorrect
Target size correction, whose value is between 1 and 100, the default value is 50.
byStreamOverlayRuleInfos
Whether to display VCA information on stream: 0-no, 1-yes.
byRes3
Reserved, set to 0.
struLine
Detection line, it is valid when byCurDetectType is 1. Refer to the structure NET_VCA_LINE for
details.
70
Device Network SDK (People Counting) Developer Guide
byHeightFilterEnable
Whether to enable height filtering: 0-no, 1-yes
byRes4
Reserved, set to 0
fHeightFilter
Filtered height, it is valid when byHeightFilterEnable is 1, unit: cm, default: 120 cm, range: 40 to
200 cm.
byCalibrateType
Calibration type: 0-not calibrate, 1-auto, 2-manual
byCountingType
Counting trigger mode: 0-none, 1-alarm input triggered, 2-VCA triggered.
bySignalType
Signal types: 0-level (connect to alarm input 1, set to remain open mode, high level indicates
opening door, low level indicates closing door); 1-pulse (connect to alarm input 1 (opening
door) and alarm input 2 (closing door), set to remain open mode, rising edge will be detected,
at least 10 ms duration are required).
byRS485TransmissionEnabled
Whether to enable RS-485 transmission: 0-no, 1-yes
fTiltAngle
Angle of pitch, unit: degree, default: 0, range: 0 to 180, read only.
fHeelAngle
Angle of roll, unit: degree, default: 0, range: -90 to 90, read only.
fHeight
Calibrated height (the distance between camera lens and ground), unit: cm, default: 300, range:
200 to 500, it can be set only when byCalibrateType is 2, otherwise, this parameter is read-only.
struCountPolygon
Counting region, read-only, refer to the structure NET_VCA_POLYGON for details.
struAutoCalibPolygon
Automatically calibrated region (for people counting function in vehicle-mounted device, this
parameter indicates the pedal area), it is valid when byCalibrateType is 1. Refer to the structure
NET_VCA_POLYGON for details.
struDailyResetTime
Clearing schedule (clear the displayed people counting information, by default, the information
will be cleared at 00:00). Refer to the structure NET_DVR_TIME_EX for details.
struPolyLine
71
Device Network SDK (People Counting) Developer Guide
A.9 NET_DVR_PDC_RULE_COND
Configuration condition structure of people counting rule.
Structure Definition
struct{
DWORD dwSize;
DWORD dwChannel;
BYTE byRes[64];
}NET_DVR_PDC_RULE_COND, *LPNET_DVR_PDC_RULE_COND;
Members
dwSize
Structure size.
dwChannel
Channel No.
byRes
Reserved, set to 0.
A.10 NET_DVR_POSINFO_OVERLAY
Text overlay parameter structure
Structure Definition
struct{
DWORD dwSize;
BYTE byEnable;
BYTE byBackpackEnanble;
BYTE bySexEnanble;
BYTE byCarryEnanble;
BYTE byRideEnanble;
BYTE byMaskEnanble;
BYTE byHatEnanble;
BYTE bySleeveEnanble;
BYTE byPantsTypeEnanble;
BYTE byHairEnanble;
72
Device Network SDK (People Counting) Developer Guide
BYTE byGlassesEnanble;
BYTE byAgeEnanble;
BYTE byHeightEnanble;
BYTE byRes[511];
}NET_DVR_POSINFO_OVERLAY,*LPNET_DVR_POSINFO_OVERLAY;
Members
dwSize
Structure size.
byEnable
whether to enable text overlay: 0-no, 1-yes.
byBackpackEnanble
whether to enable backpack information overlay: 0-no, 1-yes.
bySexEnanble
whether to enable gender information overlay: 0-no, 1-yes.
byCarryEnanble
whether to enable carrying information overlay: 0-no, 1-yes.
byRideEnanble
whether to enable riding information overlay: 0-no, 1-yes.
byMaskEnanble
whether to enable wearing mask information overlay: 0-no, 1-yes.
byHatEnanble
whether to enable wearing hat information overlay: 0-no, 1-yes.
bySleeveEnanble
whether to enable tops information overlay: 0-no, 1-yes.
byPantsTypeEnanble
whether to enable overlay bottoms information overlay: 0-no, 1-yes.
byHairEnanble
whether to enable hair information overlay: 0-no, 1-yes.
byGlassesEnanble
Whether to enable wearing glasses information overlay: 0-no, 1-yes.
byAgeEnanble
whether to enable age information overlay: 0-no, 1-yes.
byHeightEnanble
whether to enable stature information overlay: 0-no, 1-yes.
byRes
73
Device Network SDK (People Counting) Developer Guide
Reserved, set to 0.
A.11 NET_DVR_PROGRAM_INFO
Program information structure
Structure Definition
struct{
DWORD dwProgramNo;
BYTE sProgramName[NAME_LEN/*32*/];
BYTE byRes[16];
}NET_DVR_PROGRAM_INFO, *LPNET_DVR_PROGRAM_INFO;
Members
dwProgramNo
Program No.
sProgramName
Program name
byRes
Reserved, set to 0
A.12 NET_DVR_RECORD_PASSBACK_MANUAL_COND
74
Device Network SDK (People Counting) Developer Guide
A.13 NET_DVR_RECORD_PASSBACK_MANUAL_TASK_RET
A.14 NET_DVR_RESET_COUNTER_CFG
Parameter structure of statistics data clearing.
Structure Definition
struct{
DWORD dwSize;
BYTE byEnable;
BYTE byMode;
BYTE byRes1[2];
75
Device Network SDK (People Counting) Developer Guide
NET_DVR_TIME_EX struTime[MAX_DAYS/*7*/];
BYTE byRes[64];
}NET_DVR_RESET_COUNTER_CFG,*LPNET_DVR_RESET_COUNTER_CFG;
Members
dwSize
Structure size.
byEnable
Whether to enable statistics data clearing: 0-no, 1-yes.
byMode
Clearing mode: 0-scheduled, 1-manual.
byRes1
Reserved, set to 0.
struTime
Data cleared time, unit: hour, minute, second
byRes
Reserved, set to 0.
Remarks
When the clearing mode is 0, the device will automatically the data at the configured time point;
when the clearing mode is 1, you should call clearing API to clear the data.
A.15 NET_DVR_SCHEDTIME
A.16 NET_DVR_STD_CONFIG
76
Device Network SDK (People Counting) Developer Guide
A.17 NET_DVR_STD_CONTROL
Input and output parameters structure of remote control.
Structure Definition
struct{
LPVOID lpCondBuffer;
DWORD dwCondSize;
LPVOID lpStatusBuffer;
DWORD dwStatusSize;
BYTE byRes[64];
}NET_DVR_STD_CONTROL, *LPNET_DVR_STD_CONTROL;
77
Device Network SDK (People Counting) Developer Guide
Members
lpCondBuffer
Condition parameters (returned in structure or message), such as channel No., it can be set to
null.
dwCondSize
Buffer size of condition parameters.
lpStatusBuffer
Status parameters (returned in XML_ResponseStatus ), if control completed, this parameter will
not be assigned, and it can be set to null if not required.
dwStatusSize
Buffer size of status parameter.
lpXmlBuffer
Data with XML format, it is valid only when byDataType is 1.
dwXmlSize
Size of data with XML format, when the control command is getting, it is the input and output
parameters, and after getting completed, actual size will be returned; when setting, the actual
data size equals to strlen((char*) lpXmlBuffer).
byDataType
Input or output parameter type: 0-structure, 1-message
byRes
Reserved, set to 0.
Remarks
For different control function (refers to the parameter dwCommand in the API
NET_DVR_STDControl ), the lpCondBuffer in this structure are different, see details in the typical
applications.
A.18 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;
78
Device Network SDK (People Counting) Developer Guide
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.
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.19 NET_DVR_XML_CONFIG_INPUT
79
Device Network SDK (People Counting) Developer Guide
Related API
NET_DVR_STDXMLConfig
A.20 NET_DVR_XML_CONFIG_OUTPUT
80
Device Network SDK (People Counting) Developer Guide
Related API
NET_DVR_STDXMLConfig
A.21 NET_SDK_CALLBACK_STATUS_NORMAL
A.22 NET_VCA_DEV_INFO
81
Device Network SDK (People Counting) Developer Guide
Remarks
When accessing to device A, see the following figure for details.
● When the analog channel alarm of connected device (IPC, DVR, DVS, iVMS) is triggered,
struDevIP and wPort are the IP address and port No. of connected device; byChannel and
byIvmsChannel are both the alarm analog channel No.
● When the digital channel (IP channel) alarm of connected device (HDVR, NVR, iVMS) is triggered,
struDevIP, wPort and byChannel are the IP address, port No., and channel No. of connected
device, respectively; byIvmsChannel is the digital channel. In the above figure, the channel No.1
of device B1 and the channel No.1, 2 of device B2 are used as channel No.1, 2, 3 of the
connected device A; struDevIP, wPort, and byChannel are the IP address, port No. and channel
No. of B1 or B2; byIvmsChannel is the digital channel No. of device A. E.g., if the behavior
analysis alarm of channel No.2 of device B2 is triggered, struDevIP is 192.168.0.12, wPort is
8002, byChannel is 2 and byIvmsChannel is 3 in the received alarm message.
A.23 NET_VCA_LINE
Structure about line parameters.
Structure Definition
struct{
NET_VCA_POINT struStart;
NET_VCA_POINT struEnd;
}NET_VCA_LINE,*LPNET_VCA_LINE;
82
Device Network SDK (People Counting) Developer Guide
Members
struStart
Start point, see details in the structure NET_VCA_POINT
struEnd
End point, see details in the structure NET_VCA_POINT .
A.24 NET_VCA_POINT
A.25 NET_VCA_POLYGON
A.26 NET_VCA_POLYLINE
Polyline parameter structure
83
Device Network SDK (People Counting) Developer Guide
Structure Definition
struct{
NET_VCA_POINT struPoint[4];
}NET_VCA_POLYLINE,*LPNET_VCA_POLYLINE;
Members
struPoint
Coordinates of points on the polyline, refer to the structure NET_VCA_POINT for details.
A.27 NET_ALARM_CVR_SUBINFO_UNION
A.28 NET_ALARM_RECORD_EXCEPTION
84
Device Network SDK (People Counting) Developer Guide
A.29 NET_ALARM_RECORDFILE_LOSS
85
Device Network SDK (People Counting) Developer Guide
A.30 NET_ALARM_RESOURCE_USAGE
A.31 NET_ALARM_STREAM_EXCEPTION
A.32 NET_DVR_ALARMER
86
Device Network SDK (People Counting) Developer Guide
A.33 NET_DVR_ALARMINFO_DEV
87
Device Network SDK (People Counting) 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.34 NET_DVR_ALARMINFO_DEV_V40
88
Device Network SDK (People Counting) 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.35 NET_DVR_ALARMINFO_V30
89
Device Network SDK (People Counting) 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.36 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:
90
Device Network SDK (People Counting) Developer Guide
A.37 NET_DVR_ALRAM_FIXED_HEADER
91
Device Network SDK (People Counting) Developer Guide
92
Device Network SDK (People Counting) Developer Guide
93
Device Network SDK (People Counting) 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==
94
Device Network SDK (People Counting) Developer Guide
A.38 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.
95
Device Network SDK (People Counting) Developer Guide
A.39 NET_DVR_ALARM_ISAPI_PICDATA
A.40 NET_DVR_ETHERNET_V30
96
Device Network SDK (People Counting) Developer Guide
A.41 NET_DVR_IPADDR_UNION
IP Address Union
A.42 NET_DVR_NETCFG_V50
97
Device Network SDK (People Counting) 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.43 NET_DVR_PPPOECFG
98
Device Network SDK (People Counting) Developer Guide
A.44 NET_DVR_SETUPALARM_PARAM_V50
99
Device Network SDK (People Counting) 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
100
Device Network SDK (People Counting) Developer Guide
data, 1-URL
● bit1-type of picture uploaded in message: 0-
binary, 1-URL
● bit2-type of picture uploaded for face picture
101
Device Network SDK (People Counting) 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.45 NET_DVR_TIME
A.46 NET_DVR_TIME_EX
102
Device Network SDK (People Counting) Developer Guide
A.47 DATE_TIME
A.48 NET_DVR_DEVICEINFO_V30
Device parameter structure (V30).
103
Device Network SDK (People Counting) 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
supported, if the result is 1, it indicates that the
capability is supported.
104
Device Network SDK (People Counting) Developer Guide
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
105
Device Network SDK (People Counting) 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
106
Device Network SDK (People Counting) 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.49 NET_DVR_DEVICEINFO_V40
107
Device Network SDK (People Counting) Developer Guide
108
Device Network SDK (People Counting) Developer Guide
109
Device Network SDK (People Counting) 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.50 NET_DVR_INIT_CFG_ABILITY
110
Device Network SDK (People Counting) Developer Guide
Remarks
By default, up to 2048 channels are supported. More channels require higher computer
performance and network bandwidth.
See Also
NET_DVR_SetSDKInitCfg
A.51 NET_DVR_LOCAL_SDK_PATH
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.52 NET_DVR_USER_LOGIN_INFO
111
Device Network SDK (People Counting) Developer Guide
112
Device Network SDK (People Counting) Developer Guide
A.53 NET_SDK_CALLBACK_STATUS_NORMAL
A.54 NET_VCA_RECT
113
Device Network SDK (People Counting) Developer Guide
114
Device Network SDK (People Counting) Developer Guide
115
Device Network SDK (People Counting) Developer Guide
B.1 /ISAPI/ContentMgmt/capabilities
Get storage capability.
B.2 /ISAPI/Event/schedules/reverseEntrance/<ID>
Get or set arming schedule of reverse entering alarm.
116
Device Network SDK (People Counting) Developer Guide
Query None
Request None
Response Succeeded: XML_Schedule
Failed: XML_ResponseStatus
Remarks
The <ID> in the request URI refers to the macro definition of event type and channel ID
(reverseEntrance-<channelID>, e.g., reverseEntrance-101).
B.3 /ISAPI/Event/triggers/<eventType>-<channelID>
Get, set, or delete the alarm linkage action by channel.
117
Device Network SDK (People Counting) Developer Guide
Query None
Request XML_EventTrigger
Response XML_ResponseStatus
Remarks
The <eventType> in the request URI refers to the predefined event or alarm type name, and the
<channelID> is the No. of the event detection channel. For example, if the No. of the face capture
channel is 101, the "<eventType>-<channelID>" is "faceSnap-101".
B.4 /ISAPI/Smart/Shield/channels/<channelID>
Get or set parameters of shielded area for smart detection.
118
Device Network SDK (People Counting) Developer Guide
Query None.
Request XML_Smart_Shield
Response XML_ResponseStatus
Remarks
The <ID> in the request URL refers to channel ID.
B.5 /ISAPI/Smart/Shield/channels/<channelID>/capabilities
Get configuration capability of shielded area for smart detection.
B.6 /ISAPI/System/Video/inputs/channels/<ID>/counting
Get or set people counting parameters of one video input channel.
119
Device Network SDK (People Counting) Developer Guide
Remarks
The node <ID> in the URI is the video channel ID.
B.7 /ISAPI/System/Video/inputs/channels/<ID>/counting/capabilities
Get capability of people counting statistics.
Remarks
The <ID> in the request URI refers to the video input channel ID.
B.8 /ISAPI/System/Video/inputs/channels/<ID>/counting/
reverseAlarm?format=json
Get or set parameters of reverse entering alarm.
120
Device Network SDK (People Counting) Developer Guide
Remarks
The <ID> in the request URI refers to the video input channel ID.
B.9 /ISAPI/System/Video/inputs/channels/<ID>/counting/search/
capabilities
Get the people counting configuration capability of a video input channel.
121
Device Network SDK (People Counting) Developer Guide
Request None
Response Succeeded: XML_CountingSearchCap
Failed: XML_ResponseStatus
Remarks
The <ID> in the request URI refers to the video input channel ID.
B.10 /ISAPI/System/Video/inputs/channels/<ID>/counting/status
Get people counting status by channel.
Remarks
The <ID> in the request URI refers to the video input channel ID.
122
Device Network SDK (People Counting) Developer Guide
C.1 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*/
"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*/
}
C.2 JSON_EventNotificationAlert_reverseEntrance
The reverse entering alarm is uploaded in the JSON format of EventNotificationAlert message.
123
Device Network SDK (People Counting) Developer Guide
{
"ipAddress":"",
"ipv6Address":"",
"portNo": ,
"protocol":"",
"macAddress":"",
"channelID":,
"releatedChannelList": [1,2,3],
/*optional, array of integers, list of alarm related channels, which are of the same camera with channelID; this
parameter is used for live view or playback on the platform*/
"dateTime":"",
"activePostCount",
"eventType":"reverseEntrance",
/*required, event/alarm type, here it should be set to "reverseEntrance", the maximum length is 128 bytes*/
"eventState":"",
"eventDescription":""
/*refer to the message JSON_EventNotificationAlert_Alarm/EventInfo for description details of the above nodes*/
}
--MIME_boundary
Content-Disposition: form-data; name="F4F665D6A18E41308CE9934DCDDD1111"; filename="reverseEntrance.jpg";
124
Device Network SDK (People Counting) Developer Guide
Content-Type: image/jpeg
Content-Length: 5798
Content-ID: reverseEntranceImage
See Also
JSON_EventNotificationAlert_Alarm/EventInfo
C.3 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
functional modules*/
}
C.4 JSON_reverseAlarm
reverseAlarm message in JSON format
{
"reverseAlarm":[{
"id":"",
/*required, integer32 type, armed region ID*/
"enabled":""
/*required, boolean type, whether to enable reverse entering alarm*/
}]
}
125
Device Network SDK (People Counting) Developer Guide
C.5 XML_BasicCapability
BasicCapability message in XML format
<?xml version="1.0" encoding="utf-8"?>
<!--req, software and hardware capabilities-->
<BasicCapability version="2.0">
<HardwareCapability><!--req, hardware capability-->
<HardwareVersion>
<!--req, the version of front panel: higher 16-bit means the major version, and lower 16-bit means the minor
version-->
</HardwareVersion>
<AlarmInPortNum><!--req, number of alarm inputs--></AlarmInPortNum>
<AlarmOutPortNum><!--req, number of alarm outputs--></AlarmOutPortNum>
<RS232Num><!--req, number of RS232 ports--></RS232Num>
<RS485Num><!--req, number of RS485 ports--></RS485Num>
<NetworkPortNum><!--req, number of network interfaces--></NetworkPortNum>
<USBNum><!--req, nunber of USB ports--></USBNum>
<FlashSize><!--req, the flash size (unit:MB)--></FlashSize>
<RamSize><!--req, RAM size (unit:M)--></RamSize>
<USBVersion><!--req, USB version--></USBVersion>
<SDNum><!--req, number of SD cards--></SDNum>
<HardDiskNum>
<!--req, number of HDDs (including SATA, eSATA and NAS), number of available HDDs-->
</HardDiskNum>
<SATANum><!--req, number of SATAs--></SATANum>
<eSATANum><!--req, number of eSATAs--></eSATANum>
<miniSASNum><!--req, number of miniSASs--></miniSASNum>
<VideoInNum><!--req, number of video inputs--></VideoInNum>
<AudioInNum><!--req, number of audio inputs--></AudioInNum>
<VideoOutNum><!--req, number of video outputs --></VideoOutNum>
<AudioOutNum><!--req, number of audio outputs--></AudioOutNum>
<AudioTalkNum><!--req, number of two-way audio channels--></AudioTalkNum>
<SDSupport><!--req, whether support SD card: 1-support, the node does not exist-not support --></SDSupport>
<WiFiSupport><!--req, whether support WiFi: 1-support, the node does not exist-not support --></WiFiSupport>
<POESupport><!--req, whether support POE: 1-support, the node does not exist-not support --></POESupport>
<IRSupport><!--req, whether support IR: 1- support, the node does not exist-not support --></IRSupport>
<VideoOutSupport>
<!-- req, whether support local video output: 1- support, the node does not exist-not support -->
</VideoOutSupport>
<ResetSupport>
<!-- req, whether support restoring factory settings: 1- support, the node does not exist-not support -->
</ResetSupport>
<AnalogChannelNum>
<!-- req, number of analog channels, which is same with the value of byChanNum returned when logging in-->
</AnalogChannelNum>
<IPChannelNum><!-- req, number of IP channels --></IPChannelNum>
<MultiNetworkCard>
<!-- req, whether support multiple NICs: 1-support, the node does not exist-not support -->
</MultiNetworkCard>
<BondingSupport><!--req, whether support bounding: 1- support, the node does not exist-not support --></
126
Device Network SDK (People Counting) Developer Guide
BondingSupport>
<VGANumber><!--req, number of VGA ports --></VGANumber>
<HDMINumber><!--req, number of HDMI® ports --></HDMINumber>
<CVBSNumber><!--req, number of CVBS ports --> </CVBSNumber>
<AuxoutNumber><!--req, number of auxiliary outputs--></AuxoutNumber>
<RAIDType><!--req, RAID type: 0-hardware RAID, 1-software RAID--></RAIDType>
<RS485>
<localRs485No min="" max=""/><!--req, local RS485 number-->
<expandRS485No min="" max="" /><!--req, extended RS485 No.-->
<fullDuplexRS485No min="" max="" /><!--req, full duplex RS485 No., relative to local RS485 No.-->
<semiDuplexRS485No min="" max="" /><!--req, half duplex RS485 No., relative to local RS485 No.-->
<RS485SlotNo min="" max=""/><!--req, RS485 slot No.-->
</RS485>
<ZoneNum>
<!--alarm host uses the node-->
<localZoneNo min="1" max="64"/>
<!--req, local alarm input interface (local arming region) No.-->
<extendZoneNo min="1" max="64"/>
<!--req, extensible alarm input interface (extensible arming region) No.-->
</ZoneNum>
<sirenNo min="" max=""/>
<!--req, host siren No.-->
<electroLockNo min="" max=""/><!--req, electric lock No.-->
<!--req,Electric Lock No. -->
<mobileGateNo min="" max=""/>
<!--req,Mobile Gate No.-->
<TriggerNum><!--req, this node is for security control panel only-->
<localTriggerNo min="1" max="64"/>
<!--req, local alarm output No. (local trigger)-->
<extendTriggerNo min="1" max="64"/>
<!--req, extended alarm output No. (extended trigger)-->
<Sensor>
<!--req, power supply monitoring alarm host uses the node-->
<totalSensorNum&>
<!--required, xs:inter, number of analog sensors-->
</totalSensorNum>
<localSensorNo min="" max="" />
<!--req, local analog sensor No.-->
<expandSensorNo min="" max="" />
<!--req, extensible analog sensor No.-->
</Sensor>
<rs232_rs485No min="" max=""/>
<!--req,RS232/ number of RS485 serial ports-->
<MirrorChanNum>1</MirrorChanNum>
<!--req, number of mirror channels-->
<DeviceSubBoardInfo>
<!--req, device sub board information, for use of integrated display controller-->
<BackBoardType opt = "4U,8U,13U"/>
<!--req, supported back board type-->
<SubBoardType opt= "DVI-IInput,YPbPrInput,BNCInput,SDIInput,DVI DualLinkInput,OrdinaryDecodeInput,DVI-
IOutput,SDIOutput,EnhanceDecodeInput"/>
<!--req, supported sub board type-->
127
Device Network SDK (People Counting) Developer Guide
</DeviceSubBoardInfo>
</HardwareCapability>
<!-- req, software capability -->
<SoftwareCapability>
<!-- req, whether support the new mapping type of hard disk number: 1- support, the node does not exist-not
support -->
<NewHdNo>1</NewHdNo>
<!-- req, the max number of network disks supported by the device(the node does not exist-not support), including
NAS and IPSAN -->
<MaxNetworkHDNum>8</MaxNetworkHDNum>
<!-- req, whether support NAS: 1- support, the node does not exist-not support -->
<NasSupport>1</NasSupport>
<!-- req, number of NAS -->
<NasNumber>8</NasNumber>
<!-- req, the max number of text overlay strings (special for analog channel) -->
<NetDiskIdentification>
<!-- req, support network disk access authentication-->
<NASIdentification>
<!--req, support NAS access authentication-->
<NFSMountType>true</NFSMountType>
<!--req, support NAS supporting NFS access-->
<CIFSMountType>
<!--req, support NAS supporting CIFS access-->
<usernameLen min = "" max= ""/>
<!--req, max. and min. value of name length on NAS authentication-->
<passwordLen min = "" max= ""/>
<!--req, max. and min. value of password length on NAS authentication-->
</CIFSMountType>
</NASIdentification>
</NetDiskIdentification>
<NasMountPara>
<addressType opt="IP, Domain"/>
<!--req, address type of mounted HDD 0-IP address; 1-domain name-->
<domainAddressLen min = "" max= ""/>
<!--req, max. and min. length of mounted HDD domain name-->
</NasMountPara>
<NetDiskDomain>
<domainSupport>true</domainSupport>
<!--req, whether mounted HDD supports domain name: true- yes; false- no-->
<domainAddressLen min = "" max= ""/>
<!--req, max. and min. length of mounted HDD domain name-->
</NetDiskDomain>
<ShowStringNumber>8</ShowStringNumber>
<!--req, max. quantity of string overlays (special for analog channel) -->
<MotionDetectAlarmSupport>1</MotionDetectAlarmSupport>
<!-- req, whether to support motion detection: 1- Yes, not displayed if not support -->
<VILostAlarmSupport>1</VILostAlarmSupport>
<!-- req, whether to support video loss detection: 1-Yes, not displayed if not support (special for analog channel) -->
<HideAlarmSupport>1</HideAlarmSupport>
<!-- req, whether to support tamper detection: 1- Yes, not displayed if not support (special for analog channel) -->
<ShelterSupport>1</ShelterSupport>
128
Device Network SDK (People Counting) Developer Guide
<!-- req, whether to support privacy mask: 1- Yes, not displayed if not support (special for analog channel) -->
<RtspSupport>1</RtspSupport>
<!-- req, whether to support rtsp protocol: 1- Yes, not displayed if not support -->
<RtpoverRtspSupport>
<!--whether support RTP over RTSP streaming mode: 1-yes, if not supported, this node will not be returned-->
</RtpoverRtspSupport>
<RtspoverHttpsSupport>
<!--whether supports RTP over HTTPS streaming mode, 1-yes, if not supported, this node will not be returned-->
</RtspoverHttpsSupport>
<NtpSupport>1</NtpSupport>
<!-- req, whether to support NTP timing: 1-Yes, not displayed if not support -->
<EptzSupport>1</EptzSupport>
<!-- req, whether to support E-PTZ:1- Yes, not displayed if not support -->
<PtzSupport>1</PtzSupport>
<!-- req, whether to support PTZ control: 1- Yes, not displayed if not support -->
<DDNSSupport>1</DDNSSupport>
<!-- req, whether to support DDNS: 1- Yes, not displayed if not support. Compatible network camera cannot be
deleted -->
<DDNSHostType>0,1,2,3,4</DDNSHostType>
<!-- req, DDNS server type: 0- IP Server, 1-Dyndns,2-PeanutHull, 3-NO-IP, 4- hkDDNS -->
<DDNSStatus>1,2,3,4,5,6,7,8,9,10,11,12,13,14,15</DDNSStatus>
<!--req, supported DDNS status type: 1- Failed to connect to address server, 2- Failed to parse address message, 3-
Failed to connect to heartbeat server, 4- Failed to parse heartbeat server message, 5- Failed to connect to domain
name server, 6- Failed to parse domain name server message, 7- Domain name registered, 8- Failed to register domain
name, 9- Heartbeat sent, 10- DNS server is not configured, 11- Domain name is occupied, 12- Service exception, 13-
Authentication required, 14- Invalid domain name, 15- Disabled-->
<SNMPSupport>1</SNMPSupport>
<!-- req, SNMP version, 1-v1, 2-v2, 3-v3 -->
<SNMPVersion>1,2,3</SNMPVersion>
<!-- req, whether support UPNP: 1- support, the node does not exist-not support -->
<UPNPSupport>1</UPNPSupport>
<!-- req, whether support iSCSI: 1- support, the node does not exist-not support -->
<iSCSISupport>1</iSCSISupport>
<!-- req, the max number of IP SAN supported by the device -->
<iSCSINum>1</iSCSINum>
<!-- req, whether support ipv6: 1- support, the node does not exist-not support -->
<Ipv6Support>0</Ipv6Support>
<!-- req, whether support intelligent function: 1- support, the node does not exist-not support -->
<VCASupport>1</VCASupport>
<!-- req, capability set, this node will be returned when video stream is not supported -->
<VideoStreamnotSupport>true</VideoStreamnotSupport >
<!-- req, whether support composite stream(video&audio): 1- support, the node does not exist-not support(special
for analog channel) -->
<MultipleStreamSupport>1</MultipleStreamSupport>
<!-- req, whether support sub stream: 1- support, the node does not exist-not support(special for analog channel) --
>
<SubStreamSupport>1</SubStreamSupport>
<!-- req, whether support EMAIL: 1- support, the node does not exist-not support -->
<EmailSupport>1</EmailSupport>
<!-- req, SADP version: 0-V1.0, 1-V3.0 -->
<SADPVersion>0,1</SADPVersion>
<ZeroChanNumber>1</ZeroChanNumber>
129
Device Network SDK (People Counting) Developer Guide
<!-- req, whether support backup: 1- support, the node does not exist-not support -->
<BackupSupport>1</BackupSupport>
<!-- req, whether support searching record files by event: 1- support, the node does not exist-not support -->
<FindFileByEventSupport>1</FindFileByEventSupport>
<!-- req, whether support smart searching: 1- support, the node does not exist-not support -->
<SmartSearchSupport>1</SmartSearchSupport>
<!-- req, whether support ATM configuration: 1- support, the node does not exist-not support-->
<ATMSupport>1</ATMSupport>
<!-- req, whether support to lock or unlock the files: 1- support, the node does not exist-not support -->
<FileLockSupport>1</FileLockSupport>
<!-- req, whether support dynamic limit for bit rate of main/sub stream: 1- support, the node does not exist-not
support(could not configure the capability) -->
<BitrateLimitSupport>1</BitrateLimitSupport>
<!-- req, the max number of login supported by the device -->
<MaxLoginNum>0</MaxLoginNum>
<!-- req, the max number of live view supported by the device -->
<MaxPreviewNum>0</MaxPreviewNum>
<!-- req, the max number of playback supported by the device -->
<MaxPlayBackNum>0</MaxPlayBackNum>
<!-- req, the max number of connections supported by one channel -->
<MaxChanLinkNum>6</MaxChanLinkNum>
<ShutDownSupport>1</ShutDownSupport>
<!-- req, whether support to freeze preset: 1- support, the node does not exist-not support -->
<FrameFreezeSupport>1</FrameFreezeSupport>
<!-- req, whether support hard disk group configuration: 1- support, the node does not exist-not support -->
<HDgroupConfig>1</HDgroupConfig>
<!--req, whether supports auto saving mode, 1-Yes, if not supports, this node will not be displayed.-->
<AutoStorageMode>1</AutoStorageMode>
<!-- req, whether support RS232 configuration: 1- support, the node does not exist-not support -->
<RS232Config>1</RS232Config>
<!-- req, whether support PPPoE configuration: 1- support, the node does not exist-not support -->
<PPPoEConfig>1</PPPoEConfig>
<!-- req, whether support redundant recording: 1- support, the node does not exist-not support -->
<RedundancyRecord>1</RedundancyRecord>
<!-- req, whether support scale configuration of main or aux video output: 1- support, the node does not exist-not
support -->
<VideoOutScaleConfig>1</VideoOutScaleConfig>
<!-- req, whether support guest user: 1- support, the node does not exist-not support -->
<GuestUser>1</GuestUser>
<!-- req, whether support FTP to upload pictures: 1- support, the node does not exist-not support -->
<UploadFTP>1</UploadFTP>
<!-- req, whether it does not support disk quota: 1- not support, no this node if support -->
<NotSupportDiskQuota>1</NotSupportDiskQuota>
<!-- req, 2012-12-8 support ratio-based disk quota allocation, 1- support, not displayed if not supported-->
<QuotaRatio>1</QuotaRatio>
<!-- req, 2014-4-11 support time-based disk quota allocation, 1- support both recording and picture quota, 2-
support recording quota but not picture quota, not displayed if not supported-->
<QuotaByTime>1</QuotaByTime>
<QuotaWithoutChannel><!--for camera with multiple channels, channel No. is not required when performing disk
quota--></QuotaWithoutChannel>
<LocalVout>
<mainVoutType opt="mainCVBS,HDMI,VGA,auto"/>
130
Device Network SDK (People Counting) Developer Guide
<!--req, the output type which is the local main port, nonhomologous device: 0-Auto,1-main CVBS, 2-HDMI®, 3-
VGA; homologous device: 0-Auto, 1-main CVBS, 2-HDMI®/VGA-->
</LocalVout>
<SingleStorageMaxCap>16</SingleStorageMaxCap><!--req,the maximum capacity of single storage, unit: T-->
<IPCPlug>1</IPCPlug><!--req, whether support plug and play of IPC: 1- support, the node does not exist-not
support-->
<DrawFrameRecord>1</DrawFrameRecord><!--req, whether support frame extract recording: 1- support, the node
does not exist-not support-->
<DelInvalidDisk>1</DelInvalidDisk><!--req, whether support to delete invalid disks: 1- support, the node does not
exist-not support-->
<MountOrUnmountDisk>1</MountOrUnmountDisk><!--req, whether support to mount or unmount disks: 1-
support, the node does not exist-not support-->
<MaxDvcsSubDevNumNum><!--req,the maximum device number which distributed device supported, the device
which is not supported doesn't appear--></MaxDvcsSubDevNumNum>
<NotSupportInputOutputConfigFile>1</NotSupportInputOutputConfigFile><!--req,input/output the configurate file
is not supported, 1-not support-->
<NotSupportLogSearch>1</NotSupportLogSearch><!--req,not support log search, if it is supported, it doesn't
appear, 1-not support--><DateUpLoadAndDownLoad><!--data upload and download-->
<audioType opt="wave"/><!--audio type supported-->
<uploadAndDownLoad opt = "upload,download"/><!--support upload and download-->
<maxNum opt= "8"/><!--type:max audio number which is supported by device-->
</DateUpLoadAndDownLoad>
<DevModuleServerCfg><!--req,server configuration ability-->
<!--req,the configuration of telnet is only permitted by "admin" -->
<telnetServer opt="disable,enable"/><!--req 0-disable 1-enable-->
<irLampServer opt="disable,enable"/><!--req 0-disable 1-enable-->
<abfServer opt="enable,disable,"/>
<!--req 0-enable, 1-disable -->
<LEDStatus opt="disable,enable"/>
<!--req 0-disable, 1-enable-->
<autoDefog opt="disable,enable"/>
<!--req, auto defog control: 0- enable, 1- disable-->
<sshServer opt="disable,enable"/>
<!--req, SSH settings: 0- enable, 1- disable-->
<webAuthentication opt="disable,enable"/>
<!--req, WEB authentication: 0- disable, 1- enable-->
<supplementLight opt="disable,enable"/>
<!--req, illuminator control: 0- enable, 1- disable-->
<deicing opt="disable,enable"/>
<!--opt, deicing: 0- disable, 1-enable-->
<isSupportFireLaserLight><!--opt,xs:boolen, when true, it is thermal imaging fire source detection laser
supplement light--></isSupportFireLaserLight>
<visibleMovementPower opt="disable,enable"/><!--opt 0-disable, 1-enable-->
<thermalMovementPower opt="disable,enable"/><!--opt 0-disable, 1-enable-->
<ptzPower opt="disable,enable"/><!--opt 0-disable, 1-enable-->
<powerSavingControl opt="sleepMode,lowConsumptionMode"/><!--opt xs:string "Low-power consumption:
sleepMode-Sleepy mode, lowConsumptionMode-Low-power mode-->
<captureWithSupplimentLightEnabled opt="true,false"><!--opt, xs:boolean, enable snapshot supplement light--></
captureWithSupplimentLightEnabled>
</DevModuleServerCfg>
<SearchLogAbilitySupport>1</SearchLogAbilitySupport><!--req,if it supports GB/T28181 protocol, 1-support, if not
support,it does not appear-->
131
Device Network SDK (People Counting) Developer Guide
132
Device Network SDK (People Counting) Developer Guide
133
Device Network SDK (People Counting) Developer Guide
<!-- req, auto restart after multicast address is modified in network parameters, 1- restart, not displayed if not
supported -->
<NetMultiCastIPChange>1</NetMultiCastIPChange>
<!-- req, auto restart after HDD parameters are modified, 1- restart, not displayed if not supported -->
<HardDiskParamChange>1</HardDiskParamChange>
<!-- req, auto restart after recording schedule time is modified, 1- restart, not displayed if not supported -->
<RecordTimeChange>1</RecordTimeChange>
<!-- req, auto restart after video compression type is modified, 1- restart, not displayed if not supported -->
<VideoEncodeTypeChange>1</VideoEncodeTypeChange>
<!-- req, auto restart after audio compression type is modified, 1- restart, not displayed if not supported -->
<AudioEncodeTypeChange>1</AudioEncodeTypeChange>
<!-- req, auto restart after video standard is modified, 1- restart, not displayed if not supported -->
<StandardTypeChange>1</StandardTypeChange>
<!-- req, auto restart after defog status is modified, 1- restart, not displayed if not supported -->
<DehazeEnableChange>1</DehazeEnableChange>
<!-- req, auto restart after line encoding status is modified, 1- restart, not displayed if not supported -->
<LineCodingEnableChange>1</LineCodingEnableChange>
<!-- req, auto restart after IP camera parameters local output switch status is modified, 1- restart, not displayed if
not supported -->
<LocalOutputEnableChange>1</LocalOutputEnableChange>
<!-- req, auto restart after main port is switched, 1- restart, not displayed if not supported -->
<LocalMainVoutTypeChange>1</LocalMainVoutTypeChange>
<!-- req, auto restart after NAS authentication parameters are modified, 1- restart, not displayed if not supported --
>
<NASIdentificationChange>1</NASIdentificationChange>
<DeviceLanguageChange>
<!--whether the reboot is required after editing device language, 1-required, this node does not exist-not
required-->
</DeviceLanguageChange>
<CardReaderFPAlgorithmUpgradeReboot>
<!--opt, whether the reboot is required after upgrading the fingerprint algorithm program of the fingerprint
module: 1-required, this node does not exist-not required-->
</CardReaderFPAlgorithmUpgradeReboot>
<DeviceUpgradeReboot>
<!--opt, whether the device will automatically reboot after upgrading: 1-yes (the device will automatically reboot
no matter whether the upgrading succeeded or not, this node does not exist-no)>
</DeviceUpgradeReboot>
<!--whether the device restarts after switching the VoIP protocol of the video intercom device: 1-restart (the user
needs to click "Confirm" and the application will apply the command to restart the device), 2-restart automatically
(the upper-layer application applies the command to restart the device directly). If there is no need to restart the
device, this field will not be displayed-->
<IntercomProtocolTypeChange>1</IntercomProtocolTypeChange>
<!-- req, auto restart after operating mode is modified, 1- restart, not displayed if not supported -->
<DevWorkModeChange>1</DevWorkModeChange>
<!-- req, auto restart after SIP local port is modified, 1- restart, not displayed if not supported -->
<LocalPortChange>1</LocalPortChange>
<!-- req, auto restart after SIP server register cycle is modified, 1- restart, not displayed if not supported -->
<LoginCycleChange>1</LoginCycleChange>
<!-- req, auto restart after RTP port is modified, 1- restart, not displayed if not supported -->
<RtpPortChange>1</RtpPortChange>
<!-- req, auto restart after audio compression priority level is modified, 1- restart, not displayed if not supported -->
<AudioEncodePriorityChange>1</AudioEncodePriorityChange>
134
Device Network SDK (People Counting) Developer Guide
<!-- req, auto restart after preview delay time is modified, 1- restart, not displayed if not supported -->
<PreviewDelayTimeChange>1</PreviewDelayTimeChange>
<!-- req, auto restart after NIC type is modified, 0- no -->
<NetworkCardTypeChange>0</NetworkCardTypeChange>
<!--req, auto restart after device cloud storage mode is modified, 1- restart, not displayed if not supported-->
<CloudStorageModeChangeReboot>1</CloudStorageModeChangeReboot>
<VcaDecModeChange>1</VcaDecModeChange>
<!--req, auto restart after enabling smart decoding mode, 1- restart, not displayed if not supported-->
<CompleteRestoreReboot>1</CompleteRestoreReboot>
<!--req, auto restart after restoring to factory defaults, 1- restart, not displayed if not supported-->
<SwitchVehicleDetection>1</SwitchVehicleDetection>
<!--req, auto restart after vehicle detection mode is modified, 1- restart, not displayed if not supported-->
<SwitchHVTVehicleDetection>1</SwitchHVTVehicleDetection>
<!--req, auto restart after mixed vehicle detection mode is switched, 1- restart, not displayed if not supported-->
<SmartCodec>1</SmartCodec>
<!--req, auto restart after high performance compression detection mode is switched, 1- restart, not displayed if
not supported-->
<NUCLEUSToOther>1</NUCLEUSToOther>
<!--opt, auto restart after switching from nucleus to other protocol, 1- restart, not displayed if not supported-->
<SystemSwitchReboot>1</SystemSwitchReboot>
<!--opt, whether to reboot when switching video intercom system, 1-reboot, this node will not be displayed if
reboot is not required>
<TerminalModeReboot>1</TerminalModeReboot>
<!--opt, whether to reboot when the face recognition terminal switching the terminal mode, 1-reboot, this node
will not be displayed if reboot is not required>
<ThirdStream>1</ThirdStream>
<!--opt, whether to restart after third stream is enabled, 1- yes, not displayed if not supported-->
<ExtensionModuleUpgradeReboot>1</ExtensionModuleUpgradeReboot>
<!--opt, whether to reboot after upgrading extended module: 1-Reboot. If there is no need to reboot, this node
will not be displayed-->
<WorkModeReboot>
<!--opt, whether the reboot is required when switching working mode of intelligent identity detection terminal,1-
yes, if reboot is not required, this node will not return-->
</WorkModeReboot>
<MultiFaceRecogizeChange><!--opt, whether the reboot is required when switching multi-face recognition,1-yes, if
reboot is not required, this node will not return--></MultiFaceRecogizeChange>
<FaceRecogizeModeChange><!--whether reboot is required after switching facial recognition mode: 1-yes, 2-
device reboots automatically, this node is not returned if reboot is not required--></FaceRecogizeModeChange>
<ChannelControllerUpgradeReboot>1</ChannelControllerUpgradeReboot>
<!--opt, whether to reboot after upgrading lane controller: 1- Reboot. If there is no need to reboot, this node will
not be displayed-->
<UbootUpgradeReboot><!--opt, whether to reboot after upgrading uboot: 1-reboot. If there is no need to reboot,
this node will be displayed--></UbootUpgradeReboot>
</NeedReboot>
<SupportMainBoardCameraPTZ>true</SupportMainBoardCameraPTZ><!--opt, PTZ that supports camera control of
master controller-->
<Support3DPTZ>true</Support3DPTZ>
<!--opt, whether to support 3D64 speed PTZ control-->
<SupportUnifiedIPCProtocol>true</SupportUnifiedIPCProtocol>
<!--opt, whether to support unified IPC protocol, using NET_DVR_IPC_ENUM_UNIFY type-->
<SupportRemoveStorage>true</SupportRemoveStorage>
<!--opt, remove device storage function (including video, playback, picture and log) xs:boolean -->
135
Device Network SDK (People Counting) Developer Guide
<CloudSupport>1</CloudSupport>
<!--opt, whether to support third-party cloud: 1- yes, not displayed if not supported-->
<isSupportBatchUploadPic>true</isSupportBatchUploadPic>
<!--opt, whether to support batch upload picture (BATCH_UPLOAD_PICTURE_FILE), not displayed if not supported--
>
<isSupportDownloadVehicleInfo>true</isSupportDownloadVehicleInfo>
<!--opt, whether to support vehicle information search (NET_DVR_GET_VEHICLE_INFORMATION), not displayed if
not supported-->
<isSupportConfirmMechanism>true</isSupportConfirmMechanism>
<!--Whether supports confirming arming, if not supports, no return.-->
<isSupportDNS>
<!--opt, whether to support enabling manual DNS settings, 1- yes, not displayed if not supported--></
isSupportDNS>
<HRUDP>
<!--opt,HRUDP (reliable transmission) capability-->
<LinkList>
<!--req,HRUDP connection list-->
<Link>
<!--req,HRUDP connection-->
<previewLink>1</previewLink>
<!--req,HRUDP number of preview connections-->
<recommendResolution opt="39-1920*1080"></recommendResolution>
<!--req,recommended resolution-->
</Link>
</LinkList>
</HRUDP>
<isSupportCountBinocular>true</isSupportCountBinocular>
<!--opt,"supported means the device is dual-lens people counting camera, not displayed if not supported"-->
<isSupportUploadCountBinocular>true</isSupportUploadCountBinocular>
<!--opt,"If supports, the dual-lens people counting camera list will be uploaded, otherwise, no return."-->
<supportChoosePlaybackDrawframe>true</supportChoosePlaybackDrawframe>
<!--opt, whether supports extracting frames for playback, if not supported, no return-->
<isSupportMinSAS>true</isSupportMinSAS>
<isSupportMinSAS>true</isSupportMinSAS>
<!--req, whether to support miniSAS HDD-->
<isNotSupportSummerTime>true</isNotSupportSummerTime>
<!--opt,"return this capability when DST is not supported"-->
<isSupportPanoramicStitch>true</isSupportPanoramicStitch>
<!--opt, whether to support uploading panoramic view configurationfile function, not returned if not supported-->
<isSupportGetFigure/>
<!--opt,xs:boolean, whether supports getting video thumbnails-->
<isSupportGetThumbnails>
<!--opt, whether supports getting video thumbnails by time segment-->
<isSupportStreamID opt="true,false"/>
<!--opt, whether supports stream ID-->
<resultDataType opt="0,1"/><!--opt, search type: 0-I frame, 1-picture data-->
<StartTime>
<year min="" max=""/>
<month min="" max=""/>
<day min="" max=""/>
<hour min="" max=""/>
<minute min="" max=""/>
136
Device Network SDK (People Counting) Developer Guide
137
Device Network SDK (People Counting) Developer Guide
</deviceId>
</SoftwareCapability>
</BasicCapability>
C.6 XML_Counting
Counting message in XML format
<Counting version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<enabled><!--req, xs: boolean--></enabled>
<normalizedScreenSize><!--opt-->
<normalizedScreenWidth><!--req, xs: integer--></normalizedScreenWidth>
<normalizedScreenHeight><!--req, xs: integer--></normalizedScreenHeight>
</normalizedScreenSize>
<MountingConfiguration><!--opt, mounting parameters-->
<viewingAngle><!--req, xs: string, "vertical,tilt"--></viewingAngle>
<mountHeight><!--opt, xs: integer; mounting height, unit: cm--></mountHeight>
<horizontalDistance><!--opt, xs: integer; horizontal distance, unit: cm--></horizontalDistance>
<focalLength><!--opt, xs: integer; unit: mm--></focalLength>
</MountingConfiguration>
<OverlayConfiguration><!--opt, OSD parameters-->
<enabled><!--req, xs: boolean--></enabled>
<positionX><!--req, xs: interger--></positionX>
<positionY><!--req, xs: interger--></positionY>
<OSDType>
<!--dep, it is valid when enabled is "true", xs: string, "enter, leave,entreLeave,peoplePassing"-->
</OSDType>
<child><!--opt, xs: boolean, whether to enable OSD for children counting--></child>
</OverlayConfiguration>
<Demarcation><!--opt-->
<enabled><!--req, xs: boolean--></enabled>
<DemarcationRegionList><!--req-->
<DemarcationRegion><!--opt-->
<id><!--req, xs:integer--></id>
<RegionCoordinatesList>
<RegionCoordinates><!--req-->
<positionX><!--req, xs:integer;coordinate--></positionX>
<positionY><!--req, xs:integer;coordinate--></positionY>
</RegionCoordinates>
</RegionCoordinatesList>
</DemarcationRegion>
</DemarcationRegionList>
<DemarcationLine>
<StartPoint><!--req-->
<positionX><!--req, xs: integer--></positionX>
<positionY><!--req, xs: integer--></positionY>
</StartPoint>
<EndPoint><!--req-->
<positionX><!--req, xs: integer--></positionX>
<positionY><!-- req, xs: integer--></positionY>
138
Device Network SDK (People Counting) Developer Guide
</EndPoint>
</DemarcationLine>
</Demarcation>
<CountingRegionType><!--read-only, req, xs: string, detection type: "region,line"--></CountingRegionType>
<CountingRegionList><!--opt, detection region list-->
<CountingRegion><!--opt, detection region-->
<id><!--req, xs: integer, detection region ID--></id>
<Direction><!--req, detection direction-->
<StartPoint><!--req-->
<positionX><!--req, xs: integer--></positionX>
<positionY><!--req, xs: integer--></positionY>
</StartPoint>
<EndPoint><!--req-->
<positionX><!--req, xs: integer--></positionX>
<positionY><!--req, xs: integer--></positionY>
</EndPoint>
</Direction>
<sensitivityLevel><!--req, xs: integer, sensitibity--></sensitivityLevel>
<spaceGenerationSpeed><!--opt, xs: integer--></spaceGenerationSpeed>
<timeGenerationSpeed><!--opt, xs: integer--></timeGenerationSpeed>
<countingSpeed><!--opt, xs: integer--></countingSpeed>
<detectionType><!--opt, xs: string, "auto,head,shoulder"--></detectionType>
<objectSizeCorrection><!--opt, xs: integer--></objectSizeCorrection>
<RegionCoordinatesList><!--req-->
<RegionCoordinates><!--req-->
<positionX><!--req, xs: integer; x-coordinate--></positionX>
<positionY><!--req, xs: integer; y-coordinate--></positionY>
</RegionCoordinates>
</RegionCoordinatesList>
<RuleRegionCoordinatesList><!--opt, rule frame-->
<RegionCoordinates><!--req-->
<positionX><!--req, xs: integer; x-coordinate--></positionX>
<positionY><!--req, xs: integer; y-coordinate--></positionY>
</RegionCoordinates>
</RuleRegionCoordinatesList>
</CountingRegion>
</CountingRegionList>
<CountingLineItemList><!--opt, detection line list-->
<CountingLineItem><!--opt, detection line-->
<id><!--req, xs: integer, detection line ID--></id>
<direction><!--req, detection line direction-->
<StartPoint><!--req-->
<positionX><!--req, xs: integer--></positionX>
<positionY><!--req, xs: integer--></positionY>
</StartPoint>
<EndPoint><!--req-->
<positionX><!--req, xs: integer--></positionX>
<positionY><!--req, xs: integer--></positionY>
</EndPoint>
</direction>
<sensitivityLevel><!--req, xs: integer, sensitivity--></sensitivityLevel>
<spaceGenerationSpeed><!--opt, xs: integer--></spaceGenerationSpeed>
139
Device Network SDK (People Counting) Developer Guide
140
Device Network SDK (People Counting) Developer Guide
<RegionCoordinates><!--req-->
<positionX><!--req, xs:integer;coordinate--></positionX>
<positionY><!--req, xs:integer;coordinate--></positionY>
</RegionCoordinates>
</RegionCoordinatesList>
</CountingArea>
<AutomaticCalib><!--opt,it is valid when calibrateType is "automaticCalib"-->
<CalibRegion><!--opt, Calibration Region (in Green Frame)-->
<RegionCoordinatesList>
<RegionCoordinates><!--req-->
<positionX><!-- req, xs:integer;coordinate --></positionX>
<positionY><!--req, xs:integer;coordinate--></positionY>
</RegionCoordinates>
</RegionCoordinatesList>
</CalibRegion>
</AutomaticCalib>
</CountingCalibrate>
<HeightFilterOverlay><!--opt-->
<enabled>
<!--opt, xs:boolean, whether to enable height filter. By default, it is disabled-->
</enabled>
<heightFilter>
<!--opt,xs:integer, filter height, unit: centimeter. The default value is 120, and it is ranging from 0 to 250-->
</heightFilter>
</HeightFilterOverlay>
<countingType><!--opt, xs: string, method to trigger counting: "none,alarmInputTrigger,videoTrigger"--></
countingType>
<signalType>
<!--dep, xs: string, signal type: "level,pulses", this node is valid when <countingType> is set to "videoTrigger" or
"alarmInputTrigger"-->
</signalType>
<RS485TransmissionEnabled><!--dep, xs: boolen, "false,true"--></RS485TransmissionEnabled>
<dailyResetTime>
<!--opt; xs: ios_8601_time, integer hour, e.g., "22:00:00+08:00"-->
</dailyResetTime>
<streamOverlayRuleInfos><!--req, xs: boolean, "true,false", whether to enable overlaying rule information in stream--
></streamOverlayRuleInfos>
<detectThreshold><!--opt, xs: integer, global detection threshold, value range: [0,100], default: 90--></
detectThreshold>
<aidedTrackEnabled><!--opt, xs: boolean, "true,false", whether to enable auxiliary tracking, by default, it is enabled--
></aidedTrackEnabled>
<TargetRegionCoordinatesList><!--opt, target frame, only supports square-->
<RegionCoordinates><!--req-->
<positionX><!--req, xs: integer; x-coordinate--></positionX>
<positionY><!--req, xs: integer; y-coordinate--></positionY>
</RegionCoordinates>
</TargetRegionCoordinatesList>
<ChildFilter><!--opt, counting children-->
<enabled><!--req, xs: boolean, whether to enable counting children: true, false--></enabled>
<heightThreshold>
<!--dep, xs: integer, height threshold of children, the counting will start when the height of children is higher than
configured height threshold, unit: cm, value range: [100,200]-->
141
Device Network SDK (People Counting) Developer Guide
</heightThreshold>
</ChildFilter>
<MisinfoFilter><!--opt, false alarm filtering-->
<enabled><!--req, xs: boolean, whether to enable false alarm filtering: true, false--></enabled>
<threshold><!--opt, xs: integer, threshold of false alarm filtering, value range: [0,100], default value: 15, larger
threshold value corresponds to higher precision--></threshold>
<timesLimit><!--opt,xs:integer, judge times of false alarm, value range: [1,5], default value: 3, more attempts
corresponds to higher precision--></timesLimit>
</MisinfoFilter>
<detectionMode>
<!--opt, xs: string, detection mode: single-detect based on tracking algorithm, double-detect based on depth map,
double_single-detect based on depth map mainly and tracking algorithm secondarily, single_double-detect based on
tracking algorithm mainly and depth map secondarily-->
</detectionMode>
<TrajectoryCountFilter><!--opt, pattern counting filtering-->
<enabled><!--req, xs: boolean,whether to enable, by default, it is enabled--></enabled>
<movementDisplacement><!--opt, xs: integer, displacement range: [0,200], default value: 40, unit: cm--></
movementDisplacement>
<residenceTime><!--opt, xs: float, dwell time duration, range: [0,10.0], default value: 0.1, unit: second--></
residenceTime>
</TrajectoryCountFilter>
<RegionsDirectionList><!--opt, counting direction-->
<RegionsDirection>
<id><!--req, xs: integer, detection region ID--></id>
<StartRegionCoordinatesList><!--req, start region-->
<RegionCoordinates>
<positionX><!--req, xs: integer; x-coordinate--></positionX>
<positionY><!--req, xs: integer; y-coordinate--></positionY>
</RegionCoordinates>
</StartRegionCoordinatesList>
<EndRegionCoordinatesList><!--req, end region-->
<RegionCoordinates><!--req-->
<positionX><!--req, xs: integer; x-coordinate--></positionX>
<positionY><!--req, xs: integer; y-coordinate--></positionY>
</RegionCoordinates>
</EndRegionCoordinatesList>
</RegionsDirection>
</RegionsDirectionList>
<maintenanceModeEnabled><!--opt, xs: boolean, whether to enable maintenance mode--></
maintenanceModeEnabled>
<analysisMode>
<!--optional, string, ro, analysis mode: "realTimeMode"-real time, "autoSwitchMode"-auto switch-->realTimeMode
</analysisMode>
</Counting>
C.7 XML_CountingCap
CountingCap message in XML format
142
Device Network SDK (People Counting) Developer Guide
143
Device Network SDK (People Counting) Developer Guide
144
Device Network SDK (People Counting) Developer Guide
</threshold>
<timesLimit min="1" max="5" def="3">
<!--opt, xs: integer, prevention attempts of false alarm, value range: [1,5], default value: 3, more attempts
corresponds to higher precision-->
</timesLimit>
</MisinfoFilter>
<isSupportReverseAlarm><!--opt, xs: boolean, whether supports setting reverse counting alarm--></
isSupportReverseAlarm>
<detectionMode opt="single,double,double_single,single_double" def="double_single">
<!--opt, xs: string, detection mode: single-detect based on tracking algorithm, double-detect based on depth map,
double_single-detect based on depth map mainly and tracking algorithm secondarily, single_double-detect based on
tracking algorithm mainly and depth map secondarily-->
</detectionMode>
<TrajectoryCountFilter><!--opt, pattern counting filtering-->
<enabled opt="true,false"><!--req, xs: boolean, whether to enable, by default, it is enabled--></enabled>
<movementDisplacement min="0" max="200" def="40"><!--opt, xs: integer, motion displacement range: [0,200],
default value: 40, unit: cm--></movementDisplacement>
<residenceTime min="0" max="10.0" def="0.1"><!--opt, xs: float, dwell time duration, range: [0,10.0], default value:
0.1, unit: second--></residenceTime>
</TrajectoryCountFilter>
<isSupportParameterExport><!--opt, xs: boolean, whether supports one-touch exporting people counting
parameters--></isSupportParameterExport>
<MultiRegions min="" max="">
<!--opt, xs: integer, number of counting regions, this node will not be returned if people counting in multiple regions
is not supported-->
</MultiRegions>
<isSupportRegionsDirection><!--opt, xs: boolean, whether supports setting counting direction--></
isSupportRegionsDirection>
<maintenanceModeEnabled opt="true,false"><!--opt, xs: boolean, whether to enable maintenance mode--></
maintenanceModeEnabled>
<analysisMode opt="realTimeMode,autoSwitchMode">
<!--optional, string, ro, analysis mode: "realTimeMode"-real time, "autoSwitchMode"-auto switch. The engine also
has its analysis mode (refer to the <analysisMode> node in /ISAPI/Intelligent/analysisEngines/<ID>). The device will be
added to the engine with the same analysis mode via the load balancing method. If the engine is not configured
correspondingly, this node will be failed to e returned, and the error code of taskNotMatchEngine will be returned--
>test
</analysisMode>
</CountingCap>
C.8 XML_CountingSearchCap
CountingSearchCap message in XML format
<CountingSearchCap version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<statisticType opt="enternum,exitnum,peoplePassing,all">
<!--req, xs: string, enternum: number of entered people, exitnum: number of exited people, peoplePassing: number
of passed people, all: number of entered and exited people-->
</statisticType>
<reportType opt="daily,weekly,monthly,yearly">
<!--req, xs: string-->
145
Device Network SDK (People Counting) Developer Guide
</reportType>
<timeSpanList size="">
<timeSpan>
<startTime><!--req, xs: datetime--></startTime>
<endTIme><!--req, xs: datetime--></endTime>
</timeSpan>
</timeSpanList>
<triggerPeopleCountingData opt="true,false">
<!--opt, xs: boolean, whether triggers people counting statistics-->
</triggerPeopleCountingData>
<MinTimeInterval opt="quarter, half, hour, day, month, week"><!--opt, xs: string, minimum time interval--></
MinTimeInterval>
<regionsID opt="1,2,3.."><!--opt, xs: integer, region ID, which supports report format--></regionsID>
<isSupportChild><!--opt,xs: boolean, whether supports counting children only--></isSupportChild>
</CountingSearchCap>
C.9 XML_CountingStatus
CountingStatus message in XML format
<CountingStatus version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<status><!--req, xs: string, "counting,stopped,paused"--></status>
<time><!--req, operation time (local time + time zone), e.g., "22:00:00+08:00"--></time>
<doorStatus><!--opt, xs: string, door triggering status: "open,close,N_A"--></doorStatus>
</CountingStatus>
C.10 XML_Desc_VcaChanAbility
Input description message for getting intelligent device capability.
<?xml version="1.0" encoding="utf-8"?>
<!--req, description of input parameter pInBuf for getting intelligent device capability-->
<VcaChanAbility version="2.0">
<channelNO><!--req, channel No.--></channelNO>
</VcaChanAbility>
C.11 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>
146
Device Network SDK (People Counting) Developer Guide
C.12 XML_EventTrigger
Linkage parameter message in XML format
<EventTrigger version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<id><!--required, xs:string, ID--></id>
<eventType>
<!--required, xs:string, see details in the "Remarks" below-->
</eventType>
<eventDescription><!--optional, xs:string--></eventDescription>
<inputIOPortID><!--dependent, xs:string, alarm input ID--></inputIOPortID>
<dynInputIOPortID><!--dependent, xs:string, dynamic alarm input ID--></dynInputPortID>
<videoInputChannelID>
<!--dependent, xs:string, video input channel ID, it is valid when <eventType> is "VMD, videoloss, tamperdetection,
regionEntrance, regionExiting, loitering, group, rapidMove, parking, unattendedBaggage, attendedBaggage"-->
</videoInputChannelID>
<dynVideoInputChannelID><!--dependent, xs:string, dynamic video input channel ID--></dynVideoInputChannelID>
<intervalBetweenEvents><!--optional, xs:integer, event time interval, unit: second--></intervalBetweenEvents>
<WLSensorID><!--dependent, xs:string, ID--></WLSensorID>
<EventTriggerNotificationList/><!--optional, alarm/event linkage actions, see details in the message of
XML_EventTriggerNotificationList-->
</EventTrigger>
Remarks
The node <eventType> can be the following values: IO, VMD, videoloss, raidfailure,
recordingfailure, badvideo, POS, analytics, fanfailure, overheat, tamperdetection, diskfull, diskerror,
nicbroken, ipconflict, illaccess, videomismatch, resolutionmismatch, radifailure, PIR, WLSensor,
spareException, poePowerException, heatmap, counting, linedetection, fielddetection,
regionEntrance, regionExiting, loitering, group,rapidMove, parking, unattendedBaggage,
attendedBaggage, HUMANATTRIBUTE, blackList, whitelist, peopleDetection, allVehicleList,
otherVehicleList, vehicledetection, storageDetection, shipsDetection, humanAttribute,
faceContrast, blackListFaceContrast, whiteListFaceContrast, faceSnap, faceLib,
personDensityDetection, personQueueDetecton, mixedTargetDetection, HVTVehicleDetection,
illegalParking, pedestrian, trafficAccident, construction, roadblock, abandonedObject,
147
Device Network SDK (People Counting) Developer Guide
C.13 XML_EventTriggerNotification
Event linkage notification message in XML format
<EventTriggerNotification><!--opt-->
<id><!--required, xs:string, device ID--></id>
<notificationMethod>
<!--required, xs:string, linkage actions, opt="email,IM,IO,syslog,HTTP,FTP,beep,ptz,record, monitorAlarm, center,
LightAudioAlarm,focus,trace,cloud,SMS,whiteLight,audio,whiteLight,faceContrast,siren,output"-->
</notificationMethod>
<notificationRecurrence>
<!--optional, xs:string, "beginning,beginningandend,recurring"-->
</notificationRecurrence>
<notificationInterval><!--dependent, xs:integer, unit: millisecond--></notificationInterval>
<outputIOPortID><!--dependent, xs:string, video output No., it is required only when notificationMethod is "IO"--></
outputIOPortID>
<dynOutputIOPortID><!--dependent, xs:string, dynamic video output No., it is required only when
notificationMethod is "IO"--></dynOutputIOPortID>
<videoInputID><!--dependent, xs:string, video input No., it is required only when notificationMethod is "record"--></
videoInputID>
<dynVideoInputID><!--dependent, xs:string, dynamic video input No., it is required only when notificationMethod is
"record"--></dynVideoInputID>
<ptzAction><!--dependent, it is required only when notificationMethod is "ptz"-->
<ptzChannelID><!--required, xs:string, PTZ channel ID--></ptzChannelID>
<actionName><!--required, xs:string, PTZ control type: "preset", "pattern", "patrol"--></actionName>
<actionNum><!--dependent, xs:integer></actionNum>
</ptzAction>
<WhiteLightAction><!--dependent, white light linkage parameters, this node is valid when notificationMethod is
"whiteLight"-->
<whiteLightDurationTime><!--required, xs:integer, white light flashing duration, it is between 1 and 60, unit:
second--></whiteLightDurationTime>
</WhiteLightAction>
<cellphoneNumber><!--dependent, xs:string, min="0" max="11",cellphone number--></cellphoneNumber-->
</EventTriggerNotification>
148
Device Network SDK (People Counting) Developer Guide
C.14 XML_EventTriggerNotificationList
EventTriggerNotificationList message in XML format
<EventTriggerNotificationList version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<EventTriggerNotification/><!--opt, see details in the message of XML_EventTriggerNotification-->
</EventTriggerNotificationList>
See Also
XML_EventTriggerNotification
C.15 XML_RacmCap
XML message about device storage capability
<?xml version="1.0" encoding="utf-8"?>
<RacmCap version="1.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<isSupportZeroChan>
<!--optional, xs:boolean, whether it supports channel-zero, "true"-yes, "false"-no-->
</isSupportZeroChan>
<inputProxyNums><!--optional, xs:integer, number of supported digital channels--></inputProxyNums>
<eSATANums><!--optional, xs:integer, number of supported eSATAs--></eSATANums>
<miniSASNums><!--optional, xs:integer, number of supported miniSATAs--></miniSASNums>
<nasNums><!--optional, xs:integer, number of supported NASs--></nasNums>
<ipSanNums><!--optional, xs:integer, number of supported IPSANs--></ipSanNums>
<isSupportRaid>
<!--optional, xs:boolean, whether it supports RAID, "true"-yes, "false"-no-->
</isSupportRaid>
<isSupportExtHdCfg>
<!--optional, xs:boolean, whether it supports HDD advanced management, "true"-yes, "false"-no-->
</isSupportExtHdCfg>
<isSupportTransCode><!--optional, xs:boolean, whether it supports auto-switch, "true"-yes, "false"-no--></
isSupportTransCode>
<isSupportIpcImport>
<!--optional, xs:boolean, whether it supports importing configuration files to network camera, "true"-yes, "false"-
no-->
</isSupportIpcImport>
<NasMountType><!--optional-->
<isNFSSupportAuthentication/><!--optional, xs:boolean, whether it supports NFS authentication, "true"-yes, "false"-
no-->
<isCIFSSupportAuthentication/><!--optional, xs:boolean, whether it supports CIFS authentication, "true"-yes, "false"-
no-->
</NasMountType>
<isSupportIpcStreamType/><!--optional, xs:boolean-->
<isSupportIOInputProxy/><!--optional, xs:boolean, whether it supports dynamic alarm input channel: "true"-yes,
"false"-no-->
<isSupportIOOutputProxy/><!--optional, xs:boolean, whether it supports dynamic alarm output channel: "true"-yes,
"false"-no-->
149
Device Network SDK (People Counting) Developer Guide
150
Device Network SDK (People Counting) Developer Guide
151
Device Network SDK (People Counting) Developer Guide
<!--optional, xs: boolean, whether it supports extending the time zone for searching log-->
</isSupportFindLogByUTC>
<isSupportUploadRecordByUTC>
<!--optional, xs: boolean, whether it supports extending the time zone for uploading files to cloud storage-->
</isSupportUploadRecordByUTC>
<isSupportPlaybackByUTC>
<!--optional, xs: boolean, whether it supports extending the time zone for playback by time and locating by time-->
</isSupportPlaybackByUTC>
<SecurityLog>
<isSupportSecurityLog><!--optional, boolean, whether it supports security log--></isSupportSecurityLog>
<isSupportLogServer><!--optional, boolean, whether it supports log server configuration--></isSupportLogServer>
<isSupportLogServerTest><!--optional, xs: boolean, whether it supports log server test--></isSupportLogServerTest>
<SecurityLogTypeList><!--required, xs: list, supported log type list-->
<SecurityLogType>
<primaryType><!--required, xs: string, major type--></primaryType>
<secondaryType optional=""><!--required, xs: string, minor type--></secondaryType>
</SecurityLogType>
</SecurityLogTypeList>
</SecurityLog>
<iSptInputProxyChanCap>
<!--optional, xs:boolean, whether it supports getting the capability of the digital channel-->
</iSptInputProxyChanCap>
<isSupportLogDataPackage>
<!--optional, xs:boolean, whether it supports exporting logs: "true, false"-->
</isSupportLogDataPackage>
<logSearchTimeSpanNums>
<!--optional, xs:integer, supported number of time periods for log search-->
</logSearchTimeSpanNums>
<isSupportManualRecord>
<!--optional, xs:boolean, whether the device supports manual recording-->
</isSupportManualRecord>
<isSupportRemark><!--optional, xs:boolean, whether it supports file remarks--></isSupportRemark>
<FileUpload><!--optional, upload file-->
<enabled><!--required, xs:boolean, whether it supports enabling file uploading--></enabled>
</FileUpload>
<PoliceInfoUpload><!--optional, upload police information-->
<enabled><!--required, xs:boolean, whether it supports enabling police information uploading--></enabled>
</PoliceInfoUpload>
<PoliceInfo>
<policeID><!--optional, xs:boolean, whether it supports police ID--></policeID>
<policeCode><!--optional, xs:boolean, whether it supports police No.--></policeCode>
<policeName><!--optional, xs:boolean, whether it supports police name--></policeName>
<password><!--optional, xs:boolean, whether it supports police password--></password>
<deviceID><!--optional, xs:boolean, whether it supports device ID--></deviceID>
</PoliceInfo>
<behaviorEventPicSearch
opt="allBehaviorEvent,running,group,violentMotion,failDown,playCellphone,peopleNumChange,leavePosition,retentio
n,sleepOnduty">
<!--optional, xs:string, behavior analysis events supported by picture search, which is used for web display,
"allBehaviorEvent"-all events in behaviorEventPicSearch-->
</behaviorEventPicSearch>
<perimeterEventPicSearch
152
Device Network SDK (People Counting) Developer Guide
opt="allPerimeterEvent,linedetection,fielddetection,regionEntrance,regionExiting,loitering">
<!--optional, xs:string, perimeter protection events that support picture search, which is used for web display,
"allPerimeterEvent"-all events in perimeterEventPicSearch-->
</perimeterEventPicSearch>
<isSupportAssignChannelID><!--optional, xs:boolean, whether it supports specify channel No. when adding IPC--></
isSupportAssignChannelID>
<isSupportAssignStreamID><!--optional, xs:boolean, whether it supports specify stream ID of the channel when
adding IPC--></isSupportAssignStreamID>
<isSupportTimeSearch><!--optional, xs:boolean, whether it supports searching for recording start and end time by
channel--></isSupportTimeSearch>
<CloudStorageServerCap><!--optional-->
<isSupportCloudStorageParameter><!--optional, xs:boolean, whether it supports configuring cloud storage
parameters--></isSupportCloudStorageParameter>
<isSupportCloudStoragePool><!--optional, xs:boolean, whether it supports configuring cloud storage pool
parameters--></isSupportCloudStoragePool>
</CloudStorageServerCap>
<CMSearchCount/><!--optional, xs:boolean, whether it supports searching for file quantity of dock station-->
<isSupportSSDSMARTTest>
<!--optional, xs:boolean, whether the device supports SSD S.M.A.R.T detection (related URI: /ISAPI/ContentMgmt/
Storage/ssd/<ID>/SMARTTest/start)-->
</isSupportSSDSMARTTest>
<isSupportSpare><!--optional, boolean, whether the device supports hot spare configuration--></isSupportSpare>
<isSupportPTEventTableTemplate><!--optional,xs:boolean, whether the device supports importing/exporting Excel
templates of transparent transmission event type (related URI: /ISAPI/ContentMgmt/PTEventTableTemplate?
format=json)--></isSupportPTEventTableTemplate>
<isSupportPTEventTableFile><!--optional,xs:boolean, whether the device supports importing/exporting the Excel files
of transparent transmission event type (related URI: /ISAPI/ContentMgmt/PTEventTableFile?format=json)--></
isSupportPTEventTableFile>
</RacmCap>
C.16 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>
153
Device Network SDK (People Counting) 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>
C.17 XML_Schedule
Schedule message in XML format
<Schedule version="2.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<id><!--required, xs:string, ID--></id>
<eventType>
<!--optional, xs:string, alarm/event types, see details in the "Remarks" below-->
</eventType>
<inputIOPortID><!--read-only, dependent, xs:string, alarm input No.--></inputIOPortID>
<outputIOPortID><!--read-only, dependent, xs:string, alarm output No.--></inputIOPortID>
<videoInputChannelID><!--read-only, dependent, xs:string, video input channel ID--></videoInputChannelID>
<TimeBlockList size="8"><!--required-->
<TimeBlock><!--list-->
<dayOfWeek>
<!--optional, xs:integer, day of the week based on ISO8601, "1"=Monday, ...-->
</dayOfWeek>
<TimeRange><!--required-->
<beginTime><!--required, xs:time, ISO 8601 time--></beginTime>
<endTime><!--required, xs:time, ISO 8601 time--></endTime>
</TimeRange>
<CustomExtension>
<vehicleDetectSceneID>
<!--required, xs:interger-->
</vehicleDetectSceneID>
</CustomExtension>
</TimeBlock>
</TimeBlockList>
<HolidayBlockList><!--optional-->
<TimeBlock><!--list-->
<TimeRange><!--required-->
<beginTime><!--required, xs:time, ISO 8601 time--></beginTime>
<endTime><!--required, xs:time, ISO 8601 time--></endTime>
</TimeRange>
</TimeBlock>
</HolidayBlockList>
</Schedule>
154
Device Network SDK (People Counting) Developer Guide
Remarks
The node <eventType> can be set to the following values: IO, VMD,videoloss, PIR,linedetection,
fielddetection, audioexception, facedetection, regionEntrance, regionExiting, loitering, group,
rapidMove, parking, unattendedBaggage,attendedBaggage, storageDetection, shipsDetection,
HUMANATTRIBUTE, humanAttribute, faceContrast, faceSnap, faceLib, whiteListFaceContrast,
personDensityDetection, personQueueDetection, mixedTargetDetection, fireDetection,
illegalParking, pedestrian, trafficAccident,construction, roadblock, abandonedObject,
parallelParking, parkingState, congestion, intersectionAnalysis, heatMap, reverseEntrance,
vehicledetect, safetyHelmetDetection, vibrationDetection, TMPA, faceThermometry, HBDLib,
detectorTemp, detectorSmoke, detectorTamper, smokeFireRecognizesmokeFireRecognize,
indoorPasswayBlock, detectorShelter, detectorMotion, fireNoRegulation, peopleDetections.
C.18 XML_Smart_Shield
Shield message in XML format for smart detection
<Shield version="1.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<enabled><!--req, xs: string, whether to enable shielded area for smart detection: "true,false"--></enabled>
<RegionList>
<Region><!--list-->
<id><!--req, xs: string--></id>
<enabled><!--req, xs: string, "true,false"--></enabled>
<RegionCoordinatesList>
<RegionCoordinates><!--req, list-->
<positionX><!--req, xs: integer, x-coordinate--></positionX>
<positionY><!--req, xs: integer, y-coordinate--></positionY>
</RegionCoordinates>
</RegionCoordinatesList>
</Region>
</RegionList>
</Shield>
C.19 XML_Smart_ShieldCap
XML message about shield area configuration capability
<ShieldCap version="1.0" xmlns="http://www.isapi.org/ver20/XMLSchema">
<enabled opt="true,false"><!--req, xs: string--></enabled>
<RegionList size="">
<Region><!--list-->
<id><!--req, xs: string--></id>
<enabled opt="true,false"><!-- req, xs:string ""--></enabled>
<RegionCoordinatesList size="">
<RegionCoordinates><!--req, list-->
<positionX><!--req, xs: integer, x-coordinate--></positionX>
<positionY><!--req, xs: integer, y-coordinate--></positionY>
155
Device Network SDK (People Counting) Developer Guide
</RegionCoordinates>
</RegionCoordinatesList>
<minRegionCoordinatesNum><!--optional, int, the minimum number of polygon vertexes; value range: [4,10]-->4</
minRegionCoordinatesNum>
<maxRegionCoordinatesNum><!--optional, int, the maximum number of polygon vertexes; value range: [4,10]--
>10</maxRegionCoordinatesNum>
</Region>
</RegionList>
<normalizedScreenSize><!--optional, object, normalized screen size-->
<normalizedScreenWidth><!--optional, int, normalized screen width, range: [0,1000], 1000 by default-->1000</
normalizedScreenWidth>
<normalizedScreenHeight><!--optional, int, normalized screen height, range: [0,1000], 1000 by default-->1000</
normalizedScreenHeight>
</normalizedScreenSize>
<eventType opt="regionEntrance,regionExiting,linedetection,fielddetection">
<!--optional, string, event type: "regionEntrance", "regionExiting", "linedetection", and "fielddetection" --
>regionEntrance
</eventType>
</ShieldCap>
</ShieldCap>
C.20 XML_VcaChanAbility
VcaChanAbility message in XML format
<?xml version="1.0" encoding="UTF-8"?>
<VcaChanAbility><!--req, VCA capability-->
<channelNO><!--channel No.--></channelNO>
<restartLib><!--whether to support restarting algorithm library--></restartLib>
<vcaVersion><!--whether to support viewing version information of algorithm library--></vcaVersion>
<syncChannelName><!--whether to support setting the channel name of synchronization analyzer to the camera
name--></syncChannelName>
<VcaDrawMode><!--intelligent information overlay-->
<dspEncAddTarget opt="true,false"/><!--character overlay target-->
<dspEncAddRule opt="true,false"/><!--character overlay rule-->
<dspPicAddTarget opt="true,false"/><!--picture overlay target-->
<dspPicAddRule opt="true,false"/><!--picture overlay rule-->
</VcaDrawMode>
<AlarmPicResolutionList><!--alarm picture resolution-->
<picResolutionEntry index="3" name="UXGA" resolution="1600*1200"/>
<picResolutionEntry index="4" name="SVGA" resolution="800*600"/>
<picResolutionEntry index="5" name="HD720P" resolution="1280*720"/>
<picResolutionEntry index="6" name="VGA" resolution="640*480"/>
</AlarmPicResolutionList>
<GlobalSizeFilter><!--global size filter-->
<mode opt="imagePixel,realWorld,default" default="imagePixel"/>
<!--filter mode, "imagePixel"-by pixel size,"realWorld"-by actual size, "default"-->
<minRect><!--minimum target frame--></minRect>
<maxRect><!--maximum target frame--></maxRect>
</GlobalSizeFilter>
156
Device Network SDK (People Counting) Developer Guide
<Behavior><!--behavior analysis-->
<EventType-->
<BlackboardWriting><!--blackboard writing-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
</BlackboardWriting>
<Lecture><!--teaching-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<sensitivity min="1" max="5" default="5"/><!--sensitivity-->
<duration min="0" max="10" default="5"/>
<!--triggered time threshold of behavior analysis event-->
<trackingMode opt="auto,horizontal,vertical" default="auto"/>
<!--tracking mode-->
<zoomMode opt="fixed,auto" default="fixed"/>
<!--zooming mode-->
<SizeFilter>
<mode opt="imagePixel,realWorld,default" default="imagePixel"/>
<!--filter mode, "imagePixel"-by pixel size, "realWorld"-by actual size, "default"-->
<minRect><!--minimum target frame--></minRect>
<maxRect><!--maximum target frmae--></maxRect>
</SizeFilter>
</Lecture>
<Answer><!--answering-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<sensitivity min="1" max="5" default="5"/><!--sensitivity-->
<SizeFilter>
<mode opt="imagePixel,realWorld,default" default="imagePixel"/>
<!--filter mode, "imagePixel"-by pixel size, "realWorld"-by actual size, "default"-->
<minRect><!--minimum target frame--></minRect>
<maxRect><!--maximum target frmae--></maxRect>
</SizeFilter>
</Answer>
<TraversePlane><!--plane crossing-->
<planeBottom><!--plane bottom border--></planeBottom>
<crossDirection opt="bothDirection,leftToRight,rFaceSnapightToLeft" default="bothDirection"/>
<!--crossing direction, "bothDirection"-dual-direction, "leftToRight"-left to right, "rightToLeft"-right to left-->
<sensitivity min="1" max="5" default="5"/><!--sensitivity-->
<planeHeight min="0" max="255" default="5"/><!--plane height-->
<detectionTarget opt="all,human,vehicle, human_vehicle"/>
<!--detection target: "all", "human", "vehicle", "human_vehicle"-human and vehicle-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
<isSupportHumanMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false human body alarms, "true"-yes, "false"-no-->
</isSupportHumanMisinfoFilter>
<isSupportVehicleMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false vehicle alarms, "true"-yes, "false"-no-->
157
Device Network SDK (People Counting) Developer Guide
</isSupportVehicleMisinfoFilter>
</TraversePlane>
<EnterArea><!--region entrance-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<detectionTarget opt="all,human,vehicle, human_vehicle"/>
<!--detection target: "all", "human", "vehicle", "human_vehicle"-human and vehicle-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
<isSupportHumanMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false human body alarms, "true"-yes, "false"-no-->
</isSupportHumanMisinfoFilter>
<isSupportVehicleMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false vehicle alarms, "true"-yes, "false"-no-->
</isSupportVehicleMisinfoFilter>
</EnterArea>
<ExitArea><!--region exiting-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<detectionTarget opt="all,human,vehicle"/>
<!--detection target: "all", "human", "vehicle", "human_vehicle"-human and vehicle-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
<isSupportHumanMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false human body alarms, "true"-yes, "false"-no-->
</isSupportHumanMisinfoFilter>
<isSupportVehicleMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false vehicle alarms, "true"-yes, "false"-no-->
</isSupportVehicleMisinfoFilter>
</ExitArea>
<Intrusion><!--intrusion-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="0" max="100" default="5"/>
<!--triggered time threshold of intrusion alarm-->
<sensitivity min="1" max="100" default="50"/><!--sensitivity-->
<rate min="1" max="100" default="5"/><!--percentage-->
<detectionTarget opt="all,human,vehicle, human_vehicle"/>
<!--detection target: "all", "human", "vehicle", "human_vehicle"-human and vehicle-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
<isSupportHumanMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false human body alarms, "true"-yes, "false"-no-->
</isSupportHumanMisinfoFilter>
<isSupportVehicleMisinfoFilter>
<!--opt, xs:boolean, whether to support preventing false vehicle alarms, "true"-yes, "false"-no-->
</isSupportVehicleMisinfoFilter>
</Intrusion>
<Loiter><!--loitering-->
158
Device Network SDK (People Counting) Developer Guide
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="1" max="120" default="10"/><!--triggered time threshold-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
<loiterDistance min="100" max="5000" default="1000"/>
<!--opt, total distance threshold of loitering, unit: cm-->
</Loiter>
<LeftTake><!--object left and removal-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="1" max="120" default="10"/><!--triggered time threshold-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
</LeftTake>
<Parking><!--parking-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="1" max="100" default="10"/><!--triggered time threshold-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
</Parking>
<Run><!--running-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<distance min="0.1" max="1.0" default="0.5"/>
<!--maximum distance of people running-->
<mode opt="imagePixel,realWorld" default="imagePixel"/>
<!--filter mode: "imagePixel"-by pixel size, "realWorld"-by actual size-->
<ImagePixelMode><!--parameters for filter mode by pixel size-->
<distance min="0.1" max="1.0" default="0.5"/>
<!--maximum distance of people running-->
</ImagePixelMode>
<RealWorldMode><!--parameters for filter mode by actual size-->
<distance min="1" max="20" default="10"/>
<!--maximum distance of people running-->
</RealWorldMode>
<detectionTarget opt="all,human,vehicle,human_vehicle"/>
<!--detection target: "all", "human", "vehicle", "human_vehicle"-human and vehicle-->
<eventPriority opt="low,mid,high"/>
<!--opt, event priority: "low", "mid"-medium, "high"-->
</Run>
<HighDensity><!--people gathering-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<density min="0.1" max="1.0" default="0.5"/><!--density ratio-->
<duration min="20" max="360" default="20"/>
159
Device Network SDK (People Counting) Developer Guide
160
Device Network SDK (People Counting) Developer Guide
161
Device Network SDK (People Counting) Developer Guide
</ADVReachHeight>
<ToiletTarry><!--in-toilet overtime-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="1" max="3600" default="600"/><!--time of in-toilet overtime-->
</ToiletTarry>
<YardTarry><!--playground overstay-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="1" max="120" default="60"/><!--time of playground overstay-->
</YardTarry>
<ADVTraversePlane><!--plane polyline crossing-->
<Region>
<vertexNum min="2" max="10"/><!--number of region vertexes-->
</Region>
<crossDirection opt="bothDirection,leftToRight,rightToLeft" default="bothDirection"/>
<!--crossing direction: "bothDirection"-dual-direction, "leftToRight"-left to right, "rightToLeft"-right to left-->
<sensitivity min="1" max="5" default="5"/><!--sensitivity-->
</ADVTraversePlane>
<OverTime><!--operation timeout-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="4" max="60000" default="30000"/>
<!--triggered time threshold of operation timeout alarm-->
</OverTime>
<StickUp><!--sticking-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="4" max="60" default="30"/><!--triggered time threshold-->
<sensitivity min="1" max="5" default="5"/><!--sensitivity-->
</StickUp>
<InstallScanner><!--installing card reader-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<duration min="4" max="60" default="30"/><!--card reading duration-->
<sensitivity min="1" max="5" default="5"/><!--sensitivity-->
</InstallScanner>
<Standup><!--people standing up-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<sensitivity min="1" max="100" default="5"/><!--sensitivity-->
<duration min="1" max="3600" default="2"/><!--triggered time threshold-->
<heightThreshold min="0" max="250" default="130"/><!--height threshold-->
</Standup>
<PeopleNumChange><!--number of people exception-->
<Region>
162
Device Network SDK (People Counting) Developer Guide
163
Device Network SDK (People Counting) Developer Guide
164
Device Network SDK (People Counting) Developer Guide
165
Device Network SDK (People Counting) Developer Guide
166
Device Network SDK (People Counting) Developer Guide
167
Device Network SDK (People Counting) Developer Guide
168
Device Network SDK (People Counting) Developer Guide
<laneNum><!--number of lanes--></laneNum>
<laneBoundaryLine><!--lane boundary line, which is the left boundary line of the leftmost lane--></
laneBoundaryLine>
<VIALane>
<maxLaneNum><!--maximum number of lanes--></maxLaneNum>
<associatedLaneNO><!--lane No. linkage--></associatedLaneNO>
<LaneLogicParam>
<laneUseage opt="unknown,carriageWay,bus,fast,slow,motor,nonMotor,reverse,banTrucks,mix"/>
<!--lane type: "unknown", "carriageWay"-normal lane, "bus"-bus lane, "fast"-express lane, "slow"-slow lane,
"motor"-motorcycle lane, "nonMotor"-non-motor vehicle lane, "reverse"-opposite lane, "banTruck"-non-truck lane,
"mix"-all-purpose lane-->
<laneDirection
opt="unknown,left,straight,leftStraight,right,leftRight,rightStraight,leftRightStraight,leftWait,straightWait,forward,back
ward,bothway"/>
<!--lane direction: "unknown", "left"-turning left, "straight"-going straight, "leftStraight"-turning left and going
straight, "right"-turning right, "leftRight"-turning left and turning right, "rightStraight"-turning right and going straight,
"leftRightStraight"-turning left, turning right and going straight, "leftWait"-waiting to turn left, "straight"-waiting to go
straight, "forward"-driving forward, "backward"-driving backward, "bothway"-bidirectional driving-->
<carDriveDirection opt="unknown,uptodown,downtoup"/>
<!--driving direction: "unknown", "uptodown"-driving in the down direction, "downtoup"-driving in the up
direction-->
</LaneLogicParam>
<laneLine><!--lane line--></laneLine>
<Region>
<vertexNum min="3" max="20"/>
<!--plate recognition area, number of region vertexes-->
</Region>
</VIALane>
<PlateRecogParam>
<provinceAbbreviation><!--Chinese character abbreviation of the province where the device operates--></
provinceAbbreviation>
<RecogMode><!--recognition mode-->
<plateRecogPos opt="fromFront,fromBack"/>
<!--plate recognition position, "fromFront"-front plate recognition, "fromBack"-rear plate recognition-->
<plateRecogType opt="big,little"/>
<!--plate recognition type, "big"-large license plate, "little"-small license plate-->
<locationType opt="sceneLocation,frameLocation"/>
<!--location type, "sceneLocation"-scene location, "frameLocation"-frame location-->
<recogType opt="sceneRecognition,frameRecognition"/>
<!--recognition type, "sceneRecognition"-scene recognition, "frameRecognition"-frame recognition-->
<recogTime opt="daytime,night"/>
<!--recognition time, "daytime", "night"-->
<sceneType opt="EPolice,gate"/>
<!--scene type, "EPolice"-e-police, "gate"-checkpoint-->
<microPlateRecog opt="true,false"/>
<!--smaller license plate recognition-->
<farmVehicleRecog opt="true,false"/>
<!--farm vehicle recognition-->
<vechileColorRecog opt="true,false"/>
<!--vehicle color recognition-->
<motorCarRecog opt="true,false"/>
<!--motorcycle recognition-->
169
Device Network SDK (People Counting) Developer Guide
<blurRecog opt="true,false"/>
<!--fuzzy recognition-->
</RecogMode>
<vehicleLogoRecog opt="true,false"/><!--vehicle logo recognition-->
</PlateRecogParam>
</VIAVirtualCoilParam>
</ITCTriggerCfg>
</Traffic>
<PDC><!--people counting statistics-->
<PDCType opt="smart, professionalIntelligence"/>
<!--intelligent people counting type: "smart"-smart device, "professionalIntelligence"-professional intelligent iDS
device-->
<PDCRule>
<Region>
<vertexNum min="4" max="10"/><!--number of region vertexes-->
</Region>
<Line>
<support opt="leftLine,rightLine"/>
</Line>
<enterDirection><!--people counting entrance direction--></enterDirection>
<dayStartTime><!--daytime start time--></dayStartTime>
<nightStartTime><!--night start time--></nightStartTime>
<AlarmTime>
<timeSegNum min="2" max="8"/><!--number of arming period per day-->
</AlarmTime>
<alarmHandleType opt="monitor,audio,center,alarmout,picture,wirelesslight,uploadftp"/>
<!--req, handling type-->
<detecteSensitive min="" max=""/>
<!--target detection sensitivity, ranges from 1 to 100, the default value is 50-->
<generatieSpeedSpace min="" max=""/>
<!--target generating speed (space), ranges from 1 to 100, the default value is 50-->
<generatieSpeedTime min="" max=""/>
<!--target generating speed (time), ranges from 1 to 100, the default value is 50-->
<countSpeed min="" max=""/>
<!--counting speed, ranges from 1 to 100, the default value is 50-->
<detecteType opt="auto,head,shoulder"/>
<!--target detection type: "auto"-automatic detection, "head"-head detection, "shoulder"-head and shoulder
detection, the default value is "auto"-->
<targetSizeCorrect min="" max=""/>
<!--target size correction, ranges from 1 to 100, the default value is 50-->
</PDCRule>
<Calibration>
<calibRectNum min="1" max="6"/>
<!--number of calibration frames-->
<calibLine><!--whether to support calibration line--></calibLine>
<calibVerify><!--whether to support calibration verification--></calibVerify>
</Calibration>
<resetCounter><!--reset counting parameter--></resetCounter>
<resetCounterMode opt="timing,manual"/><!--reset counting mode-->
<OSD>
<enable opt="disable,enable"/><!--req, enable people counting OSD display-->
<topLeftPoint><!--req, whether to support the top left coordinate--></topLeftPoint>
170
Device Network SDK (People Counting) Developer Guide
171
Device Network SDK (People Counting) Developer Guide
172
Device Network SDK (People Counting) Developer Guide
</isSupportSearchPeoplePassing>
<countingType opt="none,alarmInputTrigger,videoTrigger" />
<!--opt, xs:string, triggering counting mode: "none", "alarmInputTrigger"-alarm input triggering, "videoTrigger"-VCA
triggering-->
<alarmInputTrigger_signalType opt="level,pulses" />
<!--opt, xs:string, signal type: "level"-level, "pulses"-pulse-->
<videoTrigger_RS485Transmission opt="true,false" />
<!--opt, xs:boolean, enable RS-485 data transmission-->
<isSupportTriggerPeopleCountingDataSearch><!--opt, whether to support triggering searching people counting
statistics--></isSupportTriggerPeopleCountingDataSearch>
<isSupportDailyResetTime><!--opt, whether to support scheduled resetting--></isSupportDailyResetTime>
<Polyline><!--opt, whether to support polyline detection-->
<maxPointNumber>
<!--req, xs:integer, supported number of polyline endpoints-->
</maxPointNumber>
</Polyline>
<isSupportBusDetectionArea><!--opt, whether to support mobile bus entry/exit detection area--></
isSupportBusDetectionArea>
<isSupportStreamOverlayRuleInfos><!--opt, whether to support stream VCA information overlay--></
isSupportStreamOverlayRuleInfos>
<isSupportInterfaceSegmentation><!--opt, whether to support window division by 4200 software--></
isSupportInterfaceSegmentation>
<isSupportMobileDescribeChange><!--opt, this node is used to mark the edited the parameter name of people
counting camera interface, which can distinguish the baseline product and mobile product--></
isSupportMobileDescribeChange>
<isSupportAdvanceConfiguration><!--opt, this node is used to mark whether the camera supports advanced
configuration--></isSupportAdvanceConfiguration>
<isSupportSearchDoorStates><!--opt, this node is used to support detecting the door status triggered by mobile
signal--></isSupportSearchDoorStates>
<isSupportMultiChannelSearch><!--opt, whether supports people counting of multiple channels--></
isSupportMultiChannelSearch>
</PDC>
<HeatMapDetection><!--req, heat map detection-->
<enable opt="true,false"/><!--req, "false"-disable, "true"-enable-->
<detSenceID min="" max=""/><!--req, detection scene ID-->
<heatMapRegionNum><!--req, number of heat map detection regions--></heatMapRegionNum>
<HeatMapParam><!--req, corresponding number of this node-->
<regionNum min="3" max="10"/>
<!--req, number of valid points supported by each heat map detection region-->
<targetTrackEnable opt="true,false"/>
<!--req, target track: "true"-open, "false"-close, the default value is "false"-->
<sensitivityLevel min="0" max="100"/>
<!--req, sensitivity-->
<backgroundUpdateRate min="1" max="100"/>
<!--req, background updating rate, ranges from 1 to 100, the default value is 50-->
<sceneChangeLevel min="1" max="100"/>
<!--req, scene change level, ranges from 1 to 100, the default value is 50-->
<minTargetSize min="1" max="100"/>
<!--req, minimum target size, ranges from 1 to 100, the default value is 50-->
</HeatMapParam>
<alarmTime><!--req, number of arming period--></alarmTime>
<alarmHandleType opt="monitor,audio,center,alarmout,picture,wirelesslight,uploadftp"/>
173
Device Network SDK (People Counting) Developer Guide
<!--req, handling type: "monitor"-warning on the monitor, "audio"-audible warning, "center"-notify surveillance
center, "alarmout"-trigger alarm output, "picture"-capture JPEG picture and send by email (Uploadftp was missing in
earlier versions and was added later. If this string cannot be resolved, firstly check whether to support capturing
pictures and uploading to FTP, and then resolve the uploadftp node of the software and hardware capability of the
device.), "wirelesslight"-wireless light and audio alarm, "uploadftp"-capture picture and upload to FTP-->
<brokenNetHttp><!--opt, whether to support ANR--></brokenNetHttp>
<uploadHeatMapResultType opt="0,1"/><!--opt, heat map type, 0-standard heat map, 1-heat map of people
counting and dwell duration-->
<confidence min="0.00" max="100.00"/><!--opt, whether supports setting target picture confidence-->
<searchType opt="duration,PDC"/><!--opt, statistics types, dwell duration statistics or people counting statistics--->
</HeatMapDetection>
<Face><!--facial detection-->
<FaceDetect>
<eventType opt="abnormalFace,normalFace,multiFace,sunglassesFace,callFace"/>
<!--"abnormalFace"-abnormal face, "normalFace"-normal face, "multiFace"-multiple faces, "sunglassesFace"-face
with sunglasses, "callFace"-face on the phone-->
<uploadLastAlarm opt="false,true"/><!--upload the latest alarm-->
<uploadFacePic opt="false,true"/><!--upload face sub-picture-->
<picRecordEnable opt="false,true"/><!--picture storage-->
<ruleNameLength min="0" max="32"/><!--rule name length-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
<picProcType opt="notProcess,upload"/>
<!--picture processing method: "notProcess"-not process, "upload"-upload-->
<sensitivity min="1" max="100" default="10"/><!--sensitivity-->
<duration min="4" max="60" default="30"/><!--triggered time threshold of face alarm-->
<JpegParam>
<picSize><!--picture size--></picSize>
<picQuality opt="best,better,normal"/>
<!--picture quality: "best", "better", "normal"-->
</JpegParam>
<SizeFilter>
<mode opt="imagePixel,realWorld,default" default="imagePixel"/>
<!--filter mode, "imagePixel"-by pixel size, "realWorld"-by actual size, "default"-->
<minRect><!--minimum target frame--></minRect>
<maxRect><!--maximum target frame--></maxRect>
</SizeFilter>
<AlarmTime>
<timeSegNum min="2" max="8"/><!--number of arming period per day-->
</AlarmTime>
<alarmHandleType opt="monitor,audio,center,alarmout,picture,wirelesslight,uploadftp"/>
<!--"monitor"-warning on the monitor, "audio"-audible warning, "center"-notify surveillance center, "alarmout"-
trigger alarm output, "picture"-capture JPEG picture and send by email, "wirelesslight"-wireless light and audio alarm,
"uploadftp"-capture picture and upload to FTP-->
<relRecordChan><!--alarm triggered channel recording--></relRecordChan>
<alarmDelay opt="5,10,30,60,120,300,600"/><!--alarm delay-->
<FaceInPicture><!--face picture-in-picture-->
<enabled opt="true,false"/><!--whether to enable-->
<backChannel><!--background channel--></backChannel>
<position opt="topLeft,topRight,bottomLeft,bottomRight" default="bottomRight"/>
<!--overlay position: "topLeft"-top left, "topRight"-top right, "bottomLeft"-bottom left, "bottomRight"-bottom
174
Device Network SDK (People Counting) Developer Guide
right-->
<division opt="1/4,1/9,1/16"/><!--window division ratio-->
<IPChannel>
<isSupport><!--whether to support IP channel, newly added to DeepinMind ATM, old devices only support face
PIP of analog channel--></isSupport>
<isSupportBackChannel><!--whether to support setting IP channel as the background channel, newly added to
DeepinMind ATM, old devices only support setting analog channel as the background channel--></
isSupportBackChannel>
</IPChannel>
</FaceInPicture>
<maxRelSnapChanNum><!--maximum number of capture linkage channels--></maxRelSnapChanNum>
<isSupportEventTypeEx><!--whether the device supports EventTypeEx extension field. It is used to determine the
compatibility of iVMS-4200--></isSupportEventTypeEx>
<AlgParam>
<!--opt, configuration display capability of face detection algorithm library, only used in ATM project. The
configuration items not contained in the capability will display by default without being determined by the capability--
>
<FaceDetectAlg><!--opt, face detection algorithm capability-->
<FaceDetectList size=""><!--opt, face detection algorithm capability list-->
<FaceDetect><!--opt-->
<eventType opt="abnormalFace,normalFace,multiFace,sunglassesFace,callFace"/>
<!--"abnormalFace"-abnormal face, "normalFace"-normal face, "multiFace"-multiple faces, "sunglassesFace"-
face with sunglasses, "callFace"-face on the phone-->
<sensitivity min="1" max="5" default="3"/><!--sensitivity-->
<duration min="30" max="1800" default="60"/>
<!--triggered time threshold of face alarm, unit: second-->
</FaceDetect>
</FaceDetectList>
</FaceDetectAlg>
</AlgParam>
<NotDisplayDefaultDetectRegion><!--The rule configuration will not display the default detection range. It is
mainly used to determine the compatibility of iVMS-4200--></NotDisplayDefaultDetectRegion>
</FaceDetect>
<FaceSnap><!--face capture-->
<snapTime min="0" max="10" default="5"/><!--capture times-->
<snapInterval min="0" max="255" default="24"/><!--capture interval, unit: frame-->
<snapThreshold min="0" max="100" default="80"/><!--capture threshold-->
<generateRate min="1" max="5" default="3"/><!--target generating rate-->
<sensitivity min="1" max="5" default="5"/><!--sensitivity-->
<referenceBright min="0" max="100" default="80"/><!--reference brightness-->
<matchType opt="alarmRealtime,alarmAfterDisappear" default="alarmRealtime"/>
<!--comparison alarm mode: "alarmRealtime"-real-time alarm, "alarmAfterDisappear"-alarm after the target
disappears-->
<matchThreshold min="0" max="100" default="80"/>
<!--real-time comparison threshold-->
<JpegParam>
<picSize><!--picture size--></picSize>
<picQuality opt="best,better,normal"/><!--picture, "best", "better", "normal"-->
</JpegParam>
<RuleEntryList>
<maxRuleNum><!--maximum number of rules--></maxRuleNum>
<RuleEntry>
175
Device Network SDK (People Counting) Developer Guide
<SizeFilter>
<mode opt="imagePixel,realWorld,default" default="imagePixel"/>
<!--filter mode, "imagePixel"-by pixel size, "realWorld"-by actual size, "default"-->
<minRect><!--minimum target frame--></minRect>
<maxRect><!--maximum target frame--></maxRect>
<PupillaryDistance><!--pupil distance limit-->
<width min="" max=""/><!--width limit-->
</PupillaryDistance>
</SizeFilter>
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
</RuleEntry>
<autoROI opt="false,true"/>
<!--whether to enable automatic face ROI switch: "false"-no, "true"-yes-->
</RuleEntryList>
<faceExposure opt="false,true"/>
<!--whether to enable face exposure: "false"-no, "true"-yes-->
<faceExposureMinDuration min="" max=""/><!--minimum face exposure duration-->
<backgroundPic opt="open,close"/>
<!--req, whether to enable uploading background picture: "open"(default), "close"-->
<faceFilteringTime min="" max="" default="">
<!--opt, face dwell time filter, ranges from 0 to 100, the default value is 5-->
</faceFilteringTime>
<isSupportMultiScene opt="true,false">
<!--opt, xs:boolean, whether to support face multi-scene configuration-->
</isSupportMultiScene>
<FaceContrast>
<!--opt, face comparison-->
<enabled opt="false,true"/>
</FaceContrast>
<brokenNetHttp><!--opt, whether to support ANR--></brokenNetHttp>
</FaceSnap>
<SnapDevAccess><!--capture access parameters-->
<devIP opt="ipv4,ipv6"/><!--IP address-->
<devPort min="8000" max="65535"/><!--port-->
<usernameLength min="0" max="32"/><!--username length-->
<passwordLength min="0" max="16"/><!--password length-->
</SnapDevAccess>
<SavePathCfg><!--storage path parameters-->
<partitionNum><!--number of partitions--></partitionNum>
<SinglePath>
<type opt="snapFace,blacklistAlarm,snapFaceAndBlacklistAlarm" default="snapFaceAndBlacklistAlarm"/>
<!--storage type: "snapFace"-capture face, "blacklistAlarm"-blocklist alarm, "snapFaceAndBlacklistAlarm"-capture
face and blocklist alarm-->
<saveAlarmPic><!--whether to support saving offline alarm picture--></saveAlarmPic>
<diskDriver min="0" max="32"/><!--disk driver symbol-->
<reservedSpace min="10" max="20" default="10"/><!--reserved space, unit: G-->
</SinglePath>
</SavePathCfg>
<MaskRegion><!--shielded region-->
<maxRegionNum><!--number of regions--></maxRegionNum>
176
Device Network SDK (People Counting) Developer Guide
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
</MaskRegion>
</Face>
<VQD><!--video quality diagnostics-->
<VQDEventType
opt="blur,luma,chroma,snow,streak,freeze,signalLoss,ptzControl,sceneChange,videoAbnormal,videoBlock"/>
<!--"blur"-blurred image, "luma"-brightness exception, "chroma"-color cast, "snow"-snow noise, "streak"-stripe
noise, "freeze"-frame freezing, "signalLoss"-signal loss, "ptzControl"-uncontrollable PTZ, "sceneChange"-sudden scene
change, "videoAbnormal"-video exception, "videoBlock"-video tampering-->
<VQDRule>
<EventParam>
<threshold min="0" max="100"/><!--alarm threshold-->
<triggerMode opt="continuous,single"/>
<!--alarm triggering mode: "continuous"-continuous triggering, "single"-single triggering-->
<uploadPic opt="false,true"/><!--upload alarm picture-->
<timeInterval min="0" max="3600" default="120"/>
<!--time interval of continuous alarm triggering, unit: second-->
</EventParam>
<AlarmTime>
<timeSegNum min="2" max="8"/><!--number of arming period per day-->
</AlarmTime>
<alarmHandleType opt="monitor,audio,center,alarmout,picture,wirelesslight,uploadftp"/>
<!--"monitor"-warning on the monitor, "audio"-audible warning, "center"-notify surveillance center, "alarmout"-
trigger alarm output, "picture"-capture JPEG picture and send by email, "wirelesslight"-wireless light and audio alarm,
"uploadftp"-capture picture and upload to FTP-->
<relRecordChan><!--alarm triggered channel recording--></relRecordChan>
</VQDRule>
<downloadAlarmPic><!--download VQD alarm picture--></downloadAlarmPic>
</VQD>
<ObjectColor><!--object color-->
<objectType opt="coat"/><!--object type,"coat"-->
<colorMode opt="value,picture" default="value"/>
<!--coloring mode: "value"-color value, "picture"-->
<colorValue>
<brightness min="0" max="255"/><!--brightness-->
<saturation min="0" max="255"/><!--saturation-->
<hue min="0" max="255"/><!--hue-->
</colorValue>
<colorPicture>
<picType opt="jpg"/><!--picture type-->
<picWidth min="100" max="400"/><!--picture width-->
<picHeight min="100" max="300"/><!--picture height-->
</colorPicture>
</ObjectColor>
<AuxArea><!--auxiliary region-->
<maxAreaNum><!--number of regions--></maxAreaNum>
<areaType opt="overlapRegion,bedLocation"/>
<!--region type, "overlapRegion"-common region, "bedLocation"-bed location-->
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
177
Device Network SDK (People Counting) Developer Guide
</Region>
</AuxArea>
<BaselineScene><!--baseline scene-->
<operation opt="update"/><!--operation, "update"-->
<downloadBaselineScenePic><!--download baseline scene picture--></downloadBaselineScenePic>
</BaselineScene>
<channelWorkMode opt="independent,master,slave"/>
<!--channel working mode: "independent"-independent mode, "master"-master mode, "slave"-slave mode-->
<SlaveChannel><!--slave channel-->
<maxChanNum><!--maximum number of slave channels--></maxChanNum>
<chanType opt="local,remote"/>
<!--slave channel type: "local"-local device channel, "remote"-remote device channel-->
<RemoteChannel><!--remote channel-->
<devAddress opt="ipv4,ipv6,domainName"/>
<!--address type: "ipv4"-IPv4, "ipv6"-IPv6, "domainName"-device domain name-->
<devPort min="8000" max="65535"/><!--port-->
<userNameLength min="0" max="32"/><!--username length-->
<passwordLength min="0" max="16"/> <!--password length-->
<channelNumber><!--channel No.--></channelNumber>
</RemoteChannel>
</SlaveChannel>
<VcaKeyParam>
<!--VCA algorithm library keyword parameter, the default type is integer currently, other types such as float and
string need extra APIs-->
<!--translation suffix explanation: "cn"-Chinese, "en"-English-->
<VcaKeyParamEntry>
<index><!--keyword index value--></index>
<PlainText>
<translationCn><!--Chinese name--></translationCn>
<translationEn><!--English name--></translationEn>
</PlainText>
<value min="1" max="100" default="50"/><!--value range-->
</VcaKeyParamEntry>
<VcaKeyParamEntry>
<index><!--keyword index value--></index>
<PlainText>
<translationCn><!--Chinese name--></translationCn>
<translationEn><!--English name--></translationEn>
</PlainText>
<value min="1" max="100" default="50"/>
</VcaKeyParamEntry>
<VcaKeyParamEntry>
<index><!--keyword index value--></index>
<PlainText>
<translationCn><!--Chinese name--></translationCn>
<translationEn><!--English name--></translationEn>
</PlainText>
<value min="1" max="100" default="50"/>
</VcaKeyParamEntry>
</VcaKeyParam>
<SwitchLamp>
<enabled opt="true,false"/>
178
Device Network SDK (People Counting) Developer Guide
<triggerMode opt="continue,once"/>
<!--req, triggering mode: "continuous"-continuous triggering, "single"-single triggering -->
<timeInterval min="0" max="3600" default="120"/>
<!--req, time interval of continuous alarm triggering, unit: second-->
<uploadPic opt="false,true"/><!--req, upload alarm picture-->
<AlarmTime>
<timeSegNum min="2" max="8"/>
<!--req, number of arming period per day-->
</AlarmTime>
<alarmHandleType opt="monitor,audio,center,alarmout,picture,wirelesslight,uploadftp"/>
<!--"monitor"-warning on the monitor, "audio"-audible warning, "center"-notify surveillance center, "alarmout"-
trigger alarm output, "picture"-capture JPEG picture and send by email, "wirelesslight"-wireless light and audio alarm,
"uploadftp"-capture picture and upload to FTP-->
<relRecordChan><!--req, alarm triggered channel recording--></relRecordChan>
</SwitchLamp>
<FaceCaptureStatistics><!--req, face capture statistics-->
<isSupportStartTime>true</isSupportStartTime>
<reportType opt="daily,weekly,monthly,yearly"/><!--req, report type-->
<statType opt="age,gender,numberOfPeople"/><!--req, statistics type-->
</FaceCaptureStatistics>
<ColorFilter><!--req, color filter>
<enable opt="true,false"/>
<ruleID min="" max=""/>
<sequenceNo min="" max=""/>
<PicInfo>
<picType opt="jpg"/>
<width>true</width>
<height>true</height>
<picDataLen min="" max=""/>
</PicInfo>
</ColorFilter>
<HumanRecognition><!--human recognition capability-->
<MaskRegion><!--shielded region-->
<maxRegionNum><!--number of regions--></maxRegionNum>
<Region>
<vertexNum min="3" max="10"/><!--number of region vertexes-->
</Region>
</MaskRegion>
</HumanRecognition>
<AtmCabinKeyParam><!--ATM safety cabin key parameters>
<VcaKeyParam>
<VcaKeyParamEntry>
<index><!--index No. of limitation on the number of people of violent motion alarm--></index>
<PlainText>
<translationCn>limitation on the number of people of violent motion alarm</translationCn>
<!--Chinese name-->
<translationEn>limitation on the number of people of violent motion alarm</translationEn>
<!--English name-->
</PlainText>
<value min="0" max="32" default="2"/>
</VcaKeyParamEntry>
<VcaKeyParamEntry>
179
Device Network SDK (People Counting) Developer Guide
180
Device Network SDK (People Counting) Developer Guide
Appendix D. Appendixes
General Errors
181
Device Network SDK (People Counting) Developer Guide
182
Device Network SDK (People Counting) Developer Guide
183
Device Network SDK (People Counting) Developer Guide
184
Device Network SDK (People Counting) Developer Guide
185
Device Network SDK (People Counting) Developer Guide
186
Device Network SDK (People Counting) Developer Guide
187
Device Network SDK (People Counting) Developer Guide
188
Device Network SDK (People Counting) Developer Guide
189
Device Network SDK (People Counting) Developer Guide
190
Device Network SDK (People Counting) Developer Guide
191
Device Network SDK (People Counting) Developer Guide
192
Device Network SDK (People Counting) Developer Guide
193
Device Network SDK (People Counting) Developer Guide
194
Device Network SDK (People Counting) Developer Guide
195
Device Network SDK (People Counting) Developer Guide
196
Device Network SDK (People Counting) Developer Guide
197
Device Network SDK (People Counting) Developer Guide
198
Device Network SDK (People Counting) Developer Guide
199
Device Network SDK (People Counting) Developer Guide
200
Device Network SDK (People Counting) Developer Guide
201
Device Network SDK (People Counting) Developer Guide
202
Device Network SDK (People Counting) Developer Guide
203
Device Network SDK (People Counting) Developer Guide
204
Device Network SDK (People Counting) Developer Guide
205
Device Network SDK (People Counting) Developer Guide
206
Device Network SDK (People Counting) Developer Guide
207
Device Network SDK (People Counting) Developer Guide
208
Device Network SDK (People Counting) Developer Guide
209
Device Network SDK (People Counting) Developer Guide
210
Device Network SDK (People Counting) Developer Guide
211
Device Network SDK (People Counting) Developer Guide
212
Device Network SDK (People Counting) Developer Guide
213
Device Network SDK (People Counting) Developer Guide
214
Device Network SDK (People Counting) Developer Guide
215
Device Network SDK (People Counting) Developer Guide
216
Device Network SDK (People Counting) Developer Guide
217
Device Network SDK (People Counting) Developer Guide
218
Device Network SDK (People Counting) Developer Guide
219
Device Network SDK (People Counting) Developer Guide
220
Device Network SDK (People Counting) Developer Guide
221
Device Network SDK (People Counting) Developer Guide
222
Device Network SDK (People Counting) Developer Guide
223
Device Network SDK (People Counting) Developer Guide
StatusCode=1
224
Device Network SDK (People Counting) Developer Guide
StatusCode=2
StatusCode=3
225
Device Network SDK (People Counting) Developer Guide
226
Device Network SDK (People Counting) Developer Guide
227
Device Network SDK (People Counting) Developer Guide
228
Device Network SDK (People Counting) Developer Guide
StatusCode=4
229
Device Network SDK (People Counting) Developer Guide
230
Device Network SDK (People Counting) Developer Guide
231
Device Network SDK (People Counting) Developer Guide
232
Device Network SDK (People Counting) Developer Guide
233
Device Network SDK (People Counting) Developer Guide
234
Device Network SDK (People Counting) Developer Guide
235
Device Network SDK (People Counting) Developer Guide
236
Device Network SDK (People Counting) Developer Guide
237
Device Network SDK (People Counting) Developer Guide
238
Device Network SDK (People Counting) Developer Guide
239
Device Network SDK (People Counting) Developer Guide
240
Device Network SDK (People Counting) Developer Guide
241
Device Network SDK (People Counting) Developer Guide
242
Device Network SDK (People Counting) Developer Guide
243
Device Network SDK (People Counting) Developer Guide
244
Device Network SDK (People Counting) Developer Guide
245
Device Network SDK (People Counting) Developer Guide
246
Device Network SDK (People Counting) Developer Guide
247
Device Network SDK (People Counting) Developer Guide
248
Device Network SDK (People Counting) Developer Guide
249
Device Network SDK (People Counting) Developer Guide
250
Device Network SDK (People Counting) Developer Guide
251
Device Network SDK (People Counting) Developer Guide
252
Device Network SDK (People Counting) Developer Guide
253
Device Network SDK (People Counting) Developer Guide
254
Device Network SDK (People Counting) Developer Guide
StatusCode=5
StatusCode=6
255
Device Network SDK (People Counting) Developer Guide
256
Device Network SDK (People Counting) Developer Guide
257
Device Network SDK (People Counting) Developer Guide
258
Device Network SDK (People Counting) Developer Guide
259
Device Network SDK (People Counting) Developer Guide
260
Device Network SDK (People Counting) Developer Guide
261
Device Network SDK (People Counting) Developer Guide
StatusCode=7
262