Stream component : unable to display rtsp stream

This works perfectly for my HikVision cameras thank you! I was using the 2nd stream in MJPEG but now I can use the full primary stream…

So how do I get this to cast/stream to a device like Kodi/Chrome Cast etc please?

So I have tested with a D-Link DCS-825L and no luck, but the error message seems more explicit :

2019-03-22 10:39:59 ERROR (stream_worker) [homeassistant.components.stream.worker] Error demuxing stream: No dts in packet

No luck with D-Link old DCS-7410. Same error message.

And it doesn’t work with Wanscam HW0036 :sob:

after adding stream to my cameras Dafang,Dahua - streaming work for a while, but afterwards frontend becomes unaccesable. “Unable to connect to Home Assistant.” This was on 0.90 release, also on 0.90.1 version.

after few mins frontend is again accessible. Anyone experience this also?

I still have an issue, even on version 0.90.1 :frowning:

Anyone got this working with Ubiquiti/nvr?

I think you can refer to this thread : Stream Component: Confirmed Cameras and Configurations

Exactly! Thank you.

I have the same errors. I swore it was working this morning, I’m now trying to connect remotely. Maybe that’s the issue? Should this work when not connected locally, or via VPN?

All my Unifi cameras when trying stream also do the same thing and error. Work fine when removing stream: from the config. Worked with FFMPEG. Running in a docker container version on latest release.

2019-03-22 14:01:45 ERROR (stream_worker) [libav.h264] error while decoding MB 79 12, bytestream -22

2019-03-22 14:02:27 ERROR (stream_worker) [libav.h264] error while decoding MB 30 24, bytestream -28

2019-03-22 14:02:39 ERROR (stream_worker) [homeassistant.components.stream.worker] Error demuxing stream: No dts in packet

2019-03-22 14:03:18 ERROR (stream_worker) [libav.h264] error while decoding MB 82 22, bytestream -18

@mcaminiti is running identical hardware to what is on my secondary site (that doesn’t work) with same errors). QNAP TS 451+, which is the same CPU as my QNAP TS 453 Pro (that does work), Unifi CloudKey gen2 Plus. Both running Home Assistant in Docker. Same camera models as well.

This makes me think either we are missing a dependency from another component that is loaded or and underlying OS component that is missing.

Interesting find on this one. So I’ve been testing all kinds of things on this.

I kept noticing

ERROR (MainThread) [frontend.js.es5.201903200]

when the stream wouldn’t load. That indicated it was falling back to the older version of javascript.

I did a few tests by appending ?latest to the end of my URL to force the latest version of javascript and it worked. It didn’t matter what browser I was using it would still fallback to es5. I still see the occasional stream errors but those might not have been the actual issue.

This could be a byproduct of another issue misidentifying the browser version and applying an improper javascript version.

example test:
clear browser history
https://homeassistant-domain.com/lovelace/default_view?latest

I’m curious if this clears up some issues for others as well.

4 Likes

I am trying to use Reolink cameras to stream to cast devices. The streams seem to load in home assistant as I am able to see the component on the state tab however when I use camera.play_stream on a device it just appears to load and shows a blank screen. Not sure if there something else I can try. On the front end it seems to work but loses connection often.

I got 0.90.1 installed. I managed to get my cameras to stream properly now since 0.90.1 release. It wasn’t working with 0.90. If i watch a camera on my chromecast and at the same time decide to go to the pane in lovelace where i keep my cameras, it’s enough to just view the preview, the frontend for homeassistant crashes. A reboot fixes it though.

I manged to solve the above by putting all my cameras in homeassistant on Generic. Now I can pretty much do everything without it crashing.

Just thought i’d give my two cents. :slight_smile:

1 Like

So I have a few different instances of HA and only one of which experienced this issue (windows 10 linux subsystem). After following your suggestion I noticed it was working properly. I think you are correct that there may be another underlying issue here. There is a bug report on the frontend repo where myself and another user had the same issue and configuring the frontend to always show latest fixed it for us.

https://github.com/home-assistant/home-assistant-polymer/issues/2987

2 Likes

This is working with my Dahua cameras on 0.91.0, but with some of the issues below

  1. Does not work with H.265, but this is probably a browser/hw limitation.
  2. Will not load playlist.m3u8 the first time I click the stream, but will load it on the subsequent requests. This seems like a server side issue, because I can open it the first time on one device, then it works immediately on another device.

Error when doing #2
https://192.168.1.4:8123/lovelace/4:0:0 ResizeObserver loop limit exceeded

2 Likes

Ditto.
Have a current model Foscam and an older Edimax. Stream component can’t handle either as yet and has the demux errors.
The Edimax supports only mjpeg and H264 streaming.
I can use either via VLC with same URL’s.
Early days for this component and it’s camera support so it will take time to tune up I expect…

Same problem here with D-Link cameras.
I’ve a lot of different models of D-Link cameras and no one is working… The stream is good with VLC but no luck with HASS.
My log is the following:

2019-04-07 19:05:28 ERROR (stream_worker) [libav.rtsp] method DESCRIBE failed: 401 Unauthorized
2019-04-07 19:05:28 ERROR (stream_worker) [libav.tcp] Connection to tcp://192.168.1.48:554?timeout=0 failed: Connection refused

You need to put the credentials in the rtsp URL

rtsp://user:pass@

2 Likes

Thanks! now it works!

dafang is working but its too slow and laggy on my chromecast. do you experience the same?