[PATCH] Support for Avermedia DVB-S Pro (A700) - Analog inputs only

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi list!

The attached patch adds support for the analog inputs (composite and svideo) 
of the Avermedia AverTV DVB-S Pro (A700) card. It is based on saa7135HL chip.
DVB support is nothing I could provide for now :(
So I decided it would be better to get analog only to work and tested :)

Wiki-page I created for this card is here:
http://www.linuxtv.org/wiki/index.php/AVerMedia_AVerTV_DVB-S_Pro_(A700)


Testing:
* Composite did work.
* As I have no svideo devices I connected my composite device to one of the 
pins of svideo connector and got a bw-image. So I guess it should work.

* Audio capturing using saa7134-alsa did work - but it showed me three mute 
and three volume control-meters in mixer. And only the mute switch did work 
to select the correct input. Is that something I could improve in my patch?

So what remains to do:
* IR receiver
* DVB

Matthias

-- 
Matthias Schwarzott (zzam)
Index: v4l-dvb/linux/drivers/media/video/saa7134/saa7134-cards.c
===================================================================
--- v4l-dvb.orig/linux/drivers/media/video/saa7134/saa7134-cards.c
+++ v4l-dvb/linux/drivers/media/video/saa7134/saa7134-cards.c
@@ -3592,6 +3592,25 @@ struct saa7134_board saa7134_boards[] = 
 			.tv     = 1,
 		}},
 	},
+	[SAA7134_BOARD_AVERMEDIA_A700] = {
+		/* Matthias Schwarzott <zzam@xxxxxxxxxx> */
+		.name           = "Avermedia A700",
+		.audio_clock    = 0x00187de7,
+		.tuner_type     = TUNER_ABSENT,
+		.radio_type     = UNSET,
+		.tuner_addr     = ADDR_UNSET,
+		.radio_addr     = ADDR_UNSET,
+		/* no DVB support for now */
+		.inputs         = {{
+			.name = name_comp,
+			.vmux = 1,
+			.amux = LINE1,
+		},{
+			.name = name_svideo,
+			.vmux = 6,
+			.amux = LINE1,
+		}},
+	},
 };
 
 const unsigned int saa7134_bcount = ARRAY_SIZE(saa7134_boards);
@@ -3824,6 +3843,12 @@ struct pci_device_id saa7134_pci_tbl[] =
 		.driver_data  = SAA7134_BOARD_MD2819,
 	},{
 		.vendor       = PCI_VENDOR_ID_PHILIPS,
+		.device       = PCI_DEVICE_ID_PHILIPS_SAA7133,
+		.subvendor    = 0x1461, /* Avermedia Technologies Inc */
+		.subdevice    = 0xa7a1,
+		.driver_data  = SAA7134_BOARD_AVERMEDIA_A700,
+	},{
+		.vendor       = PCI_VENDOR_ID_PHILIPS,
 		.device       = PCI_DEVICE_ID_PHILIPS_SAA7130,
 		.subvendor    = 0x1461, /* Avermedia Technologies Inc */
 		.subdevice    = 0x2115,
@@ -4614,6 +4639,14 @@ int saa7134_board_init1(struct saa7134_d
 		saa_andorl(SAA7134_GPIO_GPMODE0 >> 2,   0x8c040007, 0x8c040007);
 		saa_andorl(SAA7134_GPIO_GPSTATUS0 >> 2, 0x0c0007cd, 0x0c0007cd);
 		break;
+	case SAA7134_BOARD_AVERMEDIA_A700:
+		/* write windows gpio values */
+		saa_andorl(SAA7134_GPIO_GPMODE0 >> 2,   0x80040100, 0x80040100);
+		saa_andorl(SAA7134_GPIO_GPSTATUS0 >> 2, 0x80040100, 0x00040100);
+		printk("%s: %s: hybrid analog/dvb card\n"
+		       "%s: Sorry, only the analog inputs are supported for now.\n",
+			dev->name,card(dev).name,dev->name);
+		break;
 	}
 	return 0;
 }
Index: v4l-dvb/linux/drivers/media/video/saa7134/saa7134.h
===================================================================
--- v4l-dvb.orig/linux/drivers/media/video/saa7134/saa7134.h
+++ v4l-dvb/linux/drivers/media/video/saa7134/saa7134.h
@@ -247,6 +247,7 @@ struct saa7134_format {
 #define SAA7134_BOARD_SABRENT_TV_PCB05     115
 #define SAA7134_BOARD_10MOONSTVMASTER3     116
 #define SAA7134_BOARD_AVERMEDIA_SUPER_007  117
+#define SAA7134_BOARD_AVERMEDIA_A700       118
 
 #define SAA7134_MAXBOARDS 8
 #define SAA7134_INPUT_MAX 8
Index: v4l-dvb/linux/Documentation/video4linux/CARDLIST.saa7134
===================================================================
--- v4l-dvb.orig/linux/Documentation/video4linux/CARDLIST.saa7134
+++ v4l-dvb/linux/Documentation/video4linux/CARDLIST.saa7134
@@ -116,3 +116,4 @@
 115 -> Sabrent PCMCIA TV-PCB05                  [0919:2003]
 116 -> 10MOONS TM300 TV Card                    [1131:2304]
 117 -> Avermedia Super 007                      [1461:f01d]
+118 -> Avermedia A700                           [1461:a7a1]
_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb

[Index of Archives]     [Linux Media]     [Video 4 Linux]     [Asterisk]     [Samba]     [Xorg]     [Xfree86]     [Linux USB]

  Powered by Linux