MP hangs when scheduled recording starts. (1 Viewer)

Sebastiii

Development Group
  • Team MediaPortal
  • November 12, 2007
    16,583
    10,403
    France
    Home Country
    France France
    @mm1352000

    I have found an answer from @michael_t but it was about resume code event
    The configured delay should be respected in the OnResumeAutomatic() method, since this is the first to be called and it is called on every resume (automatically and manually). OnResumeSuspend() should wait until OnResumeAutomatic() has finished and then do its work.
    I am rather sure that there are no multiple messages from Windows, but maybe there are WndProc() message handlers inside MP that are called more than once (maybe because they belong to separate forms that get their own message (TV?) and are additionally called from MediaPortal.cs).
    So this should be fixed by strictly centralizing the message handling in MP.
    The only problem I can see is when there is a Windows suspend while the resume code is not yet finished (because it takes long time or because of the configured delay). Then we should carefully think what should happen: For me it makes no sense to finish the interrupted resume code after the next resume, so it should be cancelled immediately on a suspend.
    Michael
    Well, this is Microsoft's description (http://msdn.microsoft.com/en-us/library/windows/desktop/aa372720(v=vs.85).aspx) and I have no doubt that it is correct. I can also watch this on my system (1.7 Test build)

    And another comment from Tourettes :
    [14-10-18 11:40:35] about PostMessage, it is thread safe in that sense that it will deliver the message to the message queue - and MP Main thread will read those messages, so there cannot be multiple events processed at the same time and same applies to the OS events
     

    joecrow

    Test Group
  • Team MediaPortal
  • August 9, 2012
    2,660
    2,002
    Home Country
    Germany Germany
    @joecrow :)
    You can try this installer : http://tinyurl.com/jercwpc
    The bug introduce was reverted so maybe it will solve your issue :)

    This works great (y), the HTPC now wakes to make a scheduled recording without the AVR/TV waking. I can use the USB remote to then wake up the AVR/TV and MP is no longer frozen:). So far all other sleep/wake type functions also appear to be working normally.
    Many many thanks to all:D
    Joe
     

    Tuomaa

    Portal Pro
    September 21, 2007
    129
    148
    Home Country
    Finland Finland
    @joecrow :)
    You can try this installer : http://tinyurl.com/jercwpc
    The bug introduce was reverted so maybe it will solve your issue :)

    This works great (y), the HTPC now wakes to make a scheduled recording without the AVR/TV waking. I can use the USB remote to then wake up the AVR/TV and MP is no longer frozen:). So far all other sleep/wake type functions also appear to be working normally.
    Many many thanks to all:D
    Joe

    Can you confirm that everything works OK now for CECRemote as well? No need for changes?
    EDIT: I saw your post in CECRemote thread. (y)
     

    joecrow

    Test Group
  • Team MediaPortal
  • August 9, 2012
    2,660
    2,002
    Home Country
    Germany Germany
    Can you confirm that everything works OK now for CECRemote as well? No need for changes?
    EDIT: I saw your post in CECRemote thread. (y)
    Just for any further clarification:-
    From my point of view everything is looking very good, :D so definitely no need for any changes to the CECRemote(y).
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Thanks for the testing and feedback joecrow - it's very much appreciated! (y)

    Thanks also for your fast and helpful input Tuomaa. :)

    @Sebastiii
    I have found an answer...
    It seems those answers are only slightly related.
    When Michael says "multiple messages", I wonder if he means "simultaneous" or "duplicate"... because it's quite different.
    He's right about the delay for resume (though unfortunately the code currently does not do that), but IMHO that is not directly related to the question.
    I want to agree with tourettes, but the log files show that MP received a message while it was still processing the previous message. So it seems either he is mistaken, or the situation is more complex than he realised.
     

    joecrow

    Test Group
  • Team MediaPortal
  • August 9, 2012
    2,660
    2,002
    Home Country
    Germany Germany
    Is this going into 1.14 Final?

    I think it is. Sorry I can't be 100% sure :unsure:as I'm using a madvr test version, but that is based on 1.14 final and the problem reported here is fixed in that.
     

    Users who are viewing this thread

    Top Bottom