[TV] - HD-PVR TV freezes After Channel Change When using SPDIF | Page 3

Discussion in '1.3.x' started by cwchapma, April 27, 2013.

  1. cwchapma

    cwchapma Portal Pro

    Joined:
    October 15, 2006
    Messages:
    56
    Likes Received:
    17
    Ratings:
    +22 / 0
    Home Country:
    Canada Canada
    Show System Specs
    I don't even need to wait - a quick pause and play and it starts up again. Of course, I'm always waiting to make sure it's stuck (even though it always is) and it's buffering data on the server as soon as the stream sorts itself out even though my client video is frozen.

    Does that help?

    Clint


     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. Owlsroost
    • Team MediaPortal

    Owlsroost Development Group

    Joined:
    October 28, 2008
    Messages:
    5,537
    Likes Received:
    2,829
    Location:
    Cambridge
    Ratings:
    +4,131 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    Using TsReader v73, open regedit and go to HKEY_CURRENT_USER\Software\Team MediaPortal\TsReader, and set 'EnableBufferLogging' to 1.

    This will make it log the internal video/audio/RTSP buffer status every 4 seconds, which should tell us what is running out of data (or not using it, if the video decoder is hanging etc.)
     
    • Like Like x 1
  4. cwchapma

    cwchapma Portal Pro

    Joined:
    October 15, 2006
    Messages:
    56
    Likes Received:
    17
    Ratings:
    +22 / 0
    Home Country:
    Canada Canada
    Show System Specs
    Done. See attached logs. Hope that helps.

    Edit: To be clear. I started Live TV, changed the channel, waited about 5 seconds, paused and unpaused, and then shutdown.

    Clint
     
    Last edited: May 2, 2013
  5. Owlsroost
    • Team MediaPortal

    Owlsroost Development Group

    Joined:
    October 28, 2008
    Messages:
    5,537
    Likes Received:
    2,829
    Location:
    Cambridge
    Ratings:
    +4,131 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    Thanks for the logs - I'll take a look when I get back from vacation in a few days time.
     
  6. LesD

    LesD Portal Member

    Joined:
    May 10, 2012
    Messages:
    8
    Likes Received:
    0
    Gender:
    Male
    Ratings:
    +0 / 0
    Home Country:
    United States of America United States of America
    Have the same exact problem here, so if there is a need for additional logs, let me know.
     
  7. Owlsroost
    • Team MediaPortal

    Owlsroost Development Group

    Joined:
    October 28, 2008
    Messages:
    5,537
    Likes Received:
    2,829
    Location:
    Cambridge
    Ratings:
    +4,131 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    OK - shortly after the channel change, TsReader stops receiving data (as far as I can tell):

    Code (Text):
    1. 02-05-2013 18:00:47.697 [13380048] [180c] Vid/Ref : 84.515, ?-frame(00), Compensated = 0.447 ( 0.448 A/V buffers=11/07), Clk : 0.000000, SampCnt 2, stallPt 2.500
    2. 02-05-2013 18:00:47.704 [13380048] [15f0] CTsReaderFilter::Run(81515.21) state 1 seeking 0
    3. 02-05-2013 18:00:47.704 [13380048] [15f0] Run() - Elapsed time from pause to Audio/Video ( total zapping time ) : 1604 mS
    4. 02-05-2013 18:00:47.704 [13380048] [15f0] CTsReaderFilter::Run(81515.21) state 2 -->done
    5. 02-05-2013 18:00:47.705 [13380048] [180c] Vid/Ref : 84.548, ?-frame(00), Compensated = 0.497 ( 0.496 A/V buffers=10/05), Clk : 0.001000, SampCnt 4, stallPt 2.500
    6. 02-05-2013 18:00:47.706 [13380048] [ 690] Aud/Ref : 84.214, Compensated = 0.492 ( 0.489 A/V buffers=10/04), Clk : 0.003000, SampCnt 6, Sleep 1 ms, stallPt 0.800
    7. 02-05-2013 18:00:47.706 [13380048] [180c] Vid/Ref : 84.548, ?-frame(00), Compensated = 0.497 ( 0.494 A/V buffers=09/04), Clk : 0.003000, SampCnt 5, stallPt 2.500
    8. 02-05-2013 18:00:47.708 [13380048] [ 690] Aud/Ref : 84.246, Compensated = 0.524 ( 0.520 A/V buffers=09/03), Clk : 0.004000, SampCnt 7, Sleep 1 ms, stallPt 0.800
    9. 02-05-2013 18:00:47.708 [13380048] [180c] Vid/Ref : 84.582, ?-frame(00), Compensated = 0.547 ( 0.544 A/V buffers=08/03), Clk : 0.004000, SampCnt 6, stallPt 2.500
    10. 02-05-2013 18:00:47.710 [13380048] [ 690] Aud/Ref : 84.278, Compensated = 0.556 ( 0.550 A/V buffers=08/02), Clk : 0.006000, SampCnt 8, Sleep 1 ms, stallPt 0.800
    11. 02-05-2013 18:00:47.711 [13380048] [ 64c] Demux : Audio to render 0.806 Sec
    12. 02-05-2013 18:00:47.711 [13380048] [ 64c] Demux : Video to render 1.020 Sec
    13. 02-05-2013 18:00:47.723 [13380048] [ 64c] Demux : Video to render 0.908 Sec
    14. 02-05-2013 18:00:48.460 [13380048] [ 64c]  H.264 2nd GOP found 85.683000
    15. 02-05-2013 18:00:51.168 [13380048] [1180] Buffers : A/V = 0/0, RTSP = 0, A last : 86.006, V Last : 86.217
    16. 02-05-2013 18:00:55.457 [13380048] [1180] Buffers : A/V = 0/0, RTSP = 0, A last : 86.006, V Last : 86.217
    17. 02-05-2013 18:00:59.745 [13380048] [1180] Buffers : A/V = 0/0, RTSP = 0, A last : 86.006, V Last : 86.217
    18. 02-05-2013 18:01:04.033 [13380048] [1180] Buffers : A/V = 0/0, RTSP = 0, A last : 86.006, V Last : 86.217
    19. 02-05-2013 18:01:04.739 [13380048] [ 2cc] CTsReaderFilter::Pause() - IsTimeShifting = 1 - state = 2
    20. 02-05-2013 18:01:04.739 [13380048] [ 2cc]  -- Pause()  ->pause rtsp at position: 103.290000
    21. 02-05-2013 18:01:04.739 [13380048] [ 2cc] CRTSPClient::Pause()
    22. 02-05-2013 18:01:04.739 [13380048] [ 2cc] CRTSPClient::Pause() stopthread
    23.  
    There are four identical "Buffers : A/V = 0/0, RTSP = 0, A last : 86.006, V Last : 86.217" messages, which means it's not received any new RTSP data for at least 12 seconds (but it has received enough to start playing initially), so presumably the server has stopped sending it. When you pause in RTSP mode, it stops/closes the current session and then starts a new session when you un-pause it - which is presumably why it fixes the freeze.

    On the evidence so far, this looks like a TV server problem, but I can't help much more because I know nothing about how the RTSP side of TV server works at the moment.
     
  8. Owlsroost
    • Team MediaPortal

    Owlsroost Development Group

    Joined:
    October 28, 2008
    Messages:
    5,537
    Likes Received:
    2,829
    Location:
    Cambridge
    Ratings:
    +4,131 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    My guess as to why it only has the problem with SPDIF input is because the SPDIF receiver takes time to lock onto the new signal, and while it's unlocked the HDPVR probably doesn't produce any output data stream (to MP TV-server).

    I can't tell without matching server + client logs, but maybe the RTSP server is timing out because it keeps hitting timeshift buffer end-of-file in this situation ?
     
  9. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    Hmmm...
    I've never looked at the streaming server code so this will be a new adventure for me as well.
    Just thinking out loud...
    If the problem is that either the streaming server or TsReader are running out of data then it is directly due to the fact that the HD-PVR has stopped delivering data. We could increase the size of the buffer on the streaming server (with the implication that channel switching would take longer), however that seems like it isn't really solving the problem. In principle I don't really like the solution.

    What would solve the problem is to halt the channel change in the TV library until the proper PMT is received.

    Now, there are several issues with doing that.
    1. TsWriter will not event PMT when it is identical to the previous PMT in all but version number.
    2. It is difficult (if not impossible) to recognise the proper PMT when it arrives.

    The first point is really annoying but apparently necessary. (@morpheus_xx do you remember any details about this problem? Maybe we could loosen the checking?)
    http://mantis.team-mediaportal.com/view.php?id=2886

    Maybe it could be reworked so that TsWriter events the PMT but TV library (instead of TsWriter) checks whether the streams have changed.
    In the case of DVB/ATSC, if there is no stream change => don't do anything with the PMT.
    In the case of capture => *might* represent channel change.

    The second point: due to the first point and different device behaviours, one cannot easily count PMTs. One also can't know whether the audio should be AAC or AC3/DD... and this wouldn't always tell us whether the PMT represents a completed channel change either.

    No obvious solution here in my opinion.
     
  10. CanadianEh

    CanadianEh Portal Pro

    Joined:
    July 21, 2011
    Messages:
    121
    Likes Received:
    8
    Ratings:
    +13 / 0
    Home Country:
    United States of America United States of America
    I'm pretty sure I am now having this issue with MediaPortal 1.6 Pre-release, although the behavior is a little different than above. I am using the UNC paths for the remote client in the advanced settings, and when it freezes, the Pause-then-Play again doesn't do anything for me. In order to undo the freeze, I have to hit Stop, and then select the channel again in order for it to play.

    My config is using an HD-PVR with SP/DIF audio from a DirectTV receiver.

    If someone can specify which logs would be helpful on both the client and the server, I will capture them and pass them along. I'd really love to get this fixed if it's possible. The Dolby Digital sound is so much better than the stereo audio output :)[DOUBLEPOST=1387759364][/DOUBLEPOST]@cwchapma , what HD-PVR drivers are you using? I'm curious as to why you are able to use the UNC fileshares without issue, while I'm still seeing the freezing.

    Thanks!!
     
  11. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    Presumably you only experience this problem when playing live TV on remote clients, right?

    All log files from both client and server are required.

    1. Before doing anything, make sure that TV Server log level is set to debug:
    http://wiki.team-mediaportal.com/1_.../TV-Server_Configuration/06_General#Log_Level

    2. Restart the TV service.

    3. Use the watchdog/debug tool with option 1 on the client to reproduce the problem and acquire the client log files:
    http://wiki.team-mediaportal.com/1_MEDIAPORTAL_1/16_Support/3_Forums/2_Log_Files

    4. Grab the server log files. If you don't have MediaPortal installed on the server you'll have to grab the TV Server logs manually:
    1. Open TV Server configuration.
    2. Click "open log directory" in the top left corner.
    3. Zip all the files you find in that folder.​

    Otherwise, use the watchdog [on the server] with option 3.

    5. Post/attach the two zip files from steps 3 and 4 here.

    Thanks,
    mm
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!