Changes between Version 22 and Version 23 of ventana/LVDS


Ignore:
Timestamp:
09/27/2021 10:48:33 PM (14 months ago)
Author:
Tim Harvey
Comment:

added tslib section

Legend:

Unmodified
Added
Removed
Modified
  • ventana/LVDS

    v22 v23  
    760760
    761761
     762=== Touch input libraries
     763
     764[=#tslib]
     765==== tslib
     766The tslib project provides a cross-platform library that provides access to touchscreen devices and the ability to apply filters to their input events. Linux input events are translated via a 5-pt matrix configured by default in /etc/pointercal.
     767
     768References:
     769 * http://www.tslib.org/
     770 * https://github.com/libts/tslib
     771
     772tslib uses several env variables that can be used to specify the linux input dev, pointercal, ts.conf etc:
     773 * TSLIB_TSDEVICE - Touchscreen device file name. Default: automatic detection (on Linux)
     774 * TSLIB_CALIBFILE - Calibration file. Default: ${sysconfdir}/pointercal
     775 * TSLIB_CONFFILE - Config file. Default: ${sysconfdir}/ts.conf
     776 * TSLIB_PLUGINDIR - Plugin directory. Default: ${datadir}/plugins
     777 * TSLIB_CONSOLEDEVICE - Console device. Default: /dev/tty
     778 * TSLIB_FBDEVICE - Framebuffer device. Default: /dev/fb0
     779
     780tslib consists of several applications to test and calibrate your touchscreen:
     781 - ts_print will show you touch events (filtered)
     782 - ts_test will show your touch events on the display
     783 - ts_calibrate prompt for touch events on the display at the four corners and center in order to create /etc/pointercal to translate (filter) events
     784
     785Example:
     786 * install libts and tools
     787{{{#!bash
     788# apt install libts-bin
     789}}}
     790 * run ts_calibrate to create /etc/pointercal
     791{{{#!bash
     792# ts_calibrate
     793xres = 1024, yres = 600
     794Took 2 samples...
     795Top left : X =  961 Y =  530
     796Took 1 samples...
     797Top right : X =   48 Y =  539
     798Took 3 samples...
     799Bot right : X =   67 Y =   71
     800Took 1 samples...
     801Bot left : X =  966 Y =   57
     802Took 2 samples...
     803Center : X =  514 Y =  293
     8041041.238403 -1.020124 -0.026010
     805623.628540 -0.013489 -1.062863
     806Calibration constants: 68238600 -66854 -1704 40870120 -884 -69655 65536
     807# cat /etc/pointercal
     808-66854 -1704 68238600 -884 -69655 40870120 65536 1024 600 0
     809}}}
     810 * run ts_test to test input
     811{{{
     812# ts_test
     813}}}
     814
     815
     816
    762817[=#adding]
    763818== Adding Support for a Touchscreen