]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - share/man/man4/cyapa.4
Remove $FreeBSD$: two-line nroff pattern
[FreeBSD/FreeBSD.git] / share / man / man4 / cyapa.4
1 .\" Copyright (c) 2015 Michael Gmelin <freebsd@grem.de>
2 .\" All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 .\" SUCH DAMAGE.
24 .\"
25 .Dd December 18, 2018
26 .Dt CYAPA 4
27 .Os
28 .Sh NAME
29 .Nm cyapa
30 .Nd Cypress APA trackpad with I2C interface driver
31 .Sh SYNOPSIS
32 To compile this driver into the kernel, place the following lines into
33 the kernel configuration file:
34 .Bd -ragged -offset indent
35 .Cd "device cyapa"
36 .Cd "device ig4"
37 .Cd "device iicbus"
38 .Ed
39 .Pp
40 Alternatively, to load the driver as a module at boot time, place the following line in
41 .Xr loader.conf 5 :
42 .Bd -literal -offset indent
43 cyapa_load="YES"
44 ig4_load="YES"
45 .Ed
46 .Pp
47 On many Chromebook models this driver can be automatically configured with the
48 help of the
49 .Xr chromebook_platform 4
50 driver.
51 Alternatively, the
52 .Nm
53 driver can be manually configured in
54 .Pa /boot/device.hints :
55 .Cd hint.cyapa.0.at="iicbus0"
56 .Cd hint.cyapa.0.addr="0xCE"
57 .Cd hint.cyapa.1.at="iicbus1"
58 .Cd hint.cyapa.1.addr="0xCE"
59 .Sh DESCRIPTION
60 The
61 .Nm
62 driver provides support for the Cypress APA trackpad.
63 It emulates the IntelliMouse PS/2 protocol.
64 It supports basic mouse ioctls, so that
65 .Xr moused 8
66 is supported properly.
67 .Ss Trackpad layout
68 .Bd -literal
69                    2/3               1/3
70           +--------------------+------------+
71           |                    |   Middle   |
72           |                    |   Button   |
73           |       Left         |            |
74           |      Button        +------------+
75           |                    |   Right    |
76           |                    |   Button   |
77           +--------------------+............|
78           |     Thumb/Button Area           | 15%
79           +---------------------------------+
80 .Ed
81 .Ss Trackpad features
82 .Bl -tag -width 8n
83 .It Va Two finger scrolling
84 Use two fingers for Z axis scrolling.
85 .It Va Button down/second finger
86 While one finger clicks and holds down the touchpad, the second finger can be
87 used to move the mouse cursor.
88 This can be useful for drawing or selecting text.
89 .It Va Thumb/Button area
90 The lower 15% of the trackpad will not affect the mouse cursor position.
91 This allows for high precision clicking, by controlling the cursor with the
92 index finger and pushing/holding the pad down with the thumb.
93 .It Va Trackpad button
94 Push physical button.
95 The left two thirds of the pad issues a LEFT button event.
96 The upper right corner issues a MIDDLE button event.
97 The lower right corner issues a RIGHT button.
98 Optionally, tap to click can be enabled (see below).
99 .El
100 .Pp
101 On a system using
102 .Xr device.hints 5 ,
103 these values are configurable for
104 .Nm :
105 .Bl -tag -width "hint.cyapa.%d.addr"
106 .It Va hint.cyapa.%d.at
107 target
108 .Xr iicbus 4 .
109 .It Va hint.cyapa.%d.addr
110 .Nm
111 i2c address on the
112 .Xr iicbus 4 .
113 .El
114 .Sh SYSCTL VARIABLES
115 These
116 .Xr sysctl 8
117 variables are available:
118 .Bl -tag -width 8n
119 .It Va debug.cyapa_idle_freq
120 Scan frequency in idle mode, the default is 1.
121 .It Va debug.cyapa_slow_freq
122 Scan frequency in slow mode, the default is 20.
123 .It Va debug.cyapa_norm_freq
124 Scan frequency in normal mode, the default is 100.
125 .It Va debug.cyapa_minpressure
126 Minimum pressure to detect a finger, the default is 12.
127 .It Va debug.cyapa_enable_tapclick
128 Controls tap to click.
129 Possible values:
130 .Bl -tag -width 8n
131 .It 0
132 Tap to click is disabled.
133 This is the default value.
134 .It 1
135 Tap to click always generates a left mouse button event.
136 .It 2
137 Tap to click generates left mouse button event if the left 2/3rds of the pad
138 are tapped and a right mouse button event otherwise.
139 .It 3
140 Tap to click generates mouse button events as if the physical button was
141 pressed (see
142 .Sx DESCRIPTION
143 above).
144 .El
145 .It Va debug.cyapa_tapclick_min_ticks
146 Minimum tap duration in ticks to create a click, the default is 1.
147 .It Va debug.cyapa_tapclick_max_ticks
148 Maximum tap duration in ticks to create a click, the default is 8.
149 .It Va debug.cyapa_move_min_ticks
150 Minimum ticks before cursor movement occurs, the default is 4.
151 .It Va debug.cyapa_scroll_wait_ticks
152 Ticks to wait before starting to scroll, the default is 0.
153 .It Va debug.cyapa_scroll_stick_ticks
154 Ticks while preventing cursor movement on single finger after scroll,
155 the default is 15.
156 .It Va debug.cyapa_thumbarea_percent
157 Size of bottom thumb area in percent, the default is 15.
158 .It Va debug.cyapa_debug
159 Setting this to a non-zero value enables debug output to console and syslog,
160 the default is 0.
161 .It Va debug.cyapa_reset
162 Setting this to a non-zero value reinitializes the device.
163 The sysctl resets to zero immediately.
164 .El
165 .Sh FILES
166 .Nm
167 creates
168 .Pa /dev/cyapa0 ,
169 which presents the mouse as an
170 .Ar IntelliMouse PS/2
171 device.
172 It supports
173 .Xr moused 8
174 levels 0 through 2, level 1 is used by default.
175 .Sh EXAMPLES
176 To use
177 .Nm
178 with
179 .Xr moused 8 ,
180 add the following lines to the
181 .Xr rc.conf 5
182 file:
183 .Pp
184 .Dl moused_enable="YES"
185 .Dl moused_port="/dev/cyapa0"
186 .Pp
187 If vertical scrolling is not desired, add
188 .Pp
189 .Dl moused_flags="-l0"
190 .Pp
191 to
192 .Xr rc.conf 5 .
193 .Pp
194 Enable tap to click for the left and the right mouse button and
195 disable the thumb area by adding these lines to the
196 .Xr sysctl.conf 5
197 file:
198 .Pp
199 .Dl debug.cyapa_thumbarea_percent=0
200 .Dl debug.cyapa_enable_tapclick=2
201 .Sh SEE ALSO
202 .Xr chromebook_platform 4 ,
203 .Xr ig4 4 ,
204 .Xr iicbus 4 ,
205 .Xr sysmouse 4 ,
206 .Xr moused 8
207 .Sh AUTHORS
208 .An -nosplit
209 The original
210 .Nm
211 driver was written for
212 .Dx
213 by
214 .An Matthew Dillon .
215 .Pp
216 It has been ported, modified, and enhanced for
217 .Fx
218 by
219 .An Michael Gmelin Aq Mt freebsd@grem.de .
220 .Pp
221 This manual page was written by
222 .An Michael Gmelin Aq Mt freebsd@grem.de .
223 .Sh BUGS
224 The
225 .Nm
226 driver detects the device from the I2C address.
227 This might have unforeseen consequences if the initialization sequence
228 is sent to an unknown device at that address.