Annoying CI OSD asking continuously for Rights Check (1 Viewer)

morpheus_xx

Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,073
    7,459
    Home Country
    Germany Germany
    this is the code for patching the PMT for AstonCrypt2. I think that this does only work partitially, maybe more streams/pid need patching too.

    missing some PIDs might result in a message from CAM, that it was not able to descramble something...

    Code:
        /// <summary>
        /// Patches the PMT to force standard AC3 header.
        /// </summary>
        /// <param name="PMT">byte array containing the PMT</param>
        /// <param name="pmtLength">length of the pmt array</param>
        /// <param name="newPmtLength">The new PMT length</param>
        /// <returns></returns>
        private static byte[] PatchPMT_AstonCrypt2(byte[] PMT, int pmtLength, out int newPmtLength)
        {
          byte[] newPMT = new byte[1024];  // create a new array.
    
          int ps = 0;
          int pd = 0;
    
          for (int i = 0; i < 12; ++i)
            newPMT[pd++] = PMT[ps++];
          for (int i = 0; i < PMT[11]; ++i)
            newPMT[pd++] = PMT[ps++];
    
          // Need to patch audio AC3 channels 0x06, , , , ,0x6A in real AC3 descriptor 0x81, .... for ( at least !) ASTONCRYPT CAM module
          while ((ps + 5 < pmtLength) && (pd < 1024))
          {
            int len = PMT[ps + 4] + 5;
            for (int i = 0; i < len; ++i)
            {
              if (pd >= 1024)
                break;
              if ((i == 0) && (PMT[ps] == 0x06) && (PMT[ps + 5] == 0x6A)) { newPMT[pd++] = 0x81; ps++; }
              else
                newPMT[pd++] = PMT[ps++];
            }
          }
    
          newPmtLength = pd;
          return newPMT;
        }

    Question: Do the CAM messages also occur, if you set the CAM type to default (means no patching)?
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,073
    7,459
    Home Country
    Germany Germany
    Can you try the attached TvLibrary on your system?

    It adds logging of the whole decoded PMT, before and after patching. This way I like to get some more information about the differences in structure.

    Attention: EACH patched PMT gets dumped as XML twice, so you'll end up with lot of .xml in your tvserver log folder ;)

    this is only a test build, I'm not sure if the dumps contain the information to look into...
     

    DjeC64

    MP Donator
  • Premium Supporter
  • August 29, 2007
    176
    16
    Gent
    Home Country
    Belgium Belgium
    I am unlucky, my FloppyDTV does not work (red light symptom). Until I try the modification on its power line, I have installed an old NOVA-CI. Still with same Astoncrypt 2.18 (also set in Setup) , I do not see this issue anymore. So it could be a combination of FloppyDTV+CAM Astoncrypt. Also now I am running Windows 7.

    Please continue to debug as I still have hope that my FloppyDTV is not dead.
     

    Ruud

    MP Donator
  • Premium Supporter
  • December 5, 2004
    276
    6
    Home Country
    Netherlands Netherlands
    Hi,

    this weekend moved my TT CT3650CI from my server to my client, on Client did fresh install inclusive all new drivers.
    This problem was bugging me because I could not reproduce it at will, but it kept on popping up.... hence 'annoying' ;)
    I reverted back from my TT driver version 1.0.3.8 to 1.0.2.20 and haven't seen the problem since.
    Could this help in troubleshooting?

    regards,
    Ruud.

    Edit: just had one again grrrrrrrr.
     

    Ambass

    Retired Team Member
  • Premium Supporter
  • December 24, 2007
    555
    129
    Home Country
    France France
    Can you try the attached TvLibrary on your system?

    It adds logging of the whole decoded PMT, before and after patching. This way I like to get some more information about the differences in structure.

    Attention: EACH patched PMT gets dumped as XML twice, so you'll end up with lot of .xml in your tvserver log folder ;)

    this is only a test build, I'm not sure if the dumps contain the information to look into...


    Patching AC3 PMT's is mandatory. I've discussed with Aston people ( They are in France so it was quite easy ;)).

    The problem is that this modue accept do descramble only 2 audio streams, and when the AC3 descriptor is 0x06....0x6A ( like it generally is ) the stream is considered as "other" and only one can be descrambled.
    So the patch replace the 0x06 by 0x81 that is recognize as AC3-audio and two audio streams can be descrambled but no more.

    Anyway the CI problem exists selecting AstonCrypt2 CAM or other...( if you select "other", channels containing 2xAC3 are not working )

    The main problem is not to answer "OK" to th popup...but this sometimes cause MP to be unresponsive ( also without menu on the screen, just "CI menu on minidisplay" ). I should kill MP, that is absolutely not WAF:D.
     

    Ruud

    MP Donator
  • Premium Supporter
  • December 5, 2004
    276
    6
    Home Country
    Netherlands Netherlands
    Bugreport CI popup

    Can you try the attached TvLibrary on your system?

    It adds logging of the whole decoded PMT, before and after patching. This way I like to get some more information about the differences in structure.

    Attention: EACH patched PMT gets dumped as XML twice, so you'll end up with lot of .xml in your tvserver log folder ;)

    this is only a test build, I'm not sure if the dumps contain the information to look into...

    copied the two dll's in the tv server directory (after backing up the original ones.

    Okay, so here we go:
    test script:
    1. cold start PC
    2. start Radio: radio 538
    > Radio starts (this is good)
    3. stop radio
    4. start TV: RTL4
    > TV starts (this is good)
    5. stop TV
    6. goto 'home screen'
    .... wait 3 minutes till power scheduler kicks in and hibernates the PC...
    > after appr. 1 minute (in home screen) pop up:
    [ 1 you are not entitled ]
    [ 2 to receive this programme! ]
    [ press ok ]
    ! this is in the home screen with no TV / radio playing????
    7. Hibernation starts
    8. (re)start PC from hibernation
    9. start Radio: radio 538
    > message:no signal
    10 start TV: RTL4
    > message: no signal

    log files cleaned before starting tests and attached after running log collector

    as this is not only CI popup related will link from other threads to this post ;)

    hope this helps!
    regards,
    Ruud.
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,073
    7,459
    Home Country
    Germany Germany
    Code:
    2009-12-14 19:39:33.937500 [16]: card: Tune 3 to Arrow Jazz FM
    2009-12-14 19:39:33.937500 [16]: card: user: epg:3:-1 tune DVBC:radio:Ziggo Arrow Jazz FM Freq:396000 ONID:500 TSID:9 SID:9075 PMT:0x4EC FTA:False LCN:10000 SymbolRate:6875 Modulation:Mod64Qam
    2009-12-14 19:39:33.968750 [16]: dvbc: Tune:DVBC:radio:Ziggo Arrow Jazz FM Freq:396000 ONID:500 TSID:9 SID:9075 PMT:0x4EC FTA:False LCN:10000 SymbolRate:6875 Modulation:Mod64Qam
    2009-12-14 19:39:33.968750 [16]: dvb:Submiting tunerequest Channel:Arrow Jazz FM subChannel:-1 
    2009-12-14 19:39:33.968750 [16]: dvb:Getting new subchannel
    2009-12-14 19:39:33.968750 [16]: dvb:GetNewSubChannel:0 #0
    2009-12-14 19:39:33.968750 [16]: TvDvbChannel ctor new subchIndex:0
    2009-12-14 19:39:33.968750 [16]: dvb:Submit tunerequest size:1 new:0
    2009-12-14 19:39:33.968750 [16]: subch:0 OnBeforeTune
    2009-12-14 19:39:33.984375 [16]: dvb:Submit tunerequest calling put_TuneRequest
    2009-12-14 19:39:34.953125 [16]: dvb:Submit tunerequest done calling put_TuneRequest
    2009-12-14 19:39:34.953125 [16]: subch:0 OnAfterTune
    2009-12-14 19:39:34.968750 [16]: subch:0 OnGraphStart
    2009-12-14 19:39:34.968750 [16]: dvb:  RunGraph
    2009-12-14 19:39:36.390625 [16]: dvb:  LockedInOnSignal ok
    2009-12-14 19:39:36.390625 [16]: subch:0 OnGraphStarted
    2009-12-14 19:39:36.390625 [16]: subch:0 SetupPmtGrabber:pid 4EC sid:2373
    2009-12-14 19:39:36.390625 [16]: subch:0 set pmt grabber pmt:4EC sid:2373
    2009-12-14 19:39:36.390625 [16]: WaitForPMT: Waiting for PMT 4EC
    2009-12-14 19:39:36.437500 [4]: subch:0 OnPMTReceived() pmt:4EC ran:True dynamic:False
    2009-12-14 19:39:36.437500 [16]: WaitForPMT: Found PMT after 0,046875 seconds.
    2009-12-14 19:39:36.437500 [16]: subch:0 SendPmt:2373 2373 FFFFFFFF 9
    2009-12-14 19:39:36.453125 [16]: Decode pmt
    2009-12-14 19:39:36.453125 [16]: descr1 len:6 9 4 6 4 ef d2 
    2009-12-14 19:39:36.453125 [16]: descr1 len:6 9 4 6 2 f3 ba 
    2009-12-14 19:39:36.453125 [16]: Set descriptor data with length 3
    2009-12-14 19:39:36.453125 [16]: PROBLEM : descriptor lengths dont match 6 9
    2009-12-14 19:39:36.453125 [16]: subch:0 SendPMT version:9 len:52 9075
    2009-12-14 19:39:36.453125 [16]: TechnoTrend: slot 0 changed
    2009-12-14 19:39:36.453125 [16]: TechnoTrend:    CI status:SlotModuleOk 
    2009-12-14 19:39:36.453125 [16]: TechnoTrend:    CI text  :AlphaCrypt 
    2009-12-14 19:39:36.453125 [16]: TechnoTrend:      ca system id  :602 
    2009-12-14 19:39:36.453125 [16]: TechnoTrend:      ca system id  :648 
    2009-12-14 19:39:36.468750 [16]: TechnoTrend:      ca system id  :604 
    2009-12-14 19:39:36.468750 [16]: TechnoTrend:      ca system id  :606 
    2009-12-14 19:39:36.468750 [16]: TechnoTrend:      ca system id  :608 
    2009-12-14 19:39:36.468750 [16]: TechnoTrend:      ca system id  :1702 
    2009-12-14 19:39:36.468750 [16]: TechnoTrend:      ca system id  :1722 
    2009-12-14 19:39:36.468750 [16]: TechnoTrend:      ca system id  :1762 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :4A20 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :500 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :B00 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :1833 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :1834 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :D05 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :D22 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend:      ca system id  :D95 
    2009-12-14 19:39:36.484375 [16]: TechnoTrend: DescrambleMultiple:(1)
    2009-12-14 19:39:36.484375 [16]: TechnoTrend: DescrambleMultiple: serviceId:9075
    2009-12-14 19:39:36.484375 [16]: $ OnCaChange slot:255 reply:E status:0
    2009-12-14 19:39:36.484375 [16]: $ CI:    SetProgram OK
    2009-12-14 19:39:36.625000 [16]: $ OnCaChange slot:255 reply:E status:0
    2009-12-14 19:39:36.625000 [16]: $ CI:    SetProgram OK
    2009-12-14 19:39:36.625000 [16]: TechnoTrend: services decoded:Success 1
    2009-12-14 19:39:36.625000 [16]: TechnoTrend IsCamReady(): IsCamPresent:True, IsCamReady:True
    2009-12-14 19:39:36.625000 [16]: subch:0 cam flags:True
    2009-12-14 19:39:36.625000 [16]: subch:0 SetMpegPidMapping
    2009-12-14 19:39:36.625000 [16]: subch:0  pid:4EE pcr
    2009-12-14 19:39:36.625000 [16]: subch:0  pid:4EC pmt
    2009-12-14 19:39:36.640625 [16]: subch:0  pid:4EE audio lang: type:MPEG-1
    2009-12-14 19:39:36.640625 [16]: subch:0    map pid:4EE audio lang: type:MPEG-1
    2009-12-14 19:39:36.640625 [16]: subch:0 stop tif
    2009-12-14 19:39:36.640625 [16]: WaitForPMT: sending PMT to CAM took 0,203125 seconds.
    2009-12-14 19:39:36.671875 [16]: card: Tuner locked: True
    2009-12-14 19:39:36.671875 [16]: **************************************************
    2009-12-14 19:39:36.671875 [16]: ***** SIGNAL LEVEL: 82, SIGNAL QUALITY: 100 *****
    2009-12-14 19:39:36.687500 [16]: **************************************************
    2009-12-14 19:39:36.687500 [16]: card: tuned user: epg subchannel: 0
    2009-12-14 19:39:36.687500 [16]: user:epg add
    2009-12-14 19:39:36.703125 [DVB EPG timer]: Controller: GrabEpg on card ID == 3
    2009-12-14 19:39:36.703125 [DVB EPG timer]: dvb:grab epg...
    2009-12-14 19:39:38.500000 [13]: TechnoTrend: slot 0 changed
    2009-12-14 19:39:42.546875 [13]: TechnoTrend: slot 0 changed
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:    CI status:SlotModuleOk 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:    CI text  :AlphaCrypt 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :602 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :648 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :604 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :606 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :608 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :1702 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :1722 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :1762 
    2009-12-14 19:39:42.546875 [13]: TechnoTrend:      ca system id  :4A20 
    2009-12-14 19:39:42.562500 [13]: TechnoTrend:      ca system id  :500 
    2009-12-14 19:39:42.562500 [13]: TechnoTrend:      ca system id  :B00 
    2009-12-14 19:39:42.562500 [13]: TechnoTrend:      ca system id  :1833 
    2009-12-14 19:39:42.562500 [13]: TechnoTrend:      ca system id  :1834 
    2009-12-14 19:39:42.562500 [13]: TechnoTrend:      ca system id  :D05 
    2009-12-14 19:39:42.562500 [13]: TechnoTrend:      ca system id  :D22 
    2009-12-14 19:39:42.562500 [13]: TechnoTrend:      ca system id  :D95 
    2009-12-14 19:39:46.781250 [13]: TechnoTrend: OnDisplayMenu/List; 5 items; wLength: 73; pStringArray: 99980331 
    2009-12-14 19:39:46.796875 [13]: TechnoTrend: 0: —AlphaCrypt 
    2009-12-14 19:39:46.796875 [13]: TechnoTrend: 1:   
    2009-12-14 19:39:46.796875 [13]: TechnoTrend: 2: Press OK 
    2009-12-14 19:39:46.796875 [13]: TechnoTrend: 3: You are not entitled 
    2009-12-14 19:39:46.796875 [13]: TechnoTrend: 4: to receive this programme !

    The message occures by the try to tune "Arrow Jazz FM", which you probably don't have an subscription. It happens after your mentionend tune of RTL 4!

    Question is, why a radio channel gets tuned? Do you have idle epg grabber enabled, and maybe transponder enabled which you don't have an subscription???
     

    Ruud

    MP Donator
  • Premium Supporter
  • December 5, 2004
    276
    6
    Home Country
    Netherlands Netherlands
    Hi Morpeus,

    It must be the EPG grabber because after RTL4 I just went into the homescreen. Arrow Jazz FM is part of the subscription so this should play okay (unscramble) if EPG grabbing is possible I don't know. I would expect that when I have a subscription that also EPG grabbing should be possible? correct?

    I will disable EPG grabbing for the radio channels (turned that on in the new setup of my system).

    regards,
    Ruud.
     

    Users who are viewing this thread

    Top Bottom