On Wed, Oct 26, 2011 at 11:25 PM, Peter Hutterer <peter.hutte...@who-t.net> wrote: > On Mon, Oct 24, 2011 at 04:02:46PM -0700, Ping Cheng wrote: >> On Sun, Oct 23, 2011 at 8:22 PM, Peter Hutterer >> >> 1) My device advertises Pressure support with range of 0-4096 but >> >> never sends anything. If I was an application writer (I'm not, BTW, >> >> so could be wrong :-) ), I would make assumptions when I saw that >> >> valuator declared. I'd stop looking for left click and instead start >> >> looking for some non-zero pressure value as left click. >> > >> > that sounds like a kernel bug. the device shouldn't advertise the axis >> > if it doesn't use it (possibly quirked out if the HW is at fault) >> >> It is not a kernel driver issue. It is an issue in wcmInitAxes >> (xf86Wacom.c). We did not check if the axis is defined or not before >> calling InitValuatorAxisStruct. > > oh. so it's not the kernel that advertises the pressure axis then? > in that case, we should be able to fix it "easily"
Yeah, pretty easy. I've wanted to do this for a while but I've just not been able to find much spare time lately. The 1st change is pretty easy: We hard code in several places that valuator[2] is pressure and valuator[5] is a wheel (and other axis as well). Easiest solution in code is to not init that pressure axis and see how X server reacts to wholes in valuator ranges. Does it ignore them during Posts? If not then we need to compact the valuator inits and then store a valuator index when filling in these structures. The next part is to verify apps don't get cranky when they see either holes in valuators defined or if someone hard code an assumption that tablets will always declare, for example, a wheel valuator. The later I would assume is an application bug but not sure about the former. Chris ------------------------------------------------------------------------------ The demand for IT networking professionals continues to grow, and the demand for specialized networking skills is growing even more rapidly. Take a complimentary Learning@Cisco Self-Assessment and learn about Cisco certifications, training, and career opportunities. http://p.sf.net/sfu/cisco-dev2dev _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel