xref: /linux/drivers/media/rc/keymaps/rc-pixelview.c (revision 7a707b89202f905bd9f9fbde326933c59a81214c)
132cf86f6SMauro Carvalho Chehab /* pixelview.h - Keytable for pixelview 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 
162f4f58d6SMauro Carvalho Chehab static struct rc_map_table pixelview[] = {
1732cf86f6SMauro Carvalho Chehab 
1832cf86f6SMauro Carvalho Chehab 	{ 0x1e, KEY_POWER },	/* power */
196f9e46b4SMauro Carvalho Chehab 	{ 0x07, KEY_VIDEO },	/* source */
2032cf86f6SMauro Carvalho Chehab 	{ 0x1c, KEY_SEARCH },	/* scan */
2132cf86f6SMauro Carvalho Chehab 
2232cf86f6SMauro Carvalho Chehab 
2332cf86f6SMauro Carvalho Chehab 	{ 0x03, KEY_TUNER },		/* TV/FM */
2432cf86f6SMauro Carvalho Chehab 
2532cf86f6SMauro Carvalho Chehab 	{ 0x00, KEY_RECORD },
2632cf86f6SMauro Carvalho Chehab 	{ 0x08, KEY_STOP },
2732cf86f6SMauro Carvalho Chehab 	{ 0x11, KEY_PLAY },
2832cf86f6SMauro Carvalho Chehab 
2932cf86f6SMauro Carvalho Chehab 	{ 0x1a, KEY_PLAYPAUSE },	/* freeze */
3032cf86f6SMauro Carvalho Chehab 	{ 0x19, KEY_ZOOM },		/* zoom */
3132cf86f6SMauro Carvalho Chehab 	{ 0x0f, KEY_TEXT },		/* min */
3232cf86f6SMauro Carvalho Chehab 
3332cf86f6SMauro Carvalho Chehab 	{ 0x01, KEY_1 },
3432cf86f6SMauro Carvalho Chehab 	{ 0x0b, KEY_2 },
3532cf86f6SMauro Carvalho Chehab 	{ 0x1b, KEY_3 },
3632cf86f6SMauro Carvalho Chehab 	{ 0x05, KEY_4 },
3732cf86f6SMauro Carvalho Chehab 	{ 0x09, KEY_5 },
3832cf86f6SMauro Carvalho Chehab 	{ 0x15, KEY_6 },
3932cf86f6SMauro Carvalho Chehab 	{ 0x06, KEY_7 },
4032cf86f6SMauro Carvalho Chehab 	{ 0x0a, KEY_8 },
4132cf86f6SMauro Carvalho Chehab 	{ 0x12, KEY_9 },
4232cf86f6SMauro Carvalho Chehab 	{ 0x02, KEY_0 },
4332cf86f6SMauro Carvalho Chehab 	{ 0x10, KEY_LAST },		/* +100 */
4432cf86f6SMauro Carvalho Chehab 	{ 0x13, KEY_LIST },		/* recall */
4532cf86f6SMauro Carvalho Chehab 
4632cf86f6SMauro Carvalho Chehab 	{ 0x1f, KEY_CHANNELUP },	/* chn down */
4732cf86f6SMauro Carvalho Chehab 	{ 0x17, KEY_CHANNELDOWN },	/* chn up */
4832cf86f6SMauro Carvalho Chehab 	{ 0x16, KEY_VOLUMEUP },		/* vol down */
4932cf86f6SMauro Carvalho Chehab 	{ 0x14, KEY_VOLUMEDOWN },	/* vol up */
5032cf86f6SMauro Carvalho Chehab 
5132cf86f6SMauro Carvalho Chehab 	{ 0x04, KEY_KPMINUS },		/* <<< */
5232cf86f6SMauro Carvalho Chehab 	{ 0x0e, KEY_SETUP },		/* function */
5332cf86f6SMauro Carvalho Chehab 	{ 0x0c, KEY_KPPLUS },		/* >>> */
5432cf86f6SMauro Carvalho Chehab 
5532cf86f6SMauro Carvalho Chehab 	{ 0x0d, KEY_GOTO },		/* mts */
5632cf86f6SMauro Carvalho Chehab 	{ 0x1d, KEY_REFRESH },		/* reset */
5732cf86f6SMauro Carvalho Chehab 	{ 0x18, KEY_MUTE },		/* mute/unmute */
5832cf86f6SMauro Carvalho Chehab };
5932cf86f6SMauro Carvalho Chehab 
60d100e659SMauro Carvalho Chehab static struct rc_map_list pixelview_map = {
6132cf86f6SMauro Carvalho Chehab 	.map = {
6232cf86f6SMauro Carvalho Chehab 		.scan    = pixelview,
6332cf86f6SMauro Carvalho Chehab 		.size    = ARRAY_SIZE(pixelview),
6452b66144SMauro Carvalho Chehab 		.rc_type = RC_TYPE_UNKNOWN,	/* Legacy IR type */
6532cf86f6SMauro Carvalho Chehab 		.name    = RC_MAP_PIXELVIEW,
6632cf86f6SMauro Carvalho Chehab 	}
6732cf86f6SMauro Carvalho Chehab };
6832cf86f6SMauro Carvalho Chehab 
6932cf86f6SMauro Carvalho Chehab static int __init init_rc_map_pixelview(void)
7032cf86f6SMauro Carvalho Chehab {
71d100e659SMauro Carvalho Chehab 	return rc_map_register(&pixelview_map);
7232cf86f6SMauro Carvalho Chehab }
7332cf86f6SMauro Carvalho Chehab 
7432cf86f6SMauro Carvalho Chehab static void __exit exit_rc_map_pixelview(void)
7532cf86f6SMauro Carvalho Chehab {
76d100e659SMauro Carvalho Chehab 	rc_map_unregister(&pixelview_map);
7732cf86f6SMauro Carvalho Chehab }
7832cf86f6SMauro Carvalho Chehab 
7932cf86f6SMauro Carvalho Chehab module_init(init_rc_map_pixelview)
8032cf86f6SMauro Carvalho Chehab module_exit(exit_rc_map_pixelview)
8132cf86f6SMauro Carvalho Chehab 
8232cf86f6SMauro Carvalho Chehab MODULE_LICENSE("GPL");
8332cf86f6SMauro Carvalho Chehab MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
84