People Counting
Syrus can communicate with people counting cameras in order to help you count the total number of people that have passed by a location and take actions over it.
General Overview
- The way it works is that you connect a compatible people counting camera
- Configure the camera to be on the same network as the Syrus
- Configure the Syrus with the IP address of the people counting camera
- Send the system tool command to enable the people camera
- Create the Syruslang script that takes actions and configures events based on people count
Installation / Wiring Diagrams
Dual-Lens People Counting Network Camera
The people counting camera connects to the Syrus via wifi, so we just need to install and setup the camera and then configure the Syrus to find it.
Camera Installation
In order to install the camera you can follow this guide.
Installation / Quick Start Guide
Guide: Hikvision DS-2CD6825G0
Use the user manual in order to connect the camera to your network: User Manual.
Set the IP
Once you have access to the web management UI go to the network settings and set a fixed IP address.
Set the destination IP and Port to one that's available in your network, here are the settings we used:
- IP: 192.168.0.63
- Port: 7070
- ANR: Enable
Enable People Counting
To enable the people counting on the camera, head to the VCA tab and select People Counting
People Counting Rules
Set up the people counting area to monitor underneath the camera.
- Enable People counting
- Select "Auto" in calibration
- Select the hexagonal icon in the left side of the preview and with the right button of the mouse build a square into the red square (this automatic build), click on left button to exit
- Click on the diagonal line button down the previous one to put the "enter" guideline, adjust the size to fit into the previously built square, the direction can be changed clicking on the two arrow button.
Add camera config on Syrus
Now you're ready to add the people counting camera to the Syrus via the Syrus Cloud video profile section.
The video profile saved will look like this:
{
"destination": "sd",
"reserved_percentage": 100,
"cameras": [
{
"type": "people_counting",
"name": "door_cam",
"mode": "on_demand",
"ip": "192.168.0.63",
"user": "admin",
"pass": "*********",
"resolution": "HD",
"codec": "H264",
"audio": false,
"uri": "rtsp://admin:*********@192.168.0.63:554/ISAPI/streaming/channels/101"
}
]
}
Enable people counting
Next, you should use the apx system tools to enable the people counting
# Enable people counting
$ apx-ndm-pc start
Use Syruslang to take actions
Now you can use Syruslang to build custom logic depending on different conditions.
# Timewindow from 08:00 to 17:00 (M-F)
define window working_hours
from=08:00:00 to=17:00:00 days=0,1,1,1,1,1,0
enabled=true state=false tz=America/NewYork
define action start_working [email protected]_hours.start
exec apx-ndm-pc start
define action end_working [email protected]_hours.end
exec apx-ndm-pc stop
exec apx-ndm-pc reset
define event ev_start group=tracking fieldset=default
[email protected]_hours.start
ack=seq label=strtwrk code=10
define event ev_stop group=tracking fieldset=default
[email protected]_hours.end
ack=seq label=endwrk code=11
Updated 5 months ago