pxa27x-keypad.txt 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. * Marvell PXA Keypad controller
  2. Required Properties
  3. - compatible : should be "marvell,pxa27x-keypad"
  4. - reg : Address and length of the register set for the device
  5. - interrupts : The interrupt for the keypad controller
  6. - marvell,debounce-interval : How long time the key will be
  7. recognized when it is pressed. It is a u32 value, and bit[31:16]
  8. is debounce interval for direct key and bit[15:0] is debounce
  9. interval for matrix key. The value is in binary number of 2ms
  10. Optional Properties For Matrix Keyes
  11. Please refer to matrix-keymap.txt
  12. Optional Properties for Direct Keyes
  13. - marvell,direct-key-count : How many direct keyes are used.
  14. - marvell,direct-key-mask : The mask indicates which keyes
  15. are used. If bit[X] of the mask is set, the direct key X
  16. is used.
  17. - marvell,direct-key-low-active : Direct key status register
  18. tells the level of pins that connects to the direct keyes.
  19. When this property is set, it means that when the pin level
  20. is low, the key is pressed(active).
  21. - marvell,direct-key-map : It is a u16 array. Each item indicates
  22. the linux key-code for the direct key.
  23. Optional Properties For Rotary
  24. - marvell,rotary0 : It is a u32 value. Bit[31:16] is the
  25. linux key-code for rotary up. Bit[15:0] is the linux key-code
  26. for rotary down. It is for rotary 0.
  27. - marvell,rotary1 : Same as marvell,rotary0. It is for rotary 1.
  28. - marvell,rotary-rel-key : When rotary is used for relative axes
  29. in the device, the value indicates the key-code for relative
  30. axes measurement in the device. It is a u32 value. Bit[31:16]
  31. is for rotary 1, and Bit[15:0] is for rotary 0.
  32. Examples:
  33. keypad: keypad@d4012000 {
  34. keypad,num-rows = <3>;
  35. keypad,num-columns = <5>;
  36. linux,keymap = <0x0000000e /* KEY_BACKSPACE */
  37. 0x0001006b /* KEY_END */
  38. 0x00020061 /* KEY_RIGHTCTRL */
  39. 0x0003000b /* KEY_0 */
  40. 0x00040002 /* KEY_1 */
  41. 0x0100008b /* KEY_MENU */
  42. 0x01010066 /* KEY_HOME */
  43. 0x010200e7 /* KEY_SEND */
  44. 0x01030009 /* KEY_8 */
  45. 0x0104000a /* KEY_9 */
  46. 0x02000160 /* KEY_OK */
  47. 0x02010003 /* KEY_2 */
  48. 0x02020004 /* KEY_3 */
  49. 0x02030005 /* KEY_4 */
  50. 0x02040006>; /* KEY_5 */
  51. marvell,rotary0 = <0x006c0067>; /* KEY_UP & KEY_DOWN */
  52. marvell,direct-key-count = <1>;
  53. marvell,direct-key-map = <0x001c>;
  54. marvell,debounce-interval = <0x001e001e>;
  55. };