Ring Device integration via MQTT w/ Video Streaming

@tsightler

can get it to run Docker style…it is a manual endeavor though”. What does that mean exactly?

Just the single command line which is what I originally ran way back.

docker run --rm -e "MQTTHOST.....

Armbian runs on those little TV boxes that typically come with Android.  You can wipe out the Android build and replace it with Armbian or just boot to an SD card.  Another Armbian build is running on an S912 8 core mini TV box.  (smaller footprint than the RPi).  The Armbian build includes an HASSIO script or OpenHab script.  Running plain jane HA on a micro Intel box (BeeLink BT3 Pro) / Ubuntu 18.04 and Oracle VBs of embedded Windows for SAPI voices.  I use SAPI TTS and Alexa TTS here.



Thank you.  Yes and yes.

Apologies about my ramblings…

House #2 is connected here via a PFSense IPSec VPN tunnel.

Main location is also running an OmniPro 2 panel to MQTT plugin such that HA shows two alarm panels here.

Just checked my Local Ubuntu 18.04 box with HA running and the Ring to MQTT plugin running and it shows:

BTPro_HS3Lite:~# node -v
v10.22.1

Curious why this box works with v10.22.1 in Ubuntu 18.04?

I did update the Pine 64 Ubuntu 20.x …

ICS-MOK:~# node -v
v14.12.0

Just updating node works!!

root@ICS-MOK:~# sudo systemctl status ring-mqtt
● ring-mqtt.service - ring-mqtt
Loaded: loaded (/lib/systemd/system/ring-mqtt.service; enabled; vendor preset: enabled)
Active: active (running) since Sat 2020-09-26 06:25:20 CDT; 5s ago
Main PID: 6431 (node)
Tasks: 8 (limit: 2140)
Memory: 50.4M
CGroup: /system.slice/ring-mqtt.service
└─6431 /usr/bin/node /opt/ring-mqtt/ring-mqtt.js

2020-09-26T11:25:26.459Z ring-mqtt Using configuration file: ./config.json
2020-09-26T11:25:26.752Z ring-mqtt Attempting connection to Ring API using refresh token from file: ./config.json
2020-09-26T11:25:28.729Z ring-mqtt Connection to Ring API successful
2020-09-26T11:25:28.734Z ring-mqtt Starting connection to MQTT broker…
2020-09-26T11:25:29.435Z ring-mqtt MQTT connection established, processing locations…
2020-09-26T11:25:29.440Z ring-mqtt Config file saved with updated refresh token.

Using MQTT explorer and see an of the Ring devices!!!

Not sure if it’s possible but tryin to setup an automation to arm/disarm Ring based on time range and all persons being home. Between 10pm and 6am and everyone is home, set Ring to Armed Home. Is that possible and does anyone have an example of an automation they could share?

Thanks

Yes, it’s certainly possible. What are you using for automations…node red or HA’s native system? If you’re using NR, I could cook up a quick flow for you

I am using both, trying to get used to Node-Red. That would be awesome if you could do that. I really appreciate it. 4 people in my household if that helps.

Thanks

@dmoses1969 Here ya go, buddy. Between the hours of 6am - 10 pm, the alarm will be set to armed home when everybody is home. I wasn’t sure how you wanted disarm handled, so it doesn’t include that feature. If you let me know, I could add it.

Thanks for this,
I tried working on this the past two days and came up with this. I just kept thinking of different scenarios and soon as I thought I had it, I would have another “what if” moment. It would be nice to be able to arm/disarm on a schedule and if someone wasn’t home and they’re status changed to home, the alarm could be bypassed until they were in the house and locked the door again. The door lock seems to work at the moment but its not reliable. It’s an August lock and loses connection randomly like it is in the screenshot.

The only other issue I have had with this the past two days is setting the alarm off in the morning by opening a different door to let my dog out. I need to add something to look for activity in the AM, like lights coming on and motion, and disable the alarm on something like that so that opening a door to let a dog out doesn’t set it off.

after having this working for ages it just stopped working any one else having issues?

Normally, if there are widespread problems, people will start opening issues on the ring-mqtt project page within hours, sometimes minutes, even when the issue is on the Ring service side, which is most of the time. I sometimes think I know of Ring outages before the Ring status page updates. Based on the fact that there have been no such reports, and no one has reported it here either, I’d have to guess the problem is unique to your setup.

If you are using the addon, most problems are resolved by removing and re-installing, especially if you upgraded from 3.x for 4.x, although I’d guess most people are past that stage at this point. I’ve had zero reports of valid issues over the last few weeks.

1 Like

I think what changed on my end was i recently subscribed to a plan and thats when this broke. Looking further into it. Thank you

I installed this last week and it works so well! I hope this becomes a standard integration.

There’s ONE thing that isn’t working, which seems very mysterious and I’d like to get some suggestion on how to figure out what is going on, and that is specifically that automations do not trigger on the armed_home payload for alarm_control_panel. That’s so weird because they DO trigger for disarmed, and everything else is working–I can change the state of the alarm, control all the lights, get events from motion detectors and door sensors, control cameras – pretty much everything is working, and that’s so great!

But it’s a mystery to me why just this one thing isn’t working.

I can see in the UI that it knows the alarm is in armed_home state, I can see the event in the MQTT Alarm debug info “last 10 events” history, but the automation set up to trigger on it has never been invoked (last invoked time null).

Here’s the yaml:

