如题,最近在移植gt911的驱动到f1c100s上,跑的xboot;
拷贝xboot主线z11s上的gt911的驱动/src/arch/arm32/mach-z11s/driver/ts-gt911.c 到f1c100s的目录中/src/arch/arm32/mach-f1c100s/driver/
,然后修改设备树文件sast-kk131.json:
加上:
"i2c-f1c100s@0x01c27800": {
"clock-name": "link-i2c2",
"clock-frequency": 400000,
"reset": 82,
"sda-gpio": 129,
"sda-gpio-config": 4,
"scl-gpio": 128,
"scl-gpio-config": 4
},
"ts-gt911@0": {
"i2c-bus": "i2c-f1c100s.2",
"slave-address": 20,
"interrupt-gpio": 137,
"interrupt-gpio-config": 6,
"reset-gpio": 138,
"reset-gpio-config": 1
},
复位脚和中断脚用的是:PE10和PE9;iic用的是PE0和PE1;
设备树这样改不知道可以了吗?
要不要类似下面这样加上中断的定义?:
"irq-f1c100s-gpio@0x01f02a40": {
"interrupt-base": 128,
"interrupt-count": 6,
"interrupt-parent": 40
},
要加上的话,interrupt-base、interrupt-count、interrupt-parent不知道代表什么含义,中断号吗?
另外不知道怎么在应用程序中读取坐标值,请路过的大神指点一二
最近编辑记录 岁月快快快 (2022-02-09 18:05:17)
离线
@xboot
get,还有个问题,在应用程序中要调哪个接口来读取坐标值呢
离线
参考 cmd-event.c
get,多谢大佬
最近编辑记录 岁月快快快 (2022-02-10 14:50:57)
离线