Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doorbell Gen 2 Video Issue, possibly streamy type mismatch? #438

Closed
byronavory opened this issue Aug 19, 2020 · 35 comments
Closed

Doorbell Gen 2 Video Issue, possibly streamy type mismatch? #438

byronavory opened this issue Aug 19, 2020 · 35 comments
Labels
bug Something isn't working Ring An issue caused by Ring

Comments

@byronavory
Copy link

byronavory commented Aug 19, 2020

Live Streaming Issue

Describe the live streaming issue

Error streaming Doorbell since recent ring version update (Previously not updated since mid July).From what I can tell it's related to the new API and a stream type mismatch. (I believe the doorbell uses cocoa?)
Driveway Floodlight works fine. Also, after viewing driveway and switching back to doorbell, there is a "Ding 6862821198833873803 is expired (480)" error. Perhaps permissions?

Screenshots/Logs

[8/19/2020, 6:11:37 PM] [Ring] Preparing Live Stream for Front Door
[8/19/2020, 6:11:38 PM] [Ring] Failed to prepare stream for Front Door (0.51s)
[8/19/2020, 6:11:38 PM] [Ring] TypeError: Cannot read property 'match' of undefined
at getRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:23:50)
at parseRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:29:16)
at SipCall. (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:190:20)
at Generator.next ()
at fulfilled (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:5:58)
at runMicrotasks ()
at processTicksAndRejections (internal/process/task_queues.js:97:5)
[8/19/2020, 6:11:46 PM] [Ring] Preparing Live Stream for Driveway
[8/19/2020, 6:11:46 PM] [Ring] Ding 6862821198833873803 is expired (480). Fetching a new ding and trying video stream again
[8/19/2020, 6:11:47 PM] [Ring] Stream Prepared for Driveway (1.434s)
[8/19/2020, 6:11:47 PM] [Ring] Received stream data from Driveway (1.482s)
[8/19/2020, 6:11:48 PM] [Ring] Streaming active for Driveway
[8/19/2020, 6:11:50 PM] [Ring] Stopped Live Stream for Driveway
[8/19/2020, 6:11:50 PM] [Ring] Preparing Live Stream for Front Door
[8/19/2020, 6:11:51 PM] [Ring] Ding 6862821160170950766 is expired (480). Fetching a new ding and trying video stream again
err: Error: remote peer disconnected
at TLSSocket. (/usr/local/lib/node_modules/homebridge-ring/node_modules/sip/sip.js:584:43)
at TLSSocket.emit (events.js:327:22)
at endReadableNT (_stream_readable.js:1220:12)
at processTicksAndRejections (internal/process/task_queues.js:84:21)
[8/19/2020, 6:11:52 PM] [Ring] Failed to prepare stream for Front Door (2.074s)
[8/19/2020, 6:11:52 PM] [Ring] TypeError: Cannot read property 'match' of undefined
at getRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:23:50)
at parseRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:29:16)
at SipCall. (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:190:20)
at Generator.next ()
at fulfilled (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:5:58)
at runMicrotasks ()
at processTicksAndRejections (internal/process/task_queues.js:97:5)
-->

Recommended solution

Environment

  • Ring Camera: Doorbell 2 (doorbell_v4) Firmware 9.8.1
  • OS: Raspbian GNU/Linux Buster (10) - Homebridge Raspberry Pi Image
  • Node.js: v12.18.3
  • npm@6.14.8
  • homebridge-ring@9.8.1
  • homebridge@1.1.2
  • homebridge-config-ui-x v4.26.0

Network Environment

Doorbell 2 (doorbell_v4) Firmware 9.8.1 connected to
Eero Pro B010011 v3.12.1-106 on WOW Cable Internet wire connected to
Raspbian Homebridge server and Apple TV 4K 32GB MQD22LL/A

@byronavory byronavory changed the title Doorbell Gen 2 Video Issue, possibly Doorbell Gen 2 Video Issue, possibly streamy type mismatch? Aug 19, 2020
@dgreif
Copy link
Owner

dgreif commented Aug 20, 2020

