Custom Data Grabber including Sky UK Channel/EPG Grabber | Page 258

Discussion in 'General Development (no feature request here!)' started by DJBlu, May 19, 2011.

  1. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,526
    Likes Received:
    4,734
    Ratings:
    +8,200 / 17
    Home Country:
    New Zealand New Zealand
    Looks maybe like a threading issue.
    PS is listening for events. It sees the WM_POWERBROADCAST (PBT_POWERSETTINGCHANGE) and starts a thread to stop playback and clean up the graph ("PS: Player is playing, kick off stop player thread"). Then it receives another of the same events while the other thread is still running. It starts another thread which throws the exception because the first thread has already [partially] done the job. That is my best guess... :)


     
    • Thank You! Thank You! x 1
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. richardc1983

    richardc1983 Portal Pro

    Joined:
    October 10, 2012
    Messages:
    251
    Likes Received:
    18
    Gender:
    Male
    Location:
    Leeds
    Ratings:
    +25 / 3
    Home Country:
    United Kingdom United Kingdom
    If I use the standard version I lose sky functionality.
     
  4. richardc1983

    richardc1983 Portal Pro

    Joined:
    October 10, 2012
    Messages:
    251
    Likes Received:
    18
    Gender:
    Male
    Location:
    Leeds
    Ratings:
    +25 / 3
    Home Country:
    United Kingdom United Kingdom
    Sometimes it works if the server has only been put to sleep a couple of minutes and one of the clients resumes... otherwise it only seems to work if I close MP and then reopen it.

    I wish they would bring back the restart on resume feature it was flawless. They dont seem to be able to fix these issues with resume from sleep.[DOUBLEPOST=1385161327][/DOUBLEPOST]
    Are we referring to the reason why MP crashes on resume here or the tuning issue?

    Tonight I changed a setting in the resume settings of MP config "stop playback on removal of an audio renderer" and the crashes have reduced. However now sometimes it is completely frozen when it resumes rather than crashing.

    How can powerscheduler be fixed if it is a threading issue?

    Not sure what can be done really. DJblue needs to comment I guess as its his build. The tuning issue is the main concern.
     
  5. michael_t

    michael_t Portal Pro

    Joined:
    November 30, 2008
    Messages:
    1,258
    Likes Received:
    580
    Ratings:
    +813 / 2
    Home Country:
    Germany Germany
    Show System Specs
    Your guess is correct - PS gets the "enter away mode" event twice and thus tries to stop the player twice.
    What I do not understand: PS does not blindly stop the player - it checks for the player being playing before starting the stop thread and once again before calling the g_player.Stop() method. So we have a "I cannot query the player whether it is really stopped or is in the process of beeing stopped" issue here, which ofc might not get fixed easily. I wonder if it arises also with other threads / plugins trying to stop the player.
    But since it is quite easy to prevent double processing of the "away mode" events, I will provide a workaround fix for PS.

    Michael
     
  6. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,526
    Likes Received:
    4,734
    Ratings:
    +8,200 / 17
    Home Country:
    New Zealand New Zealand
    Yeah, I guess the player only sets its state to "stopped" at the end of stopping. Thanks. :)
     
  7. michael_t

    michael_t Portal Pro

    Joined:
    November 30, 2008
    Messages:
    1,258
    Likes Received:
    580
    Ratings:
    +813 / 2
    Home Country:
    Germany Germany
    Show System Specs
    I found the cause of the problem:
    The PBT_POWERSETTINGCHANGE event (e.g. indicating "enter away mode") is sent twice, since both the MP core and PowerScheduler register for it. This is an unlucky cooincidence of a rework in MediaPortal.Application\MediaPortal.cs (which is registering the event since 1.5 pre-release) and the integration of PowerScheduler (which is registering the event since its beginnings because it was not handled by MP so far...). One effect of this is that PowerScheduler tries to stop the player twice...

    I already provided a fix which removes the registering for the PBT_POWERSETTINGCHANGE event from the PowerScheduler code (JIRA issue MP1-4302).

    Michael
     
    • Thank You! Thank You! x 4
  8. DJBlu

    DJBlu Portal Pro

    Joined:
    August 14, 2007
    Messages:
    1,670
    Likes Received:
    789
    Location:
    Llanelli
    Ratings:
    +894 / 1
    Home Country:
    United Kingdom United Kingdom
    Without checking we cannot ensure it is any modifications.
     
  9. richardc1983

    richardc1983 Portal Pro

    Joined:
    October 10, 2012
    Messages:
    251
    Likes Received:
    18
    Gender:
    Male
    Location:
    Leeds
    Ratings:
    +25 / 3
    Home Country:
    United Kingdom United Kingdom
  10. Benoire
    • Premium Supporter

    Benoire MP Donator

    Joined:
    March 17, 2012
    Messages:
    679
    Likes Received:
    92
    Gender:
    Male
    Occupation:
    Civil Engineer
    Location:
    Auckland
    Ratings:
    +135 / 0
    Home Country:
    New Zealand New Zealand
    Show System Specs
    Morning fellas,

    As I'm using this mod I need to ask this here.

    How is MP set to deal with programs that overrun their timeslot? For example, it was qualifying at interlagos and it was raining. The qualifying schedule was pushed out due to heavy rain. From what I can tell, MP recorded the original set length but I know from experience Sky automatically extend the program if it overruns (I know this happened as there was no outro to the program it just simply stopped).

    Is MP able to continuously check the scheduled programs against the data being sent when recording and only activate the post record length once that PID I presume(?) has stopped transmitting? I guess I'm talking about a similar function to that old school PDC+ on VCRs that allowed the recording to extend as long as the program was running from the provider.

    In this instance, MP did not extend (despite a 7 minute post schedule record) and therefore missed the final 7 minutes of quali this morning and simply stopped without the standard end of program gumf that BBC do for their qualifying sessions.

    @DJBlu - if you get the chance, when you sort out the FTA issues for the NZ plugin can you also set the default transponder to Horizontal polarity as the latest version is set to vertical.

    Many thanks,

    Chris
     
  11. bob808
    • Premium Supporter

    bob808 MP Donator

    Joined:
    June 14, 2008
    Messages:
    295
    Likes Received:
    16
    Gender:
    Male
    Location:
    Hampshire
    Ratings:
    +17 / 0
    Home Country:
    United Kingdom United Kingdom
    I have a bit of an odd problem with 1.5 and the latest sky grabber - I am missing some of my tuners in the plugin.

    Mediaportal sees them ok, but they don't show to map tinings against.

    I have 2 tbs 6981 cards, but the latest plugin doesn't show all 4 tuners, older versions did. Any suggestions??
     
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!