1# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/input/fsl,mpr121-touchkey.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Freescale MPR121 capacitive touch sensor controller
8
9maintainers:
10  - Dmitry Torokhov <dmitry.torokhov@gmail.com>
11
12description: |
13  The MPR121 supports up to 12 completely independent electrodes/capacitance
14  sensing inputs in which 8 are multifunctional for LED driving and GPIO.
15  https://www.nxp.com/docs/en/data-sheet/MPR121.pdf
16
17allOf:
18  - $ref: input.yaml#
19
20properties:
21  compatible:
22    const: fsl,mpr121-touchkey
23
24  reg:
25    maxItems: 1
26
27  interrupts:
28    maxItems: 1
29
30  vdd-supply:
31    maxItems: 1
32
33  linux,keycodes:
34    minItems: 1
35    maxItems: 12
36
37  wakeup-source:
38    description: Use any event on keypad as wakeup event.
39    type: boolean
40
41required:
42  - compatible
43  - reg
44  - interrupts
45  - vdd-supply
46  - linux,keycodes
47
48examples:
49  - |
50    #include "dt-bindings/input/input.h"
51    i2c {
52        #address-cells = <1>;
53        #size-cells = <0>;
54
55        mpr121@5a {
56            compatible = "fsl,mpr121-touchkey";
57            reg = <0x5a>;
58            interrupt-parent = <&gpio1>;
59            interrupts = <28 2>;
60            autorepeat;
61            vdd-supply = <&ldo4_reg>;
62            linux,keycodes = <KEY_0>, <KEY_1>, <KEY_2>, <KEY_3>,
63                             <KEY_4>, <KEY_5>, <KEY_6>, <KEY_7>,
64                             <KEY_8>, <KEY_9>, <KEY_A>, <KEY_B>;
65        };
66    };
67