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