购买链接: https://item.taobao.com/item.htm?id=591896289694
店铺链接: https://shop512436263.taobao.com
参考链接: 感谢华嵌HQEmbed赠送的 漂亮高颜值S3 开发板 (底板 + 核心板)
核心板原理图: core_s3_v01.pdf
底板原理图: hq_050ips_v01.pdf
离线
接下来修改设备树:
sun8i-v3s.dtsi
i2c1_pins: i2c1 {
pins = "PE21", "PE22";
function = "i2c1";
};i2c1: i2c@01c2b000 {
compatible = "allwinner,sun6i-a31-i2c";
reg = <0x01c2b000 0x400>;
interrupts = <GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&ccu CLK_BUS_I2C1>;
resets = <&ccu RST_BUS_I2C1>;
pinctrl-names = "default";
pinctrl-0 = <&i2c1_pins>;
status = "disabled";
#address-cells = <1>;
#size-cells = <0>;
};
arch/arm/boot/dts/sun8i-v3s-licheepi-zero.dts
&i2c1 {
status = "okay";ft6x06@38 {
compatible = "focaltech,ft6236";
reg = <0x38>;
interrupt-parent = <&pio>;
interrupts = <1 4 IRQ_TYPE_EDGE_FALLING>;
reset-gpios = <&pio 4 23 GPIO_ACTIVE_LOW>;
touchscreen-size-x = <480>;
touchscreen-size-y = <854>;
touchscreen-inverted-x;
touchscreen-swapped-x-y;
};};
驱动配置开启:
CONFIG_TOUCHSCREEN_EDT_FT5X06=y
离线
Linux 启动 log:
[ 1.180920] i2c /dev entries driver
[ 1.512203] input: EP0110M09 as /devices/platform/soc/1c2b000.i2c/i2c-0/0-0038/input/input1
evtest 正常:
# evtest
No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0: 1c22800.lradc
/dev/input/event1: EP0110M09
Select the device event number [0-1]: 1
Input driver version is 1.0.1
Input device ID: bus 0x18 vendor 0x0 product 0x0 version 0x0
Input device name: "EP0110M09"
Supported events:
Event type 0 (EV_SYN)
Event type 1 (EV_KEY)
Event code 330 (BTN_TOUCH)
Event type 3 (EV_ABS)
Event code 0 (ABS_X)
Value 0
Min 0
Max 853
Event code 1 (ABS_Y)
Value 0
Min 0
Max 479
Event code 47 (ABS_MT_SLOT)
Value 0
Min 0
Max 1
Event code 53 (ABS_MT_POSITION_X)
Value 0
Min 0
Max 853
Event code 54 (ABS_MT_POSITION_Y)
Value 0
Min 0
Max 479
Event code 57 (ABS_MT_TRACKING_ID)
Value 0
Min 0
Max 65535
Properties:
Property type 1 (INPUT_PROP_DIRECT)
Testing ... (interrupt to exit)
Event: time 4744.532688, type 3 (EV_ABS), code 57 (ABS_MT_TRACKING_ID), value 0
Event: time 4744.532688, type 3 (EV_ABS), code 53 (ABS_MT_POSITION_X), value 642
Event: time 4744.532688, type 3 (EV_ABS), code 54 (ABS_MT_POSITION_Y), value 38
Event: time 4744.532688, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 1
Event: time 4744.532688, type 3 (EV_ABS), code 0 (ABS_X), value 642
Event: time 4744.532688, type 3 (EV_ABS), code 1 (ABS_Y), value 38
Event: time 4744.532688, -------------- SYN_REPORT ------------
Event: time 4744.715007, type 3 (EV_ABS), code 53 (ABS_MT_POSITION_X), value 698
Event: time 4744.715007, type 3 (EV_ABS), code 54 (ABS_MT_POSITION_Y), value 44
Event: time 4744.715007, type 3 (EV_ABS), code 0 (ABS_X), value 698
Event: time 4744.715007, type 3 (EV_ABS), code 1 (ABS_Y), value 44
Event: time 4744.715007, -------------- SYN_REPORT ------------
Event: time 4745.571258, type 3 (EV_ABS), code 53 (ABS_MT_POSITION_X), value 705
Event: time 4745.571258, type 3 (EV_ABS), code 54 (ABS_MT_POSITION_Y), value 55
Event: time 4745.571258, type 3 (EV_ABS), code 0 (ABS_X), value 705
Event: time 4745.571258, type 3 (EV_ABS), code 1 (ABS_Y), value 55
Event: time 4745.571258, -------------- SYN_REPORT ------------
Event: time 4745.593439, type 3 (EV_ABS), code 53 (ABS_MT_POSITION_X), value 712
离线