Solved

500: RTSP realplayer implementation

Posted on 2006-11-14
3
720 Views
Last Modified: 2008-01-09
Not sure if this is the most applicable topic area….please advise if you think differently…..
I have tried to implement a very basic rtsp server that negotiates with the client realplayer ™ Win32 version 10.5. However, the video is not playing on the client side and I get the error message – “A general error has occurred”. I cannot figure out why this is. I have tried to stream different files (.mpg and .wmv). I know that the video file is sent across the network because the ethereal trace proves it (as seen below) but the client only has a black screen coming up but nothing is played. Any clues on why this maybe? I want to get it working on both UDP and TCP but I started on TCP first because the negotiations are simpler. I have used TCP socket to listen on a particular port. When I compare both the ethereal trace of a successful RTSP streaming session with one of my failed ones then I do notice that all my packets are TCP only and not RTSP(as it should be) even though exactly the same bytes are sent, is this causing the problem. If so then how can implement and interpret data in to RTSP packets???? I am using PHP and only TCP and UDP sockets are available i.e. they don’t understand the rtsp//: protocol.

Any inputs will be much appreciated.........

The trace is found below:

OPTIONS rtsp://193.63.131.67:3001 RTSP/1.0 CSeq: 1 User-Agent: RealMedia Player (HelixDNAClient)/10.0.0.0 (win32) ClientChallenge: 0e6da7b9cb35056dc37265072aeaca55 ClientID: WinNT_5.1_6.0.12.1698_RealPlayer_RN30DL_en-us_UNK CompanyID: wymfa1UFf8sOX4/UuC15HA== GUID: 00000000-0000-0000-0000-000000000000 PlayerStarttime: [10/11/2006:18:09:59 00:00] Pragma: initiate-session RegionData: CF37 1RN

RTSP/1.0 200 OK
CSeq: 1
Date: Fri, 10 Nov 2006 18:09:55 +0000
Session: 1720561872-1
Server: Helix Server Version 9.0.6.1262 (linux-2.2-libc6-i586-server) (RealServer compatible)
Public: OPTIONS, DESCRIBE, ANNOUNCE, PLAY, SETUP, GET_PARAMETER, SET_PARAMETER, TEARDOWN
RealChallenge1: 6444b84fde531ae38a23136b3329d110 StatsMask: 3

DESCRIBE rtsp://193.63.131.67:3001/Blazer.mpeg RTSP/1.0
CSeq: 2
User-Agent: RealMedia Player (HelixDNAClient)/10.0.0.0 (win32)
Accept: application/sdp
Session: 1720561872-1
Bandwidth: 10485800
ClientID: WinNT_5.1_6.0.12.1698_RealPlayer_RN30DL_en-us_UNK
GUID: 00000000-0000-0000-0000-000000000000
Language: en-us
RegionData: CF37 1RN
Require: com.real.retain-entity-for-setup
SupportsMaximumASMBandwidth: 1
RTSP/1.0 200 OK
CSeq: 2
Date: Fri, 10 Nov 2006 18:09:55 +0000
Content-base: rtsp://193.63.131.67:3001/Blazer.mpeg/
ETag: 1720561872-1
Session: 1720561872-1
Content-type: application/sdp Content-length: 1504
v=0
o=- 1022199156 1022199156 IN IP4 193.63.131.67
s=Blazer.mpeg
i=<No author> <No copyright>
t=0 0
a=SdpplinVersion:1610641492
a=DefaultLicenseValue:integer;1
a=StreamCount:integer;2
a=Title:buffer;"bXBnMXZpZGVvLm1wZwA="
a=FileType:string;"MPEG1"
a=LicenseKey:string;"license.Summary.Datatypes.RealMPEG1.Enabled"
a=range:npt=0-7.845000
m=video 0 RTP/AVP 32
b=AS:1116
a=control:streamid=0
a=range:npt=0-7.845000
a=length:npt=7.845000
a=mimetype:string;"video/MPV"
a=Width:integer;320
a=StartTime:integer;0
a=AvgBitRate:integer;1116000
a=RMATimestampConversionFactor:integer;1
a=AvgPacketSize:integer;1024
a=RTPTimestampConversionFactor:integer;90
a=Height:integer;240
a=Preroll:integer;1500
a=HasOutOfOrderTs:integer;1
a=MaxPacketSize:integer;1500
a=MaxBitRate:integer;1674000
a=ASMRuleBook:string;"marker=0, Priority=9, timestampdelivery=true; marker=1, Priority=9, timestampdelivery=true;"
m=audio 0 RTP/AVP 14
b=AS:112
a=control:streamid=1
a=range:npt=0-7.845000
a=length:npt=7.845000
a=mimetype:string;"audio/MPA"
a=StartTime:integer;0
a=AvgBitRate:integer;112000
a=RMATimestampConversionFactor:integer;1
a=SampleRate:integer;44100
a=AvgPacketSize:integer;1024
a=RTPTimestampConversionFactor:integer;90
a=Preroll:integer;1500
a=NumChannels:integer;2
a=HasOutOfOrderTs:integer;1
a=MaxPacketSize:integer;1500
a=MaxBitRate:integer;168000
a=ASMRuleBook:string;"marker=0, Priority=9, timestampdelivery=true; marker=1, Priority=9, timestampdelivery=true;"
SETUP rtsp://193.63.131.67:3001/Blazer.mpeg/streamid=0 RTSP/1.0
CSeq: 3
RealChallenge2: db0062d0568e5e775e765f716c9b8d2901d0a8e3, sd=d6555568
RDTFeatureLevel: 2
Transport: x-pn-tng/tcp;mode=play,x-real-rdt/tcp;mode=play,RTP/AVP/TCP;unicast;mode=play
User-Agent: RealMedia Player (HelixDNAClient)/10.0.0.0 (win32)
If-Match: 1720561872-1
RTSP/1.0 200 OK
CSeq: 3
Date: Fri, 10 Nov 2006 18:09:55 +0000
Session: 1720561872-1
Reconnect: true
RealChallenge3: 2fe4384a4893ef35ce89ced60a2ba5864f213d09,sdr=234ecc0a
RDTFeatureLevel: 2
Transport: x-pn-tng/tcp;interleaved=0
SETUP rtsp://193.63.131.67:3001/Blazer.mpeg/streamid=1 RTSP/1.0
CSeq: 4
RDTFeatureLevel: 2
Transport: x-pn-tng/tcp;mode=play
User-Agent: RealMedia Player (HelixDNAClient)/10.0.0.0 (win32)
Session: 1720561872-1
RTSP/1.0 200 OK
CSeq: 4
Date: Fri, 10 Nov 2006 18:09:55 +0000
Session: 1720561872-1
RDTFeatureLevel: 2
Transport: x-pn-tng/tcp;interleaved=0

