Chinaunix首页 | 论坛 | 博客
  • 博客访问: 936437
  • 博文数量: 192
  • 博客积分: 3070
  • 博客等级: 中校
  • 技术积分: 1861
  • 用 户 组: 普通用户
  • 注册时间: 2007-06-27 23:44
个人简介

Start Linux Leave Linux a while Back to Linux

文章分类

全部博文(192)

文章存档

2023年(18)

2022年(11)

2021年(8)

2020年(14)

2019年(7)

2018年(13)

2017年(16)

2016年(4)

2012年(2)

2011年(13)

2010年(26)

2009年(13)

2008年(27)

2007年(20)

我的朋友

分类: LINUX

2022-09-02 13:36:17

1. apt update
2. apt install ifmetric
3. apt install net-tools
4. apt install mesa-common-dev
5. apt install nfs-kernel-server
6. Lubuntu20 修改 root自动登录

修改 /etc/sddm.conf

内容如下

[Autologin]

User=root

Session=lubuntu

7. Touch反转设置
7.1. xinput list
//情况如下,驱动为ILITEK Multi-Touch-V3000
? Virtual core pointer                        id=2    [master pointer  (3)]
?   ? Virtual core XTEST pointer                  id=4    [slave  pointer  (2)]
?   ? ILITEK Multi-Touch-V3000                    id=9    [slave  pointer  (2)]
?   ? ILITEK Multi-Touch-V3000                    id=10    [slave  pointer  (2)]
?   ? A4Tech USB Mouse                            id=8    [slave  pointer  (2)]
? Virtual core keyboard                       id=3    [master keyboard (2)]
    ? Virtual core XTEST keyboard                 id=5    [slave  keyboard (3)]
    ? gpio-keys                                   id=11    [slave  keyboard (3)]
    ? Logitech USB Keyboard                       id=6    [slave  keyboard (3)]
    ? Logitech USB Keyboard                       id=7    [slave  keyboard (3)]
7.2.配置文件
7.2.1.查看/usr/share/X11/xorg.conf.d/目录下是否有40-libinput.conf这个文件。
  opt:           没有这个文件, 则需要安装              
  sudo apt-get install xserver-xorg-input-libinput 
安装完成后ls一下,就可以看到在/usr/share/X11/xorg.conf.d/目录下存在该文件                          

7.2.2.复制该文件到/etc/X11/xorg.conf.d/目录下。

    opt:           一开始xorg.conf.d这个目录在/etc/X11可能没有,需要自己创建。

    cd /etc/X11
    sudo mkdir xorg.conf.d

    sudo cp /usr/share/X11/xorg.conf.d/40-libinput.conf /etc/X11/xorg.conf.d/
    sudo gedit /etc/X11/xorg.conf.d/40-libinput.conf

7.2.3.进入/etc/X11/xorg.conf.d/目录下修改40-libinput.conf 文件

找到touchscreen section

在Identifier下添加一行 Option “CalibrationMatrix” “你的校准矩阵”

我这里板子上需要旋转270度,所以写 Option "CalibrationMatrix" "0 1 0  -1 0 1 0 0 1"

90度       "0 -1 1 1 0 0 0 0 1"

180度      "-1 0 1 0  -1  1 0 0 1"

x ,y对调  "-1 0 1 1 0  0  0 0 1"

添加完成后

# Match on all types of devices but joysticks
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" "-1 0 1 0  -1  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

8. 解决root 用户无声音问题

Solution run PulseAudio for all your users

Add bellow lines into /etc/systemd/system/pulseaudio.service file and save

8.1 vim /etc/systemd/system/pulseaudio.service  [Unit]
Description=PulseAudio system server

[Service]
Type=notify
ExecStart=pulseaudio --daemonize=no --system --realtime --log-target=journal

[Install]
WantedBy=multi-user.target 

8.2 Enable service

sudo systemctl --system enable pulseaudio.service
sudo systemctl --system start pulseaudio.service
sudo systemctl --system status pulseaudio.service 

8.3 Edit Client conf /etc/pulse/client.conf and replace ass bellow
default-server = /var/run/pulse/native
autospawn = no 

8.4 Add root to pulse group

sudo adduser root pulse-access 

8.5 And finally reboot the system


阅读(1045) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~