xref: /netbsd/share/man/man4/pms.4 (revision 6550d01e)
1.\" $NetBSD: pms.4,v 1.24 2008/12/14 13:51:33 wiz Exp $
2.\"
3.\" Copyright (c) 1993 Christopher G. Demetriou
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\" 3. All advertising materials mentioning features or use of this software
15.\"    must display the following acknowledgement:
16.\"          This product includes software developed for the
17.\"          NetBSD Project.  See http://www.NetBSD.org/ for
18.\"          information about NetBSD.
19.\" 4. The name of the author may not be used to endorse or promote products
20.\"    derived from this software without specific prior written permission.
21.\"
22.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
23.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
24.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
25.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
26.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
27.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
31.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32.\"
33.\" <<Id: LICENSE,v 1.2 2000/06/14 15:57:33 cgd Exp>>
34.\"
35.Dd December 13, 2008
36.Dt PMS 4
37.Os
38.Sh NAME
39.Nm pms
40.Nd PS/2 auxiliary port mouse driver
41.Sh SYNOPSIS
42.Cd pckbc* at isa?
43.Cd pms* at pckbc?
44.Cd wsmouse* at pms?
45.Pp
46.Cd options PMS_DISABLE_POWERHOOK
47.Cd options PMS_SYNAPTICS_TOUCHPAD
48.Cd options PMS_ELANTECH_TOUCHPAD
49.Sh DESCRIPTION
50The
51.Nm
52driver provides an interface to PS/2 auxiliary port mice within the
53.Xr wscons 4
54framework.
55Parent device in terms of the autoconfiguration framework is
56.Xr pckbc 4 ,
57the PC keyboard controller.
58.Dq pms
59is a generic driver which supports mice using common variants of the PS/2
60protocol, including wheel mice of the
61.Dq IntelliMouse
62breed.
63Wheel movements are mapped to a third (z-) axis.
64The driver is
65believed to work with both 3-button and 5-button mice with scroll wheels.
66Mice which use other protocol extensions are not currently supported, but
67might be if protocol documentation could be found.
68Mouse related data are accessed by
69.Xr wsmouse 4
70devices.
71.Pp
72The
73.Nm
74driver has been updated to attempt to renegotiate mouse protocol after seeing
75suspicious or defective mouse protocol packets, or unusual delays in the
76middle of a packet; this should improve the chances that a mouse will recover
77after being switched away or reset (for instance, by a console switch).
78.Pp
79The
80.Va PMS_DISABLE_POWERHOOK
81kernel option disables PS/2 reset on resume.
82.Pp
83In addition, the
84.Nm
85driver supports the
86.Dq Synaptics
87and
88.Dq Elantech
89touchpads in native mode, enabled with the
90.Va PMS_SYNAPTICS_TOUCHPAD
91and
92.Va PMS_ELANTECH_TOUCHPAD
93kernel options.
94This allows the driver to take advantage of extra
95features available on Synaptics and Elantech Touchpads.
96The following
97.Xr sysctl 8
98variables control behavior of Synaptics touchpads:
99.Bl -tag
100.It Dv hw.synaptics.up_down_emulation
101If the touchpad reports the existence of Up/Down buttons, this value
102determines if they should be reported as button 4 and 5 events or if
103they should be used to emulate some other event.
104When set to 0, report Up/Down events as buttons 4 and 5.
105When set to 1, the Up and Down buttons are both mapped to the middle button.
106When set to 2 (default), the Up and Down buttons are used for Z-axis
107emulation, which more closely resembles how mouse wheels operate.
108.It Dv hw.synaptics.up_down_motion_delta
109When the Up/Down buttons are used for Z-axis emulation, this value specifies
110the emulated delta-Z value per click.
111.It Dv hw.synaptics.gesture_move
112Gestures will not be recognised if the finger moves by more than this
113amount between taps.
114.It Dv hw.synaptics.gesture_length
115Gestures will not be recognised if the number of packets (at 80 packets
116per second) between taps exceeds this value.
117.It Dv hw.synaptics.edge_left
118.It Dv hw.synaptics.edge_right
119.It Dv hw.synaptics.edge_top
120.It Dv hw.synaptics.edge_bottom
121These values define a border around the touchpad which will be used for
122edge motion emulation during a drag gesture.
123If a drag gesture is in progress and the finger moves into this border,
124the driver will behave as if the finger continues to move in the same
125direction beyond the edge of the touchpad.
126.It Dv hw.synaptics.edge_motion_delta
127This specifies the pointer speed when edge motion is in effect.
128.It Dv hw.synaptics.finger_high
129The driver will ignore new finger events until the reported pressure exceeds
130this value.
131.It Dv hw.synaptics.finger_low
132The driver will assume a finger remains on the touchpad until the
133reported pressure drops below this value.
134.It Dv hw.synaptics.two_fingers_emulation
135More recent touchpads can report the presence of more than one finger
136on the pad.
137This value determines how such events are used.
138If set to 0 (default), two-finger events are ignored.
139If set to 1, two-finger events generate a right button click.
140If set to 2, two-finger events generate a middle button click.
141.It Dv hw.synaptics.scale_x
142.It Dv hw.synaptics.scale_y
143Scale factor used to divide movement deltas derived from Synaptics
144coordinates (0-6143) to yield more reasonable values (default 16).
145.It Dv hw.synaptics.max_speed_x
146.It Dv hw.synaptics.max_speed_y
147Limits pointer rate of change (after scaling) per reported movement
148event (default 32).
149.It Dv hw.synaptics.movement_threshold
150Movements of less than this value (in Synaptics coordinates) are
151ignored (default 4).
152.El
153.Pp
154The following
155.Xr sysctl 8
156variables control behavior of Elantech touchpads:
157.Bl -tag
158.It Dv hw.elantech.xy_precision_shift
159.It Dv hw.elantech.z_precision_shift
160Increased values improve the accuracy of X, Y, and Z-axis reporting
161at the expense of slower mouse movement (default 2 for xy,
162and 3 for z).
163.El
164.Pp
165For Elantech touchpads, the Z-axis is emulated using two-finger
166Y-axis reporting.
167.Sh SEE ALSO
168.Xr pckbc 4 ,
169.Xr ums 4 ,
170.Xr wsmouse 4
171.Sh AUTHORS
172The
173.Nm
174driver was originally written by Christopher G. Demetriou.
175The changes to merge the
176.Dq IntelliMouse
177protocol in, and reset the mouse in the event of protocol problems, were
178contributed by Peter Seebach.
179Special thanks to Ray Trent, at Synaptics, who contributed valuable
180insight into how to identify bogus mouse data.
181The changes to add
182.Dq Synaptics
183pad support were by Ales Krenek, Kentaro A. Kurahone, and Steve C. Woodford.
184The changes to add
185.Dq Elantech
186pad support were by Jared D. McNeill.
187.Sh BUGS
188It is possible for the driver to mistakenly negotiate the non-scroll-wheel
189protocol, after which it is unlikely to recover until the device is closed
190and reopened.
191.Pp
192The
193.Dq Elantech
194pad code only supports trackpads with firmware version 2.48 or above.
195