[Bug] Problem with DVB-IP channels with changed SID or PID (1 Viewer)

Andrusha777

Portal Pro
December 3, 2009
132
3
Home Country
Russian Federation Russian Federation
mm1352000, thank you for answering. It is a very good idea about changes in TV server and your patch, because a lot of providers give an m3u playlist, which can change time-to time and by kind of subscription to IPTV services. In my case, all i need to do is to wrote simple query to set SID and PMT PID to 0 in all my channels (i have only iptv in TV server) and turn on debug option in tvserver. This things will take me off from mapping channels again in xmltv, changing their numbers and so on. Thanks a lot!
 

Stepko

Retired Team Member
  • Premium Supporter
  • September 29, 2007
    186
    152
    Hamburg/Wolfsburg
    Home Country
    Germany Germany
    AW: Re: Problem with DVB-IP channels with changed SID or PID

    Hi mm1352000,

    seems that your patch works good... do you think it's possible to get it in 1.2.0 RC? But I see some potential risk in your patch. What happens if -for some reason- a provider uses sid=0? Then you patch may influence the dvb-t/c/s part. I would prefer using an extra flag instead of sid=0. Then I would also check if there really is only one channel in the transportstream. And I would change the default identification for dvb-ip to using the ip addres.

    What do you think?

    Unfortunately I won't be able to do the coding the next days. I started to work on it on wendsday. Then my Laptop crashed and seems to be completly broken now. So I need to get a new one and set up everything, again. :(

    Stepko
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Re: AW: Re: Problem with DVB-IP channels with changed SID or PID

    Hi Stepko

    Unfortunately I won't be able to do the coding the next days. I started to work on it on wendsday. Then my Laptop crashed and seems to be completly broken now. So I need to get a new one and set up everything, again. :(
    :(:(:(:(:(
    I'm *very* sorry to hear that. I hope you're able to get back up and running quickly...

    ...seems that your patch works good... do you think it's possible to get it in 1.2.0 RC?
    I'm really not sure. I posted the patch so that people could at least evaluate it to see if it solves the problems. Only a few people have tried it, so I'm not confident yet that I haven't missed something...

    But I see some potential risk in your patch. What happens if -for some reason- a provider uses sid=0? Then you patch may influence the dvb-t/c/s part. I would prefer using an extra flag instead of sid=0.
    I completely agree. I only designed this fix as a trial or a fix for DVB-IP owners, not something that would get included in 1.2.0rc without changes.

    Then I would also check if there really is only one channel in the transportstream.
    How do you intend to do that? Usually the SDT is not checked when you're just viewing channels. I guess you could wait until you receive at least two PMTs, but in the common DVB-IP case where you only receive one PMT per stream you'd have to have a timeout. This would be a complicated and possibly slow solution. How many DVB-IP providers are actually providing multiple channels in the same stream? To me it always seems to be one channel per stream with a different IP, port or URL extension for each channel...

    And I would change the default identification for dvb-ip to using the ip addres.
    But are you sure that the IP address by itself is going to be unique in *all* cases? I'm certainly not. That is part of why I picked the full URL...
     

    georgius

    Retired Team Member
  • Premium Supporter
  • October 31, 2010
    1,376
    654
    Bratislava
    Home Country
    Slovakia Slovakia
    Re: AW: Re: Problem with DVB-IP channels with changed SID or PID

    But are you sure that the IP address by itself is going to be unique in *all* cases? I'm certainly not. That is part of why I picked the full URL...

    I'm not sure, but will your fix work with improvement with specifying network interface?
     

    Stepko

    Retired Team Member
  • Premium Supporter
  • September 29, 2007
    186
    152
    Hamburg/Wolfsburg
    Home Country
    Germany Germany
    AW: Re: AW: Re: Problem with DVB-IP channels with changed SID or PID

    Hi mm1352000,

    Then I would also check if there really is only one channel in the transportstream.
    How do you intend to do that? Usually the SDT is not checked when you're just viewing channels. I guess you could wait until you receive at least two PMTs, but in the common DVB-IP case where you only receive one PMT per stream you'd have to have a timeout. This would be a complicated and possibly slow solution.
    I don't know if we are talking about the same thing. When a user tunes to a channel I would try to use the pmt pid that is stored in the db. If the pmt pid has changed then I would try to get the new pmt pid from pat. Up to this point nothing changed to the current implementation.
    But instead of using the sid to get the correct pmt pid I would check if there is only one pmt pid in pat and use this pmt pid. To check if there is only one pmt pid in pat, I would use the pat's size. I think it is possible to calculate the number of pids that are in pat.
    Am I missing something?

    How many DVB-IP providers are actually providing multiple channels in the same stream? To me it always seems to be one channel per stream with a different IP, port or URL extension for each channel...
    I hope no provider provide multiple channel in one transportstream. That would be a huge waste of bandwith!!

    But are you sure that the IP address by itself is going to be unique in *all* cases? I'm certainly not. That is part of why I picked the full URL...
    Edit:
    your right the whole adress should be used for identification. But then I would suggest to use the whole adress as the default identification method for dvb-ip

    Stepko
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Re: AW: Re: AW: Re: Problem with DVB-IP channels with changed SID or PID

    I don't know if we are talking about the same thing. When a user tunes to a channel I would try to use the pmt pid that is stored in the db. If the pmt pid has changed then I would try to get the new pmt pid from pat. Up to this point nothing changed to the current implementation.
    Yes, okay - I understand that part.

    But instead of using the sid to get the correct pmt pid I would check if there is only one pmt pid in pat and use this pmt pid. To check if there is only one pmt pid in pat, I would use the pat's size. I think it is possible to calculate the number of pids that are in pat.
    Am I missing something?
    Are you talking about a general solution for 1.3.0 that can also work for DVB-S, T and C?

    I hope no provider provide multiple channel in one transportstream. That would be a huge waste of bandwith!!
    If this is the case then I don't understand why you think it is important to check how many PMTs there are. Can you explain that?

    I would say that the IP and port identifies a channel in dvb-ip. But you are right we cannot be sure for *all* cases. According to the standart the identification can be done in both ways. But it says nothing how to determine the correct way for each channel. And I really don't have an idea how to do that.
    Why not take ONID + SID + IP + port? I have not looked at the standard at all yet (just too busy :() but based on what you've said that is certain to be unique.

    And using a checkbox is really not a good way. How should the normal user know how his/her provider identifies channels....
    I agree - a user shouldn't have to worry about how a provider does things. To be honest I already don't like the checkbox that got added. MP/TV Server should "just work". The only case when you should have options is when the user actually wants the choice. For that reason I'm okay with having a choice like "fast scan" (for picking up most channels really quickly with NIT and/or SDT) or "deep scan" (for checking for the presence of channels that aren't in SDT or that have a user defined service type), but not "non-compliant provider" or "ONID + SID = unique".
     

    Stepko

    Retired Team Member
  • Premium Supporter
  • September 29, 2007
    186
    152
    Hamburg/Wolfsburg
    Home Country
    Germany Germany
    AW: Re: AW: Re: AW: Re: Problem with DVB-IP channels with changed SID or PID

    But instead of using the sid to get the correct pmt pid I would check if there is only one pmt pid in pat and use this pmt pid. To check if there is only one pmt pid in pat, I would use the pat's size. I think it is possible to calculate the number of pids that are in pat.
    Am I missing something?
    Are you talking about a general solution for 1.3.0 that can also work for DVB-S, T and C?
    I'm trying to find a good general solution to fix this bug in 1.2.0 rc already. And that means minimizing potential siedeffects.

    If this is the case then I don't understand why you think it is important to check how many PMTs there are. Can you explain that?
    Just to be really sure (again, minimizing risks). If for any reason the "don't use sid" flag is set for other than dvb-ip then this check would be another "protection" for preventing the tv server from a false behavior.
    Or even more general: We're taking the pmt pid without verifying it. We just assume that it is the correct one. And we can not do that if there are more than one pmt pids. Just assuming or hoping that there is only one channel is not enough, i think. Especially not if it is possible to check that.

    Why not take ONID + SID + IP + port? I have not looked at the standard at all yet (just too busy :() but based on what you've said that is certain to be unique.
    SID may change from time to time (depends on provider). Standart says there are two ways to identifiy a channel:
    • The same way it is done in dvb-s/t/c (I think it's ONID + SID + ??)
    • By the name of channel + name of provider in dns names, e.g.: bbc1.bbc.co.uk. As we don't have the name I would say to use the whole adress instead of name + providername
    But there is still the problem: How to determine the correct way...

    I agree - a user shouldn't have to worry about how a provider does things. To be honest I already don't like the checkbox that got added. MP/TV Server should "just work". The only case when you should have options is when the user actually wants the choice. For that reason I'm okay with having a choice like "fast scan" (for picking up most channels really quickly with NIT and/or SDT) or "deep scan" (for checking for the presence of channels that aren't in SDT or that have a user defined service type), but not "non-compliant provider" or "ONID + SID = unique".
    agree 100%

    Stepko
     

    Andrusha777

    Portal Pro
    December 3, 2009
    132
    3
    Home Country
    Russian Federation Russian Federation
    Hi all! I have some troubles with all of it. I have installed this patch, start setuptv.exe --debugoptions but i can't find any debug option in tvserver?
    So, i have 2 channels which was working perfect. I start setuptv.exe, select them and set SID and PMTPPID both to 0. Then i start mediaportal and trying to watch them - have no lucky and can't start timeshifting message. The channels i was changed SID and PMT has numbers 1 and 4
    Here are logs.
    After i have entered to setuptv again i did'nt find any changed pmt in database.
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    You need to use /debugoptions not --debugoptions. That is a change in 1.2.0b... -->wiki<--
     

    Andrusha777

    Portal Pro
    December 3, 2009
    132
    3
    Home Country
    Russian Federation Russian Federation
    mm1352000, ok, found that option, set it (always use pat lookup) but no changes - if i change SID and PMTPID to 0, then start MP and trying to watch channel - "can not start graph" message after about 10 sec.
     

    Users who are viewing this thread

    Top Bottom