[tslib] some newbie questions on the tslib API

Martin Kepplinger martink at posteo.de
Tue Sep 15 05:56:16 EDT 2020


On 13.09.20 07:36, Rich Morin wrote:
> I'd like to use tslib in a project, so I have some newbie questions.
> First, however, can someone tell me what's going on with the archive
> site (http://lists.infradead.org/pipermail/tslib)?  It doesn't show
> any entries since 2018!
> 
> Now for some questions.  Is there an tutorial / overview document
> about the API?  All I've found so far is this page:
> 
>   https://github.com/libts/tslib/blob/master/README.md
> 
> and some specific man pages such as:
> 
>   https://manpages.debian.org/unstable/libts0/ts_read.3.en.html

these documents (and all other manpages) basically are the
documentation. feel free to ask what is not clear.

> 
> This will be fine once I get past the initial questions, but at the
> moment, I'm a bit lost.  For example, when I call ts_read(), it will
> give me a number of samples.  Does each of these correspond to a
> pixel, the centroid of the fingertip, or what?
> 

The x/y values you get is what the touchscreen driver reports as touch
point. ts_read() is very old and doesn't support multitouch tough. look
at ts_read_mt() (you can use for single touch too) and the struct you
will need to use in src/tslib.h that header has all the API functions too.

thanks,
                            martin



More information about the tslib mailing list