From: Johan Myreen (jem@snakemail.hut.fi)
Date: 02/21/93


From: jem@snakemail.hut.fi (Johan Myreen)
Subject: Mouse tutorial (Was: Re: Post-FAQ question: PS/2 mouse ...)
Date: 21 Feb 1993 12:59:29 GMT


David Fox writes:

>The package the mouse came in says "Serial and Mouseport version";
>perhaps this is not a busmouse at all as I have been told? It
>seems like a mouseport should just be a disguised serial port,
>but I've tried ttyS1 thru ttyS3 with no success.

>I'm wondering what a busmouse
>really is, and how it relates to the "ps/2" style mouse,
>and the mouse ports found on most laptops? Due to the thin
>response, speculation is welcome.

The types of pointing device interfaces Linux currently supports can
be categorized into three classes:

1. Serial

These connect to a serial port on the machine, and the application
(e.g. X11) picks up the mouse movements by reading the serial port
(/dev/ttySN, where N = 0,1,2 etc.) A serial mouse usually sends data
in a stream of three byte packets containing button state information
and deltas for the X and Y directions. Unfortunately, the protocol
(ie. the meanings of the bits in the packet) is not standardised; the
Microsoft protocol is perhaps the most widely used. Note that there is
no support for serial mice in the Linux kernel per se; the application
communicates with the mouse via the standard serial drivers.

2. Bus

This kind of mice connect to an expansion board, which is plugged into
the expansion bus on the computer. The three types of busmouse Linux
knows of are the Microsoft InPort mouse (the "Microsoft busmouse"),
the Logitech busmouse and the mouse port on the ATI/XL graphics card.
The card collects movement and button state information from the mouse
and, when the mouse has moved, generates an interrupt. The movement
and button state info is then presented to the mouse driver at an I/O
address.

3. PS/2

This is a mouse interface introduced with the PS/2 line of computers.
It uses the keyboard controller (usually a 8042 microcontroller) on
the motherboard to communicate with the mouse. The mouse interface is
both mechanically and electrically similar to the keyboard interface:
a 6-pin mini-DIN plug with clock, data, +5Vdc and ground pins. IBM
refers to this as the Auxiliary Device Connector, intended for
pointing devices (but not restricted to mice.) Data is transmitted
serially, synchronized to the clock signal. Although transmission is
synchronous, start and stop bits are used, which makes the protocol
very similar to asynch transmission. Some PS/2 mice know how to act
both as a serial mouse and a PS/2 mouseport mouse. This is the type of
mouse found on most newer laptops.