Hello Everyone,
I have integrated a gt911 touch controller on the imx8mm custom board.
My device tree parameters are correct and my driver is goodix.c from the kernel source code.
I have gone through the thread IMX8 & Goodix GT911 touchscreen but did not find it useful.
Please suggest how to overcome i2c communication failure(error code -6) from the driver.
I am able to access the i2c device at address 0x5d from user space, but not through driver.
I have attached the datasheet of gt911 touch controller.
Thank you
Solved! Go to Solution.
Hi Anusha
gt911 example can be found on boundary devices nitrogen8mm board:
One can check i2c signals with oscilloscope, debug touchscreen driver in probe function
goodix.c\touchscreen\input\drivers - linux-imx - i.MX Linux kernel
May be useful to check if i2c clocks are enabled with CCM_CCGR23-26 registers.
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Anusha
gt911 example can be found on boundary devices nitrogen8mm board:
One can check i2c signals with oscilloscope, debug touchscreen driver in probe function
goodix.c\touchscreen\input\drivers - linux-imx - i.MX Linux kernel
May be useful to check if i2c clocks are enabled with CCM_CCGR23-26 registers.
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Sir,
After changing the pad control value as 0x1d6 for interrupt pin and 0x149 for reset pin it worked at once like a charm.
Thank you very much for your support.:smileyhappy:
Regards
Anusha
WOW thank you a lot. I've tried a lot of values!
imx8m mini
RST(IRQ) GPIO1_IO24
RESET(INT) GPIO1_IO26
Goodix GT911
uboot
+ IMX8MM_PAD_ENET_RX_CTL_GPIO1_IO24 | MUX_PAD_CTRL(0x1d6), // IRQ TOUCH
+ IMX8MM_PAD_ENET_RD0_GPIO1_IO26 | MUX_PAD_CTRL(0x149), // RESET TOUCH
+++ b/arch/arm64/boot/dts/freescale/fsl-imx8mm-evk-rm67191.dts
@@ -18,14 +18,14 @@
};
&i2c4 {
- synaptics_dsx_ts@20 {
- compatible = "synaptics_dsx";
- reg = <0x20>;
- pinctrl-names = "default";
- pinctrl-0 = <&pinctrl_i2c4_synaptics_dsx_io>;
- interrupt-parent = <&gpio1>;
- interrupts = <24 IRQ_TYPE_LEVEL_LOW>;
- synaptics,diagonal-rotation;
- status = "okay";
+ touchscreen@14 {
+ compatible = "goodix,gt911";
+ reg = <0x14>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&ts_reset_pin>;
+ interrupt-parent = <&gpio1>;
+ interrupts = <24 IRQ_TYPE_EDGE_FALLING>;
+ irq-gpios = <&gpio1 24 GPIO_ACTIVE_HIGH>;
+ reset-gpios = <&gpio1 26 GPIO_ACTIVE_HIGH>;
};
};
diff --git a/arch/arm64/boot/dts/freescale/fsl-imx8mm-evk.dts b/arch/arm64/boot/dts/freescale/fsl-imx8mm-evk.dts
index ca917eb02eec..69603e6fdcf1 100644
--- a/arch/arm64/boot/dts/freescale/fsl-imx8mm-evk.dts
+++ b/arch/arm64/boot/dts/freescale/fsl-imx8mm-evk.dts
@@ -71,9 +71,10 @@
>;
};
- pinctrl_i2c4_synaptics_dsx_io: synaptics_dsx_iogrp {
+ ts_reset_pin: goodix_dsx_iogrp {
fsl,pins = <
- MX8MM_IOMUXC_ENET_RX_CTL_GPIO1_IO24 0x159 /* Touch int */
+ MX8MM_IOMUXC_ENET_RX_CTL_GPIO1_IO24 0x1d6 /* Touch irq */
+ MX8MM_IOMUXC_ENET_RD0_GPIO1_IO26 0x149 /* Touch reset */
>;
};
Hi Евгений Коцарев,
Did it work for you?