homebridge-camera-ffmpeg icon indicating copy to clipboard operation
homebridge-camera-ffmpeg copied to clipboard

Hikvision NVR 7604NXI-K1

Open grmelacz opened this issue 2 years ago • 0 comments

Manufacturer/Model: Hikvision NVR 7604NXI-K1 (firmware V4.71.100 build 220526)

Homebridge Config:

{
            "name": "Camera 1",
            "unbridge": true,
            "videoConfig": {
                "source": "-i rtsp://user:pass@nvr-ip/Streaming/Channels/102/",
                "stillImageSource": "-i rtsp://user:pass@nvr-ip/Streaming/Channels/102/ -vframes 1 -r 1 -ss 00:00:01",
                "maxStreams": 2,
                "maxWidth": 640,
                "maxHeight": 360,
                "maxFPS": 25,
                "maxBitrate": 2048,
                "audio": false,
}

Additional Information: The configuration utilises the low-res substream which is helpful in case you have underpowered HomeBridge hardware like the Raspberry Pi Zero 2 W. 640x360@25 fps requires only a couple of megabytes of memory and consumes about 25 % CPU on this device. The real problem for processing 4K streams is not the CPU power as you could lower the FPS, but rather memory which gets consumed very quickly causing the process to crash.

This configuration works great even with the main stream. Replace 102 with 101 in the URL for the first camera and make sure to add a slash after the channel number. You have to have a corresponding HW to process the video stream though.

Note: The -ss 00:00:01 stills parameter is vital. Without it, even with various image corruption detection/compensation parameters, the image was nearly always corrupted (grey pixelated screen) and the preview in the Home app was unusable though the stream itself worked great.

grmelacz avatar Dec 27 '22 09:12 grmelacz