From patchwork Fri Oct 4 18:56:23 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alfredo_Jes=C3=BAs_Delaiti?= X-Patchwork-Id: 20329 Received: from mail.tu-berlin.de ([130.149.7.33]) by www.linuxtv.org with esmtp (Exim 4.72) (envelope-from ) id 1VSAiq-0007Gi-Ob; Fri, 04 Oct 2013 21:07:32 +0200 X-tubIT-Incoming-IP: 209.132.180.67 Received: from vger.kernel.org ([209.132.180.67]) by mail.tu-berlin.de (exim-4.72/mailfrontend-8) with esmtp id 1VSAio-000830-kX; Fri, 04 Oct 2013 21:07:32 +0200 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751544Ab3JDTH2 (ORCPT + 1 other); Fri, 4 Oct 2013 15:07:28 -0400 Received: from omr-m07.mx.aol.com ([64.12.143.81]:43268 "EHLO omr-m07.mx.aol.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751174Ab3JDTH1 (ORCPT ); Fri, 4 Oct 2013 15:07:27 -0400 X-Greylist: delayed 470 seconds by postgrey-1.27 at vger.kernel.org; Fri, 04 Oct 2013 15:07:27 EDT Received: from mtaout-db03.r1000.mx.aol.com (mtaout-db03.r1000.mx.aol.com [172.29.51.195]) by omr-m07.mx.aol.com (Outbound Mail Relay) with ESMTP id A35E2700354BB; Fri, 4 Oct 2013 14:59:36 -0400 (EDT) Received: from [192.168.1.37] (unknown [201.255.118.207]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mtaout-db03.r1000.mx.aol.com (MUA/Third Party Client Interface) with ESMTPSA id 2891AE0000BD; Fri, 4 Oct 2013 14:59:34 -0400 (EDT) Message-ID: <524F0F57.5020605@netscape.net> Date: Fri, 04 Oct 2013 15:56:23 -0300 From: =?UTF-8?B?QWxmcmVkbyBKZXPDunMgRGVsYWl0aQ==?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.0 MIME-Version: 1.0 To: =?UTF-8?B?TWlyb3NsYXYgU2x1Z2XFiA==?= , linux-media@vger.kernel.org, =?UTF-8?B?TWlyb3NsYXYgU2x1Z2XFiA==?= Subject: Re: cx23885: Add basic analog radio support References: In-Reply-To: x-aol-global-disposition: G X-AOL-VSS-INFO: 5600.1067/94190 X-AOL-VSS-CODE: clean x-aol-sid: 3039ac1d33c3524f10166a89 X-AOL-IP: 201.255.118.207 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-PMX-Version: 6.0.0.2142326, Antispam-Engine: 2.7.2.2107409, Antispam-Data: 2013.10.4.190036 X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' HTML_00_01 0.05, HTML_00_10 0.05, MIME_TEXT_ONLY_MP_MIXED 0.05, MSGID_ADDED_BY_MTA 0.05, BODYTEXTP_SIZE_3000_LESS 0, BODY_SIZE_5000_5999 0, BODY_SIZE_7000_LESS 0, ECARD_WORD 0, FROM_NAME_PHRASE 0, URI_ENDS_IN_HTML 0, WEBMAIL_SOURCE 0, WEBMAIL_X_AOL_IP 0, WEBMAIL_X_IP_HDR 0, __ANY_URI 0, __BAT_BOUNDARY 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CP_MEDIA_BODY 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_MIXED 0, __HAS_FROM 0, __HAS_MSGID 0, __HAS_X_MAILING_LIST 0, __INT_PROD_TV 0, __IN_REP_TO 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __MOZILLA_MSGID 0, __MOZILLA_USER_AGENT 0, __SANE_MSGID 0, __SUBJ_ALPHA_END 0, __SUBJ_ALPHA_NEGATE 0, __TO_MALFORMED_2 0, __URI_NO_WWW 0, __URI_NS , __USER_AGENT 0' Hi all El 14/01/12 15:25, Miroslav Sluge? escribió: > New version of patch, fixed video modes for DVR3200 tuners and working > audio mux. I tested this patch (https://linuxtv.org/patch/9498/) with the latest versions of git (September 28, 2013) with my TV card (Mygica X8507) and it works. I found some issue, although it may be through a bad implementation of mine. Details of them: 1) Some warning when compiling ... CC [M] /home/alfredo/ISDB/Nuevo_Driver/git/media_build/v4l/cx23885-video.o /home/alfredo/ISDB/Nuevo_Driver/git/media_build/v4l/cx23885-video.c:1910:8: : initialization from incompatible pointer type [enabled by default] /home/alfredo/ISDB/Nuevo_Driver/git/media_build/v4l/cx23885-video.c:1910:8: warning: (near initialization for 'radio_ioctl_ops.vidioc_s_tuner') [enabled by default] /home/alfredo/ISDB/Nuevo_Driver/git/media_build/v4l/cx23885-video.c:1911:8: warning: initialization from incompatible pointer type [enabled by default] /home/alfredo/ISDB/Nuevo_Driver/git/media_build/v4l/cx23885-video.c:1911:8: warning: (near initialization for 'radio_ioctl_ops.vidioc_s_audio') [enabled by default] CC [M] /home/alfredo/ISDB/Nuevo_Driver/git/media_build/v4l/cx23885-vbi.o ... -------------------------------------------------------- static const struct v4l2_ioctl_ops radio_ioctl_ops = { .vidioc_s_tuner = radio_s_tuner, /* line 1910 */ .vidioc_s_audio = radio_s_audio, /* line 1911 */ -------------------------------------------------------- 2) No reports signal strength or stereo signal with KRadio. XC5000 neither reported (modprobe xc5000 debug=1). Maybe a feature XC5000. To listen in stereo, sometimes, you have to turn on the Digital TV then Analog TV and then radio. 3) To listen Analog TV I need changed to NTSC standard and then PAL-Nc (the norm in my country is PAL-Nc). If I leave the tune in NTSC no problem with sound. The patch (https://linuxtv.org/patch/9505/) corrects the latter, if used tvtime with xawtv not always. If I see-Digital TV (ISDB-T), then so as to listen the radio I have first put the TV-Analog, because I hear very low and a strong white noise. The latter is likely to be corrected by resetting the tuner, I have to study it more. I put below attached the patch applied to the plate: X8507. Have you done any update of this patch? Thanks .../media/pci/cx23885/{ => }/media/pci/cx23885/cx23885-cards.c | 6 ++++++ drivers/media/pci/cx23885/{ => }/media/pci/cx23885/cx23885-dvb.c | 1 + 2 files changed, 7 insertions(+) diff --git a/drivers/media/pci/cx23885/cx23885-cards.c b/drivers/media/pci/cx23885/cx23885-cards.c index 6a71a96..324809a 100644 --- a/drivers/media/pci/cx23885/cx23885-cards.c +++ b/drivers/media/pci/cx23885/cx23885-cards.c @@ -526,16 +526,18 @@ struct cx23885_board cx23885_boards[] = { .amux = CX25840_AUDIO7, .gpio0 = 0, } }, }, [CX23885_BOARD_MYGICA_X8507] = { .name = "Mygica X8502/X8507 ISDB-T", .tuner_type = TUNER_XC5000, .tuner_addr = 0x61, + .radio_type = TUNER_XC5000, + .radio_addr = 0x61, .tuner_bus = 1, .porta = CX23885_ANALOG_VIDEO, .portb = CX23885_MPEG_DVB, .input = { { .type = CX23885_VMUX_TELEVISION, .vmux = CX25840_COMPOSITE2, .amux = CX25840_AUDIO8, @@ -555,16 +557,20 @@ struct cx23885_board cx23885_boards[] = { .type = CX23885_VMUX_COMPONENT, .vmux = CX25840_COMPONENT_ON | CX25840_VIN1_CH1 | CX25840_VIN6_CH2 | CX25840_VIN7_CH3, .amux = CX25840_AUDIO7, }, }, + .radio = { + .type= CX23885_RADIO, + .amux= CX25840_AUDIO8, + }, }, [CX23885_BOARD_TERRATEC_CINERGY_T_PCIE_DUAL] = { .name = "TerraTec Cinergy T PCIe Dual", .portb = CX23885_MPEG_DVB, .portc = CX23885_MPEG_DVB, }, [CX23885_BOARD_TEVII_S471] = { .name = "TeVii S471", diff --git a/drivers/media/pci/cx23885/cx23885-dvb.c b/drivers/media/pci/cx23885/cx23885-dvb.c index 971e4ff..4e946b2 100644 --- a/drivers/media/pci/cx23885/cx23885-dvb.c +++ b/drivers/media/pci/cx23885/cx23885-dvb.c @@ -495,16 +495,17 @@ static struct xc5000_config mygica_x8506_xc5000_config = { static struct mb86a20s_config mygica_x8507_mb86a20s_config = { .demod_address = 0x10, }; static struct xc5000_config mygica_x8507_xc5000_config = { .i2c_address = 0x61, .if_khz = 4000, + .radio_input = XC5000_RADIO_FM1, }; static struct stv090x_config prof_8000_stv090x_config = { .device = STV0903, .demod_mode = STV090x_SINGLE, .clk_mode = STV090x_CLK_EXT, .xtal = 27000000, .address = 0x6A,