1

I am trying to understand the touchscreens. And I came across these two kernel modules: usbtouchscreen and usbhid. I am confused as what is exactly the difference ? Lets assume I have a touchscreen connected to my hardware via USB, which among the two should I be using ? I know the obvious answer would be: try installing either and see if it works.

But what I am looking for is :

what is the data sent by these two drivers for a USB touchscreen, in case of either USBHID and plain usbtouchscreen?

And how does evdevconvert those different data packets/info into unified touch events ?

Monku
  • 267

1 Answers1

2

A HID (“human interface device”) is a device that is intended to allow humans to interact with the computer, such as a keyboard, a mouse, a monitor, a microphone, a loudspeaker, etc.

USB defines a number of standard device classes: types of devices with some common properties. One of them is HID, which in the context of USB only covers low-bandwidth devices: mostly input devices such as keyboards, mice, joysticks, touchscreen input, etc.

A touchscreen requires features that are not in the basic HID protocol (at least if it supports multitouch), so touchscreens can't be handled by a pure HID driver. Linux has a usbtouchscreen module which supports many USB touchscreen models.

In any case, USB devices identify themselves, and USB drivers know what device identification they support. Linux automatically loads the right driver for USB devices. See Are driver modules loaded and unloaded automatically? and Debian does not detect serial PCI card after reboot