2019-05-27 13:55:01 +07:00
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
2010-09-03 03:29:30 +07:00
|
|
|
/* LME2510 remote control
|
|
|
|
*
|
|
|
|
* Copyright (C) 2010 Malcolm Priestley (tvboxspy@gmail.com)
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <media/rc-map.h>
|
2011-07-04 01:03:12 +07:00
|
|
|
#include <linux/module.h>
|
2010-09-03 03:29:30 +07:00
|
|
|
|
|
|
|
|
[media] rc: Name RC keymap tables as rc_map_table
Remote keytables had different names all over the place. Part of the fault
is due to a bad naming when rc subsystem was created, but there were lots
of old names that were still here.
Use a common standard for everything.
Patch generated by this script:
for i in `find drivers/staging -type f -name *.[ch]` `find include/media -type f -name *.[ch]` `find drivers/media -type f -name *.[ch]`; do sed s,ir_scancode,rc_map_table,g <$i >a && mv a $i; done
for i in `find drivers/staging -type f -name *.[ch]` `find include/media -type f -name *.[ch]` `find drivers/media -type f -name *.[ch]`; do sed s,ir_codes_,rc_map_,g <$i >a && mv a $i; done
for i in `find drivers/staging -type f -name *.[ch]` `find include/media -type f -name *.[ch]` `find drivers/media -type f -name *.[ch]`; do sed s,rc_key_map,rc_map_table,g <$i >a && mv a $i; done
for i in `find drivers/staging -type f -name *.[ch]` `find include/media -type f -name *.[ch]` `find drivers/media -type f -name *.[ch]`; do sed s,rc_map_table_size,rc_map_size,g <$i >a && mv a $i; done
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-11-18 01:46:09 +07:00
|
|
|
static struct rc_map_table lme2510_rc[] = {
|
2011-01-24 04:26:03 +07:00
|
|
|
/* Type 1 - 26 buttons */
|
2019-06-24 22:42:14 +07:00
|
|
|
{ 0xef12ba45, KEY_NUMERIC_0 },
|
|
|
|
{ 0xef12a05f, KEY_NUMERIC_1 },
|
|
|
|
{ 0xef12af50, KEY_NUMERIC_2 },
|
|
|
|
{ 0xef12a25d, KEY_NUMERIC_3 },
|
|
|
|
{ 0xef12be41, KEY_NUMERIC_4 },
|
|
|
|
{ 0xef12f50a, KEY_NUMERIC_5 },
|
|
|
|
{ 0xef12bd42, KEY_NUMERIC_6 },
|
|
|
|
{ 0xef12b847, KEY_NUMERIC_7 },
|
|
|
|
{ 0xef12b649, KEY_NUMERIC_8 },
|
|
|
|
{ 0xef12fa05, KEY_NUMERIC_9 },
|
2015-05-20 05:03:27 +07:00
|
|
|
{ 0xef12bc43, KEY_POWER },
|
|
|
|
{ 0xef12b946, KEY_SUBTITLE },
|
|
|
|
{ 0xef12f906, KEY_PAUSE },
|
|
|
|
{ 0xef12fc03, KEY_MEDIA_REPEAT},
|
|
|
|
{ 0xef12fd02, KEY_PAUSE },
|
|
|
|
{ 0xef12a15e, KEY_VOLUMEUP },
|
|
|
|
{ 0xef12a35c, KEY_VOLUMEDOWN },
|
|
|
|
{ 0xef12f609, KEY_CHANNELUP },
|
|
|
|
{ 0xef12e51a, KEY_CHANNELDOWN },
|
|
|
|
{ 0xef12e11e, KEY_PLAY },
|
|
|
|
{ 0xef12e41b, KEY_ZOOM },
|
|
|
|
{ 0xef12a659, KEY_MUTE },
|
|
|
|
{ 0xef12a55a, KEY_TV },
|
|
|
|
{ 0xef12e718, KEY_RECORD },
|
|
|
|
{ 0xef12f807, KEY_EPG },
|
|
|
|
{ 0xef12fe01, KEY_STOP },
|
2011-01-24 04:26:03 +07:00
|
|
|
/* Type 2 - 20 buttons */
|
2019-06-24 22:42:14 +07:00
|
|
|
{ 0xff40ea15, KEY_NUMERIC_0 },
|
|
|
|
{ 0xff40f708, KEY_NUMERIC_1 },
|
|
|
|
{ 0xff40f609, KEY_NUMERIC_2 },
|
|
|
|
{ 0xff40f50a, KEY_NUMERIC_3 },
|
|
|
|
{ 0xff40f30c, KEY_NUMERIC_4 },
|
|
|
|
{ 0xff40f20d, KEY_NUMERIC_5 },
|
|
|
|
{ 0xff40f10e, KEY_NUMERIC_6 },
|
|
|
|
{ 0xff40ef10, KEY_NUMERIC_7 },
|
|
|
|
{ 0xff40ee11, KEY_NUMERIC_8 },
|
|
|
|
{ 0xff40ed12, KEY_NUMERIC_9 },
|
2015-05-20 05:03:27 +07:00
|
|
|
{ 0xff40ff00, KEY_POWER },
|
|
|
|
{ 0xff40fb04, KEY_MEDIA_REPEAT}, /* Recall */
|
|
|
|
{ 0xff40e51a, KEY_PAUSE }, /* Timeshift */
|
|
|
|
{ 0xff40fd02, KEY_VOLUMEUP }, /* 2 x -/+ Keys not marked */
|
|
|
|
{ 0xff40f906, KEY_VOLUMEDOWN }, /* Volume defined as right hand*/
|
|
|
|
{ 0xff40fe01, KEY_CHANNELUP },
|
|
|
|
{ 0xff40fa05, KEY_CHANNELDOWN },
|
|
|
|
{ 0xff40eb14, KEY_ZOOM },
|
|
|
|
{ 0xff40e718, KEY_RECORD },
|
|
|
|
{ 0xff40e916, KEY_STOP },
|
2011-01-24 04:26:03 +07:00
|
|
|
/* Type 3 - 20 buttons */
|
2019-06-24 22:42:14 +07:00
|
|
|
{ 0xff00e31c, KEY_NUMERIC_0 },
|
|
|
|
{ 0xff00f807, KEY_NUMERIC_1 },
|
|
|
|
{ 0xff00ea15, KEY_NUMERIC_2 },
|
|
|
|
{ 0xff00f609, KEY_NUMERIC_3 },
|
|
|
|
{ 0xff00e916, KEY_NUMERIC_4 },
|
|
|
|
{ 0xff00e619, KEY_NUMERIC_5 },
|
|
|
|
{ 0xff00f20d, KEY_NUMERIC_6 },
|
|
|
|
{ 0xff00f30c, KEY_NUMERIC_7 },
|
|
|
|
{ 0xff00e718, KEY_NUMERIC_8 },
|
|
|
|
{ 0xff00a15e, KEY_NUMERIC_9 },
|
2015-05-20 05:03:27 +07:00
|
|
|
{ 0xff00ba45, KEY_POWER },
|
|
|
|
{ 0xff00bb44, KEY_MEDIA_REPEAT}, /* Recall */
|
|
|
|
{ 0xff00b54a, KEY_PAUSE }, /* Timeshift */
|
|
|
|
{ 0xff00b847, KEY_VOLUMEUP }, /* 2 x -/+ Keys not marked */
|
|
|
|
{ 0xff00bc43, KEY_VOLUMEDOWN }, /* Volume defined as right hand*/
|
|
|
|
{ 0xff00b946, KEY_CHANNELUP },
|
|
|
|
{ 0xff00bf40, KEY_CHANNELDOWN },
|
|
|
|
{ 0xff00f708, KEY_ZOOM },
|
|
|
|
{ 0xff00bd42, KEY_RECORD },
|
|
|
|
{ 0xff00a55a, KEY_STOP },
|
2010-09-03 03:29:30 +07:00
|
|
|
};
|
|
|
|
|
2010-11-18 01:56:53 +07:00
|
|
|
static struct rc_map_list lme2510_map = {
|
2010-09-03 03:29:30 +07:00
|
|
|
.map = {
|
2017-08-08 03:20:58 +07:00
|
|
|
.scan = lme2510_rc,
|
|
|
|
.size = ARRAY_SIZE(lme2510_rc),
|
|
|
|
.rc_proto = RC_PROTO_NEC,
|
|
|
|
.name = RC_MAP_LME2510,
|
2010-09-03 03:29:30 +07:00
|
|
|
}
|
|
|
|
};
|
|
|
|
|
|
|
|
static int __init init_rc_lme2510_map(void)
|
|
|
|
{
|
2010-11-18 01:56:53 +07:00
|
|
|
return rc_map_register(&lme2510_map);
|
2010-09-03 03:29:30 +07:00
|
|
|
}
|
|
|
|
|
|
|
|
static void __exit exit_rc_lme2510_map(void)
|
|
|
|
{
|
2010-11-18 01:56:53 +07:00
|
|
|
rc_map_unregister(&lme2510_map);
|
2010-09-03 03:29:30 +07:00
|
|
|
}
|
|
|
|
|
|
|
|
module_init(init_rc_lme2510_map)
|
|
|
|
module_exit(exit_rc_lme2510_map)
|
|
|
|
|
|
|
|
MODULE_LICENSE("GPL");
|
|
|
|
MODULE_AUTHOR("Malcolm Priestley tvboxspy@gmail.com");
|