Difference between revisions of "AVerMedia Cardbus E500"

From LinuxTVWiki
Jump to: navigation, search
m (Reverted edits by BpgTxl (Talk); changed back to last version by Js)
m (Added category:Analog CardBus devices)
 
(One intermediate revision by one user not shown)
Line 117: Line 117:
 
It looks like that all the source changes are in the 2.6.15 kernel (and probably som lower versions).
 
It looks like that all the source changes are in the 2.6.15 kernel (and probably som lower versions).
 
//jostmart
 
//jostmart
 +
[[Category:Analog CardBus Devices]]

Latest revision as of 00:32, 7 May 2009

I have an AverMedia Cardbus (E500) which works fine with Windows XP. In recent 2.6.11 kernels there is this line in drivers/media/video/saa7134/saa7134.h:

#define SAA7134_BOARD_AVERMEDIA_CARDBUS 46

but the corresponding entry in saa7134-cards.c didn't work for me, I couldn't tune in any channel.

To make is work, I did the following:

1. Got the (almost) latest kernel from www.kernel.org (2.6.12-rc1) with support for tda8290+75.

2. In saa7134-cards.c I replaced the the board config entry for this card with the following:

   	[SAA7134_BOARD_AVERMEDIA_CARDBUS] = {
		/* Kees.Blom@cwi.nl */
		.name           = "AVerMedia Cardbus TV (E500)",
		.audio_clock    = 0x187de7,
		.tuner_type     = TUNER_PHILIPS_TDA8290,
		.inputs         = {{
			.name = name_tv,
			.vmux = 1,
			.amux = LINE2,
			.tv   = 1,
		},{
			.name = name_comp1,
			.vmux = 3,
			.amux = LINE2,
		},{
			.name = name_svideo,
			.vmux = 8,
			.amux = LINE2,
		}},
		.radio = {
                	.name = name_radio,
			.amux = LINE1,
		},
	},

3. Added this code in saa7134-cards.c, under the function saa7134_board_init1():

	case SAA7134_BOARD_AVERMEDIA_CARDBUS:
		/* wake-up tuner chip */
		saa_andorl(SAA7134_GPIO_GPMODE0 >> 2,   0x0FFFFFFFF, 0x0FFFFFFFF);
		saa_andorl(SAA7134_GPIO_GPSTATUS0 >> 2, 0x0FFFFFFFF, 0x0FFFFFFFF);
		break;

4. With these compiled, installed and rebooted, I issued

modprobe saa7134 oss=1

This resulted in the following lines in /var/log/messages:

Mar 28 21:57:55 localhost kernel: Linux video capture interface: v1.00
Mar 28 21:57:55 localhost kernel: saa7130/34: v4l2 driver version 0.2.12 loaded
Mar 28 21:57:55 localhost kernel: ACPI: PCI interrupt 0000:07:00.0[A] -> GSI 11 (level, low) -> IRQ 11
Mar 28 21:57:55 localhost kernel: saa7134[0]: found at 0000:07:00.0, rev: 1, irq : 11, latency: 64, mmio: 0x21000000
Mar 28 21:57:55 localhost kernel: saa7134[0]: subsystem: 1461:d6ee, board: AVerMedia Cardbus TV/Radio [card=46,autodetected]
Mar 28 21:57:55 localhost kernel: saa7134[0]: board init: gpio is effffff
Mar 28 21:57:56 localhost kernel: tuner 0-004b: chip found @ 0x96 (saa7134[0])
Mar 28 21:57:56 localhost kernel: tuner 0-004b: tuner: type set to tda8290+75
Mar 28 21:57:56 localhost kernel: saa7134[0]: i2c eeprom 00: 61 14 ee d6 ff ff ff ff ff ff ff ff ff ff ff ff
Mar 28 21:57:56 localhost kernel: saa7134[0]: i2c eeprom 10: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
Mar 28 21:57:56 localhost kernel: saa7134[0]: i2c eeprom 20: ee df ff ff ff ff ff ff ff ff ff ff ff ff ff ff
Mar 28 21:57:56 localhost kernel: saa7134[0]: i2c eeprom 30: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
Mar 28 21:57:56 localhost kernel: saa7134[0]: registered device video0 [v4l2]
Mar 28 21:57:56 localhost kernel: saa7134[0]: registered device vbi0
Mar 28 21:57:56 localhost kernel: saa7134[0]: registered device radio0
Mar 28 21:57:56 localhost kernel: saa7134[0]: registered device dsp2
Mar 28 21:57:56 localhost kernel: saa7134[0]: registered device mixer2

5. Video

At this point I could tune-in tv channels and see tv pictures with xawtv, tvtime and kdetv.

6. Audio

To get tv sound, I first typed in a terminal while tvtime was running (after killing artsd):

sox -tossdsp /dev/dsp2 -tossdsp /dev/dsp

However, this command is just a hack and sound terminates when changing channels in tvtime.

A better solution is to use Hartmut Hackman's code in CVS (as of 10 May 2005). I downloaded these files from linuxtv.org:

saa7134-oss.c,v 1.14 2005/05/18 22:45:16 hhackmann
saa7134-tvaudio.c,v 1.23 2005/05/18 22:46:17 hhackmann

and set

.amux = TV

After compiling and loading the module saa7134, the commands:

tvtime --mixer=/dev/mixer:vol&
sox -c 2 -s -w -r 32000 -t ossdsp /dev/dsp2 -t ossdsp -w -r 32000 /dev/dsp &

starts tvtime with sound and sound is now restored when changing channels.

The only flaw left is that, when changing channel, during ~1 sec. sound of the new channel is heard, followed by ~1 sec. of noise, whereafter sound is restored properly.

6. Problems left

  • is the code to wake up the tuner chip correct? Isn't trying to set all bits high a little bit too much?
  • so far, I haven't tested the S-Video and Composite inputs of this card.

Edit:Both S-Video and Composite inputs work fine, even before changes to saa7134-cards.c. I needed to pass the module option

modprobe saa7134 card=46 oss=1

because the card type was not auto detected.


This was done on a Dell Inspiron 4150 with Fedora Core 3 Installed.


Kees Blom

It looks like that all the source changes are in the 2.6.15 kernel (and probably som lower versions). //jostmart