Hi.
Appreciate some insights how I can use my existing camera in Home Assistant for basic Live View on the Dashboard.
I have an IMOU Ranger 2 IP cam (Model: IPC-A22E-C) that I would like to view its live stream in a Lovelace dashboard. At the moment, I don’t need it to do anything fancy, just basic live view. At most, if it has accessibile PTZ (Pan-Tilt-Zoom) controls then that’s a bonus. I also want to keep this local and not use the “IMOU Life - Cloud Integration”
My current setup:
- Home Assistant 2023.8.4 as a Virtual Machine on unraid
- The IP cam and Home Assistant are on the same subnet
In June 2021, I had this working by manually adding the Generic Camera via configuration.yaml. I then added it to the dashboard using the Picture Glance Card. I don’t recall what version of Home Assistant this would have been. This is the code I used at the time, which I commented out since I was not using it.
ffmpeg:
stream:
camera:
- platform: generic
still_image_url: http://192.168.XX.XX/jpg/image.jpg
stream_source: rtsp://admin:<SafteyCode>@192.168.XX.XX:554/cam/realmonitor?channel=1&subtype=1&unicast=true&proto=Onvif
name: tabby cam
Recently, I uncommented the config thinking it would just start working again but was greeted with a notice from HASS that the manual configuration for Generic Camera was deprecated. It converted the manual config to the Generic Camera UI integration. I never got the live view to work on either Profile 0 or 1 (presumably, this refers to Channel 0 and 1 of the RTSP stream) but some of the sensors and controls were present.
I also tried using the ONVIF integration without success. Some of the RTSP URLs I tried are below using info found at ispyconnect.com [1]. I also trial-and-error by changing the channel number between 0 and 1 and the subtype between 0 and 1 to no avail.
rtsp://admin:<SafteyCode>@192.168.XX.XX:554/cam/realmonitor?channel=1&subtype=1&unicast=true&proto=Onvif
rtsp://admin:<SafteyCode>@192.168.XX.XX:554/cam/realmonitor?channel=1&subtype=1
rtsp://192.168.XX.XX:554/cam/realmonitor?channel=1&subtype=1&unicast=true&proto=Onvif
rtsp://192.168.XX.XX:554/live
Understanding that Imou cameras are rebranded Dahua, I gave the Dahua integration (installed via HACS) a try and was also unsuccessful. I found a Github issue [2] describing why this integration will not work with Imou cameras or at least with the IPC-A22E.
I had another thought to add the camera to Frigate and then pipe Frigate into Home Assistant but I’m getting the same results (no video).
Some resources I used to get me here: