Trying to write a kdrive/XFree86 mouse driver
UPDATE: I wrote a gpm driver but now can't get it to work with kdrive -- see further down for more information
Hi
I have been cross-compiling kdrive for the ARM (so I can use the Xfbdev server) and X is now running and will allow programs to run. The problem is, it isn't much use yet since the mouse isn't working as the system uses a non-standard mouse device and so clearly, it isn't supported.
I have been looking through xc/programs/Xserver/hw/kdrive/linux/mouse.c but I can't work out how to add a new driver. I know how to get data from the device and what format it is in (you just read a single unsigned long int periodically which contains all the data you need and you don't need to write anything to it unlike some of the other mice) so it is simply a case of writing the functions to read and act upon this data.
Can anybody offer any advice as to where to start?
Thanks
PS: I'm using a copy of XFree86 4.3 if that helps
EDIT: I now have decided to use gpm as a repeater (since its code it much cleaner and easier to understand) and I've managed to write a driver which works. The problem now is that I can't work out how to get it working as a repeater. When I make it repeat as any of the supported protocols (I've tried ms3, imps2 and ps2), X will find the mouse device (I've added it to its list of search locations) but keep switching between protocols and never actually stay on any of them.
Last edited by Orkie; 05-14-2006 at 07:23 AM.
|