Reolink NVR to Home Assistant Issue

Does this work with the pet/animal detection?

Would it just be: value_template: ‘{{ value_json[0].value.animal.alarm_state }}’?

I’ve added all these sensors I’m not getting any updates, it always shows clear. Any ideas?

1 Like

Not sure what they’re calling it (not running that firmware), try “pet” :man_shrugging:
I’ll update if I find anything.

hi @rjmcfadd
for the pet detection, it’s : value_json[0].value.dog_cat.alarm_state

1 Like

Thanks @tteck and @mnpg! I tried that but I’m not getting any motion events from any of the AI sensors.

Probably of use to anyone interested in this — Reolink just posted an updated guide to their API, at Reolink Camera API User Guide_V7 (Update in Sept 2022) | Reolink Community.

Of course, this method includes making a http request per sensor frequently — in the example given, every two seconds. It’d be nice of the NVR itself could trigger webhooks — or have native MQTT! (There is a request for such on their forum, but not much attention.)

Yeah, that’s rediculous. Most of the time that doesn’t work since the camera is too busy processing the detection and recording to reply back with the status. That’s why I think the reolink integration for HA is so unreliable. … Anyway MQTT would be the best, I already made a comment on their main ask customers what they want forum here: Get to Know Your Customers Day: Tell Us What You Want! | Reolink Community We just need to upvote it I guess :man_shrugging:

1 Like

Good news is that they are working on webhooks — a little buried but this comment indicates that they plan beta firmware for at least some cameras in the next couple of months.

Nice find, I saw your comment in there. Thanks for the vote-up. I also noticed there is a new Reolink integration that apparently fixes all the issues with reolink-dev. It’s here: GitHub - JimStar/reolink_cctv: Home Assistant Reolink NVR/cameras addon I tried it and it works really well for me!

1 Like

The problem with the sensor method is that you are querying the camera every 2 seconds and if you have 5 sensors that’s a lot of querying. I have 10 cameras which would result in 40 sensors checking urls every 2 seconds. On top of it, you are using http with a user and pass right in the url :slight_smile:
The new Reolink integration uses onvif so you actually get notifications pushed instead of constantly checking urls.

1 Like

Is this working for you for notifications? I turned on ONVIF on the NVR, but all of the various sensors are reporting Clear. They trigger on the app just fine.

Also video playback seems flaky – works occasionally, but usually stalls out. Tried all of the protocols – still image works best (except all of the downsides).

That integration also seems to do a bunch of “username and password right in the URL” too, though – seems like that’s the protocol.

I don’t have NVR so I connect directly to the cameras. I have 10 POE Reolink cameras and the notifications all do work if they are present in the Reolink app. I actually verified this against notifications in the app side by side as the previous Reolink_dev plugins missed about 60% of the notification.

What helped me a lot in clearing Auth errors in the log is moving the 2 sliders in the camera plugin config all the way to the right (something like timeout and subscription). RTSP stream works smoother for me so try that. I don’t think anything can be done about user and pass in the url as it’s how Reolink api works.

I always have had just okaish performance with any camera stream in HA, I think the issue is the size of the stream so it takes a while for it to actually connect and work. I had really good success with WebRTC Lovelace card by AlexxIT. But even with that having 10 cameras request WebRTC stream doesn’t give instant results. Again this is not related to the plugin as the plugin just provides the direct stream.

In Lovelace now I switched to use GitHub - dermotduffy/frigate-hass-card: A Lovelace card for Frigate in Home Assistant Card. You dont need Frigate for it to work and it works with any camera entity, it also automtically decides the best way to stream it (It can even fallback to AlexxIT WebRTC from above).

I have those cards setup to automatically switch to camera with motion when motion is detected and start playback. So all my cameras load on screen at once and are shown as an image that’s updated every few seconds. If any of the cameras have motion those cameras starts live playback automatically and are highlighted (you just define which entities are triggered in the card config).

You can also configure it through UI so you don’t have to worry about all the options that are in the doc.

I’ll try those settings.

I am using an NVR, though, so I think that’s probably most of the trouble. The github page mentions a known problem where the NVR only gives ONVIF notifications for AI events for the camera on the first channel, but I’m not even seeing those.

