Anssi Hannula wrote: > ... > Okay, attached is a patch for nit.c that checks for all the frequencies > in frequency_list_descriptor for the channel's frequency and if found, > use it so that channel's frequency is not changed. > > Also in the detection of new transponders all frequencies are added for > the EITscanner. > > I tested it by removing a transponder from channels.conf, and VDR found > it again (though it took a while, as there are *many* frequencies in the > frequency_list_descriptor). This too hasn't been working before on the > DVB-T network of Finland. > > Note that the patch uses list from C++ STL. If you wish to implement the > list with something else, it should be trivial to modify. > > > > ------------------------------------------------------------------------ > > --- vdr-vanilla/nit.c 2006-04-15 17:10:42.000000000 +0300 > +++ vdr-vanilla/nit.c.new 2006-05-27 00:14:16.000000000 +0300 > @@ -7,6 +7,7 @@ > * $Id: nit.c 1.11 2006/04/15 14:10:42 kls Exp $ > */ > > +#include <list> > #include "nit.h" > #include <linux/dvb/frontend.h> > #include "channels.h" > @@ -95,39 +96,75 @@ void cNitFilter::Process(u_short Pid, u_ > SI::NIT::TransportStream ts; > for (SI::Loop::Iterator it; nit.transportStreamLoop.getNext(ts, it); ) { > SI::Descriptor *d; > + std::list<int> Frequencies; > + std::list<int>::iterator frequency; > + for (SI::Loop::Iterator it2; (d = ts.transportStreamDescriptors.getNext(it2, SI::FrequencyListDescriptorTag)); ) { > + SI::FrequencyListDescriptor *fld = (SI::FrequencyListDescriptor *)d; > + int coding_type = fld->getCodingType(); > + switch (coding_type) { > + case 1: // Satellite > + for (SI::Loop::Iterator it3; fld->frequencies.hasNext(it3); ) > + Frequencies.push_back(BCD2INT(fld->frequencies.getNext(it3)) / 100); > + break; > + case 2: // Cable > + for (SI::Loop::Iterator it3; fld->frequencies.hasNext(it3); ) > + Frequencies.push_back(BCD2INT(fld->frequencies.getNext(it3)) / 10); > + break; > + case 3: // Terrestrial > + for (SI::Loop::Iterator it3; fld->frequencies.hasNext(it3); ) > + Frequencies.push_back(fld->frequencies.getNext(it3) * 10); > + break; > + default: ; > + } I believe there is a 'delete d' missing here. > + } I guess it's fair to assume that each TransportStream can contain at most one FrequencyListDescriptor, right? Otherwise the above loop could mix frequencies from different coding types, which would lead to confusion later on. Klaus