[Custom component] Hikvision NVR / IP Camera

I would like to share an integration for Hikvision devices hikvision_next.

Initially it comes with following features:

  • Real-time Acusense events notifications through binary sensors
  • Switches for Acusense events detection
  • Holiday mode switch (allows to switch continuous recording with appropriate NVR setup)
  • Tracking Alarm Server settings for diagnostic purposes
  • Basic and digest authentication support

more info you’ll find in the readme.
It would be great if you check it with your devices.
I’m waiting for your feedback, please include devices model as well.

Distinguish from existing hikvision integration, this one listens for alarm events instead of pulling periodically, that’s why I decided write another one from scratch.

6 Likes

Hi,

I’ve been looking at AcuSense cameras. Does your add on expose object detection, eg human & car?

Hi,
Sure, as far that integration supports 4 AcuSense events:

  • Intrusion (human and vehicle)
  • Line Crossing
  • Region Entrance
  • Region Exiting

and other, see readme for details

1 Like

Thanks for that.

Also, on a camera such as the 2CD2386G2-ISU/SL, do you think it would be possible to trigger/expose things such as the cam ‘strobe light’ and ‘speaker’ within HA?

Hm, you are second person who asks about that feature in last days. Yes it’d possible with hikvision_next and additional automation, see my reply here Add support for smart motion detection events in 'hikvisioncam' component - #10 by maciej-or

Hi,
I’ve set up the integration through HACS and can see my NVR & Cameras listed.

I’m able to toggle the camera controls (Motion / line crossing) and have checked has activating in the NVR software, however the sensors don’t appear to reactivate to events.

The events are showing in the Hik-Connect and through the standard HA hikvisioncam intergration (using the same login details)

Is there anything obvious that might be stopping the events coming through?

NVR : DS-7616NXI-I2/16P/S
Cameras : DS-2CD2387G2-LU

Thanks.

Hi,
It seems you have not Alarm Server configured properly. See Diagnostic section at device info of NVR.
IP and port should point your HA instance.

Alarm Server can be set up in adding device dialog (check Set alarm server using following address and fill input below)

or you can set it in NVR / IP Camera admin panel:

NVR and HA must be in the same network. If cameras are connected to NVR it’s enough to setup Alarm Server at NVR. If cameras are standalone Alarm Server has to be setup on each.

1 Like

That’s great, and makes sense, thanks.

I think when I first set it up the alarm server wasn’t fully working.

All working now and seems to be quicker than the hikvisioncam sensors.

Please tell me, I installed it, but the movements on the cameras are not displayed. Sensors do not change their state. Does my recorder model not fit? I have DS-7616NI-K2.


2023-05-19_141726

hi, your model should work. As far NVR admin panel doesn’t allow to setup alaram server ip, I explained that here Alarm server IP · Issue #23 · maciej-or/hikvision_next · GitHub
If events don’t come into HA pls check all requirements GitHub - maciej-or/hikvision_next: Home Assistant integration for Hikvision NVRs and IP cameras
If it wont work report an issue in github repo.

I just managed to setup the Hikvision_next Integration and pointed it to my NVR DS-7608NI-I2/8P this registers 1 device and 5 entities.
Now my 4 cameras are on a NAT connected to the NVR should they be detected automatically?

Or do I need to add them separately using the sub stream url?

edit:
I found this in the logs after reloading the integration

2023-06-06 19:25:40.964 WARNING (MainThread) [custom_components.hikvision_next.isapi] No device identifier provided: Garage
2023-06-06 19:25:40.966 WARNING (MainThread) [custom_components.hikvision_next.isapi] No device identifier provided: Entry
2023-06-06 19:25:40.968 WARNING (MainThread) [custom_components.hikvision_next.isapi] No device identifier provided: Stairs Deck
2023-06-06 19:25:40.971 WARNING (MainThread) [custom_components.hikvision_next.isapi] No device identifier provided: Back Garden

It would be great if controls for the camera spotlights could be added.

HA and NVR must be in the same network and cameras should be added during setup.
Warnings are expected, nothing serious.

Controlling cameras LEDs is submitted Feature Request: Switch for the white ColorVU LED on cameras · Issue #16 · maciej-or/hikvision_next · GitHub, we don’t miss that :wink:

1 Like

add my debug logs to Not detecting camera · Issue #54 · maciej-or/hikvision_next · GitHub

Not sure what Im doing wrong, but when I fill in the data to install the integration, so NVR IP, user, psw I created on NVR specifically for HA and HA address, I have a message “not all mandatory data are filled in” (translation from Italian). Any idea? thanks

Loving this integration so far, it’s fantastic and drastically improved my setup, thanks!

Im trying to differentiate between each of the 4 line crossings available as by default this only exposes ‘Line Crossing’ as a singular sensor, how do I add a sensor for each of the defined line crossings?

Thanks!

1 Like

Thanks for pointing that. I’ve added this feature to enhancements list.

2 Likes

Good job @maciej-or
But one big problem is that motion detection no working for me and more users.
I use NVR DS-7616NXI-K2 FW: 4.76.005

I have no access to models with K2 suffix, it seems they send notifications in a bit different format. Logs are only way to help me with eventual fix. Please attach them in github issues.