Hikvision Doorbell / Videointercom integration

Hi, do you have an indoor device? You need something to call… In case of no indoor station and no hikconnect, you will have calling failed, so that’s normal indeed.

You can still enable hikconnect, but in hikconnect itself disable the incoming notification

Or you need to setup SIP

Hi, thank you for your prompt answer. No, I don’t have any indoor device, as I have a homepod mini, I use it as a chime when someone push the call button. Okey interesting, I don’t know the SIP option, I guess i’ll take a look to see how it works. Anyway, after blocking internet access of the device, it stopped working after it detected that it has gone offline. So as you said SIP obliged. Thank you very much.

1 Like

How to send an isapi command and where will the response come? Thank you.

Hey, for every device, there is an “isapi request”, but its disabled by default, just enable it

image

Afterwards, you can use the service below to send for example an isapi command

For example

service: text.set_value
data:
  value: GET /ISAPI/VideoIntercom/callSignal/capabilities?format=json
target:
  entity_id:
    - text.ds_kd8003_isapi_request
    - text.ds_kh9510_isapi_request

Enable DEBUG on the addon, then you see the responses in the log

log_level: DEBUG
sdk_log_level: DEBUG

Or you can see if you receive a valid response, an attribute

If you also need to send a payload, some isapi commands request it, the string needs to be like below in the service…

PUT /ISAPI/VideoIntercom/callSignal?format=json {"CallSignal":{"cmdType":"reject"}}

Hello,

First of all, my apologies if this topic was discussed earlier. I have been searching in the thread and haven’t found anything relevant.

A few days ago, I found this firmware for DS-KV6113-WPE1(B) doorbell model. If you go back to the Home menu, you can browse the whole repository, which contains a lot of tech docs and firmware versions that cannot be found in the standard end-user websites.

The thing is that such firmware version fixes the front device’s green LED behaviour. Such LED was supposed to light upon opening a gate relay. On previous and “official” version V2.2.53_220602 (the latest available in Hikvision website), the green LED was always lit. Now, the green lights when it should. But, more important, the new version sends a photo to the App, which it is displayed as an event and kept there, so if you have a missed call, you can see such photo. This was not possible until now, at least with my model:

Both features are not listed in the release notes. Is there a way to fetch such photo without using any other thing? Currently, I get photos and clips through Frigate, but it would be great for the addon to be able to get such image through an image or camera entity, for example, so it can be handled for automations, dashboard, etc. I have been Googling but I haven’t found any information about it, just the usual info to get a photo manually through an ISAPI command.

I am not sure whether this photo capture is handled by the doorbell or the Hik-Connect App itself, so I am not actually sure whether it is possible to do this, but it was worth it to ask. :slight_smile:

Thanks!

Hi , no there is no camera/picture entity in the add-on, don’t think mqtt is good for that, I don’t think it supports video at all… Best to use the rtsp stream

1 Like

Hello fabio,

i am new to this topic have the Hikvision DS-KV9503-WBE1 and want to integrate it with curl/php.

do you have any idea how?

thank you chris

Hi , i dont know that device, but in first post of this thread, you will see some example commands based on curl
btw; why not using the addon? have you tried it? SDK is always better then curl/php , its faster since its based on events and not polling

Hi fabio. because i dont use HA. i use another SmartHome System in php (Ip-Symcon).

i read almost the full thread. you are doing a great job!

thnx!

Well you can use also the docker image, it can run as standalone, you dont need HA… Mqtt is needed
See here:

1 Like

Okay I can’t figure out where I am going wrong and need some help.

Set-up:

  • DS-KH6320
  • DS-KD8003
  • Homeassistant running in Docker

Steps taken:

  • Frigate running in a docker container
  • MQTT running in a docker container
  • I am running the add-on in a docker container
  • I upgraded the go2rtc to the newest version
  • I added the go2rtc rtsp and isapi streams to my frigate docker config
  • I configured the development.env file with the path to the outside and inside units
  • I installed the frigate integration and it picks up my outside unit
  • I got HA to talk to the indoor and outdoor units using MQTT
  • I installed the lovelace card and configured it

Now I am getting a live stream from my doorbell camera and I can see the clips from the persons it detects. So that is all working.

In MQTT all the controls are in blue and I managed to decline a call by pressing ‘Hangup call’ on my indoor station. So it seems to be properly linked. But it doesn’t work in the lovelace card and I can’t get two way audio to work.

I enabled ISAPI request but that stays on ‘unknown’. Also ‘Call state’ remains unavailable on the outdoor unit.

So it seems I did something wrong or forgot something but I can’t figure out what exactly.

Have you tried stopping the docker, delete the mqtt integration, then start again?

Would it be possible to get a different state for the call_state sensor when the doorbell is on a call? Currently (at least with my DS-KV6113-WPE1(B)), the idle state is “idle”. When someone pushes the doorbell button, such state changes to “ringing”. However, if the call is picked up, state stays on “ringing”, rather than “on_call” or something similar. I checked the relevant MQTT topic state hmd/sensor/Doorbell/Call-state/state and it is updated in the same way.

Thanks!

Hi, thats correct, the SDK doesnt provide the “on_call” event, thats why we dont update the sensor state… we only see ringing/dismissed events

However, in the last addon update .14, i added an extra button, if you press on it it sends an ISAPI command, maybe you can poll that one x amount of seconds with an automation when you see an ringing event?
That call info button should give more details like “on_call” etc …

1 Like

I will try that. Thank you!

1 Like

Hi, I’m using the add-on and it works very well… but after the last update, my automations for employee face recognition stopped triggering. I read the change log that “now the employee is an attribute” but I think it does not affect the automation because I didn’t see any change in the trigger settings. Can you please help me? This is my yaml code:

trigger:
  - platform: device
    domain: mqtt
    device_id: xxxxxxxxxxxx
    type: face_verify
    subtype: employee_id_3
    discovery_id: FrontDoor ACS-Face-Employee-3

Yeah, it does effect that specific automation, there is only 1 topic now, no different subcategorys as before… The employee id is now an attribute

You should see now 1 common topic…
Can you as a test delete the mqtt device and restart add-on, that should clear the old topics

Here is an example, you can use payload too in the automation:

As your proposal remove the device and restart. The employee trigger disappears and unfortunately this doesn’t work. I will reed the mqtt option and hope to have success.

Yes, there is only 1 device trigger now, only the payload is different, that payload contains the employee id… You can use it normally in the device trigger automation

You can look with mqtt explorer to see the payload

1 Like

How to do this ?

First of all, check if ISAPI already works, you can expose/enable port 1984 in the Frigate Add-on, afterwards you can surf to to [http://mylocalip:1984](http://mylocalip:1984/) You should see the camera there, with also a "links" command, click on it, at the bottom you should see: "video+audio+microphone = two way audio from camera"

Do I have to install the go2rtc addon from Alexii or not? If I do not install it at myip:1984 I get ERR_CONNECTION_REFUSED

If I install the go2rtc addon when I go to myip:1984, I get this

Screenshot 2024-01-25 233746

my frigate.yml config


go2rtc:
 # streams:
 #   test_cam: ...
  webrtc:
    candidates:
      - 192.168.1.12:8555
      - stun:8555
  streams:
    door12n:
      - rtsp://admin:[email protected]:554/Streaming/Channels/102
      - isapi://admin:[email protected]:80/
    door14n:
      - rtsp://admin:[email protected]:554/Streaming/Channels/102
      - isapi://admin:[email protected]:80/