Hikvision get data of leave and enter fields

Joined
May 30, 2016
Messages
3
Reaction score
0
Hello!
I am using Hikvision model ids-2cd6412fwd/c.
I want to get data of fields leave and enter in any time through an api or whatever else. These data is in the upper right corner of the camera's video.
The problem is that I haven't found the way to do it in documentation.
Does anybody know or has the idea how to do it?
 
Joined
May 30, 2016
Messages
3
Reaction score
0
Thanks a lot for answer!
It helped, but this number of people entered and left is updated in that report not immediately.
What I was interested if I can take the values that are shown in the video. They are updated immediately.
Or maybe not exactly that numbers, but notification about the event of people entered or left.
 

wzhick

Pulling my weight
Joined
Dec 29, 2014
Messages
60
Reaction score
144
use "Data statistics cycle" value to set period for request.
 

Adnand

n3wb
Joined
Dec 13, 2016
Messages
2
Reaction score
0
Hi,
am getting this xml content for the same problem


<?xml version="1.0" encoding="UTF-8" ?>
<ResponseStatus version="2.0">
<requestURL>
/ISAPI/System/Video/inputs/channels/101/counting/search
</requestURL>
<statusCode>
3
</statusCode>
<statusString>
Device Error
</statusString>
<subStatusCode>
deviceError
</subStatusCode> </ResponseStatus>
 

BenskiBoy

n3wb
Joined
Dec 12, 2018
Messages
1
Reaction score
0
Location
Melbourne Australia
@Adnand has probably been solved his issue but I'll leave this here for anyone else who has this problem in the future as I just spent half a day trying to get it working.

It's not made to clear elsewhere but you REALLY need to have a payload specifying the time range for the data you want otherwise you get the statusCode 3 error.

See below python 3 code snipet.
Note that the username and password fields needs to be URL encoded (URL Decoder/Encoder)

just remember to chang all instances of <ip_address> to the ip address of your camera.

---------------------------
import requests

url = "http://<user>:<password>@<ip_address>/ISAPI/System/Video/inputs/channels/1/counting/search"

payload = "<?xml version=\"1.0\" encoding=\"UTF-8\"?><CountingStatisticsDescription><reportType>daily</reportType><timeSpanList><timeSpan><startTime>2018-12-13T00:00:00</startTime><endTime>2018-12-13T23:59:59</endTime></timeSpan></timeSpanList></CountingStatisticsDescription>"
headers = {
'accept': "*/*",
'origin': "<ip_address>",
'x-requested-with': "XMLHttpRequest",
'if-modified-since': "0",
'user-agent': "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36",
'content-type': "application/x-www-form-urlencoded; charset=UTF-8",
'referer': "http://<ip_address>/doc/page/application.asp",
'accept-encoding': "gzip, deflate",
'accept-language': "en-AU,en;q=0.9",
'cookie': "language=en; language=en",
'cache-control': "no-cache"
}

response = requests.request("POST", url, data=payload, headers=headers)

print(response.text)
---------------------------
 

MrSman

n3wb
Joined
Jan 9, 2019
Messages
7
Reaction score
0
Location
Spain
Hi guys.
I have today a similar interest about this issue and I would like to know if someone have been able to invoque the ISAPI protocol calls using a Java Aplication. Is that possible to get a Hikvision Ip Camera data using Java? Thank you very much.
 

event-cam

n3wb
Joined
Jul 22, 2019
Messages
1
Reaction score
0
Location
Germany
Hi Guys, i have a few questions about this Topic.
First thing, how can i connect to the ISAPI Protocol from Hikvision, should i only download the "SDK for Linux"? I searched for the hole day and can't find any HowTo for installation.

Second thing, is it possible to readout easily the counting data in realtime from the iDS-2CD6810F/C over a script or something else? I would like to use a Raspberry PI for this setup.

I have the following environment: a Entrance around 7meters width and two counting cameras in a line. I would build a Skript that add both enter values and give back the result. At the Exit there is the same construction. They should give back at least one leave value. Then i need to set a maximum of 8000 people entered and give out an altert to stop the entrance.

Is this possible and can you help me with this?

Thanks for reply
 

Tolting Colt Acres

Pulling my weight
Joined
Jun 7, 2016
Messages
379
Reaction score
153
You can use curl to retrieve data through the ISAPI interface, and then parse the result. If you search here you'll find several Linux scripts which do just this to change settings dynamically based upon sunset.

I have no idea what the counting data is.
 

Corbieman

n3wb
Joined
Nov 1, 2022
Messages
1
Reaction score
0
Location
Czechia
Any possibility to get real time data from enter/leave fields with ISAPI? and not via search?
 
Top