Hi, Johannes Stezenbach wrote: > On Tue, Nov 29, 2005, Hartmut Hackmann wrote: > >>Steve Toth wrote: >> >>>I went through the FMD1216 datasheet and updated the FMD PLL bands based >>>on the official document. The current values differ from the datasheet. >>> >>>The existing dvb-pll.c values appear to work fine for the HVR1100, and >>>also work fine for many of the existing FMD tuner products so I don't >>>know whether this patch will be accepted or not. Some of the existing >>>bands are out (just a little) so tuning problems with the current values >>>may not be completely obvious. The current values are close, but not >>>accurate. >> >>Hm, the data sheet of the FMD2116ME MK3 is - lets say - a problem. >>One issue is the DVB-T IF frequency. I got told it is 36.125MHz but >>this can't be right. The tuner can't tune to this frequency, it should >>be 36.167MHz. Tuning step size definitely is 166.667kHz (4MHz / 24), >>so this is wrong in your patch. Also all examples in the data sheet >>have bit 6 of the bandswitch byte set... > > > Errors in data sheets seem to be quite common, I only trust > tested code. Steve, if you can check Philips reference code > or Hauppauge Windoze driver code, this would be a more > reliable source for these numbers... > Well, I think it makes no sense to debate about the IF frequency since the values we discuss (36.167, 36.13) all fall into the same tuning step. So in practice it makes no difference... About the step size there isn't anything to debate either, everybody can calculate that 166,667kHz is the right value. The point just is that it *must* be so precise. The remaining thing just is bit 6 of the bandswitch byte. > >>There generally is a problem with dvb-pll.c: I miss functions to >>initialize and to "deinitialize" the tuner. This is very important for >>hybrid analog and digital cards. That's why i have my own versions in >>saa7134-dvb.c - including FMD1216. This should be changed some time. > > > Would should the "initialize" and "deinitialize" functions do? > I thought the PLL is used by both the analog and digital > demodulators, so all you do with the PLL when switching > between analog and digital is writing the new config > via i2c? Not really. There are 2 issues: - Some hybrid tuners like the FMD1216 need to be switched between analog and digital mode. This can be a bit in the bandswitch byte, but it doesn't need to be. - Philips recommends different setups for the RF AGC in tuners like the FMD1216 and the TD1316. The configuration bits lie in a 5th, "hidden" configuration byte to the tuner. So correct initialization is to sent a first initialization message before first tuning. Additionally, the chips currently not needed should be put into sleep mode if they are currently not needed to save power. These tasks can be done in the board layer driver, but i think code accessing a specific chip should go into a single module (file). Best regards Hartmut