|
|
|
[PATCH] Asus P7131 Dual - automate setting of RF antenna input in DVB-T mode - was - Re: RE : Re: MyCinema-P7131 Hybrid - no detection of tuner | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
Am Montag, den 04.09.2006, 22:22 +0200 schrieb hermann pitton: > Am Sonntag, den 03.09.2006, 17:50 +0200 schrieb Hartmut Hackmann: > > HI, Hermann > > > > hermann pitton wrote: > > > Am Donnerstag, den 10.08.2006, 23:54 +0200 schrieb hermann pitton: > > > > > >>Am Donnerstag, den 10.08.2006, 02:36 +0200 schrieb hermann pitton: > > >> > > >>>[...] > [...] > > > > Hi Hartmut, > > > > > > please comment. > > > > > > It is not about my personal favours, we need it for apps like xawtv4, > > > which probe on hybrid cards. > > > > > > My problem is not to use your nice legoland to make it card specific, > > > but to set gpios on cards I don't have. > > > > > Jep, i understand. The cards affected are the asus, the philips tiger > > and the md8800. I need to find out what is necessary for this. We can > > duplicate the functions for the time being, but when there is time, > > i'd like to rework the driver to use more configuration tables and as > > few board specific functions as possible. > > Hello Hartmut, > > thanks for review! > > Can I leave it for the two functions, like it is in the testpatch and > would you like that I regenerate a patch against master or your repo? Anyway, here is one against the master repository. Thanks, Hermann - Asus P7131 Dual hybrid. Introduce a card specific switch to set the RF antenna input in DVB-T mode. This allows apps to access analog and digital mode without user intervention. Signed-off-by: Hermann Pitton <hermann-pitton@xxxxxxxx>
diff -r 443f5b4e2365 linux/drivers/media/video/saa7134/saa7134-dvb.c
--- a/linux/drivers/media/video/saa7134/saa7134-dvb.c Sun Sep 3 16:33:10 2006
+++ b/linux/drivers/media/video/saa7134/saa7134-dvb.c Mon Sep 4 22:38:42 2006
@@ -875,6 +875,34 @@
/* ------------------------------------------------------------------ */
+static int asus_p7131_dual_tuner_init(struct dvb_frontend *fe)
+{
+ struct saa7134_dev *dev = fe->dvb->priv;
+ static u8 data[] = { 0x3c, 0x33, 0x6a};
+ struct i2c_msg msg = {.addr=0x08, .flags=0, .buf=data, .len = sizeof(data)};
+
+ if (i2c_transfer(&dev->i2c_adap, &msg, 1) != 1)
+ return -EIO;
+ /* make sure the DVB-T antenna input is set */
+ saa_setl(SAA7134_GPIO_GPSTATUS0 >> 2, 0x0200000);
+ return 0;
+}
+
+static int asus_p7131_dual_tuner_sleep(struct dvb_frontend *fe)
+{
+ struct saa7134_dev *dev = fe->dvb->priv;
+ static u8 data[] = { 0x3c, 0x33, 0x68};
+ struct i2c_msg msg = {.addr=0x08, .flags=0, .buf=data, .len = sizeof(data)};
+
+ i2c_transfer(&dev->i2c_adap, &msg, 1);
+ philips_tda827xa_tuner_sleep( 0x61, fe);
+ /* reset antenna inputs for analog usage */
+ saa_clearl(SAA7134_GPIO_GPSTATUS0 >> 2, 0x0200000);
+ return 0;
+}
+
+/* ------------------------------------------------------------------ */
+
static int lifeview_trio_tuner_set_params(struct dvb_frontend *fe, struct dvb_frontend_parameters *params)
{
int ret;
@@ -1148,8 +1176,8 @@
&philips_tiger_config,
&dev->i2c_adap);
if (dev->dvb.frontend) {
- dev->dvb.frontend->ops.tuner_ops.init = philips_tiger_tuner_init;
- dev->dvb.frontend->ops.tuner_ops.sleep = philips_tiger_tuner_sleep;
+ dev->dvb.frontend->ops.tuner_ops.init = asus_p7131_dual_tuner_init;
+ dev->dvb.frontend->ops.tuner_ops.sleep = asus_p7131_dual_tuner_sleep;
dev->dvb.frontend->ops.tuner_ops.set_params = philips_tiger_tuner_set_params;
}
break;
-- Unsubscribe mailto:video4linux-list-request@xxxxxxxxxx?subject=unsubscribe https://www.redhat.com/mailman/listinfo/video4linux-list
[Linux Media] [Older V4L] [Linux DVB] [Video Disk Recorder] [Linux Kernel] [Asterisk] [Photo] [DCCP] [Netdev] [Xorg] [Util Linux NG] [Xfree86] [Free Photo Albums] [Fedora Users] [Fedora Women] [ALSA Users] [ALSA Devel] [SSH] [DVB Maintainers] [Linux USB] [Yosemite Information]
![]() |
![]() |