Amcrest video doorbell AD110 initial impressions

Here is what they said

We do not have separate API document for AD110
http://mycam:80/cgi-bin/configManager.cgi?action=setConfig&MotionDetect[0].Enable=true

Tried this ?

http://mycamera/cgi-bin/configManager.cgi?action=getConfig&name=MotionDetect[0].Enable

Ok, thanks Dave. MotionDetect[0].Enable is the normal config other Amcrest/Dahua cameras use. This is NOT what the SmartHome app toggles though. The app leaves this enabled true all the time and instead toggles Alarm[0].Enable. It may accomplish the same thing, but for the doorbell, I doubt it.

Their reply does seem to indicate that even Amcrest Support isn’t fully aware of how the API on this doorbell works and is referring to older API documentation for you to try.

Ding or dong, vs ding/dong… could be many reasons for that. 1) wired to the backdoor terminals that only ding, no dong. 2) Chime is mounted upside down so gravity doesn’t bring the hammer down for a dong. 3) bell unit is mechanically broken. 4) the chime kit is switching too slow, which might slow the gravity falling of the hammer, muting the dong after a ding. The former 3 issues are easy to see/fix. The latter would require an o-scope and additional circuitry to see/fix.

Hey guys, ive managed to integrate amcrest doorbell in HA
I look at the stream and it lags 10-15 seconds from real time? why is it so?

in vlc rtsp - its all good

i tried to input the following code of yours to my configuration.yaml

camera:
 - platform: ffmpeg
    input: !secret rtsp
    extra_arguments: '-filter:v crop=1280:720:474:360'
    name: "Amcrest Doorbell"  

and i get following error:

bad indentation of a mapping entry at line 118, column 10:
        input: .secret rtsp
             ^

Unless we can safely change iFrame interval and/or frame rate in the AD110, I think we are stuck with the lag with STREAM enabled. It’s a complicated dance in how Stream works that I can’t explain other than to refer comments made by the head developer of Stream.

You may find this post interesting as it contains a detailed review of several different camera integrations with, and without stream enabled. Also note the reply from the developer, hunterjm.

BTW - we do know that it is possible to modify AD110 video configurations via the API, but one guy who tried it confirmed it worked, but then his AD110 died shortly after. It could have been due to overheating the CPU with the different settings, or it could have been coincidental.

Coming in the next .115 update are significant improvements to Stream (such as adding audio). I did not see in the PR’s anything related to lag improvements though.

All 3 fields must line up directly with “platform”…

camera:
 - platform: ffmpeg
   input: !secret rtsp
   extra_arguments: '-filter:v crop=1280:720:474:360'
   name: "Amcrest Doorbell"  

Also, you do not need the “extra_arguments” that I showed in my early example. This was just an example of how to crop an image when snapshots are taken.

Thanks for reply, it has a lot of info.
so you mean you have the same lag at yours?

The lag on my AD110 varies from about 8 to 13 seconds via HA stream. It’s not great. It’s also not a unique issue to the doorbell camera as you can see from the referenced post.

Via VLC, it’s 1-2 seconds.

ive made similar integration as you did, the lag remains, yeah and vlc is faster on pc.
Maybe there is a way to change from ffmpeg to other stream, or it is default and no options?
if i connect a hikvision camera to HA ill have same 10-15s lag?

also how did you make snapshots sent using telegram?

I think it is how the stream integration works. It uses HLS which takes in chunks of video before it sends it along.

From the Stream integration page:

The integration currently only supports proxying H.264 source streams to the HLS format

Here is a StackOverflow about it. https://stackoverflow.com/a/23924558

Typical delay in HLS is 30-60 sec, minimum in practice is around 15 sec.

In the post I referred you to, the author was using Hikvision cameras. You can see all the variations he tried with and without Stream enabled and the effect it had on video lag. He was also seeing ~13 sec lag with Hikvision/Stream.

I also refer you to this reply from the developer on tweaks that should help…

Those tweaks can be done via the Hikvision camera web UI, but since I don’t have these cameras, I can’t offer any other advice on what to try.

Correct - it’s how Stream works with HLS/H.264 processing. But as mentioned before, there are tweaks that can be done to improve/optimize this processing.

What’s unknown at this point is what can be done to optimize the AD110 “safely” via the API.

I’ll also point out that I saw one of the PR’s to Stream in HASS .115 was to support the next generation format - HEVC H.265. This is a more efficient video format that should really help - if the browser and/or device supports it.

EDIT: H.265 turns out to not be very practical at this time unless you are only going to use the Safari browser or Edge/IE with hardware support for H.265. No other browsers support it. Doubtful it would have much effect on reducing lag in any case.

Had another reply re IR issue the email states

What firmware version is your unit currently on? (already told them this) I believe that our team is working on an update to fix this issue was I have noticed an increase in this IR problem occurring. As of now, I don’t have an ETA as to when it will be released however from what I was told the update is in the final testing stages.

Will let you know if I hear more.

Re Dave

For anyone interested, here’s how to toggle the AD110 blue button indicator light . The code below creates a switch that can be used in automations. It will also reflect the current state of the light. The SmartHome app’s “Device Indicator” switch will also automatically update and reflect the current on/off status.

switch:
  - platform: command_line
    switches:
      doorbell_indicator_light:
        command_on:    '/usr/bin/curl -s --digest -u admin:password "http://192.168.xx.xx/cgi-bin/configManager.cgi?action=setConfig&LightGlobal[0].Enable=true" '
        command_off:   '/usr/bin/curl -s --digest -u admin:password "http://192.168.xx.xx/cgi-bin/configManager.cgi?action=setConfig&LightGlobal[0].Enable=false" '
        command_state: '/usr/bin/curl -s --digest -u admin:password "http://192.168.xx.xx/cgi-bin/configManager.cgi?action=getConfig&name=LightGlobal[0].Enable" | grep -oPc "true" ||true'
        value_template: '{{ value == "1" }}'

Does anyone else have an issue with the SmartHome app “Call Notification” turned off, not actually turning off push notifications from doorbell/motion alerts?
(Running 200702 firmware, not the newest 200828 that was retracted).
Thanks.

.
I just wrapped up dealing with Amcrest over my defective AD110 today, they finally agreed to replace it.

I simply cannot get the Amcrest app to stream video while RTSP is being sent to Node-RED… they of course started by pointing the finger at my transformer, to which I did upgrade, but it didn’t help.

Hopefully a replacement works 100%

Thanks, this is great, one step closer to getting that elusive button press!

Using your commands was able to turn on/off the ring light, but I haven’t been able to disable motion detection. It doesn’t error or anything just stays showing as ‘off’ in HA, but continue to get alerts.
I must be doing something wrong there I guess…

What version of AD110 firmware are you on @Snozzle ? Amcrest changed the way motion detection/alarm was handled in the most recent firmware update (which has since been recalled and is no longer avail.)

EDIT: Would you also please let me know if turning off “Call Notification” in the SmartHome app turns off push notification alerts to your phone? It’s supposed to, but it’s not working for me. I was hoping to find out if it was a wider issue which may depend on firmware version.

Anyone know the command to turn off night vision on the doorbell? As long as it’s off, my doorbell is stable but last night, it turned itself back on. Update, reboot, I have no idea. I figure a periodic command to keep it shut off is the solution…