Re: Request help for Linux mouse driver

Miquel van Smoorenburg (miquels@cistron.nl)
6 Aug 1999 12:22:05 +0200


In article <cistron.19990806051121.23908.fmail@163.net>,
<ytwei@163.net> wrote:
>Alessandro,
>
>Hi, I am a software engineer from China. The company, for which I served, want me to develop the Linux mouse driver for the Company's product--Genius Netscroll mouse. The aim is to implement the scroll function in Linux (as in MS Windows).

The Linux kernel does not implement a generic mouse driver. It just offers
a few interfaces an application can use to read the mouse status, and that
interface differs per mouse type. Eg /dev/ttyS0 for a serial mouse and
/dev/psaux for a PS/2 style mouse.

>2. In "Mouse Configuration" of "setup", there is an item "Genius Netscroll (PS/2)". For testing the Netscroll mouse, I selected it. However, the mouse can not work well, especially in X-Windows. So, what's wrong?

X uses the above mentioned interfaces in /dev to get mouse status. The
rest is implemented in X. So, if you want to make it possible to use
the scroll button in X, you need to fix the mouse driver in Xfree86,
not in the Linux kernel as the kernel doesn't really have a mouse driver.

>3. Here are a serial of questions:
>3.1 Whether Linux supports the scrolling function of the mouse? I can not find where it exists.

The kernel, no. It doesn't even know about mouse buttons etc. Xfree86?
Yes. I have a Logitech M-C48 here, and I can use the scroll button.
I had to put this in my /etc/X11/XF86Config:

Section "Pointer"
Protocol "IMPS/2"
Device "/dev/psaux"
ZAxisMapping 4 5

... now the scroll button is mapped to the ZAxis. Ofcourse the application
needs to know what to do with this as well. How to do that for Xterm
and Netscape is described at http://www4.ncsu.edu:8030/~bcwatson/

>3.2 If the answer to '3.1' is "no", could you tell me if we shall add this new function.
>3.3 If the answer to '3.2' is "yes", please tell me the steps & operations.

The Genius netscroll mouse is already supported by Xfree86. See
http://www.xfree86.org/3.3.2/mouse28.html#28

In short no need to develop anything, your mouse and the scroll button
are already well supported.

Mike.

-- 
... somehow I have a feeling the hurting hasn't even begun yet
	-- Bill, "The Terrible Thunderlizards"

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/