ubuntu lxqt触摸屏旋转校准(usb触摸屏、lxqt、ubuntu23.10)

参考文章:https://www.codetd.com/article/5651388

1.查看触摸屏驱动

bash 复制代码
root@xyy:~# xinput list
⎡ Virtual core pointer                          id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ Windows pointer                           id=6    [slave  pointer  (2)]
⎣ Virtual core keyboard                         id=3    [master keyboard (2)]
    ↳ Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]
    ↳ Windows keyboard                          id=7    [slave  keyboard (3)]

2.修改/etc/X11/xorg.conf.d/40-libinput.conf配置文件:

旋转270° (右转) 添加

bash 复制代码
 Option "CalibrationMatrix" "0 1 0 -1 0 1 0 0 1"

旋转90° (左转) 添加

bash 复制代码
 Option "CalibrationMatrix" "0 -1 1 1 0 0 0 0 1"

旋转180° (颠倒) 添加

bash 复制代码
 Option "CalibrationMatrix" "-1 0 1 0 -1 1 0 0 1"

y轴旋转 添加

bash 复制代码
 Option "CalibrationMatrix" "-1 0 1 1 0 0 0 0 1"

修改后的配置如下:

bash 复制代码
Section "InputClass"
        Identifier "libinput pointer catchall"
        MatchIsPointer "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput keyboard catchall"
        MatchIsKeyboard "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput touchpad catchall"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput touchscreen catchall"
        Option "CalibrationMatrix" "0 1 0 -1 0 1 0 0 1"
        MatchIsTouchscreen "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput tablet catchall"
        MatchIsTablet "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

参考图:

相关推荐
何双新14 分钟前
第21讲、Odoo 18 配置机制详解
linux·python·开源
21号 115 分钟前
9.进程间通信
linux·运维·服务器
搬码临时工5 小时前
电脑同时连接内网和外网的方法,附外网连接局域网的操作设置
运维·服务器·网络
藥瓿亭5 小时前
K8S认证|CKS题库+答案| 3. 默认网络策略
运维·ubuntu·docker·云原生·容器·kubernetes·cks
Gaoithe6 小时前
ubuntu 端口复用
linux·运维·ubuntu
德先生&赛先生6 小时前
Linux编程:1、文件编程
linux
程序猿小D7 小时前
第16节 Node.js 文件系统
linux·服务器·前端·node.js·编辑器·vim
gsls2008087 小时前
ocrapi服务docker镜像使用
运维·docker·容器
多多*8 小时前
微服务网关SpringCloudGateway+SaToken鉴权
linux·开发语言·redis·python·sql·log4j·bootstrap
文牧之8 小时前
PostgreSQL 的扩展pg_freespacemap
运维·数据库·postgresql