I just got HA up and running on a Pi 4 with some zwave and wifi switches. Done some simple lighting automations that I am loving so far. My next project is cameras. I want 8 or so with the ability to record, trigger on motion, and watch live streams of them from a few TVs and wall mounted tablets (ideally in the lovelace dashboard). So far, I bought an Amcrest IP camera and added it into the configuration.yaml. I also tried adding it in motionEye. The quality and speed though the amcrest app is great but the image in HA is grainy and very delayed (5-10 seconds behind). I’m trying to figure out if I am going about this the right way. What am I missing? Do I need to get a dedicated NVR? Or just tweak some settings?
I recently looked into this topic as well. If you want low(er) latency & good quality get a camera that offers h264 in hardware. Most applications as Browser won’t need an reencode that way. I use USB cams on raspberry like devices so I don’t need to trust some questionable iot firmware in my network but you’ll find Wifi cams with h264 streams as well.
A few things I’ve learned:
- There’s always a delay in camera streams, more so with H.264 streams. The i-frame setting influences the delay, lower values mean a shorter delay, and higher bandwidth for the camera stream.
- MotionEye’s replayed feed has a lower delay
- Cameras with a secondary, lower resolution stream, require much less processing power for motion detection. MotionEye can use that for detection and record the higher resolution stream. I’m using HikVision cameras, but there are other choices.
- Regardless, the Pi is not a great platform for motion detection
- Using Doods to process the image after motion detection allows you to have a lower detection threshold in MotionEye, but not get nagged by pointeless motion detection.
Those are some great tips. So hopefully I can do some tweaks and get a least a marginal setup going. I am more interested in having live streams available around the house. Motion would be nice but is not critical. I have other sensors for that which work well.
So should I be looking into better hardware for HA or getting something like a dedicated Amcrest NVR?
I’d look at something with an i3 or better, which will also make your HA experience much better.
NVRs are find, if they provide the features you want and allow you to hook it all into HA. For example, can you get all the camera feeds from it, and can it notify you upon motion detection?