xref: /linux/drivers/media/rc/keymaps/rc-npgtech.c (revision 32cf86f6d16367db5a10039c1dd938a2427d697c)
1*32cf86f6SMauro Carvalho Chehab /* npgtech.h - Keytable for npgtech Remote Controller
2*32cf86f6SMauro Carvalho Chehab  *
3*32cf86f6SMauro Carvalho Chehab  * keymap imported from ir-keymaps.c
4*32cf86f6SMauro Carvalho Chehab  *
5*32cf86f6SMauro Carvalho Chehab  * Copyright (c) 2010 by Mauro Carvalho Chehab <mchehab@redhat.com>
6*32cf86f6SMauro Carvalho Chehab  *
7*32cf86f6SMauro Carvalho Chehab  * This program is free software; you can redistribute it and/or modify
8*32cf86f6SMauro Carvalho Chehab  * it under the terms of the GNU General Public License as published by
9*32cf86f6SMauro Carvalho Chehab  * the Free Software Foundation; either version 2 of the License, or
10*32cf86f6SMauro Carvalho Chehab  * (at your option) any later version.
11*32cf86f6SMauro Carvalho Chehab  */
12*32cf86f6SMauro Carvalho Chehab 
13*32cf86f6SMauro Carvalho Chehab #include <media/rc-map.h>
14*32cf86f6SMauro Carvalho Chehab 
15*32cf86f6SMauro Carvalho Chehab static struct ir_scancode npgtech[] = {
16*32cf86f6SMauro Carvalho Chehab 	{ 0x1d, KEY_SWITCHVIDEOMODE },	/* switch inputs */
17*32cf86f6SMauro Carvalho Chehab 	{ 0x2a, KEY_FRONT },
18*32cf86f6SMauro Carvalho Chehab 
19*32cf86f6SMauro Carvalho Chehab 	{ 0x3e, KEY_1 },
20*32cf86f6SMauro Carvalho Chehab 	{ 0x02, KEY_2 },
21*32cf86f6SMauro Carvalho Chehab 	{ 0x06, KEY_3 },
22*32cf86f6SMauro Carvalho Chehab 	{ 0x0a, KEY_4 },
23*32cf86f6SMauro Carvalho Chehab 	{ 0x0e, KEY_5 },
24*32cf86f6SMauro Carvalho Chehab 	{ 0x12, KEY_6 },
25*32cf86f6SMauro Carvalho Chehab 	{ 0x16, KEY_7 },
26*32cf86f6SMauro Carvalho Chehab 	{ 0x1a, KEY_8 },
27*32cf86f6SMauro Carvalho Chehab 	{ 0x1e, KEY_9 },
28*32cf86f6SMauro Carvalho Chehab 	{ 0x3a, KEY_0 },
29*32cf86f6SMauro Carvalho Chehab 	{ 0x22, KEY_NUMLOCK },		/* -/-- */
30*32cf86f6SMauro Carvalho Chehab 	{ 0x20, KEY_REFRESH },
31*32cf86f6SMauro Carvalho Chehab 
32*32cf86f6SMauro Carvalho Chehab 	{ 0x03, KEY_BRIGHTNESSDOWN },
33*32cf86f6SMauro Carvalho Chehab 	{ 0x28, KEY_AUDIO },
34*32cf86f6SMauro Carvalho Chehab 	{ 0x3c, KEY_CHANNELUP },
35*32cf86f6SMauro Carvalho Chehab 	{ 0x3f, KEY_VOLUMEDOWN },
36*32cf86f6SMauro Carvalho Chehab 	{ 0x2e, KEY_MUTE },
37*32cf86f6SMauro Carvalho Chehab 	{ 0x3b, KEY_VOLUMEUP },
38*32cf86f6SMauro Carvalho Chehab 	{ 0x00, KEY_CHANNELDOWN },
39*32cf86f6SMauro Carvalho Chehab 	{ 0x07, KEY_BRIGHTNESSUP },
40*32cf86f6SMauro Carvalho Chehab 	{ 0x2c, KEY_TEXT },
41*32cf86f6SMauro Carvalho Chehab 
42*32cf86f6SMauro Carvalho Chehab 	{ 0x37, KEY_RECORD },
43*32cf86f6SMauro Carvalho Chehab 	{ 0x17, KEY_PLAY },
44*32cf86f6SMauro Carvalho Chehab 	{ 0x13, KEY_PAUSE },
45*32cf86f6SMauro Carvalho Chehab 	{ 0x26, KEY_STOP },
46*32cf86f6SMauro Carvalho Chehab 	{ 0x18, KEY_FASTFORWARD },
47*32cf86f6SMauro Carvalho Chehab 	{ 0x14, KEY_REWIND },
48*32cf86f6SMauro Carvalho Chehab 	{ 0x33, KEY_ZOOM },
49*32cf86f6SMauro Carvalho Chehab 	{ 0x32, KEY_KEYBOARD },
50*32cf86f6SMauro Carvalho Chehab 	{ 0x30, KEY_GOTO },		/* Pointing arrow */
51*32cf86f6SMauro Carvalho Chehab 	{ 0x36, KEY_MACRO },		/* Maximize/Minimize (yellow) */
52*32cf86f6SMauro Carvalho Chehab 	{ 0x0b, KEY_RADIO },
53*32cf86f6SMauro Carvalho Chehab 	{ 0x10, KEY_POWER },
54*32cf86f6SMauro Carvalho Chehab 
55*32cf86f6SMauro Carvalho Chehab };
56*32cf86f6SMauro Carvalho Chehab 
57*32cf86f6SMauro Carvalho Chehab static struct rc_keymap npgtech_map = {
58*32cf86f6SMauro Carvalho Chehab 	.map = {
59*32cf86f6SMauro Carvalho Chehab 		.scan    = npgtech,
60*32cf86f6SMauro Carvalho Chehab 		.size    = ARRAY_SIZE(npgtech),
61*32cf86f6SMauro Carvalho Chehab 		.ir_type = IR_TYPE_UNKNOWN,	/* Legacy IR type */
62*32cf86f6SMauro Carvalho Chehab 		.name    = RC_MAP_NPGTECH,
63*32cf86f6SMauro Carvalho Chehab 	}
64*32cf86f6SMauro Carvalho Chehab };
65*32cf86f6SMauro Carvalho Chehab 
66*32cf86f6SMauro Carvalho Chehab static int __init init_rc_map_npgtech(void)
67*32cf86f6SMauro Carvalho Chehab {
68*32cf86f6SMauro Carvalho Chehab 	return ir_register_map(&npgtech_map);
69*32cf86f6SMauro Carvalho Chehab }
70*32cf86f6SMauro Carvalho Chehab 
71*32cf86f6SMauro Carvalho Chehab static void __exit exit_rc_map_npgtech(void)
72*32cf86f6SMauro Carvalho Chehab {
73*32cf86f6SMauro Carvalho Chehab 	ir_unregister_map(&npgtech_map);
74*32cf86f6SMauro Carvalho Chehab }
75*32cf86f6SMauro Carvalho Chehab 
76*32cf86f6SMauro Carvalho Chehab module_init(init_rc_map_npgtech)
77*32cf86f6SMauro Carvalho Chehab module_exit(exit_rc_map_npgtech)
78*32cf86f6SMauro Carvalho Chehab 
79*32cf86f6SMauro Carvalho Chehab MODULE_LICENSE("GPL");
80*32cf86f6SMauro Carvalho Chehab MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>");
81