======Howto install drivers for the Kiddshop(& DealExtreme) touchscreen under Xandros====== Note:Touchscreen bought from DealExtreme worked successfully using the driver below and these steps. I followed the instructions to the letter and made it work flawlessly. (For me at least - importantpower) The solderless 7" touchscreen kit from Hongkong-based Ebay seller Kiddshop is favoured by many EEE PC users, but it is only supported for Windows XP. There are however, drivers available to get the touchscreen working and keep the pre-installed Xandros system. The Linux drivers on the CD supplied by Kiddshop are a confusing mess of files and archives, which are difficult to install for all but the most experienced Linux gurus. Thankfully EEEuser forum member **gfoot** has provided a modified kernel module which makes the touchscreen work under Xandros. =====Hardware prerequisites===== * The touchscreen from Kiddshop obviously: {{howto:kiddshop_touchscreen_in_packaging.jpg|Kiddshop touchscreen in packaging}} * Switch off the EEE PC and remove the battery and memory cover * Open up your EEE PC main casing and remove the display bezel (Check out the guide by **ta2cba** on http://forum.eeeuser.com/viewtopic.php?id=6036) * Fit the controller circuit board under the left speaker * Connect the controller to the on-board USB port of the webcam (You lose the functionality of the webcam unless you use an internal USB hub) =====Software prerequisites===== ===The driver archive=== * Download the driver archive. You need the 32 bit drivers for kernel 2.6 - the file is named **TouchKit-1.08.1227-32b-k26.tar.gz** * They are available from http://home.eeti.com.tw/web20/TouchKitDriver/linuxDriver.htm (please feel free to contact touch_fae@eeti.com if you need) * A quick search on Google for the file name revealed a possible alternate download location at http://www.cartft.com/support/drivers/TFT/tftdrivers/TouchKit-1.08.1227-32b-k26.tar.gz * unpack the archive in your home directory /home/user/TouchKit/ ===The modified kernel module=== * Download the kernel module (single file named **tkusb.ko**) compiled by gfoot from http://www.glost.eclipse.co.uk/gfoot/eee/tkusb/ ======Install driver files and device node====== Open a command shell (press Ctrl+Alt+T) and go into superuser mode (that avoids having to type sudo in front of every command) sudo su Go to the directory where you unpacked the driver archive file cd /home/user/TouchKit/ Copy the driver to the system directory cp egalax_drv.so /usr/lib/xorg/modules/input Next, create a device node by which the kernel module communicates with the touchscreen controller mknod /dev/tkpanel0 c 180 180 //Note, the modified kernel module is programmed to talk to exactly that device (tkpanel0), other device IDs will not work with gfoot's tkusb.ko module// ======Install the kernel module====== Open a command shell (press Ctrl+Alt+T) and go into superuser mode (that avoids having to type sudo in front of every command) sudo su Go to the directory where you saved the downloaded tkusb.ko file and copy it to the system directory cp tkusb.ko /lib/modules/2.6.21.4-eeepc/kernel/drivers/usb/input Deactivate the original touchscreen module by renaming it cd /lib/modules/2.6.21.4-eeepc/kernel/drivers/usb/input mv usbtouchscreen.ko usbtouchscreen.ko_OFF After these modifications to kernel modules you now re-generate the module dependencies: depmod -a This command needs to be issued every time you move a .ko file or install a new one. The new kernel module needs to be loaded on startup. The kernel needs to have loaded the module before X11 starts up. There are a number of ways to ensure the loading of a kernel module on startup. One of those methods - editing the /etc/modules files - has shown to work and is presented here: Open the modules configuration in a text editor cp -p /etc/modules /etc/modules_ORIG kwrite /etc/modules Add a new line with the single word **tkusb** at the end of the text and save the file Now, **reboot** the machine When the machine is back up, open a shell again and check which kernel modules are loaded. Type lsmod Look for a line that starts with **usbcore** and check that is contains the word **tkusb**. By restricting the output (using grep) to lines containing the word tkusb it is easier to see the changes: Type: lsmod | grep tkusb And you should get something like this: tkusb 5136 1 usbcore 91928 9 uvcvideo,usb_storage,libusual,ehci_hcd,uhci_hcd,usbhid,tkusb If the module is loaded, all is ready to continue. **Note**, that at this point you haven't verified that the modules loaded at the right phase of the boot process (it needs to be laoded before X11 starts up). However, the method of configuring the extra modules in the /etc/modules file has shown to do that correctly. **Hint** by gfoot from http://forum.eeeuser.com/viewtopic.php?pid=250352#p250352: The tkusb.ko file can actually go anywhere in /lib/modules/2.6.21.4-eeepc, provided you run "sudo depmod" after moving it. ======Configure the touchscreen in X11====== This method was first detailed in this forum post http://forum.eeeuser.com/viewtopic.php?id=18677 by **chewy** * Open a command shell (Ctrl+Alt+T) * Make a copy of the X11 configuration file sudo cp -p /etc/X11/xorg.conf /etc/X11/xorg.conf_ORIG * Open the config file in an editor sudo kwrite /etc/X11/xorg.conf find the Section ''"ServerLayout"''. See the 3 InputDevice lines? Add a line that says InputDevice "EETI" "SendCoreEvents" (this tells the system about a new device named ''EETI'' (the touchscreen)) there should still be an ''EndSection'' to close this section. Looks like this when you’re done: Section "ServerLayout" Identifier "Xandros" Screen 0 "Screen1" InputDevice "keyboard" InputDevice "mouse" InputDevice "synaptics" InputDevice "EETI" "SendCoreEvents" EndSection * Scroll further down in the file to the part that has Section "InputDevice" Identifier "mouse" Driver "mouse" ... * Add the following section to define the driver for the EETI touchscreen Section "InputDevice" Identifier "EETI" Driver "egalax" Option "Device" "/dev/tkpanel0" Option "Parameters" "/var/lib/egalax.cal" Option "ScreenNo" "0" EndSection * Note that it's the number zero in the last line (not the letter "oh") * If you copy and paste these lines to the file, make sure that the quote marks are standard simple quote marks (and not typographical quotes which slant left and right) * reboot the machine If you've made a mistake with the xorg.conf file by introducing invalid characters or lines that cannot be read by the system your system may not boot up again. Check this thread for methods to recover from that: **Restore xorg.conf file using Knoppix** at http://forum.eeeuser.com/viewtopic.php?id=25139 ======Connect and check the touchscreen====== By now you should have all the software in place to run the touchscreen. It is time to connect it and check the communication * Make sure the touchscreen cable is plugged into the webcam's mini socket on the motherboard * Boot the EEE PC * Check that the machine can "see" it as a USB device * Open a command shell (CTrl+Alt+T) and type lsusb The output should look like this: Bus 004 Device 001: ID 0000:0000 Bus 004 Device 002: ID 0eef:0001 D-WAV Scientific Co., Ltd eGalax TouchScreen Bus 003 Device 001: ID 0000:0000 Bus 005 Device 003: ID 0951:1606 Kingston Technology Bus 005 Device 001: ID 0000:0000 Bus 001 Device 001: ID 0000:0000 Bus 002 Device 001: ID 0000:0000 The second line (with ''eGalax Touchscreen'') is what you're looking for. If that shows up, your touchscreen should be ready to go. If not run these checks: * Check the wiring, make sure there's no metal in contact with the controller circuit board * make sure the webcam is turned on, In a command shell type: cat /proc/acpi/asus/camera * If the file contains a 0, the webcam USB socket is turned off and the touchscreen is naturally dead * turn the webcam back on by typing this command: sudo echo 1 > /proc/acpi/asus/camera * Check the output of **lsusb** again. * There is a small green LED light on the controller board. Tap the screen with your finger and check it lights up. It might stay lit up, or flicker - that's OK. * Once your machine can "see" the touchscreen USB device, you can check that you're receiving data via the ''/dev/tkpanel0'' device. Type sudo xxd -g1 /dev/tkpanel0 and run your finger over the screen. You should get a stream of numbers appearing in the shell window. Once you get that you're ready to calibrate the screen ======Calibrate the touchscreen====== Open a command shell window and go to the directory where you unpacked the driver archive and run the calibration tool (as superuser) cd /home/user/TouchKit sudo ./TouchKit & If the program window opens without an erro you are nearly finished. Open the "Tool" tab and go through the **4Pts Cal** and **25Pts Cal** setup routines. * reboot your machine and use the touchscreen to navigate the user interface ! ======Optional: install the icon for the calibration tool====== Download this archive of icon files {{howto:touchkit_icons.zip|touchkit_icons.zip}} unpack it in your home directory ** NOTE: The original artwork for these icons came from this image http://www.sxtouch.com/images/touchkit.jpg** Open a command shell (Ctrl+Alt+T) and change to the directory where you unzipped the archive: cd touchkit_icons sudo cp *.png /opt/xandros/share/AsusLauncher/ Download **Easy Mode Editor (emeditor)** from http://download.projectsakura.com/eeepc/emeditor.html Check the EmEditor section on http://wiki.eeeuser.com/howto:customizeeasymodeicons if you're unsure how to install the program. * Start emeditor (type **emeditor** in a command shell) * Select the Settings tab on the left * Click the (+) Button on the right * Enter "TouchKit Calibration" as the new name * Go to the icon tab, and select touchkit from the list (is only available if you've copied the icons files from the zip archive to the correct system directory) * Go to the command tab * Enter this as a command: **sudo /home/user/TouchKit/TouchKit** * Close the editor and save on exit Activate the changes by rebooting, restarting X11 (Ctrl+Alt+Backspace) or simply by choosing a different background scheme in the **Personalization** Tool. Once correctly installed, the icon will look like this (on an already customized Easy Mode Settings tab): {{howto:customized_easy_mode_with_touchkit_icon.png|Customized Easy Mode with Touchkit icon}} ======Further reading====== Any post by forum user **gfoot** :) - the man who made this possible and helped along the way! The original forum posts: * **Problems with drivers for kiddshop touchscreen** http://forum.eeeuser.com/viewtopic.php?pid=233900 * **how to get fido touchscreen working in xandros** http://forum.eeeuser.com/viewtopic.php?id=18677 * **Status of the touchscreen modding scene?** http://forum.eeeuser.com/viewtopic.php?id=22880 Forum user **gospeed.racer** (http://forum.eeeuser.com/profile.php?id=4888) builds internal USB hubs, which allow users of model 701 4G (the one with a webcam) to connect a touchscreen **AND** the webcam at the same time. Other people in the Hack and Modifications forum have built similar hubs.