> 
> - id: '1602283406443'
>   alias: Alarm Armed Home
>   description: ''
>   trigger:
>   - platform: device
>     device_id: 94xxxxxxxxxxxxxxxxxxxxxxxxxxx47f
>     domain: alarm_control_panel
>     entity_id: alarm_control_panel.home_alarm
>     type: armed_home
>   condition: []
> 
> - id: '1602345095561'
>   alias: Alarm Disarmed
>   description: ''
>   trigger:
>   - platform: device
>     device_id: 94xxxxxxxxxxxxxxxxxxxxxxxxxxx47f
>     domain: alarm_control_panel
>     entity_id: alarm_control_panel.home_alarm
>     type: disarmed
>   condition: []

I obfuscated the device_id because I don’t know if that’s sensitive, but they match and are the same for both triggers. I see this event in the MQTT. I can see this in the MQTT debug info in the UI:

> Received 8:54:12 AM
> 
> * QoS: 0
> * Payload:  `armed_home`

And I also see the disarmed one there, which DOES trigger automation.

I have actually seen this consistently as well, in that I saw this issue when I first set up HA/ring-mqtt. Since then for other reasons I blew away the whole install and reinstalled from scratch again, and AGAIN saw this issue.

Any suggestion on how to debug it, or what information I should look for to see what’s going on?

I would like to trigger some stuff on armed_home because that basically means we’ve gone to bed for the night and so turn down the thermostat, turn off the lights, etc.

I don’t have any idea as this is totally within the realm of Home Assistant, but my guess is that Home Assistant device triggers aren’t fully supported by the MQTT Alarm Control Panel which this addon uses. A quick test and I couldn’t get it to work with a device trigger either, because, as far as I can tell, Home Assistant never triggers the event.

But my suggestion is to just not use a device trigger but instead switch to a state trigger. Then it’s just something like:

platform: state
entity_id: alarm_control_panel.ring_alarm
to: armed_home

This to me is far easier and this can still be done via the UI quite easily, just pick state trigger instead of device trigger, pick your alarm control panel, and enter armed_home in the To field. I know this method works reliably.

I am relatively new to HA. Just installed everything per instructed (add-on v4.2.1)
and all seems to be working ok and all devices connected to ring base station are being detected. The only problem is that the camera part is not working right.

I did set camera to true in config but none of the camera entities are being detected. I have a door bell and 2 floodlight cam. In the native integration, the door bell cam shows ok but not the floodlight cam. I was hoping MQTT can fix it. With the latest add on, even the doorbell cam is not being detected.

Pretty much every thing (motion, light, siren, wifi strength) gets detected, except camera function. Is this a known issue or I have to manually add this in yaml?

thanks

This addon does not support video, it focuses on sensors which can be used for automation, so you should see all sensors/switches on the camera, which it seems you do, but no video options.

This addon, as it’s name implies, uses MQTT which is not exactly a platform for video streaming, but rather for event driven messages. At best it could support sending still images on events, or perhaps on a schedule, but I haven’t really had any requests for this, I guess the native integration works well enough for most people, although, according to the docs it only support doorbell/stickup cams, not spotlight/floodlight cams.

Thanks for the clarification and thanks for your hard work! Guess will use the native integration for door bell video for now.

Just a side note, I also have smartthing integrated with Ring and in the smartthings app, all camera’s video, light, mic and can be controlled. However, if integrate smartthings to HA, only sensor is visible, no video. So I guess the video function is just limited in HA?

On the SmartThings integration page your can look at the categories section on the right side of the page or scroll down to the platforms section to see the list of functions that the Home Assistant SmartThings integration supports. You’ll note that there is no listing for the camera platform so that means that this integration does not support cameras.

I don’t have any insight into the native Ring integration as I don’t use it and that’s really an issue for another thread. My thought is that it should work as there’s really no difference in camera functions between the doorbell/stickup cams vs other cameras. I’d search/post on the forums for help with that issue.

I just installed the Home Assistant native Ring camera integration for a test and all 5 of my cameras worked with no issues. I have 1 Doorbell pro, 2 stickup cams, and 2 floodlight cams and I could add them to the Lovelace UI, get updated images, etc, so you might just want to investigate that behavior since it seems like they definitely should work.

thanks for the update… I really have no idea what might have caused this but the floodlight (camera part) just don’t work in the native integration. (light, siren, motion, etc. showing up fine, except camera entity).

Just to add, I only have door bell on subscription plan, not the flood cams. I did read somewhere saying HA won’t show unless with a plan. In my smartthing app, even without subscription, all cameras are working fine.

I didn’t even know it was possible to have one camera on plan and another off without having separate accounts, interesting. Do you have like the basic plan with just the one camera?

Regardless, I was under the impression it was possible to use with a free account, just that you couldn’t download videos without a paid account, but I don’t have any way to test this. It’s possible the code is simply being confused if you have a single account with one active camera and another that is not. Anyway, good luck!

Thanks again for the confirmation.

Yea, I have doorbell + 2 cams on one account with only doorbell on basic plan. I can manually add other device to the plan for $30/yr each.

update:
Just tested adding one floodlight cam to subscription plan, reload the integration in HA, and boom it shows up a new camera entity for the cam.

I think this is due to how camera in HA and Ring integration works. Since it can only display the last captured motion, therefore hen the cam must require a plan or the cam part will just be “ignored”.

In smartthings integration, all cameras are showing as a normal web cam which can be toggled on for live with sound, light, etc. It won’t auto capture last motion but instead showing activity log in the timeline.

Someone had posted an ring live stream add-on but it kind of stopped working after ring changed rule on refresh token. Wondering if you can implement something similar as you have the token auto renewed.