根文件系统移植之tslib移植记录


一 移植步骤:

1. 下载tslib

点我进入下载地址或使用Git命令下载: 
git 地址– https://github.com/kergoth/tslib.git

2. 进入下载或解压出来的tslib目录

3. 执行下面几条命令:

<code class="hljs mel has-numbering" style="display: block; padding: 0px; color: inherit; box-sizing: border-box; font-family: 'Source Code Pro', monospace;font-size:undefined; white-space: pre; border-radius: 0px; word-wrap: normal; background: transparent;">anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span>:tslib$ ./autogen.sh  <span class="hljs-comment" style="color: rgb(136, 0, 0); box-sizing: border-box;">//得到configure</span>
anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span>:tslib$ ./configure  --host=arm-linux  --prefix=安装目录 CC=交叉编译器绝对路径
anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span>:tslib$ make
anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span>:tslib$ sudo make install

anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span>:安装目录$ <span class="hljs-keyword" style="color: rgb(0, 0, 136); box-sizing: border-box;">ls</span>    <span class="hljs-comment" style="color: rgb(136, 0, 0); box-sizing: border-box;">//成功后在安装目录有如下文件</span>
bin  etc  include  lib</code><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li><li style="box-sizing: border-box; padding: 0px 5px;">3</li><li style="box-sizing: border-box; padding: 0px 5px;">4</li><li style="box-sizing: border-box; padding: 0px 5px;">5</li><li style="box-sizing: border-box; padding: 0px 5px;">6</li><li style="box-sizing: border-box; padding: 0px 5px;">7</li></ul><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li><li style="box-sizing: border-box; padding: 0px 5px;">3</li><li style="box-sizing: border-box; padding: 0px 5px;">4</li><li style="box-sizing: border-box; padding: 0px 5px;">5</li><li style="box-sizing: border-box; padding: 0px 5px;">6</li><li style="box-sizing: border-box; padding: 0px 5px;">7</li></ul>

不用绝对路径会出些问题,一定要绝对路径。

4. 将要用到的库文件和可执行程序移入根文件系统中对应目录。

两种方法:

  • 下面->后的”/”指的是根文件系统的目录,不是你PC机的根目录,这个适合tslib稳定后移植

    • 库:tslib/lib/文件下除去pkgconfig目录以外的其他所有文件 -> /lib
    • 程序:tslib/bin文件下所有文 -> /bin
    • 配置:tslib/etc/ts.conf文件 -> /etc/ts.conf
  • 还可以选将整个目录放到根目录下的某个目录,但在配置环境变量时要做相应改变,这个适合开始移植时改错,

5. 更改文件系统的配置文件和添加环境变量

  • ts.conf:依据你开发板的触摸屏资料取消一个注释,这里取消下面的,不对就一个一个的试吧。

    # Uncomment if you’re using a Sharp Zaurus SL-C700/C750/C760/C860 
    module_raw corgi

  • 在/etc/profile 中根据自己的文件系统加入以下配置:

    export TSLIB_TSDEVICE=/dev/ts0 #此处如果选event0则ts.conf中要选module_raw input 
    export TSLIB_CONFFILE=/etc/ts.conf 
    export TSLIB_PLUGINDIR=/lib/ts 
    export TSLIB_CALIBFILE=/temp/pointercal #这里是配置校准文件保存地方的,可更改 
    export TSLIB_CONSOLEDEVICE=none 
    export TSLIB_FBDEVICE=/dev/fb0

    上一步如果是用的方法2,则配置如下:

    export TS_ROOT=/usr/local/tslib #tslib移动到文件系统里的目录 
    export TSLIB_TSDEVICE=/dev/input/ts0 
    export TSLIB_CONFFILE=$TS_ROOT/etc/ts.conf 
    export TSLIB_PLUGINDIR=$TS_ROOT/lib/ts 
    export TSLIB_CALIBFILE=/temp/pointercal 
    export TSLIB_CONSOLEDEVICE=none 
    export TSLIB_FBDEVICE=/dev/fb0 
    export PATH=$TS_ROOT/bin:$PATH 
    export LD_LIBRARY_PATH=$TS_ROOT/lib:$LD_LIBRARY_PATH

    这些配置意思查看tslib/README说明如下: 
    42 
    43 TSLIB_TSDEVICE TS device file name. 
    44 Default (non inputapi): /dev/touchscreen/ucb1x00 
    45 Default (inputapi): /dev/input/event0 
    46 TSLIB_CALIBFILE Calibration file. 
    47 Default: \${sysconfdir}/pointercal 
    48 TSLIB_CONFFILE Config file. 
    49 Default: \${sysconfdir}/ts.conf 
    50 TSLIB_PLUGINDIR Plugin directory. 
    51 Default: \${datadir}/plugins 
    52 TSLIB_CONSOLEDEVICE Console device. 
    53 Default: /dev/tty 
    54 TSLIB_FBDEVICE Framebuffer device. 
    55 Default: /dev/fb0

