<div>
Allan,<br><br>My patch has not been merged into the branch,<br><br>For the moment don't worry about it and use Chris Pascoe's xc-test branch. <br><br>I have worked out what my issue is on the one PC that didn't work. I'm actually surprised it worked on the other systems, it was only due to a weird coincidence in identifying my other tuner cards first.<br>I have been slowly going through the source to attempt to solve this, I will post when it is working reliably on all machines.<br><br>Thanks for at least trying it.<br><br>Regards,<br>Stephen<br><br>
<br>
<blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;">----- Original Message -----<br>
From: "allan k" <sonofzev@iinet.net.au><br>
To: stev391@email.com<br>
Subject: Re: [linux-dvb] DViCO Fusion HDTV DVB-T Dual Express [PATCH]<br>
Date: Sat, 17 May 2008 21:27:19 +1000<br>
<br>
<br>
Hi Steve<br>
<br>
I'm getting a large amount of noise again, although after previous<br>
restarts this didn't happen.<br>
<br>
I'm wondering if your patch is already merged into the v4l sources or if<br>
I need to use this one you sent.<br>
<br>
cheers<br>
<br>
Allan<br>
On Wed, 2008-05-14 at 15:54 +1000, stev391@email.com wrote:<br>
><br>
> I have updated my patch (from a week ago) and is included inline below<br>
> as well as an attachment. The issue that was noticed and mentioned in<br>
> previous posts regarding to tuners not resetting was possibly due to<br>
> several "__FUNCTION_" in the tuner reset code, these should be<br>
> "__func__", which is fixed in the attached patch.<br>
><br>
> This patch is against the v4l-dvb head (7897, 2e9a2e4c8435) and is<br>
> intended to merge Chris Pascoe's work into the current head to enable<br>
> support for the DViCO Fusion HDTV DVB-T Dual Express (PCIe). This<br>
> enables systems with different tuners to take advantage of other<br>
> experimental drivers, (for example my TV Walker Twin USB tuner).<br>
><br>
> Regards,<br>
><br>
> Stephen<br>
><br>
> diff -Naur v4l-dvb/linux/Documentation/video4linux/CARDLIST.cx23885<br>
> v4l-dvb_dev/linux/Documentation/video4linux/CARDLIST.cx23885<br>
> --- v4l-dvb/linux/Documentation/video4linux/CARDLIST.cx23885<br>
> 2008-05-14 09:48:21.000000000 +1000<br>
> +++ v4l-dvb_dev/linux/Documentation/video4linux/CARDLIST.cx23885<br>
> 2008-05-14 13:39:30.000000000 +1000<br>
> @@ -8,3 +8,4 @@<br>
> 7 -> Hauppauge WinTV-HVR1200<br>
> [0070:71d1,0070:71d3]<br>
> ; 8 -> Hauppauge WinTV-HVR1700<br>
> [0070:8101]<br>
> 9 -> Hauppauge WinTV-HVR1400<br>
> [0070:8010]<br>
> + 10 -> DViCO FusionHDTV DVB-T Dual Express<br>
> [18ac:db78]<br>
> diff -Naur v4l-dvb/linux/drivers/media/video/cx23885/cx23885-cards.c<br>
> v4l-dvb_dev/linux/drivers/media/video/cx23885/cx23885-cards.c<br>
> --- v4l-dvb/linux/drivers/media/video/cx23885/cx23885-cards.c<br>
> 2008-05-14 09:48:22.000000000 +1000<br>
> +++ v4l-dvb_dev/linux/drivers/media/video/cx23885/cx23885-cards.c<br>
> 2008-05-14 13:39:30.000000000 +1000<br>
> @@ -144,6 +144,11 @@<br>
> .name = "Hauppauge WinTV-HVR1400",<br>
> .portc = CX23885_MPEG_DVB,<br>
> },<br>
> + [CX23885_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL_EXP] = {<br>
> + .name = "DViCO FusionHDTV DVB-T Dual Express",<br>
> + .portb = CX23885_MPEG_DVB,<br>
> + .portc = CX23885_MPEG_DVB,<br>
> + },<br>
> };<br>
> const unsigned int cx23885_bcount = ARRAY_SIZE(cx23885_boards);<br>
><br>
> @@ -211,6 +216,10 @@<br>
> .subvendor = 0x0070,<br>
> .subdevice = 0x8010,<br>
> .card = CX23885_BOARD_HAUPPAUGE_HVR1400,<br>
> + },{<br>
> + .subvendor = 0x18ac,<br>
> + .subdevice = 0xdb78,<br>
> + .card = CX23885_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL_EXP,<br>
> },<br>
> };<br>
> const unsigned int cx23885_idcount = ARRAY_SIZE(cx23885_subids);<br>
> @@ -428,6 +437,13 @@<br>
> mdelay(20);<br>
> cx_set(GP0_IO, 0x00050005);<br>
> break;<br>
> + case CX23885_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL_EXP:<br>
> + /* GPIO-0 portb xc3028 reset */<br>
> + /* GPIO-1 portb zl10353 reset */<br>
> + /* GPIO-2 portc xc3028 reset */<br>
> + /* GPIO-3 portc zl10353 reset */<br>
> + cx_write(GP0_IO, 0x002f1000);<br>
> + break;<br>
> }<br>
> }<br>
><br>
> @@ -442,6 +458,9 @@<br>
> case CX23885_BOARD_HAUPPAUGE_HVR1400:<br>
> /* FIXME: Implement me */<br>
> break;<br>
> + case CX23885_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL_EXP:<br>
> + request_module("ir-kbd-i2c");<br>
> + break;<br>
> }<br>
><br>
> return 0;<br>
> @@ -478,6 +497,11 @@<br>
> }<br>
><br>
> switch (dev->board) {<br>
> + case CX23885_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL_EXP:<br>
> + ts2->gen_ctrl_val = 0xc; /* Serial bus + punctured clock */<br>
> + ts2->ts_clk_en_val = 0x1; /* Enable TS_CLK */<br>
> + ts2->src_sel_val = CX23885_SRC_SEL_PARALLEL_MPEG_VIDEO;<br>
> + /* FALLTHROUGH */<br>
> case CX23885_BOARD_DVICO_FUSIONHDTV_5_EXP:<br>
> ts1->gen_ctrl_val = 0xc; /* Serial bus + punctured clock */<br>
> ts1->ts_clk_en_val = 0x1; /* Enable TS_CLK */<br>
> diff -Naur v4l-dvb/linux/drivers/media/video/cx23885/cx23885-dvb.c<br>
> v4l-dvb_dev/linux/drivers/media/video/cx23885/cx23885-dvb.c<br>
> --- v4l-dvb/linux/drivers/media/video/cx23885/cx23885-dvb.c<br>
> 2008-05-14 09:48:22.000000000 +1000<br>
> +++ v4l-dvb_dev/linux/drivers/media/video/cx23885/cx23885-dvb.c<br>
> 2008-05-14 13:39:30.000000000 +1000<br>
> @@ -42,6 +42,9 @@<br>
> #include "tuner-simple.h"<br>
> #include "dib7000p.h"<br>
> #include "dibx000_common.h"<br>
> +#include "zl10353.h"<br>
> +#include "tuner-xc2028.h"<br>
> +#include "tuner-xc2028-types.h"<br>
><br>
> static unsigned int debug;<br>
><br>
> @@ -155,6 +158,44 @@<br>
> .serial_mpeg = 0x40,<br>
> };<br>
><br>
> +static int cx23885_dvico_xc2028_callback(void *ptr, int command, int<br>
> arg)<br>
> +{<br>
> + struct cx23885_tsport *port = ptr;<br>
> + struct cx23885_dev *dev = port->dev;<br>
> + u32 reset_mask = 0;<br>
> +<br>
> + switch (command) {<br>
> + case XC2028_TUNER_RESET:<br>
> + dprintk(1, "%s: XC2028_TUNER_RESET %d, port %d\n", __func__,<br>
> + arg, port->nr);<br>
> +<br>
> + if (port->nr == 1)<br>
> + reset_mask = 0x0101;<br>
> + else if (port->nr == 2)<br>
> + reset_mask = 0x0404;<br>
> +<br>
> + cx_clear(GP0_IO, reset_mask);<br>
> + mdelay(5);<br>
> + cx_set(GP0_IO, reset_mask);<br>
> + break;<br>
> + case XC2028_RESET_CLK:<br>
> + dprintk(1, "%s: XC2028_RESET_CLK %d\n", __func__, arg);<br>
> + break;<br>
> + default:<br>
> + dprintk(1, "%s: unknown command %d, arg %d\n", __func__,<br>
> + command, arg);<br>
> + return -EINVAL;<br>
> + }<br>
> +<br>
> + return 0;<br>
> +}<br>
> +<br>
> +static struct zl10353_config dvico_fusionhdtv_xc3028 = {<br>
> + .demod_address = 0x0f,<br>
> + .if2 = 45600,<br>
> + .no_tuner = 1,<br>
> +};<br>
> +<br>
> static struct s5h1409_config hauppauge_hvr1500q_config = {<br>
> .demod_address = 0x32 >> 1,<br>
> .output_mode = S5H1409_SERIAL_OUTPUT,<br>
> @@ -454,6 +495,39 @@<br>
> fe->ops.tuner_ops.set_config(fe, &ctl);<br>
> }<br>
> break;<br>
> + case CX23885_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL_EXP: {<br>
> + i2c_bus = &dev->i2c_bus[port->nr - 1];<br>
> +<br>
> + /* Take demod and tuner out of reset */<br>
> + if (port->nr == 1)<br>
> + cx_set(GP0_IO, 0x0303);<br>
> + else if (port->nr == 2)<br>
> + cx_set(GP0_IO, 0x0c0c);<br>
> + mdelay(5);<br>
> + port->dvb.frontend = dvb_attach(zl10353_attach,<br>
> + &dvico_fusionhdtv_xc3028,<br>
> + &i2c_bus->i2c_adap);<br>
> + if (port->dvb.frontend != NULL) {<br>
> + struct dvb_frontend *fe;<br>
> + struct xc2028_config cfg = {<br>
> + .i2c_adap = &i2c_bus->i2c_adap,<br>
> + .i2c_addr = 0x61,<br>
> + .video_dev = port,<br>
> + .callback = cx23885_dvico_xc2028_callback,<br>
> + };<br>
> + static struct xc2028_ctrl ctl = {<br>
> + .fname = "xc3028-dvico-au-01.fw",<br>
> + .max_len = 64,<br>
> + .scode_table = ZARLINK456,<br>
> + };<br>
> +<br>
> + fe = dvb_attach(xc2028_attach, port->dvb.frontend,<br>
> + &cfg);<br>
> + if (fe != NULL && fe->ops.tuner_ops.set_config != NULL)<br>
> + fe->ops.tuner_ops.set_config(fe, &ctl);<br>
> + }<br>
> + break;<br>
> + }<br>
> default:<br>
> printk("%s: The frontend of your DVB/ATSC card isn't<br>
> supported yet\n",<br>
> dev->name);<br>
> diff -Naur v4l-dvb/linux/drivers/media/video/cx23885/cx23885.h<br>
> v4l-dvb_dev/linux/drivers/media/video/cx23885/cx23885.h<br>
> --- v4l-dvb/linux/drivers/media/video/cx23885/cx23885.h 2008-05-14<br>
> 09:48:22.000000000 +1000<br>
> +++ v4l-dvb_dev/linux/drivers/media/video/cx23885/cx23885.h<br>
> 2008-05-14 13:39:30.000000000 +1000<br>
> @@ -66,6 +66,7 @@<br>
> #define CX23885_BOARD_HAUPPAUGE_HVR1200 7<br>
> #define CX23885_BOARD_HAUPPAUGE_HVR1700 8<br>
> #define CX23885_BOARD_HAUPPAUGE_HVR1400 9<br>
> +#define CX23885_BOARD_DVICO_FUSIONHDTV_DVB_T_DUAL_EXP 10<br>
><br>
> /* Currently unsupported by the driver: PAL/H, NTSC/Kr, SECAM<br>
> B/G/H/LC */<br>
> #define CX23885_NORMS (\<br>
> diff -Naur v4l-dvb/linux/drivers/media/video/cx23885/Kconfig<br>
> v4l-dvb_dev/linux/drivers/media/video/cx23885/Kconfig<br>
> --- v4l-dvb/linux/drivers/media/video/cx23885/Kconfig 2008-05-14<br>
> 09:48:22.000000000 +1000<br>
> +++ v4l-dvb_dev/linux/drivers/media/video/cx23885/Kconfig<br>
> 2008-05-14 13:39:30.000000000 +1000<br>
> @@ -15,6 +15,7 @@<br>
> select MEDIA_TUNER_MT2131 if !DVB_FE_CUSTOMISE<br>
> select DVB_S5H1409 if !DVB_FE_CUSTOMISE<br>
> select DVB_LGDT330X if !DVB_FE_CUSTOMISE<br>
> + select DVB_ZL10353 if !DVB_FE_CUSTOMISE<br>
> select MEDIA_TUNER_XC2028 if !DVB_FE_CUSTOMIZE<br>
> select MEDIA_TUNER_TDA8290 if !DVB_FE_CUSTOMIZE<br>
> select MEDIA_TUNER_TDA18271 if !DVB_FE_CUSTOMIZE<br>
><br>
><br>
><br>
> -- See Exclusive Video: 10th Annual Young Hollywood Awards<br>
><br>
</sonofzev@iinet.net.au></blockquote>
</div>
<BR>
--
<div> See Exclusive Video: <a href= "http://www.hollywoodlife.net/younghollywoodawards2008/" target="_blank"> <b> 10th Annual Young Hollywood Awards</b></a><br></div>