RTSP in security video surveillance

RTSP is a protocol used more in security equipment. The full name is Real Time Streaming Protocol, a real-time streaming protocol. It is better to understand the literal meaning. Streaming includes both video streams and audio. The RTSP protocol is an application layer protocol in the TCP/IP system, which supports TCP or UDP transmission. It can transmit audio and video streams one-to-many, supports two-way transmission, active or passive, and has a high tolerance for network delays.

RTSP and HTTP have a lot in common in grammar and operation, so RTSP uses HTTP webpage security mechanism. At the same time, RTSP stream can be embedded in the webpage to realize real-time playback. The following text has the corresponding HTML webpage code.

RTSP addresses of common security manufacturers’ security equipment

HIKVISION

Default IP address: 192.168.1.64/DHCP username admin password set by yourself
Port: “HTTP port” (default is 80), “RTSP port” (default is 554), “HTTPS port” (default 443) and “service port” (default 8000), ONVIF port 80.
RTSP address: rtsp://[username]:[password]@[ip]:[port]/[codec]/[channel]/[subtype]/av_stream
instruction:
username: username. For example, admin.
password: password. For example, 12345.
ip: is the device IP. For example, 192.0.0.64.
port: The default port number is 554, if it is the default, leave it blank.
codec: There are h264, MPEG-4, and mpeg4.
channel: Channel number, starting with 1. For example, channel 1 is ch1.
subtype: stream type, the main stream is main, and the auxiliary stream is sub.
For example, to request the main stream of HIKVISION camera channel 1, the Url is as follows
Main stream:
rtsp://admin:[email protected]:554/h264/ch1/main/av_stream
Sub stream:
rtsp://admin:[email protected]/mpeg4/ch1/sub/av_stream

DAHUA

Default IP address: 192.168.1.108 username/password: admin/admin
Port: TCP port 37777/UDP port 37778/http port 80/RTSP port number default is 554/HTTPs 443/ONVIF function is disabled by default, port 80
RTSP address: rtsp://username:password@ip:port/cam/realmonitor?channel=1&subtype=0
instruction:
username: username. For example, admin.
password: password. For example, admin.
ip: is the device IP. For example, 10.7.8.122.
port: The default port number is 554, if it is the default, leave it blank.
channel: Channel number, starting with 1. For example, channel 2, then channel=2.
subtype: stream type, the main stream is 0 (that is, subtype=0), and the sub stream is 1 (that is, subtype=1).
For example, to request the auxiliary stream of channel 2 of a certain device, the Url is as follows
rtsp://admin:[email protected]:554/cam/realmonitor?channel=2&subtype=1

XIONGMAI/JUFENG(XM)

Default IP address: 192.168.1.10 username admin password is empty
Port: TCP port: 34567 and HTTP port: 80, onvif port is 8899
RTSP address: rtsp://10.6.3.57:554/user=admin&password=&channel=1&stream=0.sdp?
10.6.3.57 This is the IP of the connected device
554 This is the port number of the RTSP service, which can be changed in the network service of the device
user=admin This is the login user name of the device
password= empty password
channel=1 first channel
stream=0.sdp? Main stream
stream=1.sdp? Secondary stream
Picture capture address: http://ip/webcapture.jpg?command=snap&channel=1

TOPSEE

Default IP address: 192.168.0.123 username admin password 123456
Port: http port 80 data port 8091 RTSP port 554 ONVIF port 80
RTSP address: main stream address: rtsp://192.168.0.123:554/mpeg4
Sub stream address: rtsp://192.168.0.123:554/mpeg4cif
Address where password is required: Main stream rtsp://admin:[email protected]:554/mpeg4
Sub stream rtsp://admin:[email protected]:554/mpeg4cif
Picture capture address: http://ip/snapshot.cgi

NVSEE/NVSIP(SUNYWO)

Default IP address: DHCP default username admin default password empty
RTSP address: rtsp://0.0.0.0:8554/live1.264 (secondary stream)
rtsp://0.0.0.0:8554/live0.264 (main stream)

JUAN(IP PRO,ESeeCloud,VR CAM)

RTSP address: rtsp://IP:port (website port)/ch0_0.264 (main stream)
rtsp://IP:port (website port)/ch0_1.264 (sub-stream)

GWELL(YOOSEE)

Default IP address: DHCP username admin password 123
RTSP address: Main stream: rtsp://IPadr:554/onvif1
Secondary stream: rtsp://IPadr:554/onvif2
onvif port is 5000
The port discovered by the device is 3702

V380

Default IP address: DHCP username admin and password empty/admin
onvif port 8899
RTSP address: main stream rtsp://ip//live/ch00_1
Substream rtsp://ip//live/ch00_0

UNIVIEW

Default IP address: 192.168.0.13/DHCP default username admin and default password 123456
Port: HTTP 80/RTSP 554/HTTPS 110(443)/onvif port 80
RTSP address: rtsp://username:password@ip:port number/video123 123 corresponds to 3 streams

TIANDY

Default IP address: 192.168.1.2 username “Admin”, password “1111”
onvif port number “8080”
RTSP address: rtsp: //192.168.1.2

JVT

Default IP address: 192.168.1.88 Default user name admin Default password admin
RTSP address:
Main stream address: rtsp://IP address/av0_0
Secondary stream address: rtsp://IP address/av0_1
onvif port 2000
Picture capture address: http://ip/capture/webCapture.jpg?channel=1&FTpsend=0&checkinfo=0
(http://ip/cgi-bin/images_cgi?channel=1&user=admin&pwd=admin)

Web page uses RTSP to play video

The following HTML code can directly play the rtsp video stream on the webpage, and you can use the IE core browser.

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
</head>
<body>
<script type="text/javascript">
window.onload=function(){
vlc.mrl='rtsp://admin:[email protected]:554/av0_0';

}
</script>
    <object type='application/x-vlc-plugin' id='vlc' width="220" height="130">
<param name='mrl'  value ='rtsp://admin:[email protected]:554/av0_0'/>
        <param name='autoplay' value='true' />
        <param name='fullscreen' value='true' />
    </object>
</body>
</html>

The Chrome browser does not support plug-ins, so the rtsp address cannot be used directly, but it supports the rtmp and hls protocols. You can convert rtsp to rtmp or hls, and then use the Chrome browser to play directly.

RTSP tools

The well-known VLC player can support rtsp video stream very well. At the same time, VLC player has corresponding client on computer and mobile phone, so that VLC can play rtsp video stream on multiple terminals.

For some security devices that do not know the rtsp video stream address, we can use the third-party onvif tool ONVIF Device Manager to detect the rtsp video stream address.

RTSP and HLS, RTMP

RTMP is generally used in the Internet live broadcast industry, especially CDN manufacturers, HLS streams are generally used for http web-side video stream playback, and RTSP security manufacturers are commonly used.

Although RTSP supports one-to-many access, the front-end security equipment has limited hardware performance and cannot support too many users’ access at the same time (generally, it can support up to 1-3 users online at the same time). If a large number of users are required to access online at the same time, then we need to consider using streaming media forwarding methods or Internet RTMP live broadcast solutions.

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *