Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI? (1 Viewer)

FreakyJ

Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI?

    Hey,

    do you already have got an answer from Terratec?! I don't have :(.... Nothing... absolutely no response >_>
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    No response from Terratec, and no response from Azurewave (parent company of Twinhan). :(
    I will be patient a little while longer...
     

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI?

    Any news on that? If not I would be pretty happy if the current improvements you did will find their way into SVN, because you still improved the support for my Tv-Card =)
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Hi FreakyJ

    I hope you are well. :)
    Still no response I'm afraid. Are you able to call Terratec on the phone from where you are? For me it would be an expensive international call, however if you are able to get through on the phone then they are more likely to respond. I recommend that you don't put down the phone until you receive the API in your email inbox. ;)
     

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI?

    I already had the idea to call terratec, too. But they have very stupid times (Mo - Fr: 10:00-13:00 & 14:00-18:00). I will try to call them this week, for me it looks like a local call and for these I don't have to pay :p So I will report back in a few days, so long enjoy your day^^
     

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI?

    Hey,

    as I told you Terratec wasn't really cooperative... and I really want to get this work, but can't get it done without a little more help of you =)

    I found a little tool. With this tool it is possible to monitor which parameters were sent to a function in a dll and which values were received again :p
    That said I monitored DvrCommonInterface.dll during the startup of the program, tuning to a channel and close phase of the program. The result is attached as screenshots to this post ;)
    One question from me is now, which windows function have I to monitor to spy the functions called by the dll? (What windows functions get called if I want to tell the driver something?) If we could get this info it would be possible to implement it without the terratec dll :p

    Another project from me in the past view days was to write a proxy dll, but I don't really have Assembler skills to get something fancy to work.
    What I got was to proxy all calls to the original dll and log which functions got called... I attached you the file on this post, too.

    Now I'm really excited if the info I provided in this post is helpful in any way or if you could provide me some more infos (questions above) so that I can collect some more information^^

    P.S.
    The output from the proxy dll is from a USB device on my main PC ;)
     

    Attachments

    • CiGetNumberOfDevices1.png
      CiGetNumberOfDevices1.png
      44.8 KB
    • CiGetNumberOfDevices2.png
      CiGetNumberOfDevices2.png
      27.6 KB
    • CiGlobalInitialization.png
      CiGlobalInitialization.png
      73 KB
    • CiGlobalRelease.png
      CiGlobalRelease.png
      43 KB
    • files to wrap.rar
      405.8 KB

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI?

    Just some screenshots concerning the CI Menu.

    Did the following:
    - startet the App
    - Menu -> Sttings -> CI - > Alphacrypt Classic
    - -> selected first option -> back
    - -> selected second option -> back
    - closed program
     

    Attachments

    • MMIOpenByUniqueID1.png
      MMIOpenByUniqueID1.png
      33.5 KB
    • MMIMenuAnswerByUniqueID3.png
      MMIMenuAnswerByUniqueID3.png
      40.1 KB
    • MMIMenuAnswerByUniqueID2.png
      MMIMenuAnswerByUniqueID2.png
      33.3 KB
    • MMIMenuAnswerByUniqueID1.png
      MMIMenuAnswerByUniqueID1.png
      32.9 KB
    • MMICloseByUniqueID1.png
      MMICloseByUniqueID1.png
      40.6 KB
    • CiGetNumberOfDevices3.png
      CiGetNumberOfDevices3.png
      29.9 KB
    • CiGetNumberOfDevices2.png
      CiGetNumberOfDevices2.png
      32.4 KB
    • CiGetNumberOfDevices1.png
      CiGetNumberOfDevices1.png
      34.6 KB

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Hi FreakyJ

    Yeah, I got your PM. After reading that I was ***very*** angry with Terratec. I guess now that they got my emails but didn't even have the decency to respond. One half of me wanted to say "well we won't support your devices any more" while the other half said "we'll support your devices better than you do yourself"! I think the best option is the second option. :p

    This new program that you've found is very tricksy! I'm interested, and it could definitely help, but I don't understand the screenshots. The call stacks (the lists of functions on the left hand side) are just as important as the parameters, but I can't figure out which way up the call stack is. There also appears to be at least two threads with important function calls - it is important to see information about both...

    If we're going to use this application then I think the first function we need to get information about is TTDvrCommonInterfaceGlobalInitialize() - what context is it called in, and what does it return. Having said that, I've looked at the DLLs you posted and there are other functions that might be important that weren't in the original list:

    int __cdecl _THC_RegisterCIMMINotificationCallback();
    int __cdecl _THC_RegisterNotificationCallback();
    int __cdecl THC_CheckForNewDevices();
    int __cdecl THC_CommonInterfaceActivateMMI();
    int __cdecl THC_CommonInterfaceCloseMMI();
    int __cdecl THC_CommonInterfaceSendMMIEnqAnswer();
    int __cdecl THC_CommonInterfaceSetListIndex();
    int __cdecl THC_GetCommonInterfaceCount();
    int __cdecl THC_GetCommonInterfaceInfo();
    int __cdecl THC_RegisterCIMMINotificationCallback();
    int __cdecl THC_RegisterNotificationCallback();
    int __cdecl THC_Release();

    There could be more too. There are even 2 or 3 different DvrApi.dll files that I've seen now. I suspect there may be two interfaces: 1 for the TwinHan io Control which is already supported in TV Server, and the other for TerraTec USB devices which is not yet supported. Either that or one interface is a high level one and the other is a low level one. We need to know what is happening at the low level.
     

    FreakyJ

    Retired Team Member
  • Premium Supporter
  • July 25, 2010
    4,024
    1,420
    Home Country
    Germany Germany
    AW: Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI?

    Hey,

    thanks for answering =)
    What do you exactly mean with " can't figure out which way up the call stack is"? If you mean the order in which the functions got called that is from the top to the bottom.
    Would it be possible to get more information with the proxy dll? It is no problem to create a proxy dll for the DvrCommonInterface.dll, but I can't implement a proper logging in asm :( My current problem there is the following:
    - I don't really know how many parameters the function has, so I have to pass all parameter to the stack and then call the function, but how do that in asm?!
    - I have to log the return value, that shouldn't be that problem, but without the first step (passing/forwarding a unknown number of parameters to a function) this is impossible... because currently it is made with a "jmp" operation to the original function.

    I'm sorry the application doesn't provide more information :(

    Concerning the DvrApi.dll
    Sorry, I don't really get your point...

    While writing I hust did a little test again concerning the TTDvrCommonInterfaceGlobalInitialize().
    I found a little option "Show CallStack", maybe that is what you mentioned in your post :p Screenshot attached ;)
     

    Attachments

    • GlobalInitializationStackCall.png
      GlobalInitializationStackCall.png
      157.3 KB

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Re: AW: Can someone help to create a CI Menu for the Terratec Cinergy C HD + CI?

    Some quick responses...

    What do you exactly mean with " can't figure out which way up the call stack is"? If you mean the order in which the functions got called that is from the top to the bottom.
    Yes that was what I meant, although I'm uncertain whether they are process callstacks or just lists of function calls made by each thread.

    Would it be possible to get more information with the proxy dll?
    I'm not sure. Unless you could figure out what kind of parameter (object type, address/value etc.) each parameter is then it is probably no more valuable than the tool you've found. ASM is very low level - I'm hoping we can do it without resorting to that.

    Concerning the DvrApi.dll
    Sorry, I don't really get your point...
    Among all the DLLs you have posted, I've seen:

    DvrApi.dll [1] (147kB)
    DvrApi.dll [2] (1.6MB)
    _DvrApi.dll (968kB)
    DvrStreamSource.dll (816kB)
    DvrCommonInterface.dll (125kB)

    Why are there 3 different DvrApi.dll files?
     

    Users who are viewing this thread

    Top Bottom