So, I have a Eee Top 1602. I want to run Fedora Linux on it and have it setup simply for my father. No keyboard, no mouse, just the touchscreen and a full-screen application that will let him do a small handful of tasks.
Sadly, at present, the Linux kernel does not correctly read the input for the X and Y vectors from the touchscreen. That is, it has no sense of position or direction when I touch the screen! It can tell that I've pressed it though, as it simulates the click that it should. Just not where I want it to be.
Someone wrote a small preliminary driver to fix the axes and it's available at least at the Redhat Bugzilla: bug 491629. I originally wanted to compile this driver without compiling the entire kernel. I ended up downloading the source RPM for my kernel and tried to build up the correct gcc command to compile just this one driver independently from the logical behemoth that is the Linux kernel.
This plan has wasted much more of my time than I'd like to admit (some parameters and files are dynamically generated by the kernel build process and contain values that I don't care to guess at for my machine), so I finally went the simple route of dropping the driver source file into the Linux kernel source tree, editing the relevant Makefile and Kconfig files, and compiling the kernel with the driver set as a module (rather than built-in). That's currently underway, but it seems to be progressing well.
For the record, the touchscreen is reported as this by 'lsusb':
Bus 005 Device 002: ID 1bfd:1688 TouchPack Resistive Touch Screen
This might be missing steps, so if it doesn't work for you, let me know
- Download the source code for my latest installed kernel:
yumdownloader --source kernel.i686
This gave me the file 'kernel-2.6.31-0.185.rc7.git6.fc12.src.rpm'. Yah, I'm running rawhide installed from the F12 Alpha, as I had hoped it would have better support than F11 for this computer. - Extracted the contents of the RPM file using cpio:
rpm2cpio kernel-*.rpm | cpio -i
This dumped all the files inside into the current directory. - I took a guess as to where it should go and put the driver source file (hid-touchpack.c) got from the Red Hat bug linked above (491629) into linux-2.6.30/drivers/hid/
- I edited a few files and made the following changes to make the kernel build with the driver
- To linux-2.6.30/drivers/hid/Makefile, I added
obj-$(CONFIG_HID_TOUCHPACK) += hid-touchpack.o
Under the similar entry for the sunplus driver. - To linux-2.6.30/drivers/hid/Kconfig, so that the kernel configuration process could be aware of and include the TouchPack driver, I added
config HID_TOUCHPACK tristate "TouchPack" depends on USB_HID default !EMBEDDED ---help--- Support for TouchPack Resistive Touchscreen
- To linux-2.6.30/drivers/hid/Makefile, I added
- Then, in linux-2.6.30/, I ran "make menuconfig". I then went to Device Drivers, HID Devices (near the bottom), Special HID drivers, and there was "TouchPack".
I set this to compile as a module, so that I can insert it into my currently running kernelUnfortunately, I couldn't use this as a module, as the device was claimed by another generic HID driver. Boo. So, instead, I compile with it built into the kernel, and it claims the touchscreen - hurrah! Sadly, I have to run the kernel I just compiled and not a regular Fedora one, but that's alright. - I then exited and saved the menuconfig and after configuration, ran "make" to compile it.
I just want to compile it as a module. I could have optionally written a more useful patch for the Kconfig and Makefile bits, and edited the source RPM's spec file, and built a new RPM including the driver, but I don't really like the driver so much, (wouldn't a proper solution involve linux-2.6.30/drivers/input/touchscreen/?) and I don't even know how well it'll work yet.and it works great!
I think this will be nice for my father. Uninterested in either a keyboard or a mouse or most of computers, we agree that he could still benefit from German radio, photos we upload to the web, and eventually, voice and video chat with his children. I'll update further on how well this works. Cheers.
No comments:
Post a Comment