xref: /freebsd/sys/contrib/device-tree/Bindings/input/touchscreen/resistive-adc-touch.yaml (revision 5956d97f4b3204318ceb6aa9c77bd0bc6ea87a41)
1*5956d97fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2*5956d97fSEmmanuel Vadot%YAML 1.2
3*5956d97fSEmmanuel Vadot---
4*5956d97fSEmmanuel Vadot$id: http://devicetree.org/schemas/input/touchscreen/resistive-adc-touch.yaml#
5*5956d97fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*5956d97fSEmmanuel Vadot
7*5956d97fSEmmanuel Vadottitle: Generic resistive touchscreen ADC
8*5956d97fSEmmanuel Vadot
9*5956d97fSEmmanuel Vadotmaintainers:
10*5956d97fSEmmanuel Vadot  - Oleksij Rempel <o.rempel@pengutronix.de>
11*5956d97fSEmmanuel Vadot
12*5956d97fSEmmanuel Vadotdescription: |
13*5956d97fSEmmanuel Vadot  Generic ADC based resistive touchscreen controller
14*5956d97fSEmmanuel Vadot  The device must be connected to an ADC device that provides channels for
15*5956d97fSEmmanuel Vadot  position measurement and optional pressure.
16*5956d97fSEmmanuel Vadot
17*5956d97fSEmmanuel VadotallOf:
18*5956d97fSEmmanuel Vadot  - $ref: touchscreen.yaml#
19*5956d97fSEmmanuel Vadot
20*5956d97fSEmmanuel Vadotproperties:
21*5956d97fSEmmanuel Vadot  compatible:
22*5956d97fSEmmanuel Vadot    const: resistive-adc-touch
23*5956d97fSEmmanuel Vadot
24*5956d97fSEmmanuel Vadot  io-channels:
25*5956d97fSEmmanuel Vadot    minItems: 2
26*5956d97fSEmmanuel Vadot    items:
27*5956d97fSEmmanuel Vadot      - description: x
28*5956d97fSEmmanuel Vadot      - description: y
29*5956d97fSEmmanuel Vadot      - description: pressure (optional)
30*5956d97fSEmmanuel Vadot      - description: z1 (optional)
31*5956d97fSEmmanuel Vadot      - description: z2 (optional)
32*5956d97fSEmmanuel Vadot
33*5956d97fSEmmanuel Vadot  io-channel-names:
34*5956d97fSEmmanuel Vadot    oneOf:
35*5956d97fSEmmanuel Vadot      - items:
36*5956d97fSEmmanuel Vadot          - enum: [x, y]
37*5956d97fSEmmanuel Vadot          - enum: [x, y]
38*5956d97fSEmmanuel Vadot      - items:
39*5956d97fSEmmanuel Vadot          - enum: [x, y, pressure]
40*5956d97fSEmmanuel Vadot          - enum: [x, y, pressure]
41*5956d97fSEmmanuel Vadot          - enum: [x, y, pressure]
42*5956d97fSEmmanuel Vadot      - items:
43*5956d97fSEmmanuel Vadot          - enum: [x, y, z1, z2]
44*5956d97fSEmmanuel Vadot          - enum: [x, y, z1, z2]
45*5956d97fSEmmanuel Vadot          - enum: [x, y, z1, z2]
46*5956d97fSEmmanuel Vadot          - enum: [x, y, z1, z2]
47*5956d97fSEmmanuel Vadot
48*5956d97fSEmmanuel Vadot  touchscreen-size-x: true
49*5956d97fSEmmanuel Vadot  touchscreen-size-y: true
50*5956d97fSEmmanuel Vadot  touchscreen-fuzz-x: true
51*5956d97fSEmmanuel Vadot  touchscreen-fuzz-y: true
52*5956d97fSEmmanuel Vadot  touchscreen-inverted-x: true
53*5956d97fSEmmanuel Vadot  touchscreen-inverted-y: true
54*5956d97fSEmmanuel Vadot  touchscreen-swapped-x-y: true
55*5956d97fSEmmanuel Vadot  touchscreen-min-pressure: true
56*5956d97fSEmmanuel Vadot  touchscreen-x-plate-ohms: true
57*5956d97fSEmmanuel Vadot
58*5956d97fSEmmanuel VadotadditionalProperties: false
59*5956d97fSEmmanuel Vadot
60*5956d97fSEmmanuel Vadotrequired:
61*5956d97fSEmmanuel Vadot  - compatible
62*5956d97fSEmmanuel Vadot  - io-channels
63*5956d97fSEmmanuel Vadot  - io-channel-names
64*5956d97fSEmmanuel Vadot
65*5956d97fSEmmanuel Vadotexamples:
66*5956d97fSEmmanuel Vadot  - |
67*5956d97fSEmmanuel Vadot    touchscreen {
68*5956d97fSEmmanuel Vadot      compatible = "resistive-adc-touch";
69*5956d97fSEmmanuel Vadot      io-channels = <&adc 24>, <&adc 25>;
70*5956d97fSEmmanuel Vadot      io-channel-names = "y", "x";
71*5956d97fSEmmanuel Vadot    };
72*5956d97fSEmmanuel Vadot  - |
73*5956d97fSEmmanuel Vadot    touchscreen {
74*5956d97fSEmmanuel Vadot      compatible = "resistive-adc-touch";
75*5956d97fSEmmanuel Vadot      touchscreen-min-pressure = <50000>;
76*5956d97fSEmmanuel Vadot      io-channels = <&adc 24>, <&adc 25>, <&adc 26>;
77*5956d97fSEmmanuel Vadot      io-channel-names = "y", "pressure", "x";
78*5956d97fSEmmanuel Vadot    };
79*5956d97fSEmmanuel Vadot  - |
80*5956d97fSEmmanuel Vadot    touchscreen {
81*5956d97fSEmmanuel Vadot      compatible = "resistive-adc-touch";
82*5956d97fSEmmanuel Vadot      touchscreen-min-pressure = <50000>;
83*5956d97fSEmmanuel Vadot      io-channels = <&adc 1>, <&adc 2>, <&adc 3>, <&adc 4>;
84*5956d97fSEmmanuel Vadot      io-channel-names = "x", "z1", "z2", "y";
85*5956d97fSEmmanuel Vadot      touchscreen-x-plate-ohms = <800>;
86*5956d97fSEmmanuel Vadot    };
87