Can you try v9.8.2? If it doesn't work, can you post the new errors from the logs (I added some additional logging if this section fails)

@dgreif dgreif added the bug Something isn't working label Aug 20, 2020
@byronavory
Copy link
Author

Still no luck... New errors: Removed Crypto Hash

[8/20/2020, 8:20:46 PM] [Ring] Preparing Live Stream for Front Door

[8/20/2020, 8:20:48 PM] [Ring] Failed to parse SDP from Ring
[8/20/2020, 8:20:48 PM] [Ring] v=0
o=Wantajobinstead? 1529310922 1529310923 IN IP4
s=Wantajobinstead?
c=IN IP4 35.155.12.231
t=0 0
 
m=audio 14186 RTP/SAVPF 0
a=rtpmap:0 PCMU/8000
a=rtcp:17970 IN IP4 35.155.12.231
a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:XXXXXXXXX
a=ptime:20
 
m=video 53520 RTP/SAVPF 99
a=rtpmap:99 H264/90000
a=fmtp:99 profile-level-id=42000a
a=rtcp:59135 IN IP4 35.155.12.231
a=rtcp-fb:99 nack
a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:XXXXXXXXX
 
[8/20/2020, 8:20:48 PM] [Ring] Failed to prepare stream for Front Door (1.89s)
[8/20/2020, 8:20:48 PM] [Ring] TypeError: Cannot read property 'match' of undefined
at getRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:24:54)
at parseRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:36:16)
at SipCall. (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:204:20)
at Generator.next ()
at fulfilled (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:5:58)
at processTicksAndRejections (internal/process/task_queues.js:97:5)

@dgreif
Copy link
Owner

dgreif commented Aug 21, 2020

Bummer. Can you go into the Device Health section for that camera in the Ring app and confirm it is on the latest firmware version (Should say Up To Date)? Also, do you have the paid subscription for the camera?

@byronavory
Copy link
Author

Up-to-Date and Paid... FloodCam works... just not the doorbell.

@dgreif
Copy link
Owner

dgreif commented Aug 21, 2020

K, that's all good info. This is really weird because the Ring servers aren't providing the same connection details that all other cameras seem to provide. My recent updates rely on these details to establish a streaming session. I can't think of any reason why this particular model or particular camera would connect differently. I'm pretty sure I have other users with the same camera model that aren't having issues. Anything else come to mind that may be different?

One other idea, do you have an amazon fire tv or echo show/spot? If so, please try turning on the ring Alexa skill and streaming that camera through your amazon device. That uses the same connection strategy that I'm using now.

@aveanun
Copy link

aveanun commented Aug 22, 2020

I’m also having issues with the live stream loading on my doorbell 2 after the update. It was working flawlessly prior to that. The stream does work in the ring app over LTE & WIFI, thumbnails update in the home app. However, the livestream only works in the Home app when connected to LTE, doesn’t work over wifi.

@dgreif
Copy link
Owner

dgreif commented Aug 22, 2020

@aveanun if you are able to get a live stream over LTE, then you are not having the same issue as @byronavory. You should keep an eye on #439

@dgreif
Copy link
Owner

dgreif commented Aug 28, 2020

@byronavory any chance you can try streaming the camera on an amazon fire tv or echo show/spot as I detailed above?

@byronavory
Copy link
Author

@dgreif I apologize for taking so long to get back to you. I do not have any of those, but my roommate has/had an Amazon Echo Show. He was going to go get it from his mothers last weekend and forgot. At this point, I have nothing to test with.

@bjornand1
Copy link

Also streaming from my doorbell has stopped working after the latest update, FW is up to date.

@bjornand1
Copy link

And WiFi vs 4G makes no difference.

@dgreif
Copy link
Owner

dgreif commented Sep 3, 2020

@bjornand1 Can you check your logs from homebridge and post any errors you see in there when you try to stream? What camera model is reported in the Home app if you go into the camera and then settings?

@volcore79
Copy link

volcore79 commented Sep 3, 2020

I opened issue #444 . Same Problem. Firmware of Spotlight Cam is up to date, model in Home is “Spotlight Cam (hp_cam_v2)“. This Camera has problems with live view. My doorbell “Doorbell Pro (lpd_v2)“ works fine.

