default NTSC/PAL broadcast format for ttpci

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

 



This attached patch was originally proposed by Anssi Hannula to the dvb-kernel
tree a while ago.  I have recreated the patch for v4l-dvb.  It will allow the
user to choose the default broadcast mode when using the ttpci driver.  Without
this patch, NTSC users must rebuild the module to default to NTSC or else every
time the channel is changed, the driver will go back into PAL mode, causing the
tv to "scroll".

NTSC users need to only add the following line to modprobe.d:

options dvb-ttpci tv_standard=1

PAL users will not need to change anything, for this will be the default.

Best Regards,
C.
diff -ru v4l-dvb.orig/linux/drivers/media/dvb/ttpci/av7110_av.c v4l-dvb/linux/drivers/media/dvb/ttpci/av7110_av.c
--- v4l-dvb.orig/linux/drivers/media/dvb/ttpci/av7110_av.c	2006-03-16 18:14:48.000000000 -0800
+++ v4l-dvb/linux/drivers/media/dvb/ttpci/av7110_av.c	2006-03-16 18:18:21.000000000 -0800
@@ -1479,8 +1479,6 @@
 	void (*play[])(u8 *, int, void *) = { play_audio_cb, play_video_cb };
 	int i, ret;
 
-	av7110->vidmode = VIDEO_MODE_PAL;
-
 	for (i = 0; i < 2; i++) {
 		struct ipack *ipack = av7110->ipack + i;
 
diff -ru v4l-dvb.orig/linux/drivers/media/dvb/ttpci/av7110.c v4l-dvb/linux/drivers/media/dvb/ttpci/av7110.c
--- v4l-dvb.orig/linux/drivers/media/dvb/ttpci/av7110.c	2006-03-16 05:50:36.000000000 -0800
+++ v4l-dvb/linux/drivers/media/dvb/ttpci/av7110.c	2006-03-16 18:19:31.000000000 -0800
@@ -84,6 +84,7 @@
 static int rgb_on;
 static int volume = 255;
 static int budgetpatch;
+static int tv_standard;
 
 module_param_named(debug, av7110_debug, int, 0644);
 MODULE_PARM_DESC(debug, "debug level (bitmask, default 0)");
@@ -102,6 +103,8 @@
 MODULE_PARM_DESC(volume, "initial volume: default 255 (range 0-255)");
 module_param(budgetpatch, int, 0444);
 MODULE_PARM_DESC(budgetpatch, "use budget-patch hardware modification: default 0 (0 no, 1 autodetect, 2 always)");
+module_param(tv_standard, int, 0444);
+MODULE_PARM_DESC(tv_standard, "TV standard: 0 PAL (default), 1 NTSC");
 
 static void restart_feeds(struct av7110 *av7110);
 
@@ -2632,6 +2635,9 @@
 	av7110->osdwin = 1;
 	mutex_init(&av7110->osd_mutex);
 
+	/* TV standard */
+	av7110->vidmode = tv_standard == 1 ? VIDEO_MODE_NTSC : VIDEO_MODE_PAL;
+
 	/* ARM "watchdog" */
 	init_waitqueue_head(&av7110->arm_wait);
 	av7110->arm_thread = NULL;
_______________________________________________

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