Post the issue in that plugins discussion thread the author actually has an NVR himself so it should be easier to troubleshoot.

1 Like

Hi Guys,
I tried make it work based on above example config and I struggle to do so. FInally I found the problem so I wanna share it: Make sure http is enable on the camera :slight_smile:
Settings ==> Network ==> Advanced ==> Server Settings

Hey @skynet01, how did you manage to get your frigate card to display an image that is uploaded every few seconds? I have everything else seemingly configured but I can’t figure out how to get this part working. Any chance you could post your card yaml?

Sure here you go, I have other cameras in the card as well. The view section is where I set it to be image capturing. There is also triggers for some cameras where they then start streaming live feed. This works pretty good for an iPad on the wall, where the key cameras are updated with static images every few seconds but if any of other cameras get triggered their live view comes in.

type: custom:frigate-card
cameras:
  - camera_entity: camera.doorbell
    live_provider: ha
    triggers:
      motion: true
      entities:
        - binary_sensor.doorbell_motion
      occupancy: false
    webrtc_card:
      entity: camera.doorbell
    go2rtc:
      modes:
        - webrtc
  - camera_entity: camera.cadens_room_camera
    live_provider: webrtc-card
    triggers:
      motion: false
      entities: []
      occupancy: false
    title: Cadens Camera
    webrtc_card:
      entity: camera.cadens_room_camera
  - camera_entity: camera.patio_cam
    live_provider: ha
    triggers:
      entities: []
      motion: false
      occupancy: false
    webrtc_card:
      url: rtsp://172.16.3.161:41255/4e9f56b477715e67
    go2rtc:
      modes: []
  - camera_entity: camera.yard_cam
    live_provider: ha
    triggers:
      entities: []
      motion: false
      occupancy: false
    webrtc_card:
      url: rtsp://172.16.3.161:39675/5623ff51e62f3148
  - camera_entity: camera.right_outside_garbage_camera
    live_provider: webrtc-card
    triggers:
      entities:
        - binary_sensor.trashcans_person_detected
      motion: true
      occupancy: false
    webrtc_card:
      url: rtsp://172.16.3.161:37769/eefb314783b3628f
  - camera_entity: camera.left_outside_camera
    live_provider: ha
    triggers:
      entities:
        - binary_sensor.ac_person_detected
      motion: true
      occupancy: false
    webrtc_card:
      url: rtsp://172.16.3.161:45897/31537d7b5dde98f7
view:
  camera_select: live
  default: image
  timeout_seconds: 20
  update_seconds: 5
  scan:
    enabled: true
    untrigger_seconds: 25
  update_cycle_camera: false
timeline:
  show_recordings: false
image:
  mode: camera
  refresh_seconds: 6
live:
  auto_play: selected
  auto_pause: unselected
  lazy_load: true
  transition_effect: none
  auto_unmute: selected
  auto_mute: unselected
menu:
  position: top
  alignment: left
  buttons:
    clips:
      enabled: false
    download:
      enabled: false
    timeline:
      enabled: false
    fullscreen:
      enabled: false
    snapshots:
      enabled: false
    camera_ui:
      enabled: false
media_gallery:
  controls:
    thumbnails:
      show_details: false
      show_favorite_control: false
      show_timeline_control: false
performance:
  style:
    box_shadow: false
2 Likes

The Reolink integration within Home Assistant has seen substantial enhancements, leading me to discontinue the use of REST sensors. This has made my network happy. :tada: https://www.home-assistant.io/integrations/reolink

1 Like

@tteck indeed I have made a lot of progress with the integration and it is very stable now with multiple layers off fallbacks for receiving motion/AI events.

Anyone still using a custom HACS integration schould really consider moving to the official build in integration since it is now way ahead of the custom integrations.

If you appreciate the reolink integration and want to support its development, please consider sponsering the upstream library or purchase Reolink products through this affiliate link.

2 Likes

Hi!

I bought the RLN16-410 NVR and some RLC-1224A cameras HA compatibles.

I would like to know if through HA and with a smart button, when you press it, the motion detection of the cameras is deactivated, and when you press it again, it will be activated again.

Would it be possible? :slight_smile: