LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   USB Touchscreen in linux / MDK 10.2 (https://www.linuxquestions.org/questions/linux-hardware-18/usb-touchscreen-in-linux-mdk-10-2-a-320319/)

ZX_SA 05-05-2005 04:31 AM

[SOLVED] USB Touchscreen in linux / MDK 10.2
 
Iīm trying to get this ELO touchscreen (ELO 1229L using the 2500U USB controller) to work in linux. Iīve already setup X to use the second display, but Iīm having some difficulty getting the touch input setup. I have a linux driver for the monitor which Iīve compiled and installed and now I just need get the driver to talk to the device.

The problem is that I donīt know what /dev name to use. All the documentation for the touchscreens assume that one is using the RS232 version of the screen which plugs into a normal serial port so it talks on /dev/ttyS0. But what should I use for the USB device?

The usbserial kernel module claims to use /dev/ttyUSB0-255 but they didnīt exist on my machine so I used

mknod /dev/ttyUSB0 c 188 0

as directed by the kernel documentation. But when I tell the driver to use that, it gives me "System error while sending to Elographics touchscreen".

Are there any other /dev names that I can try?

Is there anyway of finding out to which /dev name a specific device is linked to? Programs like usbview does show the touchscreen USB device plugged in but doesnīt tell me which /dev name itīs using.


Some potentially helpful info:
Distro: Mandriva Limited Edition 2005 (MDK 10.2)
Kernel: 2.6.11-6mdksmp
System: P4 3.0GHz HyperThreading, 1GB RAM, Intel 865 mobo

lsusb output:
Bus 005 Device 001: ID 0000:0000
Bus 004 Device 001: ID 0000:0000
Bus 003 Device 001: ID 0000:0000
Bus 002 Device 003: ID 04e7:0007 Elo TouchSystems
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000

Thanks,
ZX_SA

ZX_SA 05-05-2005 07:58 AM

Solution
 
After scratching around in about 100 other websites, text files, c-source files etc, I eventually discovered that the device I needed to talk to is /dev/input/event2.

# cat /proc/bus/input/devices
shows which handlers are used for the input device. These are all dev files in the /dev/input directory.

I also discovered, after listing /usr/X11R6/lib/modules/input/ that I was using the wrong driver name! The docs that came with the driver focusses on the RS232 serial version of the touchscreen and said to use "elographics" as driver in the XFree86/Xorg conf file. But it should actually be "elousb".

Cheers,
ZX_SA

J.W. 05-05-2005 07:37 PM

Congrats on solving the problem ZX_SA and thanks for posting back with the solution that worked for you. That will be a big help to future readers who might have the same question -- J.W.

festx 06-04-2005 12:02 PM

Advice for 1725L on debian
 
Hi ZX_SA,

I am also trying to use an elo touch, but can't get it to work. I am using debian testing and XFree86 4.5.0. I tried using the eloinput driver that comes with 4.5.0, but that didn't work. I also used elousb which I compiled against XFree86 4.5.0,
but the xf86 logs said that it can not open the serial device (?). I though the elousb driver was for usb devices?

Any advice?

-Steve

ZX_SA 06-13-2005 04:39 AM

Sorry for the late reply, I was out of town for a few weeks.

It seems like you may be telling the driver to use the wrong device. Don't worry about it complaining about a "serial" device. Remember that USB stands for Universal Serial Bus.

In your XF86Config file (or Xorg config file), you need to tell the driver which device to use. This is done in the touchscreen's input device section with a line similar to this:
Code:

Option "Device" "/dev/input/event4"
To find out which device your touchscreen uses, use the following command:
Code:

cat /proc/bus/input/devices
It will give a result similar to the following for all your input devices (keyboards, mice, etc):
Code:

I: Bus=0003 Vendor=04e7 Product=0007 Version=0106
N: Name="Elo TouchSystems, Inc. Elo TouchSystems IntelliTouch 2500U"
P: Phys=usb-0000:00:1d.3-1/input0
H: Handlers=event4
B: EV=1b
B: KEY=10000 0 0 0 0 0 0 0 0
B: ABS=100 3
B: MSC=10

Handlers=event4 tell you which device to use. For this example, the device is /dev/input/event4.

Also, note that the elousb driver on ELO's website contains bugs. It will look for the X axis information in the wrong place. At least, it does for my touch controller (the 2500U). If you PM me your email address, I'll send you a copy of my "fixed" elousb driver.

ZX_SA 06-13-2005 09:58 AM

Since I've had a colleage complaining about a similar issue today, I've changed the elousb driver to scan /proc/bus/input/devices to automatically find the correct /dev/input/eventX device name. So it's no longer necessary to specify it in the xf86config file.

If anyone is interested in my version of the elousb driver, PM me an email address. A warning though: I do not offer any support and I do not assume any responsibility for any damage, difficulty, problems suffered due to using my driver. I may also make the driver available on my website in the near future. When I do, and remember about this, I'll post a link here.

dukeinlondon 06-13-2005 11:23 AM

Sounds like you should send a patch to the maintainer of the driver. he might be able to take it onboard....

festx 06-13-2005 10:06 PM

ZX_SA, I can't pm but I would love to see the code for the driver. My email
is steve at nothinbut dot net. I am thinking about writing a driver for the elo touch under qt-embedded. If you are interested in tackling this project together, let me know.

-Steve

ZX_SA 06-22-2005 03:01 AM

It seems that there are a number of people interested in a working driver for ELO USB touchscreens. Therefore, I have now added a tarball of my driver to my website: http://www.softcoded.net/eduard/elousb.html

jdonigan 10-07-2005 04:39 PM

I'm having a problem with your ELO USB driver
 
I'm having a problem with your ELO USB driver - y is always 4095 (unscaled)

I'm using Fedora Core 2 and the 2500Uz controller card,
and I've tried it with two different touchscreens and two different controllers.

Any suggestions would be greatly appreciated.

Thanks!

John

ZX_SA 10-07-2005 04:54 PM

Use the original driver then. I've heard from one other person that came across a touchscreen that has that problem. There seems to be different versions of firmware used in the touchscreens.

To compile the original driver you can still use the directions in the readme file in my tarball. Just replace the source files with the originals.

jmartinez 11-04-2005 07:33 AM

Hello all,

I also have working the Elo Touchscreen 2216 (USB) using the elousb original driver with the Debian 3.1 distribution (Kernel 2.6.8).

Well, I should say "not completly working". When I move the "touch" up, the cursor moves down. Also the cursor position is not corresponding with the "touch" position". This seems to be a calibration problem, except perhaps for the down - up problem.

What do you use to calibrate the screen?

Do you have also the Y axis problem?


Thanks,

Julio

ZX_SA 11-04-2005 07:52 AM

There are some tools to help you calibrate the screen, but I think these were written for the serial version (instead of the USB version). With my LCD screens I found that if I simply tell the driver to use the maximum values for each axis, it maps quite nicely (and is well calibrated).

You can change the values in the Xorg.conf (Xf86config) file. You should have a InputDevice section for the touchscreen and there are some options for the driver that you can specify here. The ones you'll need now are:
MinX, MaxX, MinY, MaxY -- Play with these to do the calibration. I simply used 0-4095 for both the X and Y axes and it works fine.

To flip the Y axis I *think* you can simply make MinY=4096 and MaxY=0. I think I did something like that when I first started playing with the elousb driver, but I can't promise you that it will work.

jmartinez 11-07-2005 04:49 AM

Thank you Steve.

Yes, I knew about MinX, MaxX, MinY, MaxY options in XF86Config, but I'd like to know if you know any calibration program for USB touchscreens.

Finally I wrote the Mins and Mans options in the config file and playing with the values to get an accurate calibration. The final values are:

"MinX" "500"
"MaxX" "3550"
"MinY" "600"
"MaxY" "3600"

The calibration can change depending if the position of the screen change using the screen buttons.

Note that the MinY and MaxY values are in the "logic" order. Strange because without the Mins and Maxs options the movement in the Y axis was flip.

Julio

Jacko 11-27-2005 10:14 AM

Anyone else having this problem?

I am trying to run the ELO Touchscreen under Slax 5.0.6 which uses kernel 2.6.12.2 and X.org 6.8.2.

The driver binary that ZX_SA kindly provded crashed my Xserver and I am having a little problem trying to compile the source.

Any help or pointers would be most appreciated.

Jacko


All times are GMT -5. The time now is 01:27 AM.