SET_PARAMETER rtsp://193.63.131.67:3001/Blazer.mpeg RTSP/1.0
CSeq: 5
Subscribe: stream=0;rule=0,stream=0;rule=1,stream=1;rule=0,stream=1;rule=1
Session: 1720561872-1
PLAY rtsp://193.63.131.67:3001/Blazer.mpeg RTSP/1.0
CSeq: 6
User-Agent: RealMedia Player (HelixDNAClient)/10.0.0.0 (win32)
Session: 1720561872-1 Range: npt=0-7.844000

RTSP/1.0 200 OK
CSeq: 5 Date: Fri, 10 Nov 2006 18:09:55 +0000 Session: 1720561872-1
RTSP/1.0 200 OK CSeq: 6 Date: Fri, 10 Nov 2006 18:09:55 +0000 RTP-Info: url=rtsp://193.63.131.67:3001/Blazer.mpeg/streamid=0;seq=0;rtptime=0
 
......`..W......Encoded by North Valley Research, Beaverton, OR
 128x96, 30.00fps, I:P:B of 1:3:2
 Logrithmic. mot. est., radius 16
 fixed rate 140000 b/s
.
........@............b..LC.az....T..s.. ...........M..).^.w......[|..x.)....z.`U.........K...ga.x.....fP.....w]kqx.^.........S..Q.^Y]..w.........C..N.*..0.^.._..,...I......g.pn..;.Ti..E.....'.5..eXa1%.!....0{....K..1.....S./2R..u;f}.......4!..k.C...............3.#..Vmy........QN..|...|....P.j......P.p........J.+.44.3.@c.X..uk..JF,4..3'......J.......#2.?...f.U.p[..g.g.;.........(....O..@.....P..BK/.B..?...O;`...M&.4.Y7...^ID..L!.......,[.....o...M.....P.U.~YN..=Ga?.Nz.^...K.[:...w.n.%n.~.-Mh.%.>F.A...Y|...=.;..7:...s.r...?....}..+.......c3u+...o>..VQ'-*...s......s..|.N..._.AiG....>.}b...?..RQ.H.....Gn.s.s^{..}t...D...:.:N<.8 ..)....@.w._D.j....5..bK....=H._...\.!....|.O..H.RF........)fa.v.l[..6.M......{..U.....78X._...
|.Q......Om.........2....t..g{..r....s..... o../.....WS.n.AIJ.gg....n.~4...
G.....71Ds=....._..%........4BK.BKX..Nf.....1.M....II+.w.w.D..._/...u..cOq..Y5 0F.+b_f..#...r~.+.q}-.:..V.q.^8u.........}.J.5 _.e ..
.
...r.......0.e....7I.b.1
q]+O..k^..O..k.....o.>....+..TS./U...A....i.q...+.:vA/.......>.B,.:v.%.....'....NF^.|.+..!......Z~!'~.1.5%.....s.0..4.....t....N......0q....^..~v.;a?...(.....~.....[.....=yB...{.......(b:.._<R...D...<..N.F.......F..&.~'......(.BBHo.......E..).q.b....<'...B.'....V@.Kq...a.k:.Q\pHN...~ .V...9...._...6(hJ..+....|..}......"...S..i[..-U.u...g....*.Y..cm.w.}Q..)%.....m...(........!X=?....n..-...8V...:..4....4......4......../...0...a,G....
 ....RR.-#7.l...;fkw...t.T.........eU<..RS.>......b...d.....^.!4........wF...m..HA_..% .b...{..Q././.....-....v....u.i1..#..oW{..D.......@|...v.U.t....(.3>.N......e.........@|...3.._-o.....q ...............}..Wu....y...-.j.......fcO.....
.....f..` f.VR.......nwJ..f..m..?..mxjqe...;o........0.A[...s..w....C..O2...]..e..k^m.UVd....CD...yow#.j...:..`B.&.H.H.x..;.Pbh$...P.+.....q........x.A.... i I.`C.PRh$..."Z...Fq..-...W....U..... i V.....AI........P?...;..k!.g.e..P....A..0....,.....l.c.<:.$0..`....._Y.z....S...._....!,..7s...]...$..?.O.......l.W.&%......dva.).N;.....tC.. .........."...H.H.9].#a...'....>..=..:.....A$ $.......(h$...d.J.h...8.}]...L.A..4.@.@....`C.&.H.H....../Hg................R#`xXPt......G.8....4Xv.:.p..%P.<w^.}.y..;/.>......=.._f.=.......U..yF8.&..o.z#fG|......#.............>.....\(X.....
...D|x.k......k.8......f.o.6.....c.8g..|..)....$}......
R..........3i..#.;.....+...V'[.n..t"..s.V5.s......................... ` @.....>`x.." .pP..qq.a.....?...'......
...&..!<.....Y....p.,|X.O.a.C.P..5...x...0Xq.[....5...E/.....~W......P.F.T...u3.;..NQ.q.2... ....0....Lf.>.+..[>.n.wn.n...%....$...v3..z$8w.on........+:Go.{.F...0..~.....8...>.>.B.:.@.. ....#..9...1j.<{...k.p.....G>..7.K...,..O`.e...)......6dG...&.[....|."(-...`p)l.._'..<..<.....p..Dw=dW#.&..;...9....'....o.U..d.<.$....^Z.....q....9......R...rO..%(..+3.d............s...Y...Q.=..?.......a.q.ti..v....wi...q...e....8q....D..Y.>9|..K
.q}X......p..|...../...."P.......{.........%X!.~ x.............8....m.........A?.......J@......3....p.........~...v?.{........>
.O.%G..........~..%:Y.A.?..v-.7f}....gB.o..G.[.~n...p>.].......g_9.....6......_f@....~...E-....O.q...#.)..;.s~.6|......0..[....'...F.....vV..7K'..8<Wf.;..5.}!dj%.....I.R.OabH.........[...-.N.. l......#=.8.=.C..a..C........
.T....._.......b$t..;a .@..#(~_S....D..TU..x.=..I.....GQ.......d...@.;...0..#.....A.9..........4..~s......8....$..~..9......8...a.[.....TS.......G.X........Q'z".......)|A..J
...Q../.|H..(.~..X+Bn..K.i....(......y.O.~.5..3:.......S(>.....X......{.?2#..8..I....p.1...2.... h.^p..4.?.G<...O0.......................w..!.3....../n.[.+.o.EX.@........wg.E=.....G...|..89d...l.m.<..../g......_...W.......|Z... .
.
.
.Rest of file transfer….
.  
.
.
.
0
Comment
Question by:smotbd
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 7

Accepted Solution

by:
dlangr earned 500 total points
ID: 17942568
I know of no rtsp streaming server implementations in php, probably for a good reason. You should probably use something like http://developer.apple.com/opensource/server/streaming/index.html and use php to serve a link to the content.

i might be wrong ofcourse, but using php alone does not seem feasable.
0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Connectivity issues after power outage 5 64
Basic Client Hyper-V test lab connectivity issue. 7 75
VPN Server 5 55
How do you restart a stacked switch? Hp Procurve 3 60
Data center, now-a-days, is referred as the home of all the advanced technologies. In-fact, most of the businesses are now establishing their entire organizational structure around the IT capabilities.
When it comes to security, there are always trade-offs between security and convenience/ease of administration. This article examines some of the main pros and cons of using key authentication vs password authentication for hosting an SFTP server.
Viewers will learn how to connect to a wireless network using the network security key. They will also learn how to access the IP address and DNS server for connections that must be done manually. After setting up a router, find the network security…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question