I setup a DuckDNS access to my HA installation. So I login from there even when I’m at home using my WiFi. I’m not sure why, but at home it seems it access to ip devices inside LAN instead of from outside. Example, I can see my ip cams at very high resolution and frame rate.
So I would like to setup something to decide on the fly (automatically or manually) which stream receive: main or sub. When I’m inside LAN I would use the main one, when outside the sub one to reduce bandwidth.
The obvious way is to put a switch (i.e. high/low resolution) and build the rtsp path using the switch value as variable. Is there something else smarter? Any idea?
Let’s say you set up 2 cameras in HA, kitchen_high/kitchen_low, same ip cam, high and low resolution/frame rate streams. And then create input_boolean.high_stream.
In lovelace:
input_boolean.high_stream at the bottom of this picture-glance card would toggle which stream to show, or you can tie it to some automation trigger of your choice
note: rtsp path won’t work directly in picture-glance
What are the dis/advantages of using a local ip address instead of the external one?
I mean, I always thought it’s better to use local address, because in this way HA doesn’t have to reach the LAN devices from outside. It’s only the front-end that loads data from the Internet. Am I wrong?
Fill in [] for right options.
So you will have camera_proxy_stream/camera.garden and camera_proxy_stream/camera.garden_hd for picture-glance’s 2 urls.
The rtsp://user:password… url will not work in the picture-glance.
Since you have DuckDNS HA (https), local http url (non-secured) can only be seen/access inside local network. To see local http url outside of local network, you either have to open router port(s) or put it in a cloud or something.
Since HA already have the camera streams, much easier and safer to use the carmera_proxy urls.