6. 执行ts_calibrate校正

[root@bst:/]# ts_calibrate 
xres = 480, yres = 272 
Took 26 samples… 
Top left : X = 162 Y = 209 
Took 30 samples… 
Top right : X = 866 Y = 210 
Took 31 samples… 
Bot right : X = 871 Y = 581 
Took 31 samples… 
Bot left : X = 155 Y = 584 
Took 24 samples… 
Center : X = 515 Y = 395 
-35.559814 0.535173 0.001486 
-46.847839 0.000662 0.461112 
Calibration constants: -2330448 35073 97 -3070220 43 30219 65536

二 遇到的问题汇总:

1.在执行./autogen.sh 时出现:

./autogen.sh: 3: autoreconf: not found

产生的原因是因为没有安装 automake 工具,安装命令如下: 
sudo apt-get install autoconf automake libtool

2.执行./configure时出现如下错误:

  • erro1:

    libtool: install: error: cannot install `linear.la’ to a directory not ending in /usr/local/lib/ts 
    make[2]: * [install-pluginexecLTLIBRARIES] Error 1 
    make[2]: Leaving directory `/home/anzyelay/Desktop/arm/tslib/plugins’ 
    make[1]: * [install-am] Error 2 
    make[1]: Leaving directory `/home/anzyelay/Desktop/arm/tslib/plugins’ 
    make: * [install-recursive] Error 1

    错误处理,在每次./configure后都要make clean再执行make.

  • error2:

    libtool: install: (cd /home/anzyelay/Desktop/arm/tslib/plugins; /bin/bash /home/anzyelay/Desktop/arm/tslib/libtool –tag CC –mode=relink arm-linux-gcc -DTS_POINTERCAL=\”/home/anzyelay/Desktop/arm/tslib_install/etc/pointercal\” -DTSLIB_INTERNAL -fvisibility=hidden -DGCC_HASCLASSVISIBILITY -O2 -Wall -W -module -avoid-version -o linear.la -rpath /home/anzyelay/Desktop/arm/tslib_install/lib/ts linear.lo ../src/libts.la ) 
    libtool: relink: arm-linux-gcc -shared -fPIC -DPIC .libs/linear.o -Wl,-rpath -Wl,/home/anzyelay/Desktop/arm/tslib_install/lib -L/home/anzyelay/Desktop/arm/tslib_install/lib -lts -O2 -Wl,-soname -Wl,linear.so -o .libs/linear.so 
    /home/anzyelay/Desktop/arm/tslib/libtool: line 8968: arm-linux-gcc: command not found 
    libtool: install: error: relink `linear.la’ with the above command before installing it 
    make[2]: * [install-pluginexecLTLIBRARIES] Error 1

    要指明CC如下,一定要用绝对地址,不然出下面第3个错误:

    <code class="hljs ruby has-numbering" style="display: block; padding: 0px; color: inherit; box-sizing: border-box; font-family: 'Source Code Pro', monospace;font-size:undefined; white-space: pre; border-radius: 0px; word-wrap: normal; background: transparent;">anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span><span class="hljs-symbol" style="color: rgb(0, 102, 102); box-sizing: border-box;">:~/Desktop/arm/tslib</span><span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">$ </span>./configure  --host=arm-linux --prefix=<span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/home/anzyelay</span><span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/Desktop/arm</span><span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/myrootfs/usr</span><span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/local/tslib</span> <span class="hljs-constant" style="box-sizing: border-box;">CC</span>=<span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/usr/local</span><span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/arm/</span><span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">4.4</span>.<span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">3</span>/bin/arm-linux-gcc
    </code><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul>

前面配置,make都一路OK,但在make install时出错如下:

