Moderator Control Panel ]

TBS6205 DVB-T2 PLP

TBS6205 DVB-T2 PLP

Postby tolyan249 » Tue Nov 19, 2019 6:36 pm

DVB-T2 PLP switching :
IDVBTLocator2 - Does the board support this interface? What functions can I switch PLP?

KSPROPERTY_BDA_PLP_NUMBER
IBDA_DigitalDemodulator3

I am writing on DELPHI XE8.
The program works but can not switch PLP.

Thanks.
tolyan249
 
Posts: 5
Joined: Mon Nov 18, 2019 6:12 pm

Re: TBS6205 DVB-T2 PLP

Postby smile » Fri Nov 22, 2019 3:05 pm

Hi
About the plp , we are use a private interface for get and set.

// {FAA8F3E5-31D4-4e41-88EF-D9EB716F6EC9}
#define STATIC_KSPROPSETID_BdaTunerExtensionProperties \
0xfaa8f3e5, 0x31d4, 0x4e41, 0x88, 0xef, 0xd9, 0xeb, 0x71, 0x6f, 0x6e, 0xc9
DEFINE_GUIDSTRUCT("FAA8F3E5-31D4-4e41-88EF-D9EB716F6EC9", KSPROPSETID_BdaTunerExtensionProperties);
#define KSPROPSETID_BdaTunerExtensionProperties DEFINE_GUIDNAMED(KSPROPSETID_BdaTunerExtensionProperties)

typedef enum {
KSPROPERTY_BDA_DISEQC_MESSAGE = 0, //Custom property for Diseqc messaging
KSPROPERTY_BDA_DISEQC_INIT, //Custom property for Intializing Diseqc.
KSPROPERTY_BDA_SCAN_FREQ, //Not supported
KSPROPERTY_BDA_CHANNEL_CHANGE, //Custom property for changing channel
KSPROPERTY_BDA_DEMOD_INFO, //Custom property for returning demod FW state and version
KSPROPERTY_BDA_EFFECTIVE_FREQ, //Not supported
KSPROPERTY_BDA_SIGNAL_STATUS, //Custom property for returning signal quality, strength, BER and other attributes
KSPROPERTY_BDA_LOCK_STATUS, //Custom property for returning demod lock indicators
KSPROPERTY_BDA_ERROR_CONTROL, //Custom property for controlling error correction and BER window
KSPROPERTY_BDA_CHANNEL_INFO, //Custom property for exposing the locked values of frequency,symbol rate etc after
//corrections and adjustments
KSPROPERTY_BDA_NBC_PARAMS,
KSPROPERTY_BDA_BLIND_SCAN,
KSPROPERTY_BDA_GET_MEDIAINFO,
KSPROPERTY_BDA_STREAMTYPE_PARAMS,
KSPROPERTY_BDA_INPUTMULTISTREAMID,//added 2011 01 27
KSPROPERTY_BDA_MACACCESS,//added 2010 12 07

KSPROPERTY_BDA_SETHV, //added 2011 05 21 control HV , 22k , h=1;v=0; //6925;6984
KSPROPERTY_BDA_SET22K, //22k 0 off; 1 on //6925;6984
KSPROPERTY_BDA_CI_ACCESS, //BOB ci /6992,6618,6928
KSPROPERTY_BDA_UNICABLE, //******added 2011 10 19 interface for all card*****/
KSPROPERTY_BDA_PMT_ACCESS , // ci mce /6992,6618,6928
KSPROPERTY_BDA_TBSACCESS,

KSPROPERTY_BDA_PLPINFO,//added 2012 11 09 liuy DVBT2 PLP interface
KSPROPERTY_BDA_GOLDCODE,//added 2013 02 25 liuy
KSPROPERTY_BDA_MODCODES,
KSPROPERTY_BDA_TBSI2CACCESS,//added 20140617 luchy For TBS PCI-E bridge I2C interface

KSPROPERTY_BDA_FPGA_RDID = 100,
KSPROPERTY_BDA_FPGA_ERASE_WriteCtrl = 101,
KSPROPERTY_BDA_FPGA_WRITEONEPAGE = 102,
KSPROPERTY_BDA_FPGA_VERIFY = 103,
} KSPROPERTY_BDA_TUNER_EXTENSION;

this is struct of PLP:
typedef struct _plp_info
{
unsigned char plpId; //The Rel PLPID need to set
unsigned char plpCount; //PLP number
unsigned char plpResered1;//
unsigned char plpResered2;// memory size set to 4

unsigned char plpIdList[256];//store the Rel PLPID

} PLP_INFO,*p_PLP_INFO;

for example:
set property:

unsigned long BytesRead=0;
DWORD TypeSupport=0;
HRESULT hr ;
PLP_INFO plp;
plp.plpId = 2 // this plp value is you want to set .

hr = m_pKsCtrl->Set(KSPROPSETID_BdaTunerExtensionProperties,
KSPROPERTY_BDA_PLPINFO,
&plp,
sizeof( plp),
&plp,
sizeof( plp));
if (FAILED(hr))
{
MessageBox("set mode failure!!","error",MB_OK);

}

get property:
HRESULT hr = S_OK;
unsigned long BytesRead=1;
PLP_INFO plp;
DWORD TypeSupport=0;

hr = m_pKsCtrl->Get(KSPROPSETID_BdaTunerExtensionProperties,
KSPROPERTY_BDA_PLPINFO,
&plp,
sizeof( plp),
&plp,
sizeof( plp),
&BytesRead );
// here you will got the plp info form the drivers. "plpCount" the value mean how many plp id on this frequency.
//plplist[] store the plp id.

Best Regards
smile
 
Posts: 164
Joined: Sun Oct 09, 2011 9:51 am

Re: TBS6205 DVB-T2 PLP

Postby tolyan249 » Fri Nov 22, 2019 8:05 pm

You can translate this to delphi XE, how to describe it and apply it correctly, I don't know.

Wanted to ask and when apply these functions installations PLP, after launch graph filters or until launch graph filters or during installations frequency IDVBLocator or can be in any time ?

Or write a DLL to switch PLP, where you enter the receiver number and the PLP number, so that this DLL can be used in different programming languages.

Just in Dlphi there is no description of some functions that are in C++ , and how to apply what you wrote to me the code, I do not know. Help to solve the problem with switching PLP.


Thanks for the answer and help.
tolyan249
 
Posts: 5
Joined: Mon Nov 18, 2019 6:12 pm

Re: TBS6205 DVB-T2 PLP

Postby steven » Sat Nov 23, 2019 9:19 pm

you need to lock the frequency first then use the interface to get the PLP value , after get then you can set the PLP value
steven
 
Posts: 2239
Joined: Fri Aug 06, 2010 3:23 pm

Re: TBS6205 DVB-T2 PLP

Postby tolyan249 » Sun Nov 24, 2019 10:31 am

I try the code that is described above(translated to delphi), it gives an error.


KSPROPSETID_BdaTunerExtensionProperties:TGuid='{FAA8F3E5-31D4-4e41-88EF-D9EB716F6EC9}';

//---------------------------------------------------------------------------------------

TYPE
KSPROPERTY_BDA_TUNER_EXTENSION=(
KSPROPERTY_BDA_DISEQC_MESSAGE=0,
KSPROPERT_Q__D__D_D_D_T_T_T_F_RU_DB_RU_IQ_REG_REG_RUE_IND_C_I_RU_R_R_C_R_R_R_E_DI_R_R_TR_R_C_PR_RID_R_R_R_R_R_Rid_R_R_L_R_R_D_D_D_D_RDRDDWDWDWD,
KSPROPERTY_BDA_SCAN_FREQ, // Не поддерживается
KSPROPERTY_BDA_CHANNEL_CHANGE, // настраиваемого свойства для изменения канала
KSPROPERTY_BDA_DEMOD_INFO, // настраиваемого свойства для возвращения демодулятора FW состояния и версии
KSPROPERTY_BDA_EFFECTIVE_FREQ, // Не поддерживается
KSPROPERTY_BDA_SIGNAL_STATUS, // настраиваемого свойства для возвращения качества сигнала, силы, BER и других атрибуты
KSPROPERTY_BDA_LOCK_STATUS, // Пользовательский свойство для возврата индикаторов блокировки
KSPROPERTY_BDA_ERROR_CONTROL, // пользовательское свойство для управления исправлением ошибок и окном BER
KSPROPERTY_BDA_CHANNEL_INFO, // пользовательское свойство для отображения заблокированных значений частоты, скорости передачи символов и т. д. после
KSPROPERTY_BDA_NBC_PARAMS,
KSPROPERTY_BDA_BLIND_SCAN,
KSPROPERTY_BDA_GET_MEDIAINFO,
KSPROPERTY_BDA_STREAMTYPE_PARAMS,
KSPROPERTY_BDA_INPUTMULTISTREAMID, // добавили 2011 01 27
KSPROPERTY_BDA_MACACCESS, // добавили 2010 12 07
KSPROPERTY_BDA_SETHV, // добавили 2011 05 21 управления HV, 22k, ч = 1; v = 0; // 6925; 6984
KSPROPERTY_BDA_SET22K, // 22k 0 off; 1 on // 6925; 6984
KSPROPERTY_BDA_CI_ACCESS, // BOB ci / 6992,6618,6928
KSPROPERTY_BDA_UNICABLE, // ****** добавлен интерфейс 2011 10 19 для всех карт ***** /
KSPROPERTY_BDA_PMT_ACCESS, // ci mce / 6992,6618,6928
KSPROPERTY_BDA_TBSACCESS,
KSPROPERTY_BDA_PLPINFO=22, // добавлено 2012 11 09 июля DVBT2-интерфейс PLP
KSPROPERTY_BDA_GOLDCODE, // добавлено 2013 02 25 июля
KSPROPERTY_BDA_MODCODES,
KSPROPERTY_BDA_TBSI2CACCESS, // добавлена 20140617 luchy Для ТБС PCI-E моста I2C интерфейса

KSPROPERTY_BDA_FPGA_RDID = 100,
KSPROPERTY_BDA_FPGA_ERASE_WriteCtrl = 101,
KSPROPERTY_BDA_FPGA_WRITEONEPAGE = 102,
KSPROPERTY_BDA_FPGA_VERIFY = 103
);

TKSPROPERTY_BDA_TUNER_EXTENSION = KSPROPERTY_BDA_TUNER_EXTENSION;



type
TBS_PLP_INFO=record // PLP info for TBS tuners struct
plpId:integer; //The Rel PLPID need to set
cplpCount:integer; //PLP count number
plpResered1:integer;//
plpResered2:integer;// memory size set to 4
plpIdList:integer;//store the Rel PLPID
end;

TTBS_PLP_INFO=TBS_PLP_INFO;



procedure TBDAFilterGraph.setPLPINfo(TunerD:IBaseFilter; plpint:integer);
var
BytesRead:long;// = 0;
TypeSupport:DWORD ; //= 0;
hr:HRESULT;
plp:TBS_PLP_INFO;
PropertySet : IKSPropertySet;
dwSupported:Dword;
ret:Dword;
begin



ZeroMemory(@plp, sizeof(PLP));


hr:=TunerD.QueryInterface(IID_IKsPropertySet,PropertySet);
if (FAILED (hr)) then showmessage ('сбой установки интерфейса TunerD');// тут hr=0(S_OK)


hr:=PropertySet.Get(KSPROPERTYSET_IID_BdaTunerExtensionProperties,
AMPROPERTY_PIN(KSPROPERTY_BDA_PLPINFO),
NiL,
0,
plp,
sizeof(TTBS_PLP_INFO),ret); //Ошибка тут result<>0


if (FAILED (hr)) then showmessage ('сбой чтения PLP_INFO');




plp.plpId:=plpint; // это значение plp, которое вы хотите установить.


hr:=PropertySet.Set_(KSPROPSETID_BdaTunerExtensionProperties,
AMPROPERTY_PIN(KSPROPERTY_BDA_PLPINFO),
nil,
0,
@plp,
sizeof(TTBS_PLP_INFO)); //Ошибка тут result<>0

if (FAILED (hr)) then showmessage ('сбой установки PLP');

end;



Procedure BDAFilterGraph.addfilter(ch,bn,plpid:integer;TunerPath,CapturePath:string);
// Load tuner device and connect to network provider
hr := LoadFilter(KSCATEGORY_BDA_NETWORK_TUNER, FTunerDevice,FNetworkProvider, true, TunerPath);
if FAILED( hr) then
begin
WriteLog('Could not load tuner ' + SysErrorMessage(hr));
Result := hr;
Exit;
end;

//Дальше устанавливаем частоту
end;



Procedure BDAFilterGraph.rungraph;
begin
//получаем интерфейс ImediaControl
hr:=(FGraphBuilder as IFilterGraph2).QueryInterface(IID_IMediaControl, FMediaControl);
if FAILED(HR) then
begin
showmessage('Не могу получить интерфейс FmediaControl');
result:=hr;
EXIT;
end;


//устанавливаю частоту ,запускаю граф фильтров
FMediaControl.Run;



//Устанавливаем PLP
SetPlpINFO(FTunerDevice,1); 1-это номер PLP


end;

I find the interface of the tuner, I check whether it has IID_IKsPropertySet, if there is that we read PLP_INFO then we install PLP_INFO.

Thanks for the help and answers.
tolyan249
 
Posts: 5
Joined: Mon Nov 18, 2019 6:12 pm

Re: TBS6205 DVB-T2 PLP

Postby tolyan249 » Sun Nov 24, 2019 12:54 pm

What GUID have KSPROPERTY_BDA_TUNER_EXTENSION ?

Interface found {FAA8F3E5-31D4-4E41-88EF-D9EB716F6EC9}

and interface KSPROPERTY_BDA_TUNER_EXTENSION not found, also tried to find interface KSPROPERTY_BDA_PLPINFO, too, not found

Can you write a separate DLL for switching PLP, where to enter the name of the receiver and the PLP number, or can you already have such a DLL where it can be done for TBS6205.


Thanks for the answers and help.
tolyan249
 
Posts: 5
Joined: Mon Nov 18, 2019 6:12 pm

Re: TBS6205 DVB-T2 PLP

Postby smile » Tue Nov 26, 2019 3:10 pm

Hi
sorry, i do not know the delphi.
In my example, i have omited connect BDA filter. you should be add them.

Best regards
smile
 
Posts: 164
Joined: Sun Oct 09, 2011 9:51 am

Re: TBS6205 DVB-T2 PLP

Postby tolyan249 » Tue Nov 26, 2019 10:27 pm

Thank you all for the answers. The question is closed.
tolyan249
 
Posts: 5
Joined: Mon Nov 18, 2019 6:12 pm

Re: TBS6205 DVB-T2 PLP

Postby priyateke » Wed May 20, 2020 2:37 pm

Great Information :)
priyateke
 
Posts: 1
Joined: Wed May 20, 2020 2:07 pm


Return to Off topics

Who is online

Users browsing this forum: No registered users and 2 guests