Re: [patch] add module parameter to provide hardware-calibrated coordinate data for MicroTouch/3M touchscreens

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Nov 14, 2008 at 04:46:08PM -0500, Dan Streetman wrote:
> Ok - I'll update the patch to invert Y before reporting.
> 
> On the issue of whether to use a module param to send raw coordinates
> or hw-calibrated coordinates, or to just change the code to report the
> hw-calibrated coordinates instead of the raw coordinates, what do you
> think?

I'm in favor for the option, because of:

	* backwards compatibility 
	* the Linux input standard is unprocessed coordinate data
	  (but after compensating for all hardware quirks)
	* most touchscreens can't do HW calibration anyway, and we
	  benefit from common SW calibration code, eg in tslib

Actually, I don't see much value in the hw-calibrated data, but I see it
could be useful in some cases, so I'm still fine with adding the
possibility to use that mode.

Vojtech

> 
> On Fri, Nov 14, 2008 at 4:31 PM, Vojtech Pavlik <vojtech@xxxxxxx> wrote:
> > On Thu, Nov 13, 2008 at 03:22:52PM -0500, Dan Streetman wrote:
> >
> >> Note that the Y axis is inverted as reported by the touchscreen, so
> >> this reverses the Y min and max (0xffff for the min, 0 for the max).
> >> This works fine on my system using the X evdev driver.
> >
> >> +     // Default min/max xy are the raw values, override if using hw-calib
> >> +     if (hwcalib_xy) {
> >> +             input_set_abs_params(usbtouch->input, ABS_X, 0, 0xffff, 0, 0);
> >> +             input_set_abs_params(usbtouch->input, ABS_Y, 0xffff, 0, 0, 0);
> >
> > While it does work with the X evdev, please don't do it, and instead do
> > the inversion before reporting ABS_Y. Linux input devices should follow
> > the (USB) HID specification of axis direction and stick to it. The
> > behaviour with reversed min/max is undefined.
> >
> > --
> > Vojtech Pavlik
> > Director SuSE Labs
> >
> 

-- 
Vojtech Pavlik
Director SuSE Labs
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux