linux/Documentation/devicetree/bindings/input/microchip,qt1050.txt
<<
>>
Prefs
   1Microchip AT42QT1050 Five-channel Touch Sensor IC
   2
   3The AT42QT1050 (QT1050) is a QTouchADC sensor device. The device can sense from
   4one to five keys, dependent on mode. The QT1050 includes all signal processing
   5functions necessary to provide stable sensing under a wide variety of changing
   6conditions, and the outputs are fully debounced.
   7
   8The touchkey device node should be placed inside an I2C bus node.
   9
  10Required properties:
  11- compatible: Must be "microchip,qt1050"
  12- reg: The I2C address of the device
  13- interrupts: The sink for the touchpad's IRQ output,
  14  see ../interrupt-controller/interrupts.txt
  15
  16Optional properties:
  17- wakeup-source: touch keys can be used as a wakeup source
  18
  19Each button (key) is represented as a sub-node:
  20
  21Each not specified key or key with linux,code set to KEY_RESERVED gets disabled
  22in HW.
  23
  24Subnode properties:
  25- linux,code: Keycode to emit.
  26- reg: The key number. Valid values: 0, 1, 2, 3, 4.
  27
  28Optional subnode-properties:
  29
  30If a optional property is missing or has a invalid value the default value is
  31taken.
  32
  33- microchip,pre-charge-time-ns:
  34  Each touchpad need some time to precharge. The value depends on the mechanical
  35  layout.
  36  Valid value range: 0 - 637500; values must be a multiple of 2500;
  37  default is 0.
  38- microchip,average-samples:
  39  Number of data samples which are averaged for each read.
  40  Valid values: 1, 4, 16, 64, 256, 1024, 4096, 16384; default is 1.
  41- microchip,average-scaling:
  42  The scaling factor which is used to scale the average-samples.
  43  Valid values: 1, 2, 4, 8, 16, 32, 64, 128; default is 1.
  44- microchip,threshold:
  45  Number of counts to register a touch detection.
  46  Valid value range: 0 - 255; default is 20.
  47
  48Example:
  49QT1050 with 3 non continuous keys, key2 and key4 are disabled.
  50
  51touchkeys@41 {
  52        compatible = "microchip,qt1050";
  53        reg = <0x41>;
  54        interrupt-parent = <&gpio0>;
  55        interrupts = <17 IRQ_TYPE_EDGE_FALLING>;
  56
  57        up@0 {
  58                reg = <0>;
  59                linux,code = <KEY_UP>;
  60                microchip,average-samples = <64>;
  61                microchip,average-scaling = <16>;
  62                microchip,pre-charge-time-ns = <10000>;
  63        };
  64
  65        right@1 {
  66                reg = <1>;
  67                linux,code = <KEY_RIGHT>;
  68                microchip,average-samples = <64>;
  69                microchip,average-scaling = <8>;
  70        };
  71
  72        down@3 {
  73                reg = <3>;
  74                linux,code = <KEY_DOWN>;
  75                microchip,average-samples = <256>;
  76                microchip,average-scaling = <16>;
  77        };
  78};
  79