Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
torvalds
GitHub Repository: torvalds/linux
Path: blob/master/Documentation/devicetree/bindings/input/gpio-decoder.txt
26308 views
1
* GPIO Decoder DT bindings
2
3
Required Properties:
4
- compatible: should be "gpio-decoder"
5
- gpios: a spec of gpios (at least two) to be decoded to a number with
6
first entry representing the MSB.
7
8
Optional Properties:
9
- decoder-max-value: Maximum possible value that can be reported by
10
the gpios.
11
- linux,axis: the input subsystem axis to map to (ABS_X/ABS_Y).
12
Defaults to 0 (ABS_X).
13
14
Example:
15
gpio-decoder0 {
16
compatible = "gpio-decoder";
17
gpios = <&pca9536 3 GPIO_ACTIVE_HIGH>,
18
<&pca9536 2 GPIO_ACTIVE_HIGH>,
19
<&pca9536 1 GPIO_ACTIVE_HIGH>,
20
<&pca9536 0 GPIO_ACTIVE_HIGH>;
21
linux,axis = <0>; /* ABS_X */
22
decoder-max-value = <9>;
23
};
24
25