```
/bin/bash ../libtool   --mode=install /usr/bin/install -c   linear.la dejitter.la variance.la pthres.la ucb1x00.la corgi.la collie.la h3600.la mk712.la arctic2.la tatung.la dmc.la linear_h2200.la input.la galax.la touchkit.la '/home/anzyelay/Desktop/arm/tslib/build/lib/ts'
libtool: install: warning: relinking `linear.la'
libtool: install: (cd /home/anzyelay/Desktop/arm/tslib/plugins; /bin/bash /home/anzyelay/Desktop/arm/tslib/libtool  --tag CC --mode=relink arm-linux-gnueabi-gcc -DTS_POINTERCAL=\"/home/anzyelay/Desktop/arm/tslib/build/etc/pointercal\" -DTSLIB_INTERNAL -fvisibility=hidden -DGCC_HASCLASSVISIBILITY -O2 -Wall -W -module -avoid-version -o linear.la -rpath /home/anzyelay/Desktop/arm/tslib/build/lib/ts linear.lo ../src/libts.la )
libtool: relink: arm-linux-gnueabi-gcc -shared  -fPIC -DPIC  .libs/linear.o   -Wl,-rpath -Wl,/home/anzyelay/Desktop/arm/tslib/build/lib -L/home/anzyelay/Desktop/arm/tslib/build/lib -lts  -O2   -Wl,-soname -Wl,linear.so -o .libs/linear.so
/home/anzyelay/Desktop/arm/tslib/libtool: line 8968: arm-linux-gnueabi-gcc: command not found
libtool: install: error: relink `linear.la' with the above command before installing it
make[2]: *** [install-pluginexecLTLIBRARIES] Error 1
make[2]: Leaving directory `/home/anzyelay/Desktop/arm/tslib/plugins'
make[1]: *** [install-am] Error 2
make[1]: Leaving directory `/home/anzyelay/Desktop/arm/tslib/plugins'
make: *** [install-recursive] Error 1

```

修改CC=项为其绝对地址,如下, 
错误时

<code class="hljs lasso has-numbering" style="display: block; padding: 0px; color: inherit; box-sizing: border-box; font-family: 'Source Code Pro', monospace;font-size:undefined; white-space: pre; border-radius: 0px; word-wrap: normal; background: transparent;">anzyelay@ubuntu:tslib$ <span class="hljs-built_in" style="color: rgb(102, 0, 102); box-sizing: border-box;">.</span>/configure <span class="hljs-subst" style="color: rgb(0, 0, 0); box-sizing: border-box;">--</span>host<span class="hljs-subst" style="color: rgb(0, 0, 0); box-sizing: border-box;">=</span>arm<span class="hljs-attribute" style="box-sizing: border-box;">-linux</span> <span class="hljs-subst" style="color: rgb(0, 0, 0); box-sizing: border-box;">--</span>prefix<span class="hljs-subst" style="color: rgb(0, 0, 0); box-sizing: border-box;">=</span><span class="hljs-string" style="color: rgb(0, 136, 0); box-sizing: border-box;">`pwd`</span>/build CC<span class="hljs-subst" style="color: rgb(0, 0, 0); box-sizing: border-box;">=</span>arm<span class="hljs-attribute" style="box-sizing: border-box;">-linux</span><span class="hljs-attribute" style="box-sizing: border-box;">-gcc</span>
</code><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul>

正确时

<code class="hljs ruby has-numbering" style="display: block; padding: 0px; color: inherit; box-sizing: border-box; font-family: 'Source Code Pro', monospace;font-size:undefined; white-space: pre; border-radius: 0px; word-wrap: normal; background: transparent;">anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span><span class="hljs-symbol" style="color: rgb(0, 102, 102); box-sizing: border-box;">:tslib</span><span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">$ </span>./configure --host=arm-linux --prefix=`pwd`/build <span class="hljs-constant" style="box-sizing: border-box;">CC</span>=<span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/usr/local</span><span class="hljs-regexp" style="color: rgb(0, 136, 0); box-sizing: border-box;">/arm/</span><span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">4.9</span>.<span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">4</span>/bin/arm-linux-gcc
</code><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul>

虽然我编译环境也设好了,可以找到arm-linux-gcc,但就是出错,使用绝对地址时就OK。

4.执行ts_calibrat出错如下

  • error1: 
    /bin/ts_calibrate: line 1: syntax error: unexpected end of file 
    file了下发现居然是x86的文件,不是arm的。

    <code class="hljs ruby has-numbering" style="display: block; padding: 0px; color: inherit; box-sizing: border-box; font-family: 'Source Code Pro', monospace;font-size:undefined; white-space: pre; border-radius: 0px; word-wrap: normal; background: transparent;">anzyelay<span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">@ubuntu</span><span class="hljs-symbol" style="color: rgb(0, 102, 102); box-sizing: border-box;">:myrootfs</span><span class="hljs-variable" style="color: rgb(102, 0, 102); box-sizing: border-box;">$ </span>file bin/ts_calibrate 
    bin/<span class="hljs-symbol" style="color: rgb(0, 102, 102); box-sizing: border-box;">ts_calibrate:</span> <span class="hljs-constant" style="box-sizing: border-box;">ELF</span> <span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">64</span>-bit <span class="hljs-constant" style="box-sizing: border-box;">LSB</span> executable, x86-<span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">64</span>, version <span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">1</span> (<span class="hljs-constant" style="box-sizing: border-box;">SYSV</span>), dynamically linked (uses shared libs), <span class="hljs-keyword" style="color: rgb(0, 0, 136); box-sizing: border-box;">for</span> <span class="hljs-constant" style="box-sizing: border-box;">GNU</span>/<span class="hljs-constant" style="box-sizing: border-box;">Linux</span> <span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">2.6</span>.<span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">24</span>, <span class="hljs-constant" style="box-sizing: border-box;">BuildID</span>[sha1]=<span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">0xb79294591df01693dcc3ae349c4995c59a527f80</span>, <span class="hljs-keyword" style="color: rgb(0, 0, 136); box-sizing: border-box;">not</span> stripped</code><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li></ul>

    后来发现PC机的PATH变量复原了,应该是sudo su后转回来是复原的,查看/etc/profile是正常的,重新执行了下source /etc/profile,查看PATH正常了。再重新编译安装后正常:

    <code class="hljs livecodeserver has-numbering" style="display: block; padding: 0px; color: inherit; box-sizing: border-box; font-family: 'Source Code Pro', monospace;font-size:undefined; white-space: pre; border-radius: 0px; word-wrap: normal; background: transparent;">anzyelay@ubuntu:myrootfs$ <span class="hljs-built_in" style="color: rgb(102, 0, 102); box-sizing: border-box;">file</span> usr/<span class="hljs-built_in" style="color: rgb(102, 0, 102); box-sizing: border-box;">local</span>/tslib/bin/ts_calibrate 
    usr/<span class="hljs-built_in" style="color: rgb(102, 0, 102); box-sizing: border-box;">local</span>/tslib/bin/ts_calibrate: ELF <span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">32</span>-bit LSB executable, ARM, <span class="hljs-built_in" style="color: rgb(102, 0, 102); box-sizing: border-box;">version</span> <span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">1</span> (SYSV), dynamically linked (uses shared libs), <span class="hljs-keyword" style="color: rgb(0, 0, 136); box-sizing: border-box;">for</span> GNU/Linux <span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">2.6</span><span class="hljs-number" style="color: rgb(0, 102, 102); box-sizing: border-box;">.32</span>, <span class="hljs-operator" style="box-sizing: border-box;">not</span> stripped
    </code><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li><li style="box-sizing: border-box; padding: 0px 5px;">3</li></ul><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li><li style="box-sizing: border-box; padding: 0px 5px;">3</li></ul>
  • error2:

    [root@bst:/]# ts_calibrate 
    ts_calibrate: error while loading shared libraries: libts-1.0.so.0: wrong ELF class: ELFCLASS64

    这个是由于库文件不对造成的,看是否把tslib/lib/libts-1.0.so.0移到了/lib下,如果是用方法2整个tslib目录移的则要指定库文件的搜索路径如下: 
    export TS_ROOT=/usr/local/tslib 
    export LD_LIBRARY_PATH=$TS_ROOT/lib:$LD_LIBRARY_PATH

  • error3:

    [root@bst:/]# ts_calibrate 
    xres = 480, yres = 272 
    ts_read: Invalid argument

    因为我的ts.conf中选的模块是“module_raw corgi”,故更改配置文件中的TSLIB_TSDEVICE变量如下

    <code class="hljs bash has-numbering" style="display: block; padding: 0px; color: inherit; box-sizing: border-box; font-family: 'Source Code Pro', monospace;font-size:undefined; white-space: pre; border-radius: 0px; word-wrap: normal; background: transparent;"><span class="hljs-keyword" style="color: rgb(0, 0, 136); box-sizing: border-box;">export</span> TSLIB_TSDEVICE=/dev/input/event0 
    修改为
    <span class="hljs-keyword" style="color: rgb(0, 0, 136); box-sizing: border-box;">export</span> TSLIB_TSDEVICE=/dev/input/ts0</code><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li><li style="box-sizing: border-box; padding: 0px 5px;">3</li></ul><ul class="pre-numbering" style="box-sizing: border-box; position: absolute; width: 50px; top: 0px; left: 0px; margin: 0px; padding: 6px 0px 40px; border-right-width: 1px; border-right-style: solid; border-right-color: rgb(221, 221, 221); list-style: none; text-align: right; background-color: rgb(238, 238, 238);"><li style="box-sizing: border-box; padding: 0px 5px;">1</li><li style="box-sizing: border-box; padding: 0px 5px;">2</li><li style="box-sizing: border-box; padding: 0px 5px;">3</li></ul>

    深入探究发现有以下对应关系: 
    /dev/input/event0 <—>module_raw input 
    /dev/input/ts0 <—>module_raw corgi 
    两者都是可以的,只要ts.conf和profile写上对应配置。


  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值