From: metroycn on 30 Dec 2008 01:34 Hi I want to add private interface to BDA driver so the comunication with driver will be easy for specific application such as: debug device register value while watching TV remote controller receiving IR key code. I have try add ksproperty but it is not working. the default: /***************************************************************/ DEFINE_KSMETHOD_SET_TABLE(FilterMethods) { DEFINE_KSMETHOD_SET ( &KSMETHODSETID_BdaDeviceConfiguration, SIZEOF_ARRAY(FilterConfiguration), FilterConfiguration, 0,NULL ), DEFINE_KSMETHOD_SET ( &KSMETHODSETID_BdaChangeSync, SIZEOF_ARRAY(FilterChangeSync), FilterChangeSync, 0,NULL ), }; DEFINE_KSAUTOMATION_TABLE(FilterAutomation) { DEFINE_KSAUTOMATION_PROPERTIES_NULL, DEFINE_KSAUTOMATION_METHODS(FilterMethods), DEFINE_KSAUTOMATION_EVENTS_NULL }; /*****************************************************/ add ksproperty: const KSPROPERTY_SET property_table[] = { DEFINE_KSPROPERTY_SET ( &PROPSETID_VIDCAP_CUSTOM_IRCAPTURE, SIZEOF_ARRAY(g_ir_custom_properties), g_ir_custom_properties, 0, NULL ), }; DEFINE_KSAUTOMATION_TABLE(FilterAutomation) { SIZEOF_ARRAY( property_table ), sizeof(KSPROPERTY_ITEM), property_table, DEFINE_KSAUTOMATION_METHODS(FilterMethods), DEFINE_KSAUTOMATION_EVENTS_NULL }; /************************/ but it is not working, how can I add an interface, I can only use standard interface, like setfrequency, get_fec..... thanks
From: Tim Roberts on 31 Dec 2008 01:08 metroycn(a)hotmail.com wrote: > >I want to add private interface to BDA driver >so the comunication with driver will be easy for specific application > >such as: >debug device register value while watching TV >remote controller receiving IR key code. > >I have try add ksproperty but it is not working. How did you test this? Can you show us the code? What happened when you accessed the private property? >/*****************************************************/ > >add ksproperty: > > >const KSPROPERTY_SET property_table[] = You should get in the habit of using the standard macros, as in: DEFINE_KSPROPERTY_SET_TABLE(property_table) > { > DEFINE_KSPROPERTY_SET > ( > &PROPSETID_VIDCAP_CUSTOM_IRCAPTURE, > SIZEOF_ARRAY(g_ir_custom_properties), > g_ir_custom_properties, > 0, > NULL > ), > }; > >DEFINE_KSAUTOMATION_TABLE(FilterAutomation) { > SIZEOF_ARRAY( property_table ), > sizeof(KSPROPERTY_ITEM), > property_table, > DEFINE_KSAUTOMATION_METHODS(FilterMethods), > DEFINE_KSAUTOMATION_EVENTS_NULL >}; DEFINE_KSAUTOMATION_TABLE(FilterAutomation) { DEFINE_KSAUTOMATION_PROPERTIES(property_table), DEFINE_KSAUTOMATION_METHODS(FilterMethods), DEFINE_KSAUTOMATION_EVENTS_NULL }; >but it is not working, how can I add an interface, >I can only use standard interface, like setfrequency, get_fec..... How are you getting "standard interfaces", if your filter doesn't define any of the standard properties? Is this a capture driver or a tuner driver? -- Tim Roberts, timr(a)probo.com Providenza & Boekelheide, Inc.
From: metroycn on 31 Dec 2008 02:19 On Dec 31, 2:08 pm, Tim Roberts <t...(a)probo.com> wrote: > metro...(a)hotmail.com wrote: > > >I want to add private interface to BDA driver > >so the comunication with driver will be easy for specific application > > >such as: > >debug device register value while watching TV > >remote controller receiving IR key code. > > >I have try add ksproperty but it is not working. > > How did you test this? Can you show us the code? What happened when you > accessed the private property? > > >/*****************************************************/ > > >add ksproperty: > > >const KSPROPERTY_SET property_table[] = > > You should get in the habit of using the standard macros, as in: > > DEFINE_KSPROPERTY_SET_TABLE(property_table) > > > > > > > { > > DEFINE_KSPROPERTY_SET > > ( > > &PROPSETID_VIDCAP_CUSTOM_IRCAPTURE, > > SIZEOF_ARRAY(g_ir_custom_properties), > > g_ir_custom_properties, > > 0, > > NULL > > ), > > }; > > >DEFINE_KSAUTOMATION_TABLE(FilterAutomation) { > > SIZEOF_ARRAY( property_table ), > > sizeof(KSPROPERTY_ITEM), > > property_table, > > DEFINE_KSAUTOMATION_METHODS(FilterMethods), > > DEFINE_KSAUTOMATION_EVENTS_NULL > >}; > > DEFINE_KSAUTOMATION_TABLE(FilterAutomation) { > DEFINE_KSAUTOMATION_PROPERTIES(property_table), > DEFINE_KSAUTOMATION_METHODS(FilterMethods), > DEFINE_KSAUTOMATION_EVENTS_NULL > > }; > >but it is not working, how can I add an interface, > >I can only use standard interface, like setfrequency, get_fec..... > > How are you getting "standard interfaces", if your filter doesn't define > any of the standard properties? Is this a capture driver or a tuner > driver? > -- > Tim Roberts, t...(a)probo.com > Providenza & Boekelheide, Inc.- Hide quoted text - > > - Show quoted text - /* guid*************/ const GUID PROPSETID_VIDCAP_CUSTOM_IRCAPTURE = { 0xca9bcf47, 0xc5df, 0x4fb0, 0x95, 0xc6, 0x68, 0x1d, 0x52, 0xaf, 0xc2, 0x49}; typedef enum { KSPROPERTY_IRCAPTURE_KEYSTROKES = 0, KSPROPERTY_IRCAPTURE_COMMAND = 1 }KSPROPERTY_IRCAPTURE_PROPS; /* guid*************/ It is always very Helpful from you. thanks . the following is application code: IKsPropertySet *PKS; if (FAILED(hr = piBDADemod->QueryInterface (IID_IKsPropertySet,reinterpret_cast<void **>(&PKS)))) { return (log << "Cannot Find IID_IKsPropertySet\n").Show(hr); } if (FAILED(hr = PKS->Get (PROPSETID_VIDCAP_CUSTOM_IRCAPTURE,KSPROPERTY_IRCAPTURE_KEYSTROKES, NULL, 0, NULL, 0, &irlength))) { if(hr = E_PROP_SET_UNSUPPORTED) { return (log << "error E_PROP_SET_UNSUPPROTED \n").Show(hr); } if(hr = E_PROP_ID_UNSUPPORTED) { return (log << "error E_PROP_ID_UNSUPPROTED \n").Show(hr); } } happy new year!
From: metroycn on 31 Dec 2008 02:29 it is from the bda tuner driver, It is working. only one tuner filter, it is created dynamically. when accessing the property, realized by accessing the node table these property are standard API. accessing the standard property: for ( int i=0 ; i<NodeTypes ; i++ ) { hr = bdaNetTop->GetControlNode(0, 1, NodeType[i], &iNode); if (hr == S_OK) { CComPtr <IBDA_DigitalDemodulator> pSigStats; hr = iNode.QueryInterface( &pSigStats); if (hr == S_OK) { printf("the initial value is 0x%x\n", longVal); longVal = 02; if (SUCCEEDED(hr = pSigStats->get_SymbolRate(&longVal))) { regdata = longVal; printf("the value is 0x%x\n", longVal); } printf("the ret is 0x%x\n", hr); pSigStats.Release(); } iNode.Release(); } } bdaNetTop.Release();
From: metroycn on 31 Dec 2008 02:31 accessing the standard property: for ( int i=0 ; i<NodeTypes ; i++ ) { hr = bdaNetTop->GetControlNode(0, 1, NodeType[i], &iNode); if (hr == S_OK) { CComPtr <IBDA_DigitalDemodulator> pSigStats; hr = iNode.QueryInterface( &pSigStats); if (hr == S_OK) { printf("the initial value is 0x%x\n", longVal); longVal = 02; if (SUCCEEDED(hr = pSigStats->get_SymbolRate(&longVal))) { regdata = longVal; printf("the value is 0x%x\n", longVal); } printf("the ret is 0x%x\n", hr); pSigStats.Release(); } iNode.Release(); } } bdaNetTop.Release();
|
Next
|
Last
Pages: 1 2 Prev: Installing WinUsb Next: Uninstall NDIS Lightweight filter driver vista |