Hello everybody ,
today i implemented my reolink WLAN cameras in HA I run in a Docker container.
Please recognize these entries i made in the configurations.yaml to do it:
camera:
- platform: generic
name: Innen
still_image_url: !secret Innen_URL
stream_source: !secret Innen_Source
- platform: generic
name: Haustuer
still_image_url: !secret Haustuer_URL
stream_source: !secret Haustuer_Source
binary_sensor:
- platform: rest
resource: !secret reolink1
name: Motion Haustuer
scan_interval: 1
#value_template: “{{ value_json[0].value.state }}"
value_template: “{{ value_json0.value.state }}"
Via the following in the !secret file i get response from the camera when posted
reolink1: "http://192.168.178.___/api.cgi?cmd=GetMdState&user=admin&password=YOUR_PW"
posting http://192.168.178.___/api.cgi?cmd=GetMdState&user=admin&password=YOUR_PW in my browser returs:
[ { “cmd” : “GetMdState”, “code” : 0, “value” : { “state” : 0 } } ]
or:
[ { “cmd” : “GetMdState”, “code” : 0, “value” : { “state” : 1 } } ]
When motion is present in front of the camera --> this works so far
The stream is accessiable via a picture glance card with this config:
aspect_ratio: 55%
camera_image: camera.haustuer
camera_view: live
entities:
- entity: camera.haustuer
- entity: binary_sensor.motion_haustur
title: Haustür
type: picture-glance
However, my progress ended when I tried to establish a motion detection with the binary sensor setup.
The binary sensor in the card does not respond on motion nor is in the sensor history a motion recorded whereas i recive notifications of events via the reolink app.
Does anyone has a clue what needs to added to the binary sensor configuration to make this work?
Thank you in advance for your time!
Best regards
Thorsten