No problems in Ring App or using Alexa Show.

Absolutely no idea what‘s the problem there.

@dgreif
Copy link
Owner

dgreif commented Sep 4, 2020

@bjornand1 @volcore79 either of you have an amazon fire tv or Alexa device that you can try streaming the camera from? If so, let me know if you can successfully stream the problematic camera

@bjornand1

This comment has been minimized.

@volcore79
Copy link

Alexa Show works fine.

@bjornand1

This comment has been minimized.

@dgreif
Copy link
Owner

dgreif commented Sep 7, 2020

Thanks for the update @bjornand1. I'm really at a loss right now because it seems like this is only impacting a tiny subset of users, and it looks like it isn't limited to one type of camera. I think the only way I can gain more insight would be to have one of you share you camera with me via the Ring app so that I can do some tests with it. Any of you have the camera in a place where it wouldn't be an intrusion on your privacy for me to access it? If so, can you share it with me at dustin.greif@gmail.com? I don't have a lot of free time at the moment, so no promises on when I'll be able to get it figured out.

@bjornand1
Copy link

Thanks, @dgreif, much appreciated if you could look into it. Ours is doing its duty as a regular front door doorbell, in a rural area, so I think the most exciting thing you could see are cows in the field next to our house. I'll share it.

@volcore79
Copy link

Thanks a lot @bjornand1 ! With my camera this sharing would not be possible :-/

@dgreif
Copy link
Owner

dgreif commented Sep 7, 2020

@bjornand1 I tried a couple streams with you camera and it doesn't appear to be having the same issue as the others here. I don't think we ever confirmed that your logs had the Cannot read property 'match' of undefined error in them. It looks like your camera is actually having difficulty with streaming to the Ring servers in general. The fact that you were seeing issues in the Ring app confirms this. I had several instances where I tried a live stream and the recording of it was all black. You should reach out to Ring support and see if they can help you out. No need to mention the homebridge plugin since it is not related. You are welcome to revoke my access at this point as there is nothing else I can do to improve your experience.

@byronavory is your camera positioned such that you would be willing to share access? Doesn't sound like @volcore79 can.

@volcore79
Copy link

If rhere is no other chance i can do it. where are you from? Perhabs during the night in germany?

@volcore79
Copy link

@dgreif you have access now for about 9 hours during my night. Hope you will have some time. If not we will try some other night.

@byronavory
Copy link
Author

I apologize. I just woke up and saw this. I’ve added you to mine.

@bjornand1

This comment has been minimized.

@bjornand1

This comment has been minimized.

@bjornand1

This comment has been minimized.

@bjornand1

This comment has been minimized.

@dgreif
Copy link
Owner

dgreif commented Sep 8, 2020

@bjornand1 I hope you can get it working consistently, seems like a big pain! I'm going to hide your comments on this tread since your issue wasn't directly related to the original issue.

@volcore79 I've pulled the data that I need from your camera that you shared, but I think you mentioned you have another camera that isn't having the issue. Would it be possible for you to share access to that camera so that I can compare settings and connection details between the two? So far I want to just claim this is some outdated server in Europe that Ring needs to fix, but the fact that you have one camera that works and one that doesn't kills that theory.

@byronavory thanks for sharing your camera. So far I can see some similarities with @volcore79 but I'm not sure exactly how to fix the issue yet. If you don't mind, I'd appreciate it if you can keep sharing it with me for now so that I can test any possible fixes against it.

@volcore79
Copy link

@dgreif I will share both cameras in about 2-3 hours again during the german night.

@dgreif
Copy link
Owner

dgreif commented Sep 9, 2020

@byronavory @volcore79 I got some time to compare the cameras this afternoon and unfortunately I can't find anything definitive that would be causing the different behavior on these particular cameras. The settings/features listed on the cameras all seem standard. The only thing that seems to indicate that the stream connection is going to behave differently is that the sip_session_id for the stream, which is normally 33 random characters, on these cameras is always r.ms. followed by 32 random characters. It seems like Ring is internally marking these streams differently, causing them to use a different backend software that doesn't support some of the features I'm using in newer versions of the plugin.

