Hello all,

The TI touch screen driver does not work _right_ with the libts-bin package
in the jessie image.

$ cat /etc/dogtag 
BeagleBoard.org Debian Image 2018-01-01

$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 8.10 (jessie)
Release:        8.10
Codename:       jessie

$ dpkg -l | grep  libts-bin
ii  libts-bin                             1.14-1rcnee0~jessie+20171122      
                      armhf        touch screen library utilities

$ sudo ts_calibrate
ts_setup: No such file or directory

It is possible to make it work by setting the TSLIB_TSDEVICE environment
variable:

$ sudo su
# export TSLIB_TSDEVICE=/dev/input/event2
# ts_calibrate

But, that's a bit of a pain since the environment variable always needs to
be set in order to use the touchscreen.

It appears that this version of the utilities uses the INPUT_PROP_DIRECT
propbit to automatically detect which /dev/input/event device is the 
touchscreen.

It looks like the following is the only change needed to make it work.

Unfortunately, I don't have currently have a way to build a custom kernel
for the BeagleBone in order to test it. If there is anyone that could I 
would
appreciate it.

Regards,
Hartley

---

>From 51e72377245fef6516001555cce6f5c36e487da1 Mon Sep 17 00:00:00 2001
From: H Hartley Sweeten <[email protected]>
Date: Wed, 3 Jan 2018 16:19:06 -0700
Subject: [PATCH] Input: ti_am335x_tsc - set INPUT_PROP_DIRECT

If INPUT_PROP_DIRECT is set, userspace doesn't have to fall back to old
ways of identifying touchscreen devices.

According to the documentation, touchscreen drivers should have this
property set and in order to make life easy for userspace, let's set it.

Signed-off-by: H Hartley Sweeten <[email protected]>
---
 drivers/input/touchscreen/ti_am335x_tsc.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/input/touchscreen/ti_am335x_tsc.c 
b/drivers/input/touchscreen/ti_am335x_tsc.c
index f1043ae71dcc..ea982fa3742f 100644
--- a/drivers/input/touchscreen/ti_am335x_tsc.c
+++ b/drivers/input/touchscreen/ti_am335x_tsc.c
@@ -446,6 +446,7 @@ static int titsc_probe(struct platform_device *pdev)
  input_dev->name = "ti-tsc";
  input_dev->dev.parent = &pdev->dev;
 
+ __set_bit(INPUT_PROP_DIRECT, input_dev->propbit);
  input_dev->evbit[0] = BIT_MASK(EV_KEY) | BIT_MASK(EV_ABS);
  input_dev->keybit[BIT_WORD(BTN_TOUCH)] = BIT_MASK(BTN_TOUCH);
 
-- 
2.13.3

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/69d0d31b-c5bc-410c-9575-952f6538d12d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to