WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: [SOLVED] custom kernel to include /dev/uinput for touchscreen support  (Read 6248 times)

Offline LazyLarry

  • Newbie
  • *
  • Posts: 42
I'm experimenting with a custom kernel to enable uinput to support an eeti touchscreen driver. I need to have a /dev/uinput directory to support the touchscreen daemon. I've gotten the config file from tc. When i do make menuconfig, I cant select the option for userinput, the option is <*>  I cant set it to <y>.
Do I need to enable something else first?

Also I note a section just above it for touchscreen support, which has an option for EETI touchscreen panel support. HAs anbyone tried setting that?
« Last Edit: December 08, 2013, 06:38:56 PM by LazyLarry »

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11041
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #1 on: November 29, 2013, 10:51:52 AM »
You don't need a custom kernel for uinput. It's already included in the base. You may need to load it (modprobe uinput).

Likewise, the open eeti driver is already built, search for the touchscreen input extension.
The only barriers that can stop you are the ones you create yourself.

Offline LazyLarry

  • Newbie
  • *
  • Posts: 42
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #2 on: November 29, 2013, 11:47:30 AM »
thats the ticket. modprobe uinput did the trick with the eGTouch drivers. Touchscreen working + calibrated

thanks a million.

so, do i just need to add uinput to modprobe.conf?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11041
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #3 on: November 29, 2013, 12:06:14 PM »
There is no modprobe.conf. You would add the command in bootlocal.sh or bootsync.sh.
The only barriers that can stop you are the ones you create yourself.

Offline LazyLarry

  • Newbie
  • *
  • Posts: 42
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #4 on: December 07, 2013, 10:04:40 PM »
OK, I've been trying a few things to get this working automatically at startup. If I wait for boot to complete, run "sudo modprobe uinput" in a terminal, then run the egalax daemon (eGTouchD), the touchscreen works properly. I've actually needed Xorg ver > 1.13 to get reliable touchscreen operation. With 1.11, the cursor doesnt track finger movements accurately enough. Its working fine with TC5.1 and Xorg7.7

So I want to get it working automatically, so I've put the modprobe uinput command into .X.d and it runs and appears in the processes list when I check via control panel system stats. Ive also put "sudo eGTouchD" into .X.d and it runs too, appearing in the processes list. But the touchscreen doesnt work. The problem appears to be a chicken and egg, because i get an entry in the galax log when the daemon starts up that there is no /dev/uinput . Is this because the modprobe command hasnt finished?

is there a way to not run the daemon until the modprobe command has completed?

btw, the egalax documentation says to put the eGTouchD daemon into etc/rc.local, but we dont have this in tinycore.
« Last Edit: December 07, 2013, 10:10:20 PM by LazyLarry »

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14791
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #5 on: December 07, 2013, 10:35:41 PM »
It would be better to put "modprobe uinput" in /opt/bootlocal.sh and keep "eGTouchD" in ~/.X.d

Offline LazyLarry

  • Newbie
  • *
  • Posts: 42
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #6 on: December 08, 2013, 08:03:14 AM »
Thanks, I tried that. Still the same problem. Is it possible to get a script to run after a delay, therefore everything is up and running before the daemon is launched?

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14791
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #7 on: December 08, 2013, 08:13:56 AM »
you could put something like "sleep 10" after the modprobe command in bootlocal - "10" being 10 seconds

Offline LazyLarry

  • Newbie
  • *
  • Posts: 42
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #8 on: December 08, 2013, 08:30:40 AM »
Tried that too, no joy.
 Maybe it's something else.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11041
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #9 on: December 08, 2013, 08:49:34 AM »
Bootlocal.sh is backgrounded, so please put the modprobe (without sleep) into bootsync.sh.
The only barriers that can stop you are the ones you create yourself.

Offline LazyLarry

  • Newbie
  • *
  • Posts: 42
Re: custom kernel to include /dev/uinput for touchscreen support
« Reply #10 on: December 08, 2013, 06:38:28 PM »
sorted, thanks.

Offline LazyLarry

  • Newbie
  • *
  • Posts: 42
Re: [SOLVED] custom kernel to include /dev/uinput for touchscreen support
« Reply #11 on: December 10, 2013, 08:22:21 AM »
As a follow up on this, it seems the modprobe uinput command takes quite a while to complete. Despite returning immediately after execution, the /dev/uinput file isnt created for quite a while afterwards, hence causing a very inconsistent results when launching the eGTouchD daemon.

I got best results by inserting a while loop after the modprobe command in bootsync, waiting until the file is present before continuing. then launch the daemon from bootsync, rather than .X.d. My bootsync looks something like

blah
blah
sudo modprobe uinput
while ! find /dev/uinput ; do sleep 1 ; done
sudo eGTouchD

It takes approx 17 or 18 secs before the while loop exits. I dont know if this is normal, but at least it starts reliably now.

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: [SOLVED] custom kernel to include /dev/uinput for touchscreen support
« Reply #12 on: December 10, 2013, 09:21:54 AM »
You can omit sudu.
bootsync.sh and bootlocal.sh are running as root.
Download a copy and keep it handy: Core book ;)