From patchwork Fri Dec 9 00:16:24 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: CrazyCat X-Patchwork-Id: 9467305 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8B35A607D4 for ; Fri, 9 Dec 2016 00:26:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7E02228628 for ; Fri, 9 Dec 2016 00:26:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7308728634; Fri, 9 Dec 2016 00:26:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 107AF28633 for ; Fri, 9 Dec 2016 00:26:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753929AbcLIAZy (ORCPT ); Thu, 8 Dec 2016 19:25:54 -0500 Received: from forward13p.cmail.yandex.net ([87.250.241.140]:35841 "EHLO forward13p.cmail.yandex.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753836AbcLIAZu (ORCPT ); Thu, 8 Dec 2016 19:25:50 -0500 X-Greylist: delayed 557 seconds by postgrey-1.27 at vger.kernel.org; Thu, 08 Dec 2016 19:25:49 EST Received: from smtp1p.mail.yandex.net (smtp1p.mail.yandex.net [IPv6:2a02:6b8:0:1472:2741:0:8b6:6]) by forward13p.cmail.yandex.net (Yandex) with ESMTP id 234FA218D3 for ; Fri, 9 Dec 2016 03:16:30 +0300 (MSK) Received: from smtp1p.mail.yandex.net (localhost.localdomain [127.0.0.1]) by smtp1p.mail.yandex.net (Yandex) with ESMTP id 0198D1780964 for ; Fri, 9 Dec 2016 03:16:29 +0300 (MSK) Received: by smtp1p.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id uzq8lmBdqK-GROeKpYl; Fri, 09 Dec 2016 03:16:27 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=narod.ru; s=mail; t=1481242588; bh=luIMfLasvoI3+FJ5K9K6NkIxn4BQjH2FItcAmFoaq04=; h=From:To:Subject:Date:Message-ID; b=ZxIEuepdF1EP7CTKT0rViHTvDLoZwaYb40Xip/qSsDZ4GeyCBaJo1I60AfFr1ys46 wKH5LmjRMfmPpFvZTSqy/5orRtM+ENBeDkTNj8m1cvVakJBDq6by+C24X/4IzdjdeW zhBw9A0w3Naua6z+x3+fsJM+pb/nMCCgXp2ag7bU= Authentication-Results: smtp1p.mail.yandex.net; dkim=pass header.i=@narod.ru X-Yandex-Suid-Status: 1 0 From: CrazyCat To: linux-media@vger.kernel.org Subject: [PATCH 1/4] dvb-usb-cxusb: New RC map for Geniatech Mygica T230. Date: Fri, 09 Dec 2016 02:16:24 +0200 Message-ID: <3439935.7iTQ9ktDGz@computer> User-Agent: KMail/4.13.3 (Linux/4.4.0-42-generic; KDE/4.13.3; x86_64; ; ) MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Updated RC map for Geniatech DVB-T/T2 sticks. Signed-off-by: CrazyCat --- drivers/media/usb/dvb-usb/cxusb.c | 42 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 40 insertions(+), 2 deletions(-) diff --git a/drivers/media/usb/dvb-usb/cxusb.c b/drivers/media/usb/dvb-usb/cxusb.c index 9b8771e..3edc30d 100644 --- a/drivers/media/usb/dvb-usb/cxusb.c +++ b/drivers/media/usb/dvb-usb/cxusb.c @@ -653,6 +653,44 @@ static int cxusb_d680_dmb_rc_query(struct dvb_usb_device *d, u32 *event, { 0x0025, KEY_POWER }, }; +static struct rc_map_table rc_map_t230_table[] = { + { 0x0000, KEY_0 }, + { 0x0001, KEY_1 }, + { 0x0002, KEY_2 }, + { 0x0003, KEY_3 }, + { 0x0004, KEY_4 }, + { 0x0005, KEY_5 }, + { 0x0006, KEY_6 }, + { 0x0007, KEY_7 }, + { 0x0008, KEY_8 }, + { 0x0009, KEY_9 }, + { 0x000a, KEY_MUTE }, + { 0x000b, KEY_STOP }, /* Stop */ + { 0x000c, KEY_POWER2 }, /* Turn on/off application */ + { 0x000d, KEY_OK }, /* OK */ + { 0x000e, KEY_CAMERA }, /* Snapshot */ + { 0x000f, KEY_ZOOM }, /* Full Screen/Restore */ + { 0x0010, KEY_RIGHT }, /* Right arrow */ + { 0x0011, KEY_LEFT }, /* Left arrow */ + { 0x0012, KEY_CHANNELUP }, + { 0x0013, KEY_CHANNELDOWN }, + { 0x0014, KEY_SHUFFLE }, + { 0x0016, KEY_PAUSE }, + { 0x0017, KEY_PLAY }, /* Play */ + { 0x001e, KEY_TIME }, /* Time Shift */ + { 0x001f, KEY_RECORD }, + { 0x0020, KEY_UP }, + { 0x0021, KEY_DOWN }, + { 0x0025, KEY_POWER }, /* Turn off computer */ + { 0x0026, KEY_REWIND }, /* FR << */ + { 0x0027, KEY_FASTFORWARD }, /* FF >> */ + { 0x0029, KEY_ESC }, + { 0x002b, KEY_VOLUMEUP }, + { 0x002c, KEY_VOLUMEDOWN }, + { 0x002d, KEY_CHANNEL }, /* CH Surfing */ + { 0x0038, KEY_VIDEO }, /* TV/AV/S-Video/YPbPr */ +}; + static int cxusb_dee1601_demod_init(struct dvb_frontend* fe) { static u8 clock_config [] = { CLOCK_CTL, 0x38, 0x28 }; @@ -2317,8 +2355,8 @@ struct dvb_usb_device_properties cxusb_bluebird_dualdig4_rev2_properties = { .rc.legacy = { .rc_interval = 100, - .rc_map_table = rc_map_d680_dmb_table, - .rc_map_size = ARRAY_SIZE(rc_map_d680_dmb_table), + .rc_map_table = rc_map_t230_table, + .rc_map_size = ARRAY_SIZE(rc_map_t230_table), .rc_query = cxusb_d680_dmb_rc_query, },