^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) Device tree bindings for Microchip CAP11xx based capacitive touch sensors
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3) The node for this device must be a child of a I2C controller node, as the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4) device communication via I2C only.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) Required properties:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8) compatible: Must contain one of:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9) "microchip,cap1106"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) "microchip,cap1126"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) "microchip,cap1188"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) reg: The I2C slave address of the device.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) interrupts: Property describing the interrupt line the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) device's ALERT#/CM_IRQ# pin is connected to.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) The device only has one interrupt source.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) Optional properties:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) autorepeat: Enables the Linux input system's autorepeat
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) feature on the input device.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) microchip,sensor-gain: Defines the gain of the sensor circuitry. This
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) effectively controls the sensitivity, as a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) smaller delta capacitance is required to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) generate the same delta count values.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) Valid values are 1, 2, 4, and 8.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) By default, a gain of 1 is set.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) microchip,irq-active-high: By default the interrupt pin is active low
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) open drain. This property allows using the active
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) high push-pull output.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) linux,keycodes: Specifies an array of numeric keycode values to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) be used for the channels. If this property is
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) omitted, KEY_A, KEY_B, etc are used as
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) defaults. The array must have exactly six
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) entries.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) Example:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) i2c_controller {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) cap1106@28 {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) compatible = "microchip,cap1106";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) interrupt-parent = <&gpio1>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) interrupts = <0 0>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) reg = <0x28>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) autorepeat;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) microchip,sensor-gain = <2>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) linux,keycodes = <103>, /* KEY_UP */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) <106>, /* KEY_RIGHT */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) <108>, /* KEY_DOWN */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) <105>, /* KEY_LEFT */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) <109>, /* KEY_PAGEDOWN */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57) <104>; /* KEY_PAGEUP */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) #address-cells = <1>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60) #size-cells = <0>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) usr@0 {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63) label = "cap11xx:green:usr0";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) reg = <0>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67) usr@1 {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68) label = "cap11xx:green:usr1";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) reg = <1>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) alive@2 {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73) label = "cap11xx:green:alive";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74) reg = <2>;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75) linux,default_trigger = "heartbeat";
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78) }