13c910ecbSThomas Gleixner // SPDX-License-Identifier: GPL-2.0-only
2ad596b68SOleh Kravchenko /*
3ad596b68SOleh Kravchenko * Keytable for the Astrometa T2hybrid remote controller
4ad596b68SOleh Kravchenko *
5ad596b68SOleh Kravchenko * Copyright (C) 2017 Oleh Kravchenko <oleg@kaa.org.ua>
6ad596b68SOleh Kravchenko */
7ad596b68SOleh Kravchenko
8ad596b68SOleh Kravchenko #include <media/rc-map.h>
9ad596b68SOleh Kravchenko #include <linux/module.h>
10ad596b68SOleh Kravchenko
11ad596b68SOleh Kravchenko static struct rc_map_table t2hybrid[] = {
12ad596b68SOleh Kravchenko { 0x4d, KEY_POWER2 },
13ad596b68SOleh Kravchenko { 0x54, KEY_VIDEO }, /* Source */
14ad596b68SOleh Kravchenko { 0x16, KEY_MUTE },
15ad596b68SOleh Kravchenko
16ad596b68SOleh Kravchenko { 0x4c, KEY_RECORD },
17ad596b68SOleh Kravchenko { 0x05, KEY_CHANNELUP },
18ad596b68SOleh Kravchenko { 0x0c, KEY_TIME}, /* Timeshift */
19ad596b68SOleh Kravchenko
20ad596b68SOleh Kravchenko { 0x0a, KEY_VOLUMEDOWN },
21ad596b68SOleh Kravchenko { 0x40, KEY_ZOOM }, /* Fullscreen */
22ad596b68SOleh Kravchenko { 0x1e, KEY_VOLUMEUP },
23ad596b68SOleh Kravchenko
24*1910ea42SBastien Nocera { 0x12, KEY_NUMERIC_0 },
25ad596b68SOleh Kravchenko { 0x02, KEY_CHANNELDOWN },
26ad596b68SOleh Kravchenko { 0x1c, KEY_AGAIN }, /* Recall */
27ad596b68SOleh Kravchenko
28*1910ea42SBastien Nocera { 0x09, KEY_NUMERIC_1 },
29*1910ea42SBastien Nocera { 0x1d, KEY_NUMERIC_2 },
30*1910ea42SBastien Nocera { 0x1f, KEY_NUMERIC_3 },
31ad596b68SOleh Kravchenko
32*1910ea42SBastien Nocera { 0x0d, KEY_NUMERIC_4 },
33*1910ea42SBastien Nocera { 0x19, KEY_NUMERIC_5 },
34*1910ea42SBastien Nocera { 0x1b, KEY_NUMERIC_6 },
35ad596b68SOleh Kravchenko
36*1910ea42SBastien Nocera { 0x11, KEY_NUMERIC_7 },
37*1910ea42SBastien Nocera { 0x15, KEY_NUMERIC_8 },
38*1910ea42SBastien Nocera { 0x17, KEY_NUMERIC_9 },
39ad596b68SOleh Kravchenko };
40ad596b68SOleh Kravchenko
41ad596b68SOleh Kravchenko static struct rc_map_list t2hybrid_map = {
42ad596b68SOleh Kravchenko .map = {
43ad596b68SOleh Kravchenko .scan = t2hybrid,
44ad596b68SOleh Kravchenko .size = ARRAY_SIZE(t2hybrid),
45ad596b68SOleh Kravchenko .rc_proto = RC_PROTO_NEC,
46ad596b68SOleh Kravchenko .name = RC_MAP_ASTROMETA_T2HYBRID,
47ad596b68SOleh Kravchenko }
48ad596b68SOleh Kravchenko };
49ad596b68SOleh Kravchenko
init_rc_map_t2hybrid(void)50ad596b68SOleh Kravchenko static int __init init_rc_map_t2hybrid(void)
51ad596b68SOleh Kravchenko {
52ad596b68SOleh Kravchenko return rc_map_register(&t2hybrid_map);
53ad596b68SOleh Kravchenko }
54ad596b68SOleh Kravchenko
exit_rc_map_t2hybrid(void)55ad596b68SOleh Kravchenko static void __exit exit_rc_map_t2hybrid(void)
56ad596b68SOleh Kravchenko {
57ad596b68SOleh Kravchenko rc_map_unregister(&t2hybrid_map);
58ad596b68SOleh Kravchenko }
59ad596b68SOleh Kravchenko
60ad596b68SOleh Kravchenko module_init(init_rc_map_t2hybrid)
61ad596b68SOleh Kravchenko module_exit(exit_rc_map_t2hybrid)
62ad596b68SOleh Kravchenko
63ad596b68SOleh Kravchenko MODULE_LICENSE("GPL");
64ad596b68SOleh Kravchenko MODULE_AUTHOR("Oleh Kravchenko <oleg@kaa.org.ua>");
65