Difference between revisions of "Hikvision DS-2CD2025FWD-I"
(→Notes) |
|||
Line 35: | Line 35: | ||
You can login with a browser. No requirement to use an app. | You can login with a browser. No requirement to use an app. | ||
stream | stream resolutions are limited depending on main stream or sub stream | ||
<pre> | <pre> | ||
main stream | main stream |
Revision as of 23:27, 10 March 2019
EXIR MINI BULLET NETWORK CAMERA
- Max Resolution: 1920x1080
- 30 FPS
- 0.005 LUX at F1.2
This applies to the following Firmware Versions:
- Firmware 5.4.5 build 170124
- Encoding 7.3 build 170123
- Web 4.0.1 build 170123
- Plugin 3.0.6.14
Setup in ZM
I was able to get this camera to work with the following settings.
RTSP via FFMPEG:
Main stream rtsp://user:password@xxx.xxx.xxx.xxx:554/Streaming/Channels/1
Sub stream rtsp://admin:password@xxx.xxx.xxx.xxx:554/Streaming/Channels/2
MJPEG path:
Main stream: http://192.168.1.64/api/mjpegvideo.cgi?InputNumber=1&StreamNumber=1
Sub stream: http://192.168.1.64/api/mjpegvideo.cgi?InputNumber=1&StreamNumber=1
Notes
The default IP is 192.168.1.64 You can login with a browser. No requirement to use an app.
stream resolutions are limited depending on main stream or sub stream
main stream 1920x1080 1280x960 1280x720 sub stream 640x360 352x240
FPS can be from 1/16 fps to 30. You can adjust each stream separately. You can view both main and sub stream at the same time.
Encoding can be H264, H265, or MJPEG. Backwards compatibility is nice.
Live view stream is an .asp page (aspx) A plugin is required to view the stream. :/. However, you can view the MJPEG path via a browser (see path above or below).
They have a GPL notice:
1. Software Licensed under the GNU General Public License
This product includes software licensed under the GNU General Public License (GPL), Version 2. Please see Appendix A below for the terms of this license.
Specifically, the following software included in this product is subject to the GPL:
GCC library (note that an exception clause applies, see Appendix B) Linux kernel busybox 1.19.3 u-boot udev 114 IPTables 1.4.18 ppp - Pauls PPP Package 2.4.3 RP PPP OE 3.8 wpa_supplicant 0.7.2
Too bad it's not GPLv3, might make reverse engineering easier.
This path works:
rtsp://user:password@xxx.xxx.xxx.xxx:554/Streaming/Channels/1
for the main stream.
rtsp://user:password@xxx.xxx.xxx.xxx:554/Streaming/Channels/2 is for the substream with mplayer
so, easy enough. Good and simple configuration. mplayer output:
mplayer rtsp://admin:password@192.168.1.64:554/Streaming/Channels/2 librtsp: server responds: 'RTSP/1.0 401 Unauthorized' rtsp_session: unsupported RTSP server. Server type is 'unknown'. libavformat version 56.40.101 (internal) libavformat file format detected. [lavf] stream 0: video (h264), -vid 0 VIDEO: [H264] 352x240 0bpp 30.000 fps 0.0 kbps ( 0.0 kbyte/s) Clip info: title: Media Presentation [vdpau] Error when calling vdp_device_create_x11: 1
there is some smearing on mplayer, when large motion occurs which goes away after a moment. may need more keyframes
Smearing on the 1.32.3 is not an issue with the substream.
Using an RPI3 here. at 352x240, I have 0.3 load. with Most camera settings at default, but of interest is the FPS at: 4 I'm using FFMPEG and Mocord. RAM 154MB Looking at Htop, all Cores are about 5-10%. Not bad at all. I had to make sure to set H264 encode disabled on my build, as earlier 1.32 builds would default to it - even on arm, where it's not supported.
is it possible to watch the stream with my computer, and my RPI? Two
streams at once? Yes. No issues with two viewers. This is something,
I've been thinking about with Multi-Server Setups. Not all cameras support this.
I set the FPS to 25, and the RPI3, seems to be able to handle it upon first glance... The stream, is extremely fluid, though admittedly - only 352x240. I don't think the RPI3 can do 720p very fast with this camera, but we will find out.
Load is about 1.3 Mocord.
Note that this is on H264 encoding.
Let's try MJPEG, and se if it changes...
Where is the MJPEG path?
A quick trip to ispy shows the path:
http://192.168.1.64/api/mjpegvideo.cgi?InputNumber=1&StreamNumber=2
Which can be tested in the browser. It looks like even when MJPEG is enabled, the RTSP will also work. Not sure why...
Perhaps, once a session is open, it stays open. It's also possibly that all streams are enabled at all times, which would be nice.
If you are using this camera, at 30FPS, it actually means you should remove the max fps limit put in 1.32.3 of 30. As it will cap the variable FPS to no more than 30, causing potential delays. (Set it to 60 or so)
The next test: 640x480 FPS 30 (in camera)
Mocord. Default zone FFMPEG method Load is about 2.4 Now, is the hardware decoding peripheral of the RPI3 being used? let's enable logging and find out. Notes from this thread: https://forums.zoneminder.com/viewtopic.php?f=34&t=26112&p=106795&hilit=mmal#p106795
and restart...
[Starting Capture version 1.32.3] g_camera.cpp/163 [Priming capture from rtsp://admin:opensourcecam2@192.168.1.64:554/Streaming/Channe g_camera.cpp/344 [Calling avformat_open_input for rtsp://admin:opensourcecam2@192.168.1.64:554/Strea g_camera.cpp/376 [Opened input] g_camera.cpp/378 [Stream open rtsp://admin:opensourcecam2@192.168.1.64:554/Streaming/Channels/2, par g_camera.cpp/384 [Calling avformat_find_stream_info] g_camera.cpp/393 [Got stream info] g_camera.cpp/436 [Unable to locate audio stream in rtsp://admin:opensourcecam2@192.168.1.64:554/Stre g_camera.cpp/438 [Found video stream at index 0] g_camera.cpp/439 [Found audio stream at index -1] g_camera.cpp/514 [Video Found decoder mjpeg] g.cpp/267 [Dumping stream index i(0) index(0)] g.cpp/272 [ Stream #0:0] g.cpp/280 [, frames:21, timebase: 1/90000] g.cpp/282 [: Video: mjpeg, yuvj420p(pc, bt470bg/unknown/unknown), 640x360 [SAR 1:1 DAR 16:9]] g.cpp/307 [ g.cpp/229 [90k stream tb numerator , ] g.cpp/229 [90k codec time base:] g.cpp/337 [ g_camera.cpp/521 [Calling avcodec_open2] g_camera.cpp/544 [HWACCEL not in use]
Ah, it looks like you can put MJPEG into RTSP. I wasn't aware of this. I thought it would be H264 only.
Let's turn it back to H264, and see if HWACCEL is used.
03/09/19 23:35:56.391559 zmc_m2[1371].DB1-zm_ffmpeg_camera.cpp/503 [Failed to find decoder (h264_mmal)] 03/09/19 23:35:56.391698 zmc_m2[1371].DB1-zm_ffmpeg_camera.cpp/514 [Video Found decoder h264] 03/09/19 23:35:56.391767 zmc_m2[1371].DB1-zm_ffmpeg.cpp/267 [Dumping stream index i(0) index(0)]
So it looks like it tried to find the mmal decoder, but I must not have it installed. I will forget about it for now.
I'm sure I would need to install libavcodec-dev from the Raspbian repos in order to obtain it. I may have installed Debian, then migrated to Devuan, so in this case - the Pi doesn't have hardware decoding. Quite tricky to get it all setup.
Enough of that, let's try 720P and see what the PI can do...
1280x720 Mocord 2FPS (in camera)
FFMPEG Load is about 1.3
at 4FPS in camera, there is not much of a Load increase.
1.35
at 10FPS in camera, there is: about 2.9 load. some skipping on video stream, when lots of motion. I haven't tested whether the stream restarts out over time or not.
Let's jump to 1280x960
at 10FPS
about 3 load.
1920x1080 at 4FPS
about 2.6 load.
What's the max FPS we can do with this camera? Looks like it limits itself to about 1920x1080 about 9FPS
with no motion.
the streaming lags quite a bit behind.
So I would go with maybe half that, as a recommendation. 1920x1080 4FPS max.
That might be the max the RPI3 can do. with 1.32.3 or newer, 1 camera at 4FPS and 1920x1080 or similar.
No hardware encoding necessary on RPI.