thanks again
Touchsupport
-
_Jackson_ -
March 21, 2016 at 2:25 PM -
Thread is Resolved
-
-
No need to do anything in /storage/.kodi/addons/service.touchscreen folder.
-
My touchscreen doesn't work, not even the top left "small area", nothing at all.
It's a resistive "waveshare" touchscreen (it shows up as "d-wav..."). It works in Raspbian but not in LibreELEC.
I've downloaded and installed Libreelec(version 8.0.3) since it doesn't need complied anymore. Then I searched for the Touchscreen service (service.touchscreen-8.1.100.100) & System Tools addon and installed them. I've copied ts.conf-waveshare to ts.conf and ts_env.sh-waveshare to ts_env.sh. I'm not sure exactly what directory to put these, I put them in /storage/.kodi/userdata/addon_data/service.touchscreen. Through tweaking, I've even got the Touchscreen addon to display (not just the loading spinner) but I can't press the cross-hairs because there's no touchscreen inputs. Running evtest does give me output when I touch the screen.
I believe the problem is the service.touchscreen isn't running...probably because it's error-ed off.
Where are the logs to see why the daemon isn't running?Please help.
-
I changed the PID=0001 (waveshare driver) in ts_env.sh to get the touchscreen calibration addon working. But again, I'm not getting any input on the touchscreen itself to calibrate it. How can I tell if the service.touchscreen is running?
-
i got it to finally work. For some reason my touchscreen lists 2 items. When I run evtest, this is what I get...
CodeNo device specified, trying to scan all of /dev/input/event* Available devices: /dev/input/event0: eGalax Inc. USB TouchController Pen /dev/input/event1: eGalax Inc. USB TouchController /dev/input/event2: tslib to uinput daemon Select the device event number [0-2]:
I get touchscreen inputs only from /dev/input/event1. When I put the name from /dev/input/event1 into ts_env.sh as such...
It didn't work. After a lot of experimenting, I saw this when I ran
systemctl status service.touchscreen -l
Code
Display Moreservice.touchscreen.service - Touchscreen support daemon Loaded: loaded (/storage/.kodi/addons/service.touchscreen/system.d/service.touchscreen.service; enabled; vendor preset: disa bled) Active: active (exited) since Fri 2017-05-19 14:01:29 UTC; 3 months 24 days ago Process: 474 ExecStart=/bin/sh -c exec /bin/sh /storage/.kodi/addons/service.touchscreen/bin/ts_uinput_touch.sh service (code =exited, status=0/SUCCESS) Process: 450 ExecStartPre=/bin/sh -c exec /bin/sh /storage/.kodi/addons/service.touchscreen/bin/ts_calibrate.sh service (code =exited, status=0/SUCCESS) Main PID: 474 (code=exited, status=0/SUCCESS) CGroup: /system.slice/service.touchscreen.service └─490 ts_uinput_touch -x 1280 -y 1024 -d May 19 14:01:29 LibreELEC sh[474]: TSLIB_FBDEVICE: '/dev/fb0' May 19 14:01:29 LibreELEC sh[474]: TSLIB_CALIBFILE: '/storage/.kodi/userdata/addon_data/service.touchscreen/pointercal' May 19 14:01:29 LibreELEC sh[474]: TSLIB_CONFFILE: '/storage/.kodi/userdata/addon_data/service.touchscreen/ts.conf' May 19 14:01:29 LibreELEC sh[474]: TSLIB_RES_X: '1280' May 19 14:01:29 LibreELEC sh[474]: TSLIB_RES_Y: '1024' May 19 14:01:29 LibreELEC sh[474]: TSLIB_TOUCH_HOME_TIME: '(null)' May 19 14:01:29 LibreELEC sh[474]: using fb device: /dev/fb0 May 19 14:01:29 LibreELEC sh[474]: resolution: 1280x1024 May 19 14:01:29 LibreELEC sh[474]: using touch device: /dev/input/event0 May 19 14:01:29 LibreELEC sh[474]: daemonizing...
If you'll notice the second to last line, it's reading from /dev/input/event0, the wrong on. it was always picking up the previous input. I plugged in a bluetooth module which moved everything down but again, it was always off by the previous one. My guess is that there is something wrong with the comparison in the TSLIB_TSDEVICE= line in ts_env.sh.
I got it to work by commenting out the line in ts_env.sh that tries to discover the device by name and added this line under it.
CodeTOUCHSCREEN_NAME="eGalax Inc. USB TouchController" # TSLIB_TSDEVICE=$(echo 999 | evtest 2>&1 >/dev/null | awk -F':' -v TS_NAME="$TOUCHSCREEN_NAME" '$0 ~ TS_NAME {print $1; exit}') TSLIB_TSDEVICE=/dev/input/event1
I basically forced TSLIB_TSDEVICE for testing purposes and it worked. It's not a permanent fix because things move around depending what's plugged into the USB but at least it's a start.
-
You can try
Notice $ at the end meaning end of string.
Or checking whole name with
-
Putting the $ in at the end of the string did the trick!
It now works whether there's USB devices plugged in or not. Thank you so much!
-
Btw: when waveshare touchscreen shows events with evtest then ts_env.sh-sample must be copied.
ts_env.sh-waveshare is used only for waveshare displays which are using proprietary driver which is included in tslib (it uses raw data from
/dev/hidrawX).
-
I originally tried the waveshare drivers because after reading here, that's what mine displayed as. However, I could never get it to work. I figured the device was simply displaying the wrong information even though it had 'eGalax' in the description.
After much frustration, changing the PID in the waveshare driver and what not, I tried the 2 generic drivers, set the TOUCHSCREEN_NAME and noticed that the 'tslib to uinput daemon' was running when I did evtest. However, it was pointed to the wrong device(post #203) so I forced the device for testing purposes and the touchscreen worked! I then used your recommendation with the $ and all is good. Long story short, my touchscreen must not be a waveshare device. Got it from someone on eBay dealing straight from China, no documentation.
Mod note: added hyperlink to post #93.
-
Sorry, 'here' was suppose to be a hyper link to post #93
-
Hey,
I've tried to use the image provided by Grruhn to calibrate my faytech touchscreen, but all that comes up when i try to open the calibration addon is a black box...
How do I get the addon on the latest LibreELEC release? You said it's on the repository, but after looking to install it from within kodi, i couldnt find it listed anywhere. Do I need to add it outside of kodi?
-
Just search touchscreen and it will be there.
-
Thanks, I've found it! However when trying to run it, it just keeps loading infinitely displaying the two blue circles rotating...
-
Did you copied required files (ts_env.sh, ts.conf) manually with ssh session? Probably not.
This addon is not magic one which would do everything automatically.
-
Fair enough, I assumed that the addon now handles everything. I copied these two files as instructed from Grruhn's post, but with the same result.
-
-
Its the faytech 10" capacitive touch monitor (FT10TMBCAP). Does work with evtest. By name do you mean the event name, if so yes.
Status shows:
Code
Display Moreservice.touchscreen.service - Touchscreen support daemon Loaded: loaded (/storage/.kodi/addons/service.touchscreen/system.d/service.touchscreen.service; enabled; vendor preset: disabled) Active: active (exited) since Tue 2017-08-29 07:51:32 UTC; 3 weeks 0 days ago Process: 465 ExecStart=/bin/sh -c exec /bin/sh /storage/.kodi/addons/service.touchscreen/bin/ts_uinput_touch.sh service (code=exited, status=1/FAILURE) Process: 433 ExecStartPre=/bin/sh -c exec /bin/sh /storage/.kodi/addons/service.touchscreen/bin/ts_calibrate.sh service (code=exited, status=0/SUCCESS) Main PID: 465 (code=exited, status=1/FAILURE) CGroup: /system.slice/service.touchscreen.service Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_PLUGINDIR: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_CONSOLEDEVICE: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_FBDEVICE: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_CALIBFILE: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_CONFFILE: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_RES_X: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_RES_Y: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: TSLIB_TOUCH_HOME_TIME: '(null)' Aug 29 07:51:32 LibreELEC sh[465]: resolution: 0x0 Aug 29 07:51:32 LibreELEC systemd[1]: Started Touchscreen support daemon.
-
You are probably missing files ts.conf and ts_env.sh in folder /storage/.kodi/userdata/addon_data/service.touchscreen.
Codecp /storage/.kodi/userdata/addon_data/service.touchscreen/ts_env.sh-sample /storage/.kodi/userdata/addon_data/service.touchscreen/ts_env.sh cp /storage/.kodi/userdata/addon_data/service.touchscreen/ts.conf-generic /storage/.kodi/userdata/addon_data/service.touchscreen/ts.conf
Then change in ts_env.sh the line with your touchscreen name
QuoteTOUCHSCREEN_NAME="Goodix Capacitive TouchScreen"
-