OH3 - RTSP camera setup

Fantastic! Things are now happening!

With your first suggestion, I now have some images.

The Image URL is working in my browser http://10.0.0.100:45230/ipcamera.jpg
I don’t get an image in my Image item though. Do you know why?

This widget Camera: Clickable thumbnail opens to a larger stream - #17 by maxmaximax works. It shows a static thumbnail, and a video in motion when clicked.

I’m seeing a few things in the logs that don’t look right.
When I click the widget and start the mjpeg stream I get:

2021-06-13 16:53:40.711 [DEBUG] [pcamera.internal.StreamServerHandler] - Stream Server recieved request 	GET:/ipcamera.jpg
2021-06-13 16:53:45.234 [TRACE] [era.internal.handler.IpCameraHandler] - Sending camera: GET: http://10.0.0.217:554
2021-06-13 16:53:47.901 [DEBUG] [pcamera.internal.StreamServerHandler] - Stream Server recieved request 	GET:/ipcamera.mjpeg
2021-06-13 16:53:47.903 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - Starting ffmpeg with this command now:-rtsp_transport udp -hide_banner -loglevel warning -i rtsp://admin:********@10.0.0.217/onvif1 -q:v 5 -r 2 -vf scale=320:-2 -update 1 http://127.0.0.1:45230/ipcamera.jpg
2021-06-13 16:53:48.703 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] PPS id out of range: 0
2021-06-13 16:53:48.705 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] -     Last message repeated 1 times
2021-06-13 16:53:48.706 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] Error parsing NAL unit #0.
2021-06-13 16:53:48.707 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] PPS id out of range: 0
2021-06-13 16:53:48.708 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] -     Last message repeated 1 times
2021-06-13 16:53:48.709 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] Error parsing NAL unit #0.
2021-06-13 16:53:48.780 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] PPS id out of range: 0
2021-06-13 16:53:48.782 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] -     Last message repeated 1 times
2021-06-13 16:53:48.783 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] Error parsing NAL unit #0.
2021-06-13 16:53:48.862 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] PPS id out of range: 0
2021-06-13 16:53:48.864 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] -     Last message repeated 1 times
2021-06-13 16:53:48.865 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x8f5630] Error parsing NAL unit #0.
2021-06-13 16:53:50.683 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - Guessed Channel Layout for Input Stream #0.1 : mono
2021-06-13 16:53:50.713 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [hevc @ 0x965780] Could not find ref with POC 70
2021-06-13 16:53:50.802 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [swscaler @ 0xece230] deprecated pixel format used, make sure you did set range correctly
2021-06-13 16:53:51.391 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [rtsp @ 0x8f2260] max delay reached. need to consume packet
2021-06-13 16:53:51.392 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [rtsp @ 0x8f2260] RTP: missed 10 packets
2021-06-13 16:53:51.416 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [rtsp @ 0x8f2260] max delay reached. need to consume packet
2021-06-13 16:53:51.418 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [rtsp @ 0x8f2260] RTP: missed 2 packets
2021-06-13 16:53:55.233 [TRACE] [era.internal.handler.IpCameraHandler] - Sending camera: GET: http://10.0.0.217:554

Then it seems to work for a while. Then I get

2021-06-13 16:55:54.784 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - More than 1000 frames duplicated

and the feed stops. When I reload the p[age I can view it again.

I’m also seeing:

2021-06-13 17:10:15.614 [DEBUG] [hab.binding.ipcamera.internal.Ffmpeg] - [swscaler @ 0x23e7220] deprecated pixel format used, make sure you did set range correctly

sometimes