rc-ue-rf4ce.c 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /* Copyright (c) 2012, The Linux Foundation. All rights reserved.
  2. *
  3. * This program is free software; you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License version 2 and
  5. * only version 2 as published by the Free Software Foundation.
  6. *
  7. * This program is distributed in the hope that it will be useful,
  8. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  10. * GNU General Public License for more details.
  11. */
  12. #include <linux/module.h>
  13. #include <media/rc-map.h>
  14. static struct rc_map_table ue_rf4ce[] = {
  15. { 0x0a, KEY_SETUP },
  16. { 0x6b, KEY_POWER },
  17. { 0x00, KEY_OK },
  18. { 0x03, KEY_LEFT },
  19. { 0x04, KEY_RIGHT },
  20. { 0x01, KEY_UP },
  21. { 0x02, KEY_DOWN },
  22. { 0x53, KEY_HOMEPAGE },
  23. { 0x0d, KEY_EXIT },
  24. { 0x72, KEY_TV },
  25. { 0x73, KEY_VIDEO },
  26. { 0x74, KEY_PC },
  27. { 0x71, KEY_AUX },
  28. { 0x45, KEY_STOP },
  29. { 0x0b, KEY_LIST },
  30. { 0x47, KEY_RECORD },
  31. { 0x48, KEY_REWIND },
  32. { 0x44, KEY_PLAY },
  33. { 0x49, KEY_FASTFORWARD },
  34. { 0x4c, KEY_BACK },
  35. { 0x46, KEY_PAUSE },
  36. { 0x4b, KEY_NEXT },
  37. { 0x41, KEY_VOLUMEUP },
  38. { 0x42, KEY_VOLUMEDOWN },
  39. { 0x32, KEY_LAST },
  40. { 0x43, KEY_MUTE },
  41. { 0x30, KEY_CHANNELUP },
  42. { 0x31, KEY_CHANNELDOWN },
  43. { 0x20, KEY_0 },
  44. { 0x21, KEY_1 },
  45. { 0x22, KEY_2 },
  46. { 0x23, KEY_3 },
  47. { 0x24, KEY_4 },
  48. { 0x25, KEY_5 },
  49. { 0x26, KEY_6 },
  50. { 0x27, KEY_7 },
  51. { 0x28, KEY_8 },
  52. { 0x29, KEY_9 },
  53. { 0x34, KEY_TV2 },
  54. { 0x2b, KEY_ENTER },
  55. { 0x35, KEY_INFO },
  56. { 0x09, KEY_MENU },
  57. };
  58. static struct rc_map_list ue_rf4ce_map = {
  59. .map = {
  60. .scan = ue_rf4ce,
  61. .size = ARRAY_SIZE(ue_rf4ce),
  62. .rc_type = RC_TYPE_OTHER,
  63. .name = RC_MAP_UE_RF4CE,
  64. }
  65. };
  66. static int __init init_rc_map_ue_rf4ce(void)
  67. {
  68. return rc_map_register(&ue_rf4ce_map);
  69. }
  70. static void __exit exit_rc_map_ue_rf4ce(void)
  71. {
  72. rc_map_unregister(&ue_rf4ce_map);
  73. }
  74. module_init(init_rc_map_ue_rf4ce)
  75. module_exit(exit_rc_map_ue_rf4ce)
  76. MODULE_DESCRIPTION("UE RF4CE Remote Keymap ");
  77. MODULE_LICENSE("GPL v2");