From: Bryan W. H. <bwh...@ea...> - 2004-06-06 14:44:30
|
Darryl Luff wrote: > Hi all, > > I've spent the morning trying to get the aiptek driver working with > the 2.6.6 kernel and XFree86. > > - I got the current CVS drivers (5th June) from sourceforge. To get > the driver to work under the 2.6.6 kernel I had to copy in an > implementation of msleep from another driver. I think the global > msleep only appears in 2.6.7?? Anyway, it then worked. evtest shows > Pressure events that seem to be normal. > > - In then looked at the XFree86 driver. It compiled OK, but in the > Gimp, the devices show up but don't seem to do anything. If I > understand it correctly, changing to the > erasor tool in Gimp should make the Erasor active in the Device Status > dialog? In mine, the "Core Pointer" is always active, and the three > aiptek devices seem > insensitive and never change. I can draw in the gimp but it's not > pressure sensitive. > It probably "should", yes, but doesn't. I was talking with one of the Wacom driver guys, and he was thinking about sending patches to Gtk/Gimp to fix it's behavior with tablets. > I'm assuming that this is because the device never changes, but I dont > really know anything about this. > > - In AiptekReadEvents, the eventType field is always zero at the end > of the checks that use AiptekIsEventValid(common, i) to check for an > available driver. This is because AiptekIsEventValid returns > "Success", which has the value 0 on my system, so the check: > > if (AiptekIsEventValid(common, i)) > { > > always fails. I changed it to check for a "Success" return value. > if (AiptekIsEventValid(common, i) == Success) > { > > also changed the other calls to this function to be the same. Good catch! > > - Now, eventType seems to be set properly. But I dont understand where > the distinction between erasor, stylus and cursor comes from? Do I > have to somehow tell the tablet to switch modes? Yes. Write to the tool_mode file. Or use Gaiptek. > > - I know the loop around the AiptekIsEventValid call is trying to make > sure there is a valid driver, but I'm not really following the method. > If eventType is originally 2 (CURSOR_ID), then 'start' is set to 2. It > is then used to initialise 'i' to the value of deviceIdArray[start], > which is deviceIdArray[2], which is ERASER_ID (4). So the call to > AiptekIsEventValid is AiptekIsEventValid(common, ERASOR_ID). This > returns Success, so the eventType is set to ERASOR_ID? > > - Shouldnt the line "if (deviceIdArray[start] != deviceIdArray[i])" > that triggers the re-routing warning, be "if (deviceIdArray[start] != > i)", as 'i' was already set using "i = deviceIdArray[j]". This is why I get headaches... common->currentValues.eventType = 1 << i; > > Thanks for any pointers! Two quality patches; what pointers do you think you need? |