本帖最后由 xiao592408 于 2016-6-30 11:03 编辑
连接和系统调试
SBC8600开发板+LVDS8000 Plus+ AA104XF02液晶屏的连接图
Linux 内核中添加usb触摸屏驱动的添加 1,在文件"drivers/hid/hid-ids.h"添加厂商的宏定义 #defineUSB_VENDOR_ID_MITSUBISHI_ELECTRIC 0x06d3 #define USB_DEVICE_ID_MITSUBISHI_ELECTRIC_USB_TOUCH_64000x6400
2,在文件 “drivers/hid/hid-core.c “在结构体hid_have_special_driver中添加Touch定义 staticconst struct hid_device_id hid_have_special_driver[] = {HID_USB_DEVICE(USB_VENDOR_ID_MITSUBISHI_ELECTRIC, USB_DEVICE_ID_MITSUBISHI_ELECTRIC_USB_TOUCH_6400) } "
3, 在文件”drivers/hid/hid-multitouch.c”修改Touch相关定义 static const struct hid_device_idmt_devices[] = { driver_data = MT_CLS_DEFAULT, HID_USB_DEVICE(USB_VENDOR_ID_MITSUBISHI_ELECTRIC, USB_DEVICE_ID_MITSUBISHI_ELECTRIC_USB_TOUCH_6400) } "
4, 在内核的config文件中,确认驱动中是否添加了hid-multitouch模块。 运行makemenuconfig,将HIDMultitouch panels选上。执行"makemenuconfig" 命令。HIDmultitouch panels support under: devicedriver->HID device->special HID drivers->HID Multitouch panels
5,重新编译内核.将内核替换光盘image文件夹下内核,镜像拷贝至TF卡,参考SBC8600B用户手册将镜像更新至SBC8600BNandFlash.
6,启动内核,通过修改 etc/profile 指定触摸屏路径 Modify exportTSLIB_TSDEVICE=/dev/input/touchscreen0 To exportTSLIB_TSDEVICE=/dev/input/event1
7,屏幕分辨路设置,重新启动板子,按空格进去uboot,将屏幕的分辨率设置成1024*768, 命令如下: setenv dispmode LVDS_1024x768 saveenv 重新boot启动板子,信息如下图:
使用root权限登录. LCD进行触摸屏校准, 输入命令 ts_calibrate
|