xref: /linux/drivers/media/rc/keymaps/rc-eztv.c (revision 7a707b89202f905bd9f9fbde326933c59a81214c)
132cf86f6SMauro Carvalho Chehab /* eztv.h - Keytable for eztv Remote Controller
232cf86f6SMauro Carvalho Chehab  *
332cf86f6SMauro Carvalho Chehab  * keymap imported from ir-keymaps.c
432cf86f6SMauro Carvalho Chehab  *
532cf86f6SMauro Carvalho Chehab  * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
632cf86f6SMauro Carvalho Chehab  *
732cf86f6SMauro Carvalho Chehab  * This program is free software; you can redistribute it and/or modify
832cf86f6SMauro Carvalho Chehab  * it under the terms of the GNU General Public License as published by
932cf86f6SMauro Carvalho Chehab  * the Free Software Foundation; either version 2 of the License, or
1032cf86f6SMauro Carvalho Chehab  * (at your option) any later version.
1132cf86f6SMauro Carvalho Chehab  */
1232cf86f6SMauro Carvalho Chehab 
1332cf86f6SMauro Carvalho Chehab #include <media/rc-map.h>
14*7a707b89SPaul Gortmaker #include <linux/module.h>
1532cf86f6SMauro Carvalho Chehab 
1632cf86f6SMauro Carvalho Chehab /* Alfons Geser <a.geser@cox.net>
1732cf86f6SMauro Carvalho Chehab  * updates from Job D. R. Borges <jobdrb@ig.com.br> */
1832cf86f6SMauro Carvalho Chehab 
192f4f58d6SMauro Carvalho Chehab static struct rc_map_table eztv[] = {
2032cf86f6SMauro Carvalho Chehab 	{ 0x12, KEY_POWER },
2132cf86f6SMauro Carvalho Chehab 	{ 0x01, KEY_TV },	/* DVR */
2232cf86f6SMauro Carvalho Chehab 	{ 0x15, KEY_DVD },	/* DVD */
2332cf86f6SMauro Carvalho Chehab 	{ 0x17, KEY_AUDIO },	/* music */
2432cf86f6SMauro Carvalho Chehab 				/* DVR mode / DVD mode / music mode */
2532cf86f6SMauro Carvalho Chehab 
2632cf86f6SMauro Carvalho Chehab 	{ 0x1b, KEY_MUTE },	/* mute */
2732cf86f6SMauro Carvalho Chehab 	{ 0x02, KEY_LANGUAGE },	/* MTS/SAP / audio / autoseek */
2832cf86f6SMauro Carvalho Chehab 	{ 0x1e, KEY_SUBTITLE },	/* closed captioning / subtitle / seek */
2932cf86f6SMauro Carvalho Chehab 	{ 0x16, KEY_ZOOM },	/* full screen */
3032cf86f6SMauro Carvalho Chehab 	{ 0x1c, KEY_VIDEO },	/* video source / eject / delall */
3132cf86f6SMauro Carvalho Chehab 	{ 0x1d, KEY_RESTART },	/* playback / angle / del */
3232cf86f6SMauro Carvalho Chehab 	{ 0x2f, KEY_SEARCH },	/* scan / menu / playlist */
3332cf86f6SMauro Carvalho Chehab 	{ 0x30, KEY_CHANNEL },	/* CH surfing / bookmark / memo */
3432cf86f6SMauro Carvalho Chehab 
3532cf86f6SMauro Carvalho Chehab 	{ 0x31, KEY_HELP },	/* help */
3632cf86f6SMauro Carvalho Chehab 	{ 0x32, KEY_MODE },	/* num/memo */
3732cf86f6SMauro Carvalho Chehab 	{ 0x33, KEY_ESC },	/* cancel */
3832cf86f6SMauro Carvalho Chehab 
3932cf86f6SMauro Carvalho Chehab 	{ 0x0c, KEY_UP },	/* up */
4032cf86f6SMauro Carvalho Chehab 	{ 0x10, KEY_DOWN },	/* down */
4132cf86f6SMauro Carvalho Chehab 	{ 0x08, KEY_LEFT },	/* left */
4232cf86f6SMauro Carvalho Chehab 	{ 0x04, KEY_RIGHT },	/* right */
4332cf86f6SMauro Carvalho Chehab 	{ 0x03, KEY_SELECT },	/* select */
4432cf86f6SMauro Carvalho Chehab 
4532cf86f6SMauro Carvalho Chehab 	{ 0x1f, KEY_REWIND },	/* rewind */
4632cf86f6SMauro Carvalho Chehab 	{ 0x20, KEY_PLAYPAUSE },/* play/pause */
4732cf86f6SMauro Carvalho Chehab 	{ 0x29, KEY_FORWARD },	/* forward */
4832cf86f6SMauro Carvalho Chehab 	{ 0x14, KEY_AGAIN },	/* repeat */
4932cf86f6SMauro Carvalho Chehab 	{ 0x2b, KEY_RECORD },	/* recording */
5032cf86f6SMauro Carvalho Chehab 	{ 0x2c, KEY_STOP },	/* stop */
5132cf86f6SMauro Carvalho Chehab 	{ 0x2d, KEY_PLAY },	/* play */
5232cf86f6SMauro Carvalho Chehab 	{ 0x2e, KEY_CAMERA },	/* snapshot / shuffle */
5332cf86f6SMauro Carvalho Chehab 
5432cf86f6SMauro Carvalho Chehab 	{ 0x00, KEY_0 },
5532cf86f6SMauro Carvalho Chehab 	{ 0x05, KEY_1 },
5632cf86f6SMauro Carvalho Chehab 	{ 0x06, KEY_2 },
5732cf86f6SMauro Carvalho Chehab 	{ 0x07, KEY_3 },
5832cf86f6SMauro Carvalho Chehab 	{ 0x09, KEY_4 },
5932cf86f6SMauro Carvalho Chehab 	{ 0x0a, KEY_5 },
6032cf86f6SMauro Carvalho Chehab 	{ 0x0b, KEY_6 },
6132cf86f6SMauro Carvalho Chehab 	{ 0x0d, KEY_7 },
6232cf86f6SMauro Carvalho Chehab 	{ 0x0e, KEY_8 },
6332cf86f6SMauro Carvalho Chehab 	{ 0x0f, KEY_9 },
6432cf86f6SMauro Carvalho Chehab 
6532cf86f6SMauro Carvalho Chehab 	{ 0x2a, KEY_VOLUMEUP },
6632cf86f6SMauro Carvalho Chehab 	{ 0x11, KEY_VOLUMEDOWN },
6732cf86f6SMauro Carvalho Chehab 	{ 0x18, KEY_CHANNELUP },/* CH.tracking up */
6832cf86f6SMauro Carvalho Chehab 	{ 0x19, KEY_CHANNELDOWN },/* CH.tracking down */
6932cf86f6SMauro Carvalho Chehab 
7032cf86f6SMauro Carvalho Chehab 	{ 0x13, KEY_ENTER },	/* enter */
7132cf86f6SMauro Carvalho Chehab 	{ 0x21, KEY_DOT },	/* . (decimal dot) */
7232cf86f6SMauro Carvalho Chehab };
7332cf86f6SMauro Carvalho Chehab 
74d100e659SMauro Carvalho Chehab static struct rc_map_list eztv_map = {
7532cf86f6SMauro Carvalho Chehab 	.map = {
7632cf86f6SMauro Carvalho Chehab 		.scan    = eztv,
7732cf86f6SMauro Carvalho Chehab 		.size    = ARRAY_SIZE(eztv),
7852b66144SMauro Carvalho Chehab 		.rc_type = RC_TYPE_UNKNOWN,	/* Legacy IR type */
7932cf86f6SMauro Carvalho Chehab 		.name    = RC_MAP_EZTV,
8032cf86f6SMauro Carvalho Chehab 	}
8132cf86f6SMauro Carvalho Chehab };
8232cf86f6SMauro Carvalho Chehab 
8332cf86f6SMauro Carvalho Chehab static int __init init_rc_map_eztv(void)
8432cf86f6SMauro Carvalho Chehab {
85d100e659SMauro Carvalho Chehab 	return rc_map_register(&eztv_map);
8632cf86f6SMauro Carvalho Chehab }
8732cf86f6SMauro Carvalho Chehab 
8832cf86f6SMauro Carvalho Chehab static void __exit exit_rc_map_eztv(void)
8932cf86f6SMauro Carvalho Chehab {
90d100e659SMauro Carvalho Chehab 	rc_map_unregister(&eztv_map);
9132cf86f6SMauro Carvalho Chehab }
9232cf86f6SMauro Carvalho Chehab 
9332cf86f6SMauro Carvalho Chehab module_init(init_rc_map_eztv)
9432cf86f6SMauro Carvalho Chehab module_exit(exit_rc_map_eztv)
9532cf86f6SMauro Carvalho Chehab 
9632cf86f6SMauro Carvalho Chehab MODULE_LICENSE("GPL");
9732cf86f6SMauro Carvalho Chehab MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
98