Part Number: TSC2004
Other Parts Discussed in Thread: TSC2005
Hi,
We have checked the operation by connecting the TSC2004 to the IMX8MP, but the connection has not been successful.
Linux uses 5.10 base, and the device tree is implemented by referring to the following.
- kernel-source/Documentation/devicetree/bindings/input/touchscreen/tsc2005.txt
* Texas Instruments tsc2004 and tsc2005 touchscreen controllers
Required properties:
- compatible : "ti,tsc2004" or "ti,tsc2005"
- reg : Device address
- interrupts : IRQ specifier
- spi-max-frequency : Maximum SPI clocking speed of the
device
(for tsc2005)
Optional properties:
- vio-supply : Regulator specifier
- reset-gpios : GPIO specifier for the controller
reset line
- ti,x-plate-ohms : integer, resistance of the
touchscreen's X plates
in ohm (defaults to 280)
- ti,esd-recovery-timeout-ms : integer, if the touchscreen does not respond after
the configured time (in milli
seconds), the driver
will reset it. This is disabled by
default.
- properties defined in touchscreen.txt
Example:
&i2c3 {
tsc2004@48 {
compatible = "ti,tsc2004";
reg = <0x48>;
vio-supply = <&vio>;
reset-gpios = <&gpio4 8 GPIO_ACTIVE_HIGH>;
interrupts-extended = <&gpio1 27
IRQ_TYPE_EDGE_RISING>;
touchscreen-fuzz-x = <4>;
touchscreen-fuzz-y = <7>;
touchscreen-fuzz-pressure = <2>;
touchscreen-size-x = <4096>;
touchscreen-size-y = <4096>;
touchscreen-max-pressure = <2048>;
ti,x-plate-ohms = <280>;
ti,esd-recovery-timeout-ms = <8000>;
};
}
Below is the DTS in our environment. It is connected to the I2C1 bus (AD0/AD1 of TSC2004 = 49).
&i2c1 {
tsc2004@49 {
compatible = "ti,tsc2004";
reg = <0x49>;
vio-supply = <®_vcc_3v3>;
reset-gpios = <&gpio5 5 GPIO_ACTIVE_LOW>;
interrupts-extended = <&gpio5 4
IRQ_TYPE_EDGE_RISING>;
pinctrl-0 = <&pinctrl_tsc2004>;
touchscreen-fuzz-x = <4>;
touchscreen-fuzz-y = <7>;
touchscreen-fuzz-pressure = <2>;
touchscreen-size-x = <4096>;
touchscreen-size-y = <4096>;
touchscreen-max-pressure = <2048>;
ti,x-plate-ohms = <280>;
ti,esd-recovery-timeout-ms = <8000>;
};
&iomuxc {
pinctrl_tsc2004: gpio-tsc2004 {
fsl,pins = <
MX8MP_IOMUXC_SPDIF_RX__GPIO5_IO04 0x60
MX8MP_IOMUXC_SPDIF_EXT_CLK__GPIO5_IO05 0x14
>;
};
};
Below is the error. I would like some advice on how to fix the error.
--------------------------------
[ 5.728597] gpio gpiochip4: (30240000.gpio): gpiochip_lock_as_irq: tried
to flag a GPIO set as output for IRQ
[ 5.740564] gpio-mxc 30240000.gpio: unable to lock HW IRQ 4 for IRQ
[ 5.757522] genirq: Failed to request resources for tsc200x (irq 201) on
irqchip gpio-mxc
[ 5.767092] tsc2004 0-0049: Failed to request irq, err: -22
------------------------------
If you need any additional information, please let me know.
Thanks,
Astro


