Wowza Community

Pushing RTSP from Sercomm cameras

Forgive me if such an issue has been discussed anywhere in the forum before, but I wasn’t able to find it.

We have a H.264-capable Sercomm IP camera, that is able to push live streams via RTSP - I understand that Wowza is capable of receiving such a stream (based on https://www.wowza.com/docs/how-to-set-up-live-streaming-using-an-rtsp-rtp-based-encoder ). However, I wasn’t able to get that working (using pure RTP or RTP over HTTP). Is there anything in general that’s preventing such a solution from working, or should it be possible in principle? In the latter case I can provide additional details.

Thanks,

Roman

Hi

Yes Wowza can receive an RTSP stream are you sending the stream on port 1935?

Which ports are open in the VHost.xml?

Have you copied the .sdp file that is mentioned in the link you provided.

RTSP is on port 554 by default.

There is another tutorial here,

https://www.wowza.com/docs/how-to-re-stream-video-from-an-ip-camera-rtsp-rtp-re-streaming

Jason

Yes, in the current and recent version of Wowza the Property is /conf/[app-name]/Application.xml /MediaCaster /RTP /RTSP /RTPTransportMode. The default is “interleave”, which is what you want.

Note that the above is a recent change, I think it was first in Wowza 3.0.3. Prior to that, the default was UDP and the way to change to TCP (interleaved) was by adding the forceInterleaved Property to /MediaCaster /Properties list

<Property>
	<Name>forceInterleaved</Name>
	<Value>true</Value>
	<Type>Boolean</Type>
</Property>

Richard

No, this Property affects incoming streams. You cannot change the protocol for outgoing streams, which is controlled by the client.

Richard

Wowza doesn’t listen in this case. You have to know what URL:Port the stream has been published to re-stream it in Wowza.

Richard

With this method, the encoder connects to Wowza and sends a .sdp file: SDP announce. That SDP file contains the info including port that Wowza needs.

Richard

Hi

Try this link instead of the original that you posted,

https://www.wowza.com/docs/how-to-set-up-live-streaming-using-a-native-rtp-encoder-with-sdp-file

Let me know if this works for you or if you have any problems.

Jason

Re-streaming is not an option unfortunately, it has to be camera-initiated. Yes I’m sending it to port 1935 and it’s definately open (the camera get’s the connection and is able to send data, it just fails after that).

Could you elaborate a bit more on copying the .sdp? That might be the culprit since I didn’t copy anything. And the tutorial doesn’t say anything about copying an .sdp, unless I can’t read! :slight_smile:

Here’s the debug output from Wowza when an RTSP session is initiated from the camera. The connection reset by peer worries me a bit (I’m not ruling out that it’s a problem on the camera end yet):

DEBUG server comment - open

INFO server comment - handshake0: 768

INFO server comment - handshake0: 3664

DEBUG server comment - Handshake[1]: length:3575

DEBUG server comment - Handshake[2]: length:2039

DEBUG server comment - Handshake[2]: length:4935

DEBUG server comment - Handshake[2]: length:6383

DEBUG server comment - Handshake[2]: length:10046

DEBUG server comment - Handshake[2]: length:13061

DEBUG server comment - Handshake[2]: length:13129

INFO server comment - ServerHandler.exceptionCaught[[any]:1935:192.168.2.8]: java.io.IOException: Connection reset by peer

DEBUG server comment - sessionClosed: closeConnection: vhost:defaultVHost clientId:423567858

INFO session disconnect 423567858 -

DEBUG server comment - ServerHandler.handleSessionIdle: isDidClose

Looking at the TCP dump, the camera is sending an RST right at the very end which explains the reset by peer, don’t understand why though.

Hi,

sorry Jason, still the same results, the camera seems to close the connection after a short period (Wowza’s logs are always similar to the one I pasted earlier). I managed to capture what’s going on with Wireshark and this is what the Camera is sending to Wowza:

RTSP/1.0 200 OK

Host: 192.168.2.2

User-Agent: RS/000E8F779C10

Content-Type: application/octet-stream

X-Precapture: 0

X-SDP: dj0wDQpvPS0gMTM1ODggMTM1ODggSU4gSVA0IDE5Mi4xNjguMi44DQpzPVJUU1AgU2VydmVyKEgyNjQpIC0gUkM4MjIxNzc5QzEwDQpjPUlOIElQNCAwLjAuMC4wDQp0PTAgMA0KYT1jaGFyc2V0OlNoaWZ0X0pJUw0KYT1yYW5nZTpucHQ9MC0NCmE9Y29udHJvbDoqDQphPWV0YWc6MTIzNDU2Nzg5MA0KbT12aWRlbyAwIFJUUC9BVlAgOTYNCmI9QVM6NjE0NA0KYT1ydHBtYXA6OTYgSDI2NC85MDAwMA0KYT1jb250cm9sOnRyYWNrSUQ9MQ0KYT1mbXRwOjk2IHBhY2tldGl6YXRpb24tbW9kZT0xO3Byb2ZpbGUtbGV2ZWwtaWQ9NDI4MDI4O3Nwcm9wLXBhcmFtZXRlci1zZXRzPVowS0FLTm9CUUJiTUJWSUFBQU1BQkFBQUF3QjR3SUFBQyt2Q0FBQmZYaFh2ZkM4SWhHbz0sYU00OGdBPT0NCmE9eC1mcmFtZXJhdGU6MzANCmE9ZnJhbWVyYXRlOjMwLjANCmE9eC1kdXJhdGlvbjozMDANCg==

[skip binary data]

I’ve pasted the whole TCP dump with both the request and the first response from Wowza here: http://pastebin.com/WpkEjWZM . Like I’ve said, I’m not ruling out that the camera is misbehaving, but would like to understand what’s going on. Hope this isn’t too much trouble.

Update:

I finally did get it working with RTP with the SDP file (the camera was acting up and pushing the stream to random UDP ports each time…). However, pure RTP over UDP isn’t an ideal variant for us, as we’d prefer to have it over TCP. Is that something that Wowza is capable of in principle?

I thought that was a property of the outgoing stream, or am I mistaken? Whereas I’m looking for a way for Wowza to receive the stream from the camera over RTP-TCP. In any case, that only leaves me with the error I already pasted earlier (handshake, handshake … reset by peer).

Hi,

talking about UDP again. Using pure RTP, I can make the camera stream to a specific UDP port, but can’t seem to find a way of telling Wowza to listen on a specific port on a per application instance basis. Is there some way of doing that? There is the DatagramStartingPort property, but it only defines the port Wowza starts listening on, and then it incrementally increases.

Following the tutorial in https://www.wowza.com/docs/how-to-set-up-live-streaming-using-a-native-rtp-encoder-with-sdp-file, when I start receiving the stream in the stream manager (by specifying the .sdp file as the stream name), Wowza starts incrementally listening on UDP ports starting from DatagramStartingPort for the stream from the camera. Or is that not the case?

Ah, I think I see what the problem was then: the Camera would generate the SDP and set the port to 0:

m=video 0 RTP/AVP 96

so Wowza would keep trying different ports.

Problem solved, thanks for your time!

Ah, I think I see what the problem was then: the Camera would generate the SDP and set the port to 0:

m=video 0 RTP/AVP 96

so Wowza would keep trying different ports.

Problem solved, thanks for your time!

Hello,

Would you mind posting the content of the SDP file that worked for you and the settings for your sercomm camera? Thank you in advance