~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/Documentation/input/devices/elantech.rst

Version: ~ [ linux-6.11.5 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.58 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.114 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.169 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.228 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.284 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.322 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

Diff markup

Differences between /Documentation/input/devices/elantech.rst (Version linux-6.11.5) and /Documentation/input/devices/elantech.rst (Version linux-4.13.16)


  1 Elantech Touchpad Driver                            1 Elantech Touchpad Driver
  2 ========================                            2 ========================
  3                                                     3 
  4         Copyright (C) 2007-2008 Arjan Opmeer <a      4         Copyright (C) 2007-2008 Arjan Opmeer <arjan@opmeer.net>
  5                                                     5 
  6         Extra information for hardware version      6         Extra information for hardware version 1 found and
  7         provided by Steve Havelka                   7         provided by Steve Havelka
  8                                                     8 
  9         Version 2 (EeePC) hardware support bas      9         Version 2 (EeePC) hardware support based on patches
 10         received from Woody at Xandros and for     10         received from Woody at Xandros and forwarded to me
 11         by user StewieGriffin at the eeeuser.c     11         by user StewieGriffin at the eeeuser.com forum
 12                                                    12 
 13 .. Contents                                        13 .. Contents
 14                                                    14 
 15  1. Introduction                                   15  1. Introduction
 16  2. Extra knobs                                    16  2. Extra knobs
 17  3. Differentiating hardware versions              17  3. Differentiating hardware versions
 18  4. Hardware version 1                             18  4. Hardware version 1
 19     4.1 Registers                                  19     4.1 Registers
 20     4.2 Native relative mode 4 byte packet for     20     4.2 Native relative mode 4 byte packet format
 21     4.3 Native absolute mode 4 byte packet for     21     4.3 Native absolute mode 4 byte packet format
 22  5. Hardware version 2                             22  5. Hardware version 2
 23     5.1 Registers                                  23     5.1 Registers
 24     5.2 Native absolute mode 6 byte packet for     24     5.2 Native absolute mode 6 byte packet format
 25         5.2.1 Parity checking and packet re-sy     25         5.2.1 Parity checking and packet re-synchronization
 26         5.2.2 One/Three finger touch               26         5.2.2 One/Three finger touch
 27         5.2.3 Two finger touch                     27         5.2.3 Two finger touch
 28  6. Hardware version 3                             28  6. Hardware version 3
 29     6.1 Registers                                  29     6.1 Registers
 30     6.2 Native absolute mode 6 byte packet for     30     6.2 Native absolute mode 6 byte packet format
 31         6.2.1 One/Three finger touch               31         6.2.1 One/Three finger touch
 32         6.2.2 Two finger touch                     32         6.2.2 Two finger touch
 33  7. Hardware version 4                             33  7. Hardware version 4
 34     7.1 Registers                                  34     7.1 Registers
 35     7.2 Native absolute mode 6 byte packet for     35     7.2 Native absolute mode 6 byte packet format
 36         7.2.1 Status packet                        36         7.2.1 Status packet
 37         7.2.2 Head packet                          37         7.2.2 Head packet
 38         7.2.3 Motion packet                        38         7.2.3 Motion packet
 39  8. Trackpoint (for Hardware version 3 and 4)      39  8. Trackpoint (for Hardware version 3 and 4)
 40     8.1 Registers                                  40     8.1 Registers
 41     8.2 Native relative mode 6 byte packet for     41     8.2 Native relative mode 6 byte packet format
 42         8.2.1 Status Packet                        42         8.2.1 Status Packet
 43                                                    43 
 44                                                    44 
 45                                                    45 
 46 Introduction                                       46 Introduction
 47 ~~~~~~~~~~~~                                       47 ~~~~~~~~~~~~
 48                                                    48 
 49 Currently the Linux Elantech touchpad driver i     49 Currently the Linux Elantech touchpad driver is aware of four different
 50 hardware versions unimaginatively called versi     50 hardware versions unimaginatively called version 1,version 2, version 3
 51 and version 4. Version 1 is found in "older" l     51 and version 4. Version 1 is found in "older" laptops and uses 4 bytes per
 52 packet. Version 2 seems to be introduced with      52 packet. Version 2 seems to be introduced with the EeePC and uses 6 bytes
 53 per packet, and provides additional features s     53 per packet, and provides additional features such as position of two fingers,
 54 and width of the touch.  Hardware version 3 us     54 and width of the touch.  Hardware version 3 uses 6 bytes per packet (and
 55 for 2 fingers the concatenation of two 6 bytes     55 for 2 fingers the concatenation of two 6 bytes packets) and allows tracking
 56 of up to 3 fingers. Hardware version 4 uses 6      56 of up to 3 fingers. Hardware version 4 uses 6 bytes per packet, and can
 57 combine a status packet with multiple head or      57 combine a status packet with multiple head or motion packets. Hardware version
 58 4 allows tracking up to 5 fingers.                 58 4 allows tracking up to 5 fingers.
 59                                                    59 
 60 Some Hardware version 3 and version 4 also hav     60 Some Hardware version 3 and version 4 also have a trackpoint which uses a
 61 separate packet format. It is also 6 bytes per     61 separate packet format. It is also 6 bytes per packet.
 62                                                    62 
 63 The driver tries to support both hardware vers     63 The driver tries to support both hardware versions and should be compatible
 64 with the Xorg Synaptics touchpad driver and it     64 with the Xorg Synaptics touchpad driver and its graphical configuration
 65 utilities.                                         65 utilities.
 66                                                    66 
 67 Note that a mouse button is also associated wi     67 Note that a mouse button is also associated with either the touchpad or the
 68 trackpoint when a trackpoint is available.  Di     68 trackpoint when a trackpoint is available.  Disabling the Touchpad in xorg
 69 (TouchPadOff=0) will also disable the buttons      69 (TouchPadOff=0) will also disable the buttons associated with the touchpad.
 70                                                    70 
 71 Additionally the operation of the touchpad can     71 Additionally the operation of the touchpad can be altered by adjusting the
 72 contents of some of its internal registers. Th     72 contents of some of its internal registers. These registers are represented
 73 by the driver as sysfs entries under /sys/bus/     73 by the driver as sysfs entries under /sys/bus/serio/drivers/psmouse/serio?
 74 that can be read from and written to.              74 that can be read from and written to.
 75                                                    75 
 76 Currently only the registers for hardware vers     76 Currently only the registers for hardware version 1 are somewhat understood.
 77 Hardware version 2 seems to use some of the sa     77 Hardware version 2 seems to use some of the same registers but it is not
 78 known whether the bits in the registers repres     78 known whether the bits in the registers represent the same thing or might
 79 have changed their meaning.                        79 have changed their meaning.
 80                                                    80 
 81 On top of that, some register settings have ef     81 On top of that, some register settings have effect only when the touchpad is
 82 in relative mode and not in absolute mode. As      82 in relative mode and not in absolute mode. As the Linux Elantech touchpad
 83 driver always puts the hardware into absolute      83 driver always puts the hardware into absolute mode not all information
 84 mentioned below can be used immediately. But b     84 mentioned below can be used immediately. But because there is no freely
 85 available Elantech documentation the informati     85 available Elantech documentation the information is provided here anyway for
 86 completeness sake.                                 86 completeness sake.
 87                                                    87 
 88                                                    88 
 89 Extra knobs                                        89 Extra knobs
 90 ~~~~~~~~~~~                                        90 ~~~~~~~~~~~
 91                                                    91 
 92 Currently the Linux Elantech touchpad driver p     92 Currently the Linux Elantech touchpad driver provides three extra knobs under
 93 /sys/bus/serio/drivers/psmouse/serio? for the      93 /sys/bus/serio/drivers/psmouse/serio? for the user.
 94                                                    94 
 95 * debug                                            95 * debug
 96                                                    96 
 97    Turn different levels of debugging ON or OF     97    Turn different levels of debugging ON or OFF.
 98                                                    98 
 99    By echoing "0" to this file all debugging w     99    By echoing "0" to this file all debugging will be turned OFF.
100                                                   100 
101    Currently a value of "1" will turn on some     101    Currently a value of "1" will turn on some basic debugging and a value of
102    "2" will turn on packet debugging. For hard    102    "2" will turn on packet debugging. For hardware version 1 the default is
103    OFF. For version 2 the default is "1".         103    OFF. For version 2 the default is "1".
104                                                   104 
105    Turning packet debugging on will make the d    105    Turning packet debugging on will make the driver dump every packet
106    received to the syslog before processing it    106    received to the syslog before processing it. Be warned that this can
107    generate quite a lot of data!                  107    generate quite a lot of data!
108                                                   108 
109 * paritycheck                                     109 * paritycheck
110                                                   110 
111    Turns parity checking ON or OFF.               111    Turns parity checking ON or OFF.
112                                                   112 
113    By echoing "0" to this file parity checking    113    By echoing "0" to this file parity checking will be turned OFF. Any
114    non-zero value will turn it ON. For hardwar    114    non-zero value will turn it ON. For hardware version 1 the default is ON.
115    For version 2 the default it is OFF.           115    For version 2 the default it is OFF.
116                                                   116 
117    Hardware version 1 provides basic data inte    117    Hardware version 1 provides basic data integrity verification by
118    calculating a parity bit for the last 3 byt    118    calculating a parity bit for the last 3 bytes of each packet. The driver
119    can check these bits and reject any packet     119    can check these bits and reject any packet that appears corrupted. Using
120    this knob you can bypass that check.           120    this knob you can bypass that check.
121                                                   121 
122    Hardware version 2 does not provide the sam    122    Hardware version 2 does not provide the same parity bits. Only some basic
123    data consistency checking can be done. For     123    data consistency checking can be done. For now checking is disabled by
124    default. Currently even turning it on will     124    default. Currently even turning it on will do nothing.
125                                                   125 
126 * crc_enabled                                     126 * crc_enabled
127                                                   127 
128    Sets crc_enabled to 0/1. The name "crc_enab    128    Sets crc_enabled to 0/1. The name "crc_enabled" is the official name of
129    this integrity check, even though it is not    129    this integrity check, even though it is not an actual cyclic redundancy
130    check.                                         130    check.
131                                                   131 
132    Depending on the state of crc_enabled, cert    132    Depending on the state of crc_enabled, certain basic data integrity
133    verification is done by the driver on hardw    133    verification is done by the driver on hardware version 3 and 4. The
134    driver will reject any packet that appears     134    driver will reject any packet that appears corrupted. Using this knob,
135    The state of crc_enabled can be altered wit    135    The state of crc_enabled can be altered with this knob.
136                                                   136 
137    Reading the crc_enabled value will show the    137    Reading the crc_enabled value will show the active value. Echoing
138    "0" or "1" to this file will set the state     138    "0" or "1" to this file will set the state to "0" or "1".
139                                                   139 
140 Differentiating hardware versions                 140 Differentiating hardware versions
141 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~                 141 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
142                                                   142 
143 To detect the hardware version, read the versi    143 To detect the hardware version, read the version number as param[0].param[1].param[2]::
144                                                   144 
145  4 bytes version: (after the arrow is the name    145  4 bytes version: (after the arrow is the name given in the Dell-provided driver)
146  02.00.22 => EF013                                146  02.00.22 => EF013
147  02.06.00 => EF019                                147  02.06.00 => EF019
148                                                   148 
149 In the wild, there appear to be more versions,    149 In the wild, there appear to be more versions, such as 00.01.64, 01.00.21,
150 02.00.00, 02.00.04, 02.00.06::                    150 02.00.00, 02.00.04, 02.00.06::
151                                                   151 
152  6 bytes:                                         152  6 bytes:
153  02.00.30 => EF113                                153  02.00.30 => EF113
154  02.08.00 => EF023                                154  02.08.00 => EF023
155  02.08.XX => EF123                                155  02.08.XX => EF123
156  02.0B.00 => EF215                                156  02.0B.00 => EF215
157  04.01.XX => Scroll_EF051                         157  04.01.XX => Scroll_EF051
158  04.02.XX => EF051                                158  04.02.XX => EF051
159                                                   159 
160 In the wild, there appear to be more versions,    160 In the wild, there appear to be more versions, such as 04.03.01, 04.04.11. There
161 appears to be almost no difference, except for    161 appears to be almost no difference, except for EF113, which does not report
162 pressure/width and has different data consiste    162 pressure/width and has different data consistency checks.
163                                                   163 
164 Probably all the versions with param[0] <= 01     164 Probably all the versions with param[0] <= 01 can be considered as
165 4 bytes/firmware 1. The versions < 02.08.00, w    165 4 bytes/firmware 1. The versions < 02.08.00, with the exception of 02.00.30, as
166 4 bytes/firmware 2. Everything >= 02.08.00 can    166 4 bytes/firmware 2. Everything >= 02.08.00 can be considered as 6 bytes.
167                                                   167 
168                                                   168 
169 Hardware version 1                                169 Hardware version 1
170 ~~~~~~~~~~~~~~~~~~                                170 ~~~~~~~~~~~~~~~~~~
171                                                   171 
172 Registers                                         172 Registers
173 ---------                                         173 ---------
174                                                   174 
175 By echoing a hexadecimal value to a register i    175 By echoing a hexadecimal value to a register it contents can be altered.
176                                                   176 
177 For example::                                     177 For example::
178                                                   178 
179    echo -n 0x16 > reg_10                          179    echo -n 0x16 > reg_10
180                                                   180 
181 * reg_10::                                        181 * reg_10::
182                                                   182 
183    bit   7   6   5   4   3   2   1   0            183    bit   7   6   5   4   3   2   1   0
184          B   C   T   D   L   A   S   E            184          B   C   T   D   L   A   S   E
185                                                   185 
186          E: 1 = enable smart edges uncondition    186          E: 1 = enable smart edges unconditionally
187          S: 1 = enable smart edges only when d    187          S: 1 = enable smart edges only when dragging
188          A: 1 = absolute mode (needs 4 byte pa    188          A: 1 = absolute mode (needs 4 byte packets, see reg_11)
189          L: 1 = enable drag lock (see reg_22)     189          L: 1 = enable drag lock (see reg_22)
190          D: 1 = disable dynamic resolution        190          D: 1 = disable dynamic resolution
191          T: 1 = disable tapping                   191          T: 1 = disable tapping
192          C: 1 = enable corner tap                 192          C: 1 = enable corner tap
193          B: 1 = swap left and right button        193          B: 1 = swap left and right button
194                                                   194 
195 * reg_11::                                        195 * reg_11::
196                                                   196 
197    bit   7   6   5   4   3   2   1   0            197    bit   7   6   5   4   3   2   1   0
198          1   0   0   H   V   1   F   P            198          1   0   0   H   V   1   F   P
199                                                   199 
200          P: 1 = enable parity checking for rel    200          P: 1 = enable parity checking for relative mode
201          F: 1 = enable native 4 byte packet mo    201          F: 1 = enable native 4 byte packet mode
202          V: 1 = enable vertical scroll area       202          V: 1 = enable vertical scroll area
203          H: 1 = enable horizontal scroll area     203          H: 1 = enable horizontal scroll area
204                                                   204 
205 * reg_20::                                        205 * reg_20::
206                                                   206 
207          single finger width?                     207          single finger width?
208                                                   208 
209 * reg_21::                                        209 * reg_21::
210                                                   210 
211          scroll area width (small: 0x40 ... wi    211          scroll area width (small: 0x40 ... wide: 0xff)
212                                                   212 
213 * reg_22::                                        213 * reg_22::
214                                                   214 
215          drag lock time out (short: 0x14 ... l    215          drag lock time out (short: 0x14 ... long: 0xfe;
216                              0xff = tap again     216                              0xff = tap again to release)
217                                                   217 
218 * reg_23::                                        218 * reg_23::
219                                                   219 
220          tap make timeout?                        220          tap make timeout?
221                                                   221 
222 * reg_24::                                        222 * reg_24::
223                                                   223 
224          tap release timeout?                     224          tap release timeout?
225                                                   225 
226 * reg_25::                                        226 * reg_25::
227                                                   227 
228          smart edge cursor speed (0x02 = slow,    228          smart edge cursor speed (0x02 = slow, 0x03 = medium, 0x04 = fast)
229                                                   229 
230 * reg_26::                                        230 * reg_26::
231                                                   231 
232          smart edge activation area width?        232          smart edge activation area width?
233                                                   233 
234                                                   234 
235 Native relative mode 4 byte packet format         235 Native relative mode 4 byte packet format
236 -----------------------------------------         236 -----------------------------------------
237                                                   237 
238 byte 0::                                          238 byte 0::
239                                                   239 
240    bit   7   6   5   4   3   2   1   0            240    bit   7   6   5   4   3   2   1   0
241          c   c  p2  p1   1   M   R   L            241          c   c  p2  p1   1   M   R   L
242                                                   242 
243          L, R, M = 1 when Left, Right, Middle     243          L, R, M = 1 when Left, Right, Middle mouse button pressed
244             some models have M as byte 3 odd p    244             some models have M as byte 3 odd parity bit
245          when parity checking is enabled (reg_    245          when parity checking is enabled (reg_11, P = 1):
246             p1..p2 = byte 1 and 2 odd parity b    246             p1..p2 = byte 1 and 2 odd parity bit
247          c = 1 when corner tap detected           247          c = 1 when corner tap detected
248                                                   248 
249 byte 1::                                          249 byte 1::
250                                                   250 
251    bit   7   6   5   4   3   2   1   0            251    bit   7   6   5   4   3   2   1   0
252         dx7 dx6 dx5 dx4 dx3 dx2 dx1 dx0           252         dx7 dx6 dx5 dx4 dx3 dx2 dx1 dx0
253                                                   253 
254          dx7..dx0 = x movement;   positive = r    254          dx7..dx0 = x movement;   positive = right, negative = left
255          byte 1 = 0xf0 when corner tap detecte    255          byte 1 = 0xf0 when corner tap detected
256                                                   256 
257 byte 2::                                          257 byte 2::
258                                                   258 
259    bit   7   6   5   4   3   2   1   0            259    bit   7   6   5   4   3   2   1   0
260         dy7 dy6 dy5 dy4 dy3 dy2 dy1 dy0           260         dy7 dy6 dy5 dy4 dy3 dy2 dy1 dy0
261                                                   261 
262          dy7..dy0 = y movement;   positive = u    262          dy7..dy0 = y movement;   positive = up,    negative = down
263                                                   263 
264 byte 3::                                          264 byte 3::
265                                                   265 
266    parity checking enabled (reg_11, P = 1):       266    parity checking enabled (reg_11, P = 1):
267                                                   267 
268       bit   7   6   5   4   3   2   1   0         268       bit   7   6   5   4   3   2   1   0
269             w   h  n1  n0  ds3 ds2 ds1 ds0        269             w   h  n1  n0  ds3 ds2 ds1 ds0
270                                                   270 
271             normally:                             271             normally:
272                ds3..ds0 = scroll wheel amount     272                ds3..ds0 = scroll wheel amount and direction
273                           positive = down or l    273                           positive = down or left
274                           negative = up or rig    274                           negative = up or right
275             when corner tap detected:             275             when corner tap detected:
276                ds0 = 1 when top right corner t    276                ds0 = 1 when top right corner tapped
277                ds1 = 1 when bottom right corne    277                ds1 = 1 when bottom right corner tapped
278                ds2 = 1 when bottom left corner    278                ds2 = 1 when bottom left corner tapped
279                ds3 = 1 when top left corner ta    279                ds3 = 1 when top left corner tapped
280             n1..n0 = number of fingers on touc    280             n1..n0 = number of fingers on touchpad
281                only models with firmware 2.x r    281                only models with firmware 2.x report this, models with
282                firmware 1.x seem to map one, t    282                firmware 1.x seem to map one, two and three finger taps
283                directly to L, M and R mouse bu    283                directly to L, M and R mouse buttons
284             h = 1 when horizontal scroll actio    284             h = 1 when horizontal scroll action
285             w = 1 when wide finger touch?         285             w = 1 when wide finger touch?
286                                                   286 
287    otherwise (reg_11, P = 0):                     287    otherwise (reg_11, P = 0):
288                                                   288 
289       bit   7   6   5   4   3   2   1   0         289       bit   7   6   5   4   3   2   1   0
290            ds7 ds6 ds5 ds4 ds3 ds2 ds1 ds0        290            ds7 ds6 ds5 ds4 ds3 ds2 ds1 ds0
291                                                   291 
292             ds7..ds0 = vertical scroll amount     292             ds7..ds0 = vertical scroll amount and direction
293                        negative = up              293                        negative = up
294                        positive = down            294                        positive = down
295                                                   295 
296                                                   296 
297 Native absolute mode 4 byte packet format         297 Native absolute mode 4 byte packet format
298 -----------------------------------------         298 -----------------------------------------
299                                                   299 
300 EF013 and EF019 have a special behaviour (due     300 EF013 and EF019 have a special behaviour (due to a bug in the firmware?), and
301 when 1 finger is touching, the first 2 positio    301 when 1 finger is touching, the first 2 position reports must be discarded.
302 This counting is reset whenever a different nu    302 This counting is reset whenever a different number of fingers is reported.
303                                                   303 
304 byte 0::                                          304 byte 0::
305                                                   305 
306    firmware version 1.x:                          306    firmware version 1.x:
307                                                   307 
308       bit   7   6   5   4   3   2   1   0         308       bit   7   6   5   4   3   2   1   0
309             D   U  p1  p2   1  p3   R   L         309             D   U  p1  p2   1  p3   R   L
310                                                   310 
311             L, R = 1 when Left, Right mouse bu    311             L, R = 1 when Left, Right mouse button pressed
312             p1..p3 = byte 1..3 odd parity bit     312             p1..p3 = byte 1..3 odd parity bit
313             D, U = 1 when rocker switch presse    313             D, U = 1 when rocker switch pressed Up, Down
314                                                   314 
315    firmware version 2.x:                          315    firmware version 2.x:
316                                                   316 
317       bit   7   6   5   4   3   2   1   0         317       bit   7   6   5   4   3   2   1   0
318            n1  n0  p2  p1   1  p3   R   L         318            n1  n0  p2  p1   1  p3   R   L
319                                                   319 
320             L, R = 1 when Left, Right mouse bu    320             L, R = 1 when Left, Right mouse button pressed
321             p1..p3 = byte 1..3 odd parity bit     321             p1..p3 = byte 1..3 odd parity bit
322             n1..n0 = number of fingers on touc    322             n1..n0 = number of fingers on touchpad
323                                                   323 
324 byte 1::                                          324 byte 1::
325                                                   325 
326    firmware version 1.x:                          326    firmware version 1.x:
327                                                   327 
328       bit   7   6   5   4   3   2   1   0         328       bit   7   6   5   4   3   2   1   0
329             f   0  th  tw  x9  x8  y9  y8         329             f   0  th  tw  x9  x8  y9  y8
330                                                   330 
331             tw = 1 when two finger touch          331             tw = 1 when two finger touch
332             th = 1 when three finger touch        332             th = 1 when three finger touch
333             f  = 1 when finger touch              333             f  = 1 when finger touch
334                                                   334 
335    firmware version 2.x:                          335    firmware version 2.x:
336                                                   336 
337       bit   7   6   5   4   3   2   1   0         337       bit   7   6   5   4   3   2   1   0
338             .   .   .   .  x9  x8  y9  y8         338             .   .   .   .  x9  x8  y9  y8
339                                                   339 
340 byte 2::                                          340 byte 2::
341                                                   341 
342    bit   7   6   5   4   3   2   1   0            342    bit   7   6   5   4   3   2   1   0
343         x7  x6  x5  x4  x3  x2  x1  x0            343         x7  x6  x5  x4  x3  x2  x1  x0
344                                                   344 
345          x9..x0 = absolute x value (horizontal    345          x9..x0 = absolute x value (horizontal)
346                                                   346 
347 byte 3::                                          347 byte 3::
348                                                   348 
349    bit   7   6   5   4   3   2   1   0            349    bit   7   6   5   4   3   2   1   0
350         y7  y6  y5  y4  y3  y2  y1  y0            350         y7  y6  y5  y4  y3  y2  y1  y0
351                                                   351 
352          y9..y0 = absolute y value (vertical)     352          y9..y0 = absolute y value (vertical)
353                                                   353 
354                                                   354 
355 Hardware version 2                                355 Hardware version 2
356 ~~~~~~~~~~~~~~~~~~                                356 ~~~~~~~~~~~~~~~~~~
357                                                   357 
358                                                   358 
359 Registers                                         359 Registers
360 ---------                                         360 ---------
361                                                   361 
362 By echoing a hexadecimal value to a register i    362 By echoing a hexadecimal value to a register it contents can be altered.
363                                                   363 
364 For example::                                     364 For example::
365                                                   365 
366    echo -n 0x56 > reg_10                          366    echo -n 0x56 > reg_10
367                                                   367 
368 * reg_10::                                        368 * reg_10::
369                                                   369 
370    bit   7   6   5   4   3   2   1   0            370    bit   7   6   5   4   3   2   1   0
371          0   1   0   1   0   1   D   0            371          0   1   0   1   0   1   D   0
372                                                   372 
373          D: 1 = enable drag and drop              373          D: 1 = enable drag and drop
374                                                   374 
375 * reg_11::                                        375 * reg_11::
376                                                   376 
377    bit   7   6   5   4   3   2   1   0            377    bit   7   6   5   4   3   2   1   0
378          1   0   0   0   S   0   1   0            378          1   0   0   0   S   0   1   0
379                                                   379 
380          S: 1 = enable vertical scroll            380          S: 1 = enable vertical scroll
381                                                   381 
382 * reg_21::                                        382 * reg_21::
383                                                   383 
384          unknown (0x00)                           384          unknown (0x00)
385                                                   385 
386 * reg_22::                                        386 * reg_22::
387                                                   387 
388          drag and drop release time out (short    388          drag and drop release time out (short: 0x70 ... long 0x7e;
389                                    0x7f = neve    389                                    0x7f = never i.e. tap again to release)
390                                                   390 
391                                                   391 
392 Native absolute mode 6 byte packet format         392 Native absolute mode 6 byte packet format
393 -----------------------------------------         393 -----------------------------------------
394                                                   394 
395 Parity checking and packet re-synchronization     395 Parity checking and packet re-synchronization
396 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^     396 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
397                                                   397 
398 There is no parity checking, however some cons    398 There is no parity checking, however some consistency checks can be performed.
399                                                   399 
400 For instance for EF113::                          400 For instance for EF113::
401                                                   401 
402         SA1= packet[0];                           402         SA1= packet[0];
403         A1 = packet[1];                           403         A1 = packet[1];
404         B1 = packet[2];                           404         B1 = packet[2];
405         SB1= packet[3];                           405         SB1= packet[3];
406         C1 = packet[4];                           406         C1 = packet[4];
407         D1 = packet[5];                           407         D1 = packet[5];
408         if( (((SA1 & 0x3C) != 0x3C) && ((SA1 &    408         if( (((SA1 & 0x3C) != 0x3C) && ((SA1 & 0xC0) != 0x80)) || // check Byte 1
409             (((SA1 & 0x0C) != 0x0C) && ((SA1 &    409             (((SA1 & 0x0C) != 0x0C) && ((SA1 & 0xC0) == 0x80)) || // check Byte 1 (one finger pressed)
410             (((SA1 & 0xC0) != 0x80) && (( A1 &    410             (((SA1 & 0xC0) != 0x80) && (( A1 & 0xF0) != 0x00)) || // check Byte 2
411             (((SB1 & 0x3E) != 0x38) && ((SA1 &    411             (((SB1 & 0x3E) != 0x38) && ((SA1 & 0xC0) != 0x80)) || // check Byte 4
412             (((SB1 & 0x0E) != 0x08) && ((SA1 &    412             (((SB1 & 0x0E) != 0x08) && ((SA1 & 0xC0) == 0x80)) || // check Byte 4 (one finger pressed)
413             (((SA1 & 0xC0) != 0x80) && (( C1 &    413             (((SA1 & 0xC0) != 0x80) && (( C1 & 0xF0) != 0x00))  ) // check Byte 5
414                 // error detected                 414                 // error detected
415                                                   415 
416 For all the other ones, there are just a few c    416 For all the other ones, there are just a few constant bits::
417                                                   417 
418         if( ((packet[0] & 0x0C) != 0x04) ||       418         if( ((packet[0] & 0x0C) != 0x04) ||
419             ((packet[3] & 0x0f) != 0x02) )        419             ((packet[3] & 0x0f) != 0x02) )
420                 // error detected                 420                 // error detected
421                                                   421 
422                                                   422 
423 In case an error is detected, all the packets     423 In case an error is detected, all the packets are shifted by one (and packet[0] is discarded).
424                                                   424 
425 One/Three finger touch                            425 One/Three finger touch
426 ^^^^^^^^^^^^^^^^^^^^^^                            426 ^^^^^^^^^^^^^^^^^^^^^^
427                                                   427 
428 byte 0::                                          428 byte 0::
429                                                   429 
430    bit   7   6   5   4   3   2   1   0            430    bit   7   6   5   4   3   2   1   0
431          n1  n0  w3  w2   .   .   R   L           431          n1  n0  w3  w2   .   .   R   L
432                                                   432 
433          L, R = 1 when Left, Right mouse butto    433          L, R = 1 when Left, Right mouse button pressed
434          n1..n0 = number of fingers on touchpa    434          n1..n0 = number of fingers on touchpad
435                                                   435 
436 byte 1::                                          436 byte 1::
437                                                   437 
438    bit   7   6   5   4   3   2   1   0            438    bit   7   6   5   4   3   2   1   0
439          p7  p6  p5  p4 x11 x10 x9  x8            439          p7  p6  p5  p4 x11 x10 x9  x8
440                                                   440 
441 byte 2::                                          441 byte 2::
442                                                   442 
443    bit   7   6   5   4   3   2   1   0            443    bit   7   6   5   4   3   2   1   0
444          x7  x6  x5  x4  x3  x2  x1  x0           444          x7  x6  x5  x4  x3  x2  x1  x0
445                                                   445 
446          x11..x0 = absolute x value (horizonta    446          x11..x0 = absolute x value (horizontal)
447                                                   447 
448 byte 3::                                          448 byte 3::
449                                                   449 
450    bit   7   6   5   4   3   2   1   0            450    bit   7   6   5   4   3   2   1   0
451          n4  vf  w1  w0   .   .   .  b2           451          n4  vf  w1  w0   .   .   .  b2
452                                                   452 
453          n4 = set if more than 3 fingers (only    453          n4 = set if more than 3 fingers (only in 3 fingers mode)
454          vf = a kind of flag ? (only on EF123,    454          vf = a kind of flag ? (only on EF123, 0 when finger is over one
455               of the buttons, 1 otherwise)        455               of the buttons, 1 otherwise)
456          w3..w0 = width of the finger touch (n    456          w3..w0 = width of the finger touch (not EF113)
457          b2 (on EF113 only, 0 otherwise), b2.R    457          b2 (on EF113 only, 0 otherwise), b2.R.L indicates one button pressed:
458                 0 = none                          458                 0 = none
459                 1 = Left                          459                 1 = Left
460                 2 = Right                         460                 2 = Right
461                 3 = Middle (Left and Right)       461                 3 = Middle (Left and Right)
462                 4 = Forward                       462                 4 = Forward
463                 5 = Back                          463                 5 = Back
464                 6 = Another one                   464                 6 = Another one
465                 7 = Another one                   465                 7 = Another one
466                                                   466 
467 byte 4::                                          467 byte 4::
468                                                   468 
469    bit   7   6   5   4   3   2   1   0            469    bit   7   6   5   4   3   2   1   0
470         p3  p1  p2  p0  y11 y10 y9  y8            470         p3  p1  p2  p0  y11 y10 y9  y8
471                                                   471 
472          p7..p0 = pressure (not EF113)            472          p7..p0 = pressure (not EF113)
473                                                   473 
474 byte 5::                                          474 byte 5::
475                                                   475 
476    bit   7   6   5   4   3   2   1   0            476    bit   7   6   5   4   3   2   1   0
477         y7  y6  y5  y4  y3  y2  y1  y0            477         y7  y6  y5  y4  y3  y2  y1  y0
478                                                   478 
479          y11..y0 = absolute y value (vertical)    479          y11..y0 = absolute y value (vertical)
480                                                   480 
481                                                   481 
482 Two finger touch                                  482 Two finger touch
483 ^^^^^^^^^^^^^^^^                                  483 ^^^^^^^^^^^^^^^^
484                                                   484 
485 Note that the two pairs of coordinates are not    485 Note that the two pairs of coordinates are not exactly the coordinates of the
486 two fingers, but only the pair of the lower-le    486 two fingers, but only the pair of the lower-left and upper-right coordinates.
487 So the actual fingers might be situated on the    487 So the actual fingers might be situated on the other diagonal of the square
488 defined by these two points.                      488 defined by these two points.
489                                                   489 
490 byte 0::                                          490 byte 0::
491                                                   491 
492    bit   7   6   5   4   3   2   1   0            492    bit   7   6   5   4   3   2   1   0
493         n1  n0  ay8 ax8  .   .   R   L            493         n1  n0  ay8 ax8  .   .   R   L
494                                                   494 
495          L, R = 1 when Left, Right mouse butto    495          L, R = 1 when Left, Right mouse button pressed
496          n1..n0 = number of fingers on touchpa    496          n1..n0 = number of fingers on touchpad
497                                                   497 
498 byte 1::                                          498 byte 1::
499                                                   499 
500    bit   7   6   5   4   3   2   1   0            500    bit   7   6   5   4   3   2   1   0
501         ax7 ax6 ax5 ax4 ax3 ax2 ax1 ax0           501         ax7 ax6 ax5 ax4 ax3 ax2 ax1 ax0
502                                                   502 
503          ax8..ax0 = lower-left finger absolute    503          ax8..ax0 = lower-left finger absolute x value
504                                                   504 
505 byte 2::                                          505 byte 2::
506                                                   506 
507    bit   7   6   5   4   3   2   1   0            507    bit   7   6   5   4   3   2   1   0
508         ay7 ay6 ay5 ay4 ay3 ay2 ay1 ay0           508         ay7 ay6 ay5 ay4 ay3 ay2 ay1 ay0
509                                                   509 
510          ay8..ay0 = lower-left finger absolute    510          ay8..ay0 = lower-left finger absolute y value
511                                                   511 
512 byte 3::                                          512 byte 3::
513                                                   513 
514    bit   7   6   5   4   3   2   1   0            514    bit   7   6   5   4   3   2   1   0
515          .   .  by8 bx8  .   .   .   .            515          .   .  by8 bx8  .   .   .   .
516                                                   516 
517 byte 4::                                          517 byte 4::
518                                                   518 
519    bit   7   6   5   4   3   2   1   0            519    bit   7   6   5   4   3   2   1   0
520         bx7 bx6 bx5 bx4 bx3 bx2 bx1 bx0           520         bx7 bx6 bx5 bx4 bx3 bx2 bx1 bx0
521                                                   521 
522          bx8..bx0 = upper-right finger absolut    522          bx8..bx0 = upper-right finger absolute x value
523                                                   523 
524 byte 5::                                          524 byte 5::
525                                                   525 
526    bit   7   6   5   4   3   2   1   0            526    bit   7   6   5   4   3   2   1   0
527         by7 by8 by5 by4 by3 by2 by1 by0           527         by7 by8 by5 by4 by3 by2 by1 by0
528                                                   528 
529          by8..by0 = upper-right finger absolut    529          by8..by0 = upper-right finger absolute y value
530                                                   530 
531 Hardware version 3                                531 Hardware version 3
532 ~~~~~~~~~~~~~~~~~~                                532 ~~~~~~~~~~~~~~~~~~
533                                                   533 
534 Registers                                         534 Registers
535 ---------                                         535 ---------
536                                                   536 
537 * reg_10::                                        537 * reg_10::
538                                                   538 
539    bit   7   6   5   4   3   2   1   0            539    bit   7   6   5   4   3   2   1   0
540          0   0   0   0   R   F   T   A            540          0   0   0   0   R   F   T   A
541                                                   541 
542          A: 1 = enable absolute tracking          542          A: 1 = enable absolute tracking
543          T: 1 = enable two finger mode auto co    543          T: 1 = enable two finger mode auto correct
544          F: 1 = disable ABS Position Filter       544          F: 1 = disable ABS Position Filter
545          R: 1 = enable real hardware resolutio    545          R: 1 = enable real hardware resolution
546                                                   546 
547 Native absolute mode 6 byte packet format         547 Native absolute mode 6 byte packet format
548 -----------------------------------------         548 -----------------------------------------
549                                                   549 
550 1 and 3 finger touch shares the same 6-byte pa    550 1 and 3 finger touch shares the same 6-byte packet format, except that
551 3 finger touch only reports the position of th    551 3 finger touch only reports the position of the center of all three fingers.
552                                                   552 
553 Firmware would send 12 bytes of data for 2 fin    553 Firmware would send 12 bytes of data for 2 finger touch.
554                                                   554 
555 Note on debounce:                                 555 Note on debounce:
556 In case the box has unstable power supply or o    556 In case the box has unstable power supply or other electricity issues, or
557 when number of finger changes, F/W would send     557 when number of finger changes, F/W would send "debounce packet" to inform
558 driver that the hardware is in debounce status    558 driver that the hardware is in debounce status.
559 The debouce packet has the following signature    559 The debouce packet has the following signature::
560                                                   560 
561     byte 0: 0xc4                                  561     byte 0: 0xc4
562     byte 1: 0xff                                  562     byte 1: 0xff
563     byte 2: 0xff                                  563     byte 2: 0xff
564     byte 3: 0x02                                  564     byte 3: 0x02
565     byte 4: 0xff                                  565     byte 4: 0xff
566     byte 5: 0xff                                  566     byte 5: 0xff
567                                                   567 
568 When we encounter this kind of packet, we just    568 When we encounter this kind of packet, we just ignore it.
569                                                   569 
570 One/Three finger touch                            570 One/Three finger touch
571 ^^^^^^^^^^^^^^^^^^^^^^                            571 ^^^^^^^^^^^^^^^^^^^^^^
572                                                   572 
573 byte 0::                                          573 byte 0::
574                                                   574 
575    bit   7   6   5   4   3   2   1   0            575    bit   7   6   5   4   3   2   1   0
576         n1  n0  w3  w2   0   1   R   L            576         n1  n0  w3  w2   0   1   R   L
577                                                   577 
578         L, R = 1 when Left, Right mouse button    578         L, R = 1 when Left, Right mouse button pressed
579         n1..n0 = number of fingers on touchpad    579         n1..n0 = number of fingers on touchpad
580                                                   580 
581 byte 1::                                          581 byte 1::
582                                                   582 
583    bit   7   6   5   4   3   2   1   0            583    bit   7   6   5   4   3   2   1   0
584         p7  p6  p5  p4 x11 x10  x9  x8            584         p7  p6  p5  p4 x11 x10  x9  x8
585                                                   585 
586 byte 2::                                          586 byte 2::
587                                                   587 
588    bit   7   6   5   4   3   2   1   0            588    bit   7   6   5   4   3   2   1   0
589         x7  x6  x5  x4  x3  x2  x1  x0            589         x7  x6  x5  x4  x3  x2  x1  x0
590                                                   590 
591         x11..x0 = absolute x value (horizontal    591         x11..x0 = absolute x value (horizontal)
592                                                   592 
593 byte 3::                                          593 byte 3::
594                                                   594 
595    bit   7   6   5   4   3   2   1   0            595    bit   7   6   5   4   3   2   1   0
596          0   0  w1  w0   0   0   1   0            596          0   0  w1  w0   0   0   1   0
597                                                   597 
598          w3..w0 = width of the finger touch       598          w3..w0 = width of the finger touch
599                                                   599 
600 byte 4::                                          600 byte 4::
601                                                   601 
602    bit   7   6   5   4   3   2   1   0            602    bit   7   6   5   4   3   2   1   0
603         p3  p1  p2  p0  y11 y10 y9  y8            603         p3  p1  p2  p0  y11 y10 y9  y8
604                                                   604 
605         p7..p0 = pressure                         605         p7..p0 = pressure
606                                                   606 
607 byte 5::                                          607 byte 5::
608                                                   608 
609    bit   7   6   5   4   3   2   1   0            609    bit   7   6   5   4   3   2   1   0
610         y7  y6  y5  y4  y3  y2  y1  y0            610         y7  y6  y5  y4  y3  y2  y1  y0
611                                                   611 
612         y11..y0 = absolute y value (vertical)     612         y11..y0 = absolute y value (vertical)
613                                                   613 
614 Two finger touch                                  614 Two finger touch
615 ^^^^^^^^^^^^^^^^                                  615 ^^^^^^^^^^^^^^^^
616                                                   616 
617 The packet format is exactly the same for two     617 The packet format is exactly the same for two finger touch, except the hardware
618 sends two 6 byte packets. The first packet con    618 sends two 6 byte packets. The first packet contains data for the first finger,
619 the second packet has data for the second fing    619 the second packet has data for the second finger. So for two finger touch a
620 total of 12 bytes are sent.                       620 total of 12 bytes are sent.
621                                                   621 
622 Hardware version 4                                622 Hardware version 4
623 ~~~~~~~~~~~~~~~~~~                                623 ~~~~~~~~~~~~~~~~~~
624                                                   624 
625 Registers                                         625 Registers
626 ---------                                         626 ---------
627                                                   627 
628 * reg_07::                                        628 * reg_07::
629                                                   629 
630    bit   7   6   5   4   3   2   1   0            630    bit   7   6   5   4   3   2   1   0
631          0   0   0   0   0   0   0   A            631          0   0   0   0   0   0   0   A
632                                                   632 
633          A: 1 = enable absolute tracking          633          A: 1 = enable absolute tracking
634                                                   634 
635 Native absolute mode 6 byte packet format         635 Native absolute mode 6 byte packet format
636 -----------------------------------------         636 -----------------------------------------
637                                                   637 
638 v4 hardware is a true multitouch touchpad, cap    638 v4 hardware is a true multitouch touchpad, capable of tracking up to 5 fingers.
639 Unfortunately, due to PS/2's limited bandwidth    639 Unfortunately, due to PS/2's limited bandwidth, its packet format is rather
640 complex.                                          640 complex.
641                                                   641 
642 Whenever the numbers or identities of the fing    642 Whenever the numbers or identities of the fingers changes, the hardware sends a
643 status packet to indicate how many and which f    643 status packet to indicate how many and which fingers is on touchpad, followed by
644 head packets or motion packets. A head packet     644 head packets or motion packets. A head packet contains data of finger id, finger
645 position (absolute x, y values), width, and pr    645 position (absolute x, y values), width, and pressure. A motion packet contains
646 two fingers' position delta.                      646 two fingers' position delta.
647                                                   647 
648 For example, when status packet tells there ar    648 For example, when status packet tells there are 2 fingers on touchpad, then we
649 can expect two following head packets. If the     649 can expect two following head packets. If the finger status doesn't change,
650 the following packets would be motion packets,    650 the following packets would be motion packets, only sending delta of finger
651 position, until we receive a status packet.       651 position, until we receive a status packet.
652                                                   652 
653 One exception is one finger touch. when a stat    653 One exception is one finger touch. when a status packet tells us there is only
654 one finger, the hardware would just send head     654 one finger, the hardware would just send head packets afterwards.
655                                                   655 
656 Status packet                                     656 Status packet
657 ^^^^^^^^^^^^^                                     657 ^^^^^^^^^^^^^
658                                                   658 
659 byte 0::                                          659 byte 0::
660                                                   660 
661    bit   7   6   5   4   3   2   1   0            661    bit   7   6   5   4   3   2   1   0
662          .   .   .   .   0   1   R   L            662          .   .   .   .   0   1   R   L
663                                                   663 
664          L, R = 1 when Left, Right mouse butto    664          L, R = 1 when Left, Right mouse button pressed
665                                                   665 
666 byte 1::                                          666 byte 1::
667                                                   667 
668    bit   7   6   5   4   3   2   1   0            668    bit   7   6   5   4   3   2   1   0
669          .   .   . ft4 ft3 ft2 ft1 ft0            669          .   .   . ft4 ft3 ft2 ft1 ft0
670                                                   670 
671          ft4 ft3 ft2 ft1 ft0 ftn = 1 when fing    671          ft4 ft3 ft2 ft1 ft0 ftn = 1 when finger n is on touchpad
672                                                   672 
673 byte 2::                                          673 byte 2::
674                                                   674 
675    not used                                       675    not used
676                                                   676 
677 byte 3::                                          677 byte 3::
678                                                   678 
679    bit   7   6   5   4   3   2   1   0            679    bit   7   6   5   4   3   2   1   0
680          .   .   .   1   0   0   0   0            680          .   .   .   1   0   0   0   0
681                                                   681 
682          constant bits                            682          constant bits
683                                                   683 
684 byte 4::                                          684 byte 4::
685                                                   685 
686    bit   7   6   5   4   3   2   1   0            686    bit   7   6   5   4   3   2   1   0
687          p   .   .   .   .   .   .   .            687          p   .   .   .   .   .   .   .
688                                                   688 
689          p = 1 for palm                           689          p = 1 for palm
690                                                   690 
691 byte 5::                                          691 byte 5::
692                                                   692 
693    not used                                       693    not used
694                                                   694 
695 Head packet                                       695 Head packet
696 ^^^^^^^^^^^                                       696 ^^^^^^^^^^^
697                                                   697 
698 byte 0::                                          698 byte 0::
699                                                   699 
700    bit   7   6   5   4   3   2   1   0            700    bit   7   6   5   4   3   2   1   0
701         w3  w2  w1  w0   0   1   R   L            701         w3  w2  w1  w0   0   1   R   L
702                                                   702 
703         L, R = 1 when Left, Right mouse button    703         L, R = 1 when Left, Right mouse button pressed
704         w3..w0 = finger width (spans how many     704         w3..w0 = finger width (spans how many trace lines)
705                                                   705 
706 byte 1::                                          706 byte 1::
707                                                   707 
708    bit   7   6   5   4   3   2   1   0            708    bit   7   6   5   4   3   2   1   0
709         p7  p6  p5  p4 x11 x10  x9  x8            709         p7  p6  p5  p4 x11 x10  x9  x8
710                                                   710 
711 byte 2::                                          711 byte 2::
712                                                   712 
713    bit   7   6   5   4   3   2   1   0            713    bit   7   6   5   4   3   2   1   0
714         x7  x6  x5  x4  x3  x2  x1  x0            714         x7  x6  x5  x4  x3  x2  x1  x0
715                                                   715 
716         x11..x0 = absolute x value (horizontal    716         x11..x0 = absolute x value (horizontal)
717                                                   717 
718 byte 3::                                          718 byte 3::
719                                                   719 
720    bit   7   6   5   4   3   2   1   0            720    bit   7   6   5   4   3   2   1   0
721        id2 id1 id0   1   0   0   0   1            721        id2 id1 id0   1   0   0   0   1
722                                                   722 
723        id2..id0 = finger id                       723        id2..id0 = finger id
724                                                   724 
725 byte 4::                                          725 byte 4::
726                                                   726 
727    bit   7   6   5   4   3   2   1   0            727    bit   7   6   5   4   3   2   1   0
728         p3  p1  p2  p0  y11 y10 y9  y8            728         p3  p1  p2  p0  y11 y10 y9  y8
729                                                   729 
730         p7..p0 = pressure                         730         p7..p0 = pressure
731                                                   731 
732 byte 5::                                          732 byte 5::
733                                                   733 
734    bit   7   6   5   4   3   2   1   0            734    bit   7   6   5   4   3   2   1   0
735         y7  y6  y5  y4  y3  y2  y1  y0            735         y7  y6  y5  y4  y3  y2  y1  y0
736                                                   736 
737         y11..y0 = absolute y value (vertical)     737         y11..y0 = absolute y value (vertical)
738                                                   738 
739 Motion packet                                     739 Motion packet
740 ^^^^^^^^^^^^^                                     740 ^^^^^^^^^^^^^
741                                                   741 
742 byte 0::                                          742 byte 0::
743                                                   743 
744    bit   7   6   5   4   3   2   1   0            744    bit   7   6   5   4   3   2   1   0
745        id2 id1 id0   w   0   1   R   L            745        id2 id1 id0   w   0   1   R   L
746                                                   746 
747        L, R = 1 when Left, Right mouse button     747        L, R = 1 when Left, Right mouse button pressed
748        id2..id0 = finger id                       748        id2..id0 = finger id
749        w = 1 when delta overflows (> 127 or <     749        w = 1 when delta overflows (> 127 or < -128), in this case
750        firmware sends us (delta x / 5) and (de    750        firmware sends us (delta x / 5) and (delta y  / 5)
751                                                   751 
752 byte 1::                                          752 byte 1::
753                                                   753 
754    bit   7   6   5   4   3   2   1   0            754    bit   7   6   5   4   3   2   1   0
755         x7  x6  x5  x4  x3  x2  x1  x0            755         x7  x6  x5  x4  x3  x2  x1  x0
756                                                   756 
757         x7..x0 = delta x (two's complement)       757         x7..x0 = delta x (two's complement)
758                                                   758 
759 byte 2::                                          759 byte 2::
760                                                   760 
761    bit   7   6   5   4   3   2   1   0            761    bit   7   6   5   4   3   2   1   0
762         y7  y6  y5  y4  y3  y2  y1  y0            762         y7  y6  y5  y4  y3  y2  y1  y0
763                                                   763 
764         y7..y0 = delta y (two's complement)       764         y7..y0 = delta y (two's complement)
765                                                   765 
766 byte 3::                                          766 byte 3::
767                                                   767 
768    bit   7   6   5   4   3   2   1   0            768    bit   7   6   5   4   3   2   1   0
769        id2 id1 id0   1   0   0   1   0            769        id2 id1 id0   1   0   0   1   0
770                                                   770 
771        id2..id0 = finger id                       771        id2..id0 = finger id
772                                                   772 
773 byte 4::                                          773 byte 4::
774                                                   774 
775    bit   7   6   5   4   3   2   1   0            775    bit   7   6   5   4   3   2   1   0
776         x7  x6  x5  x4  x3  x2  x1  x0            776         x7  x6  x5  x4  x3  x2  x1  x0
777                                                   777 
778         x7..x0 = delta x (two's complement)       778         x7..x0 = delta x (two's complement)
779                                                   779 
780 byte 5::                                          780 byte 5::
781                                                   781 
782    bit   7   6   5   4   3   2   1   0            782    bit   7   6   5   4   3   2   1   0
783         y7  y6  y5  y4  y3  y2  y1  y0            783         y7  y6  y5  y4  y3  y2  y1  y0
784                                                   784 
785         y7..y0 = delta y (two's complement)       785         y7..y0 = delta y (two's complement)
786                                                   786 
787         byte 0 ~ 2 for one finger                 787         byte 0 ~ 2 for one finger
788         byte 3 ~ 5 for another                    788         byte 3 ~ 5 for another
789                                                   789 
790                                                   790 
791 Trackpoint (for Hardware version 3 and 4)         791 Trackpoint (for Hardware version 3 and 4)
792 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~         792 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
793                                                   793 
794 Registers                                         794 Registers
795 ---------                                         795 ---------
796                                                   796 
797 No special registers have been identified.        797 No special registers have been identified.
798                                                   798 
799 Native relative mode 6 byte packet format         799 Native relative mode 6 byte packet format
800 -----------------------------------------         800 -----------------------------------------
801                                                   801 
802 Status Packet                                     802 Status Packet
803 ^^^^^^^^^^^^^                                     803 ^^^^^^^^^^^^^
804                                                   804 
805 byte 0::                                          805 byte 0::
806                                                   806 
807    bit   7   6   5   4   3   2   1   0            807    bit   7   6   5   4   3   2   1   0
808          0   0  sx  sy   0   M   R   L            808          0   0  sx  sy   0   M   R   L
809                                                   809 
810 byte 1::                                          810 byte 1::
811                                                   811 
812    bit   7   6   5   4   3   2   1   0            812    bit   7   6   5   4   3   2   1   0
813        ~sx   0   0   0   0   0   0   0            813        ~sx   0   0   0   0   0   0   0
814                                                   814 
815 byte 2::                                          815 byte 2::
816                                                   816 
817    bit   7   6   5   4   3   2   1   0            817    bit   7   6   5   4   3   2   1   0
818        ~sy   0   0   0   0   0   0   0            818        ~sy   0   0   0   0   0   0   0
819                                                   819 
820 byte 3::                                          820 byte 3::
821                                                   821 
822    bit   7   6   5   4   3   2   1   0            822    bit   7   6   5   4   3   2   1   0
823          0   0 ~sy ~sx   0   1   1   0            823          0   0 ~sy ~sx   0   1   1   0
824                                                   824 
825 byte 4::                                          825 byte 4::
826                                                   826 
827    bit   7   6   5   4   3   2   1   0            827    bit   7   6   5   4   3   2   1   0
828         x7  x6  x5  x4  x3  x2  x1  x0            828         x7  x6  x5  x4  x3  x2  x1  x0
829                                                   829 
830 byte 5::                                          830 byte 5::
831                                                   831 
832    bit   7   6   5   4   3   2   1   0            832    bit   7   6   5   4   3   2   1   0
833         y7  y6  y5  y4  y3  y2  y1  y0            833         y7  y6  y5  y4  y3  y2  y1  y0
834                                                   834 
835                                                   835 
836          x and y are written in two's compleme    836          x and y are written in two's complement spread
837              over 9 bits with sx/sy the relati    837              over 9 bits with sx/sy the relative top bit and
838              x7..x0 and y7..y0 the lower bits.    838              x7..x0 and y7..y0 the lower bits.
839          ~sx is the inverse of sx, ~sy is the     839          ~sx is the inverse of sx, ~sy is the inverse of sy.
840          The sign of y is opposite to what the    840          The sign of y is opposite to what the input driver
841              expects for a relative movement      841              expects for a relative movement
                                                      

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php