On Wed, 2 May 2007, Petri Helin wrote: > >>>>> If your device is using the philips tda1316 tuner, i think there is a > >>>>> problem in setting the correct Band. 162 MHz and above should be band > >>>>> 2 (Mid-Band). But in dvbc_philips_tdm1316l_tuner_set_params band 1 is > >>>>> set for frequencies below 200 MHz: > >>>>> // determine charge pump > >>>>> tuner_frequency = params->frequency; > >>>>> if (tuner_frequency < 87000000) {return -EINVAL;} > >>>>> else if (tuner_frequency < 130000000) {cp = 3; band = 1;} > >>>>> else if (tuner_frequency < 160000000) {cp = 5; band = 1;} > >>>>> else if (tuner_frequency < 200000000) {cp = 6; band = 1;} <<== > > > >> Just to let you all know, in case you didn't see an earlier post about > >> tuning problems with TechnoTrend's C1500 card, the above change broke > >> tuning on those cards with frequencies under 160MHz. > > > > That doesn't seem possible, that it would break tuning for under 160Mhz. > > > > This change only affects the band for frequencies between 160 Mhz and 200 > > Mhz, nothing outside this of this range should be affected in any way. > > > > What frequency does it break exactly? > > > > The problem seams to be that the fix was applied in the wrong file - > budget-ci.c instead of dvb-ttusb-budget.c as supposed to. > dvbc_philips_tdm1316l_tuner_set_params in budget-ci.c uses an offset of > 36125000 for frequency before assigning the charge pump and band (what's > the need for this offset??) and therefore the failing frequencies (for > example 138MHz and 146MHz) are actually interpreted as something between > 160MHz and 200MHz when the band is set. This offset is the IF frequency. Search this list for "if frequency" and you should find plenty of information. These tuning functions are old code, and should be converted into users of dvb-pll. I'll put it on my dvb-pll todo list, right after fmd1216me is committed. In budget-ci.c, philips_tdm1316l_tuner_set_params() uses 159 Mhz *pre-IF-offset* as the low-mid band switch point. While dvbc_philips_tdm1316l_tuner_set_params() uses 200 MHz *post-IF-offset* as the band switch point. In dvb-ttusb-budget.c, philips_tdm1316l_tuner_set_params() uses 159 MHz pre-IF-offset. And dvbc_philips_tdm1316l_tuner_set_params() uses 200 MHz pre-IF-offset. This 4x duplication of the same code with random bugs in some copies is exactly why this should be converted to dvb-pll! I think it is highly likely that the band switch point post-IF-offset is the same for both the DVB-T and the DVB-C tuners. driver tuner post-IF-offset low-mid band switch point budget-ci DVB-T 195 1/8 MHz (to two decimal places) budget-ci DVB-C 200 MHz (this is the likely correct value) ttusb-budget DVB-T 195 1/8 MHz (to two decimal places) ttusb-budget DVB-C 236 1/8 MHz (this is clearly wrong) My guess is the correct value is 200 MHz, not 195 1/8th. It would only make a difference for a channel between 159 MHz and 163.87 MHz. Does anyone have the datasheet to check? _______________________________________________ linux-dvb mailing list linux-dvb@xxxxxxxxxxx http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb