Thread (5 messages) flat view 5 messages, 3 authors, 2011-11-16

Re: [PATCH] HID: Add support for pressure sensitive buttons

From: Sean Young <sean@mess.org>
Date: 2011-11-16 10:24:00

On Tue, Nov 15, 2011 at 03:27:42PM +0100, Jiri Kosina wrote:
On Mon, 14 Nov 2011, Sean Young wrote:
quoted
 	left = left * 0xff / 0xffff;
 	right = (right != 0); /* on/off only */
 
+	sjoyff->report->field[0]->value[0] = 1;
 	sjoyff->report->field[0]->value[1] = right;
 	sjoyff->report->field[0]->value[2] = left;
General comment to the whole patch applicable on many other places as 
well: it'd be nice if you could stick a short comment to the places which 
contain magic contants mandated by the device protocol, so that anyone 
else looking at the driver gets at least a basic idea why are individial 
fields initialized the way they are.
The constants are found by snooping what the windows driver does. I have 
no idea why the values are what they are; in the v2 version of my patch
I've attempted to document better what the device is supposed to do. Is
that what you're after?


Sean
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help