static void mt2032_set_radio_freq(struct i2c_client *c, unsigned int freq) { struct tuner *t = i2c_get_clientdata(c); int if2 = t->radio_if2; // per Manual for FM tuning: first if center freq. 1085 MHz mt2032_set_if_freq(c, freq*62500 /* freq*1000*1000/16 */, 1085*1000*1000,if2,if2,if2); }
static int mt2032_set_radio_freq(struct dvb_frontend *fe, struct analog_parameters *params) { struct microtune_priv *priv = fe->tuner_priv; int if2; if (params->std & V4L2_STD_525_60) { tuner_dbg("pinnacle ntsc\n"); if2 = 41300 * 1000; } else { tuner_dbg("pinnacle pal\n"); if2 = 33300 * 1000; } // per Manual for FM tuning: first if center freq. 1085 MHz mt2032_set_if_freq(fe, params->frequency * 125 / 2, 1085*1000*1000,if2,if2,if2); return 0; }
static void mt2032_set_tv_freq(struct i2c_client *c, unsigned int freq) { struct tuner *t = i2c_get_clientdata(c); int if2,from,to; // signal bandwidth and picture carrier if (t->std & V4L2_STD_525_60) { // NTSC from = 40750*1000; to = 46750*1000; if2 = 45750*1000; } else { // PAL from = 32900*1000; to = 39900*1000; if2 = 38900*1000; } mt2032_set_if_freq(c, freq*62500 /* freq*1000*1000/16 */, 1090*1000*1000, if2, from, to); }
static int mt2032_set_tv_freq(struct dvb_frontend *fe, struct analog_parameters *params) { int if2,from,to; // signal bandwidth and picture carrier if (params->std & V4L2_STD_525_60) { // NTSC from = 40750*1000; to = 46750*1000; if2 = 45750*1000; } else { // PAL from = 32900*1000; to = 39900*1000; if2 = 38900*1000; } mt2032_set_if_freq(fe, params->frequency*62500, 1090*1000*1000, if2, from, to); return 0; }