上下文
我使用的i.MX6 ULL应用程序处理器与Goodix 9271触摸屏显示.显示已添加到设备树中,并且工作正常。我现在想要添加触摸控制器,它通过I 2 C连接到我的应用程序处理器。因此我添加了
我在此列举了这些问题:
/* #1: Device node on the I2C bus */
&i2c1 {
clock_frequency = <100000>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c1>;
status = "okay";
/* Awesome new touch controller */
gt9271_ts@5d {
compatible = "goodix,gt9271"; /* Device tree binding */
reg = <0x5d>; /* I2C bus address */
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_gt9271_ts_gpio>; /* Custom pinctrl group node */
interrupt-parent = <&gpio4>;
interrupts = <16,0>; /* GPIO 4 + pin 16 + active high */
reset-gpios = <&gpio4 12 0>; /* GPIO 4 + Pin 12 + active high */
touchscreen-size-x = <1200>;
touchscreen-size-y = <800>;
touchscreen-inverted-x;
touchscreen-inverted-y;
};
/* ... */
};
/* #2: Pin control group */
&iomuxc {
pinctrl_gt9271_ts_gpio: gt9271_ts_gpiogrp {
fsl,pins = <
MX6UL_PAD_NAND_DQS__GPIO4_IO16 0x80000000 /* Interrupt */
MX6UL_PAD_NAND_READY_B__GPIO4_IO12 0x80000000 /* Reset */
>;
};
/* ... */
};
说明:巴士地址
设备数据表可用这里表示支持两个从地址:0xBA/0xBB
和0x28/0x29
。该设备被设置为使用按本装订推荐的7位寻址调整的本装订(因此在节点中分配的地址实际上是0x5d
)。
说明:控制针
I平方C复位和中断分别连接到GPIO 4、pin 16和GPIO 4、pin 12。这些都是为NAND保留的,但是NAND没有和这个处理器一起使用,所以引脚是免费的。
问题
不幸的是,我添加的触摸屏控制器配置在引导时失败了,这是一条与is相关的消息。我在靴子上受到以下的欢迎:
[ 2.118110] Goodix-TS 0-005d: 0-005d supply AVDD28 not found, using dummy regulator
[ 2.126059] Goodix-TS 0-005d: 0-005d supply VDDIO not found, using dummy regulator
[ 2.134510] Goodix-TS 0-005d: i2c test failed attempt 1: -6
[ 2.177733] Goodix-TS 0-005d: i2c test failed attempt 2: -6
[ 2.217377] Goodix-TS 0-005d: I2C communication failure: -6
我试图搜索错误代码(-6),但在网上发现稀疏的搜索结果。我已经检查过连接器是否在物理上,而且它似乎是。
我应该采取哪些步骤来诊断这样的错误代码?
发布于 2021-06-04 13:57:36
解决办法如下:
irq-gpios
格式包含该属性。我以前认为我只需要interrupts
属性。添加irq-gpios = <&gpio4 16 0>;
后,设备通过了I2C测试。touchscreen-inverted-x;
和touchscreen-inverted-y;
。我错误地认为我本来就需要这样做。裁决:
试着精确地跟踪文档。
https://stackoverflow.com/questions/67835577
复制相似问题