PowerBook5,8 - TrackPad update

Parag Warudkar kernel-stuff at comcast.net
Tue Nov 22 10:57:05 EST 2005


On Nov 15, 2005, at 4:43 PM, Parag Warudkar wrote:

> Just a heads up - After some lame hacking I finally have got the  
> trackpad on the PB5,8  (15" Late Oct 2005) to work.
>
> Ok, here is the current definition of working - mouse moves but for  
> that you have to roll over on the trackpad ;)!
>
> Currently negotiating with it so that it's happy with the fingers!! :D
>
> Will post the modified source once for appletouch once it starts  
> working acceptably.
>

Ok, the format interpretation of the trackpad data is taking up more  
of my time and brain than I was happy with! :)

If someone wants to take this up, here is something small to begin  
with -

So far the three simple changes that are required for the original  
appletouch.c in order to get it to produce _some_ wayward mouse  
movements and reliable button clicks at the least are

1) #define ATP_DATASIZE 81 - This needs to be made a module parameter  
and if not specified should be detected and set in code - to 81 if  
the machine_is_compatible() with the older powerbooks and 256 if the  
machine_is_compatible() with newer (Oct 05) PowerBooks

2) Convert the appletouch.c to use input_allocate_device()

3) Change the code to lookup either the 80th or 255th byte for button  
press depending upon it's old or new trackpad

Attached is the code which takes care of above 3 - tested but it  
should be considered half baked for obvious reasons and in addition I  
added some relayfs write calls so the received data can be sampled by  
writing a user space client for reading the relayfs file. The code  
might break the existing (old) trackpads as the detection might not  
be correct.

Needless to say the complete logic of interpreting the data and  
determining pressure and movement needs  to be changed such that it  
works for old as well as new.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: appletouch.c
Type: application/octet-stream
Size: 14729 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20051121/70bc2886/attachment.obj>
-------------- next part --------------

Parag





More information about the Linuxppc-dev mailing list