Sign up here and you can log into the forum!

Problem with UMSP flv streaming (blank picture on playback)

Discussion, features, plugins--everything about zoster's UMSP UPnP Media Server software

Problem with UMSP flv streaming (blank picture on playback)   

Postby aenbacka » Sun Sep 30, 2012 10:41 pm

I am developing a WLDXTV UMSP media server plug-in for the Finnish Yle Areena broadcast service. The plugin currently works fine up to the point when playback should begin. Then all i get is a blank (black picture), and after a while a message that the media file format is not supported. Yle Areena provides it content using h.264 codec in FLV container, so it should be playable on wdtv (I have tried by downloading a complete show from Yle-Areena to local usb disk, and playback works just fine). Debug output from media render shows error MediaFormat_Unknown. Below is an extract from the php rtmp-proxy that I am using with the UMSP plugin (I am running the proxy on a raspberrypi dedicated to this task, it should be up to it as no transcoding should be necessary):


Code: Select all
...
  $cmd = "/usr/local/bin/yle-dl $pageURL -o - | cat -";
  $format = "x-flv";
  $filename = "tmp_video.flv";
  header('Content-Type: video/'.$format.'');
  header('Content-Length: 1073741823'); //some sufficient content length
  header('Content-Disposition: attachment; filename='.$filename.'');
  header("Accept-Ranges: bytes");
  header("Connection: close");   
  passthru($cmd); //execute commands (i.e., start the yle-dl process)


Any information, suggestions concerning what could be wrong is greatly appreciated. I am currently on firmware 1.03.49_V-WDLXTV-Live-0.4.7.3 (I have also tried with firmware 1.05.04_V-WDLXTV-Live-0.5.1.1 with same result).
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby Gui » Mon Oct 01, 2012 4:24 am

"If the server closes the connection without sending back anything (including headers), MediaLogic locks up."
User avatar
Gui
Developer
 
Posts: 161
Joined: Wed Jan 11, 2012 4:19 pm
Location: Hellgarve

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby mad_ady » Mon Oct 01, 2012 7:46 am

I doubt it it's this issue - since he is sending the headers and then passthru-ing the content.

You could try a packet capture (between the wdtv and the rapsberry pi - to make sure you are sending correct video output, and not some php warnings... Also, you can try a light container change with ffmpeg - from flv (which doesn't have great support) to mkv or mp4...
User avatar
mad_ady
Developer
 
Posts: 4552
Joined: Fri Nov 05, 2010 9:08 am
Location: Bucharest, Romania

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Tue Oct 02, 2012 1:33 am

Thanks a lot for the suggestion. I could try to use ffmpeg indeed and change container to e.g., matroska mkv. I have tried with the umsp-test.php script and the proxy seems to deliver valid .flv data.
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Tue Oct 02, 2012 10:05 am

I have now tried by using ffmpeg and outputting matroska mkv, with the same result. It seems that whatever format I use the result is the same, just a blank screen with no output. Running the problem with umsp-test produces the correct (working) output that can be played back by wdtv (as a local file).
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby mad_ady » Tue Oct 02, 2012 9:40 pm

How long are you waiting when playing back? I know there are issues when wdtv tries to play back a stream, and it tries to buffer it, so it may take from 20s - 1 minute before playback begins.
Make sure you leave it time.
User avatar
mad_ady
Developer
 
Posts: 4552
Joined: Fri Nov 05, 2010 9:08 am
Location: Bucharest, Romania

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Tue Oct 02, 2012 9:58 pm

I have trying to wait for a quite long time, after a while it normally ends up with an error message about "unknown media format". Could this problem be related to firmware / firmware version?
I have also tried to transcode the output with ffmpeg (using e.g., video codec mpeg-4) with the same result. In case someone is interested in the plugin source, it can be downloaded from the link below.

https://skydrive.live.com/redir?resid=FB2975A3FD49F679!293&auth
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby mad_ady » Wed Oct 03, 2012 12:27 am

Not sure if it will help, but you can try to run MediaLogic in debug mode to see if you can find out why it complains (compare it with output from a playable video):

Code: Select all
kill `pidof MediaLogic`
MediaLogic AV MSGL_DBG
User avatar
mad_ady
Developer
 
Posts: 4552
Joined: Fri Nov 05, 2010 9:08 am
Location: Bucharest, Romania

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Wed Oct 03, 2012 12:39 am

Thanks a lot for the suggestion, I will indeed give that a try.
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Wed Oct 03, 2012 10:23 am

I tried again with the matroska mkv format, and got the following MediaLogic debug output:

Code: Select all
...
NW_Http_ParseResponse 266 http get header timeout
MA_GetServerProperty 714 replace method get with head
(MPAuxiliary.c , 927 )server_type = 0
[ERR:MediaPlayer:MA_HttpPrepareProc:933]get server property failed
[ERR:MediaPlayer:mp_open:376] errNo=-8
SMD_SendMallocCommand enter
SMD_SendCommand 8
SMD_GetCommand 4 8
[ERR:MediaPlayer:mp_open:514]Leave MP_CreateInstance with error
SMD_SendMallocCommand enter
SMD_SendCommand 8


Does this tell something what could be the problem?
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Next

Return to UMSP Media Server

Who is online

Users browsing this forum: No registered users and 2 guests

cron