敦泰触摸屏移植DTS修改
时间: 2023-11-03 18:04:40 浏览: 50
敦泰触摸屏的移植需要进行DTS修改,以下是具体步骤:
1. 首先,需要在设备树(DTS)文件中增加触摸屏节点,例如:
```
&i2c1 {
touch@38 {
compatible = "duntai,xxx";
reg = <0x38>;
interrupt-parent = <&gpio>;
interrupts = <10 0>;
interrupt-names = "touch_irq";
};
};
```
其中,`compatible` 属性表示设备的兼容性,`reg` 属性表示I2C地址,`interrupt-parent` 属性表示触摸屏中断的父节点,`interrupts` 属性表示触摸屏中断的信息,`interrupt-names` 属性表示中断的名称。
2. 接下来,需要在设备树文件中添加触摸屏的中断控制器节点,例如:
```
&gpio {
touch_irq: touch_irq {
gpio-hog;
gpios = <10 GPIO_ACTIVE_HIGH>;
output-low;
};
};
```
其中,`touch_irq` 表示触摸屏中断节点的名称,`gpio-hog` 属性表示将GPIO设置为默认状态,`gpios` 属性表示GPIO的编号和状态,`output-low` 属性表示初始状态为低电平。
3. 最后,在内核配置文件中开启触摸屏驱动和I2C总线驱动的支持,并编译内核。完成后,将新的设备树文件和内核镜像烧录到设备中即可。
以上是敦泰触摸屏移植DTS修改的具体步骤,希望能对你有所帮助。
相关推荐
![-](https://csdnimg.cn/download_wenku/file_type_lunwen.png)
![-](https://csdnimg.cn/download_wenku/file_type_column_c1.png)
![-](https://csdnimg.cn/download_wenku/file_type_column_c1.png)
![-](https://csdnimg.cn/download_wenku/file_type_column_c1.png)
![-](https://csdnimg.cn/download_wenku/file_type_column_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)