Попал в засаду с линуксом. Точнее с дисплеем адвантек, а именно с тач. Не хочет работать тач в qt5.
Что делал.
Сначала подключил дисплей к малине. После выполнил команду lsusb
root@pi:~# lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 0eef:0001 D-WAV Scientific Co., Ltd eGalax Touch Screen
Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
root@pi:~#
Дальнейшее изыскания: Запустил тест evtest:
root@pi:~# evtest
No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0: eGalax Inc. USB TouchController UNKNOWN
/dev/input/event1: eGalax Inc. USB TouchController Stylus
/dev/input/event2: eGalax Inc. USB TouchController
Выбрал 1:
root@pi:~# evtest
No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0: eGalax Inc. USB TouchController UNKNOWN
/dev/input/event1: eGalax Inc. USB TouchController Stylus
/dev/input/event2: eGalax Inc. USB TouchController
Select the device event number [0-2]: 1
Input driver version is 1.0.1
Input device ID: bus 0x3 vendor 0xeef product 0x1 version 0x210
Input device name: "eGalax Inc. USB TouchController Stylus"
Supported events:
Event type 0 (EV_SYN)
Event type 1 (EV_KEY)
Event code 320 (BTN_TOOL_PEN)
Event code 330 (BTN_TOUCH)
Event code 331 (BTN_STYLUS)
Event type 3 (EV_ABS)
Event code 0 (ABS_X)
Value 2008
Min 0
Max 4095
Event code 1 (ABS_Y)
Value 2052
Min 0
Max 4095
Event type 4 (EV_MSC)
Event code 4 (MSC_SCAN)
Properties:
Testing ... (interrupt to exit)
Event: time 1716869875.859086, type 4 (EV_MSC), code 4 (MSC_SCAN), value d0042
Event: time 1716869875.859086, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 1
Event: time 1716869875.859086, type 3 (EV_ABS), code 0 (ABS_X), value 1488
Event: time 1716869875.859086, type 3 (EV_ABS), code 1 (ABS_Y), value 1990
Event: time 1716869875.859086, -------------- SYN_REPORT ------------
Event: time 1716869875.874988, type 3 (EV_ABS), code 0 (ABS_X), value 1490
Event: time 1716869875.874988, -------------- SYN_REPORT ------------
Event: time 1716869875.878990, type 3 (EV_ABS), code 0 (ABS_X), value 1496
Event: time 1716869875.878990, -------------- SYN_REPORT ------------
Event: time 1716869875.885024, type 3 (EV_ABS), code 0 (ABS_X), value 1506
Event: time 1716869875.885024, -------------- SYN_REPORT ------------
Event: time 1716869875.890991, type 3 (EV_ABS), code 0 (ABS_X), value 1518
Выше показал реакции а нажатия тач. Далее пытался настроить калибровку тачскрин. Делал:
apt-get install evtest libts-bin
apt-get install libts-dev
export TSLIB_TSDEVICE=/dev/input/event1
export TSLIB_FBDEVICE=/dev/fb0:
Калибровка запустилась и тач заработал. Далее заменил
libinput на evdev в файле nano /usr/share/X11/xorg.conf.d/40-libinput.conf
Section "InputClass"
Identifier "evdev tablet catchall"
MatchIsTablet "on"
MatchDevicePath "/dev/input/event*"
Driver "evdev"
EndSection
Добавил
export TSLIB_TSDEVICE=/dev/input/event1
ts_calibrate
export QWS_MOUSE_PROTO=tslib:/dev/inut/event1
Но qt не работает тач. Кнопки не нажимаются