The only thing I can think of to try on your end is disconnecting power from the camera (or pulling battery if equipped) to cause a full power-cycle in hopes that it will trigger a firmware update if one is available. Beyond that, I have no idea what would be causing this behavior.

Unfortunately, the features that these camera streams are missing are features that I'm heavily relying on to reliably open video streams in the plugin. Older versions used a different approach, but it was much more complex and less reliable. I really don't want to add the old approach back, especially if only a handful of users world-wide are seeing issues. If you need live streams from these cameras, you can reinstall version 9.7.3 by running npm i -g --unsafe-perm homebridge-ring@9.7.3, which was the last version that used the old connection approach.

I recommend updating to the latest version of the plugin in a couple months to see if Ring has fixed this issue on there end. Until then, I really appreciate your input and willingness to share cameras for debugging, and I'm sorry I couldn't find a better solution.

@byronavory @volcore79 @bjornand1 you are all welcome to remove me as a shared user on your cameras. For some reason Ring doesn't allow me to remove myself, so I have access until you revoke it on your end.

@djm181
Copy link
Contributor

djm181 commented Sep 30, 2020

Hey Dusty,

I'm running into this as well but I'm running ring api 9.7.3 as you suggested. Before I downgraded I was seeing the Cannot read property 'match' of undefined error, but now it will appear to start the video stream, but ffmpeg just hangs and kicks out this message: ring ffmpeg stderr From Ring: HMAC mismatch

Any thoughts?

@dgreif
Copy link
Owner

dgreif commented Oct 11, 2020

@djm181 I was incorrect when I suggested downgrading. These new media servers do not work with either streaming approach, but I am working with Ring to get it figured out. Keep an eye on #447 for updates

@ekobres
Copy link

ekobres commented Oct 14, 2020

Hello - I'm seeing the same thing - has been happening for a while, but I was having other general weirdness with Catalina and IOS14 that cleaned up when I upgraded Node to the latest.

These are both Ring Doorbell Pro original version. Ring app works fine - Echo Show can show them both fine.

I wonder if this might be related to recent changes with ring snapshots? That feature reaches out and grabs a frame every so often from the camera - could they be implementing that by changing the stream name so the backend knows to reach back and grab a frame periodically?

I'm using The Homebridge Config UI Buster image from the Homebridge site on a RPi 3 - everything is the latest version.

Here's the log snip from one of them - they both do the same thing:

[10/14/2020, 12:38:53] [Ring] v=0
o=Wantajobinstead? 1529310922 1529310923 IN IP4
s=Wantajobinstead?
c=IN IP4 3.232.82.93
t=0 0

m=audio 51972 RTP/SAVPF 0
a=rtpmap:0 PCMU/8000
a=rtcp:28629 IN IP4 3.232.82.93
a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:***
a=ptime:20

m=video 40773 RTP/SAVPF 99
a=rtpmap:99 H264/90000
a=fmtp:99 profile-level-id=42000a
a=rtcp:55794 IN IP4 3.232.82.93
a=rtcp-fb:99 nack
a=crypto:1 AES_CM_128_HMAC_SHA1_80 inline:***

[10/14/2020, 12:38:53] [Ring] Failed to prepare stream for Driveway (0.556s)
[10/14/2020, 12:38:53] [Ring] TypeError: Cannot read property 'match' of undefined
at getRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:24:54)
at parseRtpDescription (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:36:16)
at SipCall. (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:204:20)
at Generator.next ()
at fulfilled (/usr/local/lib/node_modules/homebridge-ring/lib/api/sip-call.js:5:58)
at runMicrotasks ()
at processTicksAndRejections (internal/process/task_queues.js:97:5)

@dgreif
Copy link
Owner

dgreif commented Oct 14, 2020

@ekobres this issue is being tracked in #447

Repository owner locked and limited conversation to collaborators Oct 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working Ring An issue caused by Ring
Projects
None yet
Development

No branches or pull requests

7 participants