static void mt2050_set_radio_freq(struct i2c_client *c, unsigned int freq) { struct tuner *t = i2c_get_clientdata(c); int if2 = t->radio_if2; mt2050_set_if_freq(c, freq*62500, if2); mt2050_set_antenna(c, radio_antenna); }
static int mt2050_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; } mt2050_set_if_freq(fe, params->frequency * 125 / 2, if2); mt2050_set_antenna(fe, radio_antenna); return 0; }
static void mt2050_set_tv_freq(struct i2c_client *c, unsigned int freq) { struct tuner *t = i2c_get_clientdata(c); unsigned int if2; if (t->std & V4L2_STD_525_60) { // NTSC if2 = 45750*1000; } else { // PAL if2 = 38900*1000; } if (V4L2_TUNER_DIGITAL_TV == t->mode) { // DVB (pinnacle 300i) if2 = 36150*1000; } mt2050_set_if_freq(c, freq*62500, if2); mt2050_set_antenna(c, tv_antenna); }
static int mt2050_set_tv_freq(struct dvb_frontend *fe, struct analog_parameters *params) { unsigned int if2; if (params->std & V4L2_STD_525_60) { // NTSC if2 = 45750*1000; } else { // PAL if2 = 38900*1000; } if (V4L2_TUNER_DIGITAL_TV == params->mode) { // DVB (pinnacle 300i) if2 = 36150*1000; } mt2050_set_if_freq(fe, params->frequency*62500, if2); mt2050_set_antenna(fe, tv_antenna); return 0; }