132cf86f6SMauro Carvalho Chehab /* rc-dvb0700-big.c - Keytable for devices in dvb0700 232cf86f6SMauro Carvalho Chehab * 3*37e59f87SMauro Carvalho Chehab * Copyright (c) 2010 by Mauro Carvalho Chehab 432cf86f6SMauro Carvalho Chehab * 532cf86f6SMauro Carvalho Chehab * TODO: This table is a real mess, as it merges RC codes from several 632cf86f6SMauro Carvalho Chehab * devices into a big table. It also has both RC-5 and NEC codes inside. 732cf86f6SMauro Carvalho Chehab * It should be broken into small tables, and the protocols should properly 83f79410cSMaxime Jayat * be identificated. 932cf86f6SMauro Carvalho Chehab * 1032cf86f6SMauro Carvalho Chehab * The table were imported from dib0700_devices.c. 1132cf86f6SMauro Carvalho Chehab * 1232cf86f6SMauro Carvalho Chehab * This program is free software; you can redistribute it and/or modify 1332cf86f6SMauro Carvalho Chehab * it under the terms of the GNU General Public License as published by 1432cf86f6SMauro Carvalho Chehab * the Free Software Foundation; either version 2 of the License, or 1532cf86f6SMauro Carvalho Chehab * (at your option) any later version. 1632cf86f6SMauro Carvalho Chehab */ 1732cf86f6SMauro Carvalho Chehab 1832cf86f6SMauro Carvalho Chehab #include <media/rc-map.h> 197a707b89SPaul Gortmaker #include <linux/module.h> 2032cf86f6SMauro Carvalho Chehab 212f4f58d6SMauro Carvalho Chehab static struct rc_map_table dib0700_rc5_table[] = { 2232cf86f6SMauro Carvalho Chehab /* Key codes for the tiny Pinnacle remote*/ 2332cf86f6SMauro Carvalho Chehab { 0x0700, KEY_MUTE }, 2432cf86f6SMauro Carvalho Chehab { 0x0701, KEY_MENU }, /* Pinnacle logo */ 2532cf86f6SMauro Carvalho Chehab { 0x0739, KEY_POWER }, 2632cf86f6SMauro Carvalho Chehab { 0x0703, KEY_VOLUMEUP }, 2732cf86f6SMauro Carvalho Chehab { 0x0709, KEY_VOLUMEDOWN }, 2832cf86f6SMauro Carvalho Chehab { 0x0706, KEY_CHANNELUP }, 2932cf86f6SMauro Carvalho Chehab { 0x070c, KEY_CHANNELDOWN }, 3032cf86f6SMauro Carvalho Chehab { 0x070f, KEY_1 }, 3132cf86f6SMauro Carvalho Chehab { 0x0715, KEY_2 }, 3232cf86f6SMauro Carvalho Chehab { 0x0710, KEY_3 }, 3332cf86f6SMauro Carvalho Chehab { 0x0718, KEY_4 }, 3432cf86f6SMauro Carvalho Chehab { 0x071b, KEY_5 }, 3532cf86f6SMauro Carvalho Chehab { 0x071e, KEY_6 }, 3632cf86f6SMauro Carvalho Chehab { 0x0711, KEY_7 }, 3732cf86f6SMauro Carvalho Chehab { 0x0721, KEY_8 }, 3832cf86f6SMauro Carvalho Chehab { 0x0712, KEY_9 }, 3932cf86f6SMauro Carvalho Chehab { 0x0727, KEY_0 }, 4032cf86f6SMauro Carvalho Chehab { 0x0724, KEY_SCREEN }, /* 'Square' key */ 4132cf86f6SMauro Carvalho Chehab { 0x072a, KEY_TEXT }, /* 'T' key */ 4232cf86f6SMauro Carvalho Chehab { 0x072d, KEY_REWIND }, 4332cf86f6SMauro Carvalho Chehab { 0x0730, KEY_PLAY }, 4432cf86f6SMauro Carvalho Chehab { 0x0733, KEY_FASTFORWARD }, 4532cf86f6SMauro Carvalho Chehab { 0x0736, KEY_RECORD }, 4632cf86f6SMauro Carvalho Chehab { 0x073c, KEY_STOP }, 4732cf86f6SMauro Carvalho Chehab { 0x073f, KEY_CANCEL }, /* '?' key */ 4832cf86f6SMauro Carvalho Chehab 4932cf86f6SMauro Carvalho Chehab /* Key codes for the Terratec Cinergy DT XS Diversity, similar to cinergyT2.c */ 5032cf86f6SMauro Carvalho Chehab { 0xeb01, KEY_POWER }, 5132cf86f6SMauro Carvalho Chehab { 0xeb02, KEY_1 }, 5232cf86f6SMauro Carvalho Chehab { 0xeb03, KEY_2 }, 5332cf86f6SMauro Carvalho Chehab { 0xeb04, KEY_3 }, 5432cf86f6SMauro Carvalho Chehab { 0xeb05, KEY_4 }, 5532cf86f6SMauro Carvalho Chehab { 0xeb06, KEY_5 }, 5632cf86f6SMauro Carvalho Chehab { 0xeb07, KEY_6 }, 5732cf86f6SMauro Carvalho Chehab { 0xeb08, KEY_7 }, 5832cf86f6SMauro Carvalho Chehab { 0xeb09, KEY_8 }, 5932cf86f6SMauro Carvalho Chehab { 0xeb0a, KEY_9 }, 6032cf86f6SMauro Carvalho Chehab { 0xeb0b, KEY_VIDEO }, 6132cf86f6SMauro Carvalho Chehab { 0xeb0c, KEY_0 }, 6232cf86f6SMauro Carvalho Chehab { 0xeb0d, KEY_REFRESH }, 6332cf86f6SMauro Carvalho Chehab { 0xeb0f, KEY_EPG }, 6432cf86f6SMauro Carvalho Chehab { 0xeb10, KEY_UP }, 6532cf86f6SMauro Carvalho Chehab { 0xeb11, KEY_LEFT }, 6632cf86f6SMauro Carvalho Chehab { 0xeb12, KEY_OK }, 6732cf86f6SMauro Carvalho Chehab { 0xeb13, KEY_RIGHT }, 6832cf86f6SMauro Carvalho Chehab { 0xeb14, KEY_DOWN }, 6932cf86f6SMauro Carvalho Chehab { 0xeb16, KEY_INFO }, 7032cf86f6SMauro Carvalho Chehab { 0xeb17, KEY_RED }, 7132cf86f6SMauro Carvalho Chehab { 0xeb18, KEY_GREEN }, 7232cf86f6SMauro Carvalho Chehab { 0xeb19, KEY_YELLOW }, 7332cf86f6SMauro Carvalho Chehab { 0xeb1a, KEY_BLUE }, 7432cf86f6SMauro Carvalho Chehab { 0xeb1b, KEY_CHANNELUP }, 7532cf86f6SMauro Carvalho Chehab { 0xeb1c, KEY_VOLUMEUP }, 7632cf86f6SMauro Carvalho Chehab { 0xeb1d, KEY_MUTE }, 7732cf86f6SMauro Carvalho Chehab { 0xeb1e, KEY_VOLUMEDOWN }, 7832cf86f6SMauro Carvalho Chehab { 0xeb1f, KEY_CHANNELDOWN }, 7932cf86f6SMauro Carvalho Chehab { 0xeb40, KEY_PAUSE }, 8032cf86f6SMauro Carvalho Chehab { 0xeb41, KEY_HOME }, 8132cf86f6SMauro Carvalho Chehab { 0xeb42, KEY_MENU }, /* DVD Menu */ 8232cf86f6SMauro Carvalho Chehab { 0xeb43, KEY_SUBTITLE }, 8332cf86f6SMauro Carvalho Chehab { 0xeb44, KEY_TEXT }, /* Teletext */ 8432cf86f6SMauro Carvalho Chehab { 0xeb45, KEY_DELETE }, 8532cf86f6SMauro Carvalho Chehab { 0xeb46, KEY_TV }, 8632cf86f6SMauro Carvalho Chehab { 0xeb47, KEY_DVD }, 8732cf86f6SMauro Carvalho Chehab { 0xeb48, KEY_STOP }, 8832cf86f6SMauro Carvalho Chehab { 0xeb49, KEY_VIDEO }, 8932cf86f6SMauro Carvalho Chehab { 0xeb4a, KEY_AUDIO }, /* Music */ 9032cf86f6SMauro Carvalho Chehab { 0xeb4b, KEY_SCREEN }, /* Pic */ 9132cf86f6SMauro Carvalho Chehab { 0xeb4c, KEY_PLAY }, 9232cf86f6SMauro Carvalho Chehab { 0xeb4d, KEY_BACK }, 9332cf86f6SMauro Carvalho Chehab { 0xeb4e, KEY_REWIND }, 9432cf86f6SMauro Carvalho Chehab { 0xeb4f, KEY_FASTFORWARD }, 9532cf86f6SMauro Carvalho Chehab { 0xeb54, KEY_PREVIOUS }, 9632cf86f6SMauro Carvalho Chehab { 0xeb58, KEY_RECORD }, 9732cf86f6SMauro Carvalho Chehab { 0xeb5c, KEY_NEXT }, 9832cf86f6SMauro Carvalho Chehab 9932cf86f6SMauro Carvalho Chehab /* Key codes for the Haupauge WinTV Nova-TD, copied from nova-t-usb2.c (Nova-T USB2) */ 10032cf86f6SMauro Carvalho Chehab { 0x1e00, KEY_0 }, 10132cf86f6SMauro Carvalho Chehab { 0x1e01, KEY_1 }, 10232cf86f6SMauro Carvalho Chehab { 0x1e02, KEY_2 }, 10332cf86f6SMauro Carvalho Chehab { 0x1e03, KEY_3 }, 10432cf86f6SMauro Carvalho Chehab { 0x1e04, KEY_4 }, 10532cf86f6SMauro Carvalho Chehab { 0x1e05, KEY_5 }, 10632cf86f6SMauro Carvalho Chehab { 0x1e06, KEY_6 }, 10732cf86f6SMauro Carvalho Chehab { 0x1e07, KEY_7 }, 10832cf86f6SMauro Carvalho Chehab { 0x1e08, KEY_8 }, 10932cf86f6SMauro Carvalho Chehab { 0x1e09, KEY_9 }, 11032cf86f6SMauro Carvalho Chehab { 0x1e0a, KEY_KPASTERISK }, 11132cf86f6SMauro Carvalho Chehab { 0x1e0b, KEY_RED }, 11232cf86f6SMauro Carvalho Chehab { 0x1e0c, KEY_RADIO }, 11332cf86f6SMauro Carvalho Chehab { 0x1e0d, KEY_MENU }, 11432cf86f6SMauro Carvalho Chehab { 0x1e0e, KEY_GRAVE }, /* # */ 11532cf86f6SMauro Carvalho Chehab { 0x1e0f, KEY_MUTE }, 11632cf86f6SMauro Carvalho Chehab { 0x1e10, KEY_VOLUMEUP }, 11732cf86f6SMauro Carvalho Chehab { 0x1e11, KEY_VOLUMEDOWN }, 11832cf86f6SMauro Carvalho Chehab { 0x1e12, KEY_CHANNEL }, 11932cf86f6SMauro Carvalho Chehab { 0x1e14, KEY_UP }, 12032cf86f6SMauro Carvalho Chehab { 0x1e15, KEY_DOWN }, 12132cf86f6SMauro Carvalho Chehab { 0x1e16, KEY_LEFT }, 12232cf86f6SMauro Carvalho Chehab { 0x1e17, KEY_RIGHT }, 12332cf86f6SMauro Carvalho Chehab { 0x1e18, KEY_VIDEO }, 12432cf86f6SMauro Carvalho Chehab { 0x1e19, KEY_AUDIO }, 12532cf86f6SMauro Carvalho Chehab { 0x1e1a, KEY_MEDIA }, 12632cf86f6SMauro Carvalho Chehab { 0x1e1b, KEY_EPG }, 12732cf86f6SMauro Carvalho Chehab { 0x1e1c, KEY_TV }, 12832cf86f6SMauro Carvalho Chehab { 0x1e1e, KEY_NEXT }, 12932cf86f6SMauro Carvalho Chehab { 0x1e1f, KEY_BACK }, 13032cf86f6SMauro Carvalho Chehab { 0x1e20, KEY_CHANNELUP }, 13132cf86f6SMauro Carvalho Chehab { 0x1e21, KEY_CHANNELDOWN }, 13232cf86f6SMauro Carvalho Chehab { 0x1e24, KEY_LAST }, /* Skip backwards */ 13332cf86f6SMauro Carvalho Chehab { 0x1e25, KEY_OK }, 13432cf86f6SMauro Carvalho Chehab { 0x1e29, KEY_BLUE}, 13532cf86f6SMauro Carvalho Chehab { 0x1e2e, KEY_GREEN }, 13632cf86f6SMauro Carvalho Chehab { 0x1e30, KEY_PAUSE }, 13732cf86f6SMauro Carvalho Chehab { 0x1e32, KEY_REWIND }, 13832cf86f6SMauro Carvalho Chehab { 0x1e34, KEY_FASTFORWARD }, 13932cf86f6SMauro Carvalho Chehab { 0x1e35, KEY_PLAY }, 14032cf86f6SMauro Carvalho Chehab { 0x1e36, KEY_STOP }, 14132cf86f6SMauro Carvalho Chehab { 0x1e37, KEY_RECORD }, 14232cf86f6SMauro Carvalho Chehab { 0x1e38, KEY_YELLOW }, 14332cf86f6SMauro Carvalho Chehab { 0x1e3b, KEY_GOTO }, 14432cf86f6SMauro Carvalho Chehab { 0x1e3d, KEY_POWER }, 14532cf86f6SMauro Carvalho Chehab 14632cf86f6SMauro Carvalho Chehab /* Key codes for the Leadtek Winfast DTV Dongle */ 14732cf86f6SMauro Carvalho Chehab { 0x0042, KEY_POWER }, 14832cf86f6SMauro Carvalho Chehab { 0x077c, KEY_TUNER }, 14932cf86f6SMauro Carvalho Chehab { 0x0f4e, KEY_PRINT }, /* PREVIEW */ 15032cf86f6SMauro Carvalho Chehab { 0x0840, KEY_SCREEN }, /* full screen toggle*/ 15132cf86f6SMauro Carvalho Chehab { 0x0f71, KEY_DOT }, /* frequency */ 15232cf86f6SMauro Carvalho Chehab { 0x0743, KEY_0 }, 15332cf86f6SMauro Carvalho Chehab { 0x0c41, KEY_1 }, 15432cf86f6SMauro Carvalho Chehab { 0x0443, KEY_2 }, 15532cf86f6SMauro Carvalho Chehab { 0x0b7f, KEY_3 }, 15632cf86f6SMauro Carvalho Chehab { 0x0e41, KEY_4 }, 15732cf86f6SMauro Carvalho Chehab { 0x0643, KEY_5 }, 15832cf86f6SMauro Carvalho Chehab { 0x097f, KEY_6 }, 15932cf86f6SMauro Carvalho Chehab { 0x0d7e, KEY_7 }, 16032cf86f6SMauro Carvalho Chehab { 0x057c, KEY_8 }, 16132cf86f6SMauro Carvalho Chehab { 0x0a40, KEY_9 }, 16232cf86f6SMauro Carvalho Chehab { 0x0e4e, KEY_CLEAR }, 16332cf86f6SMauro Carvalho Chehab { 0x047c, KEY_CHANNEL }, /* show channel number */ 16432cf86f6SMauro Carvalho Chehab { 0x0f41, KEY_LAST }, /* recall */ 16532cf86f6SMauro Carvalho Chehab { 0x0342, KEY_MUTE }, 16632cf86f6SMauro Carvalho Chehab { 0x064c, KEY_RESERVED }, /* PIP button*/ 16732cf86f6SMauro Carvalho Chehab { 0x0172, KEY_SHUFFLE }, /* SNAPSHOT */ 16832cf86f6SMauro Carvalho Chehab { 0x0c4e, KEY_PLAYPAUSE }, /* TIMESHIFT */ 16932cf86f6SMauro Carvalho Chehab { 0x0b70, KEY_RECORD }, 17032cf86f6SMauro Carvalho Chehab { 0x037d, KEY_VOLUMEUP }, 17132cf86f6SMauro Carvalho Chehab { 0x017d, KEY_VOLUMEDOWN }, 17232cf86f6SMauro Carvalho Chehab { 0x0242, KEY_CHANNELUP }, 17332cf86f6SMauro Carvalho Chehab { 0x007d, KEY_CHANNELDOWN }, 17432cf86f6SMauro Carvalho Chehab 17532cf86f6SMauro Carvalho Chehab /* Key codes for Nova-TD "credit card" remote control. */ 17632cf86f6SMauro Carvalho Chehab { 0x1d00, KEY_0 }, 17732cf86f6SMauro Carvalho Chehab { 0x1d01, KEY_1 }, 17832cf86f6SMauro Carvalho Chehab { 0x1d02, KEY_2 }, 17932cf86f6SMauro Carvalho Chehab { 0x1d03, KEY_3 }, 18032cf86f6SMauro Carvalho Chehab { 0x1d04, KEY_4 }, 18132cf86f6SMauro Carvalho Chehab { 0x1d05, KEY_5 }, 18232cf86f6SMauro Carvalho Chehab { 0x1d06, KEY_6 }, 18332cf86f6SMauro Carvalho Chehab { 0x1d07, KEY_7 }, 18432cf86f6SMauro Carvalho Chehab { 0x1d08, KEY_8 }, 18532cf86f6SMauro Carvalho Chehab { 0x1d09, KEY_9 }, 18632cf86f6SMauro Carvalho Chehab { 0x1d0a, KEY_TEXT }, 18732cf86f6SMauro Carvalho Chehab { 0x1d0d, KEY_MENU }, 18832cf86f6SMauro Carvalho Chehab { 0x1d0f, KEY_MUTE }, 18932cf86f6SMauro Carvalho Chehab { 0x1d10, KEY_VOLUMEUP }, 19032cf86f6SMauro Carvalho Chehab { 0x1d11, KEY_VOLUMEDOWN }, 19132cf86f6SMauro Carvalho Chehab { 0x1d12, KEY_CHANNEL }, 19232cf86f6SMauro Carvalho Chehab { 0x1d14, KEY_UP }, 19332cf86f6SMauro Carvalho Chehab { 0x1d15, KEY_DOWN }, 19432cf86f6SMauro Carvalho Chehab { 0x1d16, KEY_LEFT }, 19532cf86f6SMauro Carvalho Chehab { 0x1d17, KEY_RIGHT }, 19632cf86f6SMauro Carvalho Chehab { 0x1d1c, KEY_TV }, 19732cf86f6SMauro Carvalho Chehab { 0x1d1e, KEY_NEXT }, 19832cf86f6SMauro Carvalho Chehab { 0x1d1f, KEY_BACK }, 19932cf86f6SMauro Carvalho Chehab { 0x1d20, KEY_CHANNELUP }, 20032cf86f6SMauro Carvalho Chehab { 0x1d21, KEY_CHANNELDOWN }, 20132cf86f6SMauro Carvalho Chehab { 0x1d24, KEY_LAST }, 20232cf86f6SMauro Carvalho Chehab { 0x1d25, KEY_OK }, 20332cf86f6SMauro Carvalho Chehab { 0x1d30, KEY_PAUSE }, 20432cf86f6SMauro Carvalho Chehab { 0x1d32, KEY_REWIND }, 20532cf86f6SMauro Carvalho Chehab { 0x1d34, KEY_FASTFORWARD }, 20632cf86f6SMauro Carvalho Chehab { 0x1d35, KEY_PLAY }, 20732cf86f6SMauro Carvalho Chehab { 0x1d36, KEY_STOP }, 20832cf86f6SMauro Carvalho Chehab { 0x1d37, KEY_RECORD }, 20932cf86f6SMauro Carvalho Chehab { 0x1d3b, KEY_GOTO }, 21032cf86f6SMauro Carvalho Chehab { 0x1d3d, KEY_POWER }, 21132cf86f6SMauro Carvalho Chehab }; 21232cf86f6SMauro Carvalho Chehab 213d100e659SMauro Carvalho Chehab static struct rc_map_list dib0700_rc5_map = { 21432cf86f6SMauro Carvalho Chehab .map = { 21532cf86f6SMauro Carvalho Chehab .scan = dib0700_rc5_table, 21632cf86f6SMauro Carvalho Chehab .size = ARRAY_SIZE(dib0700_rc5_table), 21752b66144SMauro Carvalho Chehab .rc_type = RC_TYPE_RC5, 21832cf86f6SMauro Carvalho Chehab .name = RC_MAP_DIB0700_RC5_TABLE, 21932cf86f6SMauro Carvalho Chehab } 22032cf86f6SMauro Carvalho Chehab }; 22132cf86f6SMauro Carvalho Chehab 22232cf86f6SMauro Carvalho Chehab static int __init init_rc_map(void) 22332cf86f6SMauro Carvalho Chehab { 224d100e659SMauro Carvalho Chehab return rc_map_register(&dib0700_rc5_map); 22532cf86f6SMauro Carvalho Chehab } 22632cf86f6SMauro Carvalho Chehab 22732cf86f6SMauro Carvalho Chehab static void __exit exit_rc_map(void) 22832cf86f6SMauro Carvalho Chehab { 229d100e659SMauro Carvalho Chehab rc_map_unregister(&dib0700_rc5_map); 23032cf86f6SMauro Carvalho Chehab } 23132cf86f6SMauro Carvalho Chehab 23232cf86f6SMauro Carvalho Chehab module_init(init_rc_map) 23332cf86f6SMauro Carvalho Chehab module_exit(exit_rc_map) 23432cf86f6SMauro Carvalho Chehab 23532cf86f6SMauro Carvalho Chehab MODULE_LICENSE("GPL"); 236*37e59f87SMauro Carvalho Chehab MODULE_AUTHOR("Mauro Carvalho Chehab"); 237