1 // SPDX-License-Identifier: GPL-2.0+
2 // apac-viewcomp.h - Keytable for apac_viewcomp Remote Controller
3 //
4 // keymap imported from ir-keymaps.c
5 //
6 // Copyright (c) 2010 by Mauro Carvalho Chehab
7
8 #include <media/rc-map.h>
9 #include <linux/module.h>
10
11 /* Attila Kondoros <attila.kondoros@chello.hu> */
12
13 static struct rc_map_table apac_viewcomp[] = {
14
15 { 0x01, KEY_1 },
16 { 0x02, KEY_2 },
17 { 0x03, KEY_3 },
18 { 0x04, KEY_4 },
19 { 0x05, KEY_5 },
20 { 0x06, KEY_6 },
21 { 0x07, KEY_7 },
22 { 0x08, KEY_8 },
23 { 0x09, KEY_9 },
24 { 0x00, KEY_0 },
25 { 0x17, KEY_LAST }, /* +100 */
26 { 0x0a, KEY_LIST }, /* recall */
27
28
29 { 0x1c, KEY_TUNER }, /* TV/FM */
30 { 0x15, KEY_SEARCH }, /* scan */
31 { 0x12, KEY_POWER }, /* power */
32 { 0x1f, KEY_VOLUMEDOWN }, /* vol up */
33 { 0x1b, KEY_VOLUMEUP }, /* vol down */
34 { 0x1e, KEY_CHANNELDOWN }, /* chn up */
35 { 0x1a, KEY_CHANNELUP }, /* chn down */
36
37 { 0x11, KEY_VIDEO }, /* video */
38 { 0x0f, KEY_ZOOM }, /* full screen */
39 { 0x13, KEY_MUTE }, /* mute/unmute */
40 { 0x10, KEY_TEXT }, /* min */
41
42 { 0x0d, KEY_STOP }, /* freeze */
43 { 0x0e, KEY_RECORD }, /* record */
44 { 0x1d, KEY_PLAYPAUSE }, /* stop */
45 { 0x19, KEY_PLAY }, /* play */
46
47 { 0x16, KEY_GOTO }, /* osd */
48 { 0x14, KEY_REFRESH }, /* default */
49 { 0x0c, KEY_KPPLUS }, /* fine tune >>>> */
50 { 0x18, KEY_KPMINUS }, /* fine tune <<<< */
51 };
52
53 static struct rc_map_list apac_viewcomp_map = {
54 .map = {
55 .scan = apac_viewcomp,
56 .size = ARRAY_SIZE(apac_viewcomp),
57 .rc_proto = RC_PROTO_UNKNOWN, /* Legacy IR type */
58 .name = RC_MAP_APAC_VIEWCOMP,
59 }
60 };
61
init_rc_map_apac_viewcomp(void)62 static int __init init_rc_map_apac_viewcomp(void)
63 {
64 return rc_map_register(&apac_viewcomp_map);
65 }
66
exit_rc_map_apac_viewcomp(void)67 static void __exit exit_rc_map_apac_viewcomp(void)
68 {
69 rc_map_unregister(&apac_viewcomp_map);
70 }
71
72 module_init(init_rc_map_apac_viewcomp)
73 module_exit(exit_rc_map_apac_viewcomp)
74
75 MODULE_LICENSE("GPL");
76 MODULE_AUTHOR("Mauro Carvalho Chehab");
77