1

I am trying to find a generic way for Linux to recognize my custom touchscreen driver without using xinput / xorg config. I'm not certain what Linux system the customer will be using, but I can be certain of a fixed com port such as ttyS0.

How does Linux recognize the touchscreen device and attach to the device ttyS0 if not using Xorg / xinput? Or do all Linux OS with a UI use Xorg?

8
  • To answer your last question, Xorg is not what all Linux installations use. There are alternatives available, with the most popular being Wayland Commented Feb 1, 2018 at 16:52
  • Sounds like a job for inputattach... Commented Feb 1, 2018 at 16:58
  • Stephen - Is it possible to add a custom driver to inputattach? I only saw the drivers that inputattach already came with. Thanks.
    – OtterFox
    Commented Feb 1, 2018 at 17:02
  • Yes, you can add a custom driver, as long as you have a matching line discipline in the kernel. The way it usually happens is that people send me a patch (or rather, [email protected]) and I merge it and release a new version. Commented Feb 1, 2018 at 17:06
  • I can't unfortunately release it to the community as it's using a proprietary interface that we had to sign a NDA for. So would Xorg be the better option in this case?
    – OtterFox
    Commented Feb 1, 2018 at 17:07

1 Answer 1

1

To solve this, I added my device to the array of 'struct input_types' within inputattach.c. This source file I had to find online. After adding the correct parameters to this list and recompiling, I was then able to start my driver running my own built inputattach file: ./myInputAttach -mydriver /dev/ttyUSB0

Running a tail -f /var/log/kern.log shows "printk" output from the driver starting and the interrupts.

I still do not see the driver on xinput, but this at least solves the issue of the driver not being used.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .