Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/hid/bcm5974.c
Show First 20 Lines • Show All 319 Lines • ▼ Show 20 Lines | [BCM5974_FLAG_WELLSPRING8] = { | ||||
.tp = tp + TYPE3, | .tp = tp + TYPE3, | ||||
.p = { SN_PRESSURE, 0, 300, 0 }, | .p = { SN_PRESSURE, 0, 300, 0 }, | ||||
.w = { SN_WIDTH, 0, 2048, 0 }, | .w = { SN_WIDTH, 0, 2048, 0 }, | ||||
.x = { SN_COORD, -4620, 5140, 105 }, | .x = { SN_COORD, -4620, 5140, 105 }, | ||||
.y = { SN_COORD, -150, 6600, 75 }, | .y = { SN_COORD, -150, 6600, 75 }, | ||||
.o = { SN_ORIENT, | .o = { SN_ORIENT, | ||||
-MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION, 0 }, | -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION, 0 }, | ||||
}, | }, | ||||
/* | |||||
* NOTE: Actually force-sensitive. Pressure has a "size" equal to the max | |||||
* so that the "resolution" is 1 (i.e. values will be interpreted as grams). | |||||
* No scientific measurements have been done :) but a really hard press | |||||
* results in a value around 3500 on model 4. | |||||
*/ | |||||
[BCM5974_FLAG_WELLSPRING9] = { | [BCM5974_FLAG_WELLSPRING9] = { | ||||
.tp = tp + TYPE4, | .tp = tp + TYPE4, | ||||
.p = { SN_PRESSURE, 0, 300, 0 }, | .p = { SN_PRESSURE, 0, 4096, 4096 }, | ||||
wulf: last member (size) value should be 0 for pressure.
To adjust max member you may use… | |||||
val_packett.coolAuthorUnsubmitted Done Inline Actionssize being zero is the problem. wellspring9 does not behave similarly, it is a real pressure sensitive touchpad, where pressure is actual physical force instead of a contact size based approximation. And non-zero resolution is how this is indicated in evdev:
val_packett.cool: `size` being zero //is the problem//.
wellspring9 does not behave similarly, it is a real… | |||||
.w = { SN_WIDTH, 0, 2048, 0 }, | .w = { SN_WIDTH, 0, 2048, 0 }, | ||||
.x = { SN_COORD, -4828, 5345, 105 }, | .x = { SN_COORD, -4828, 5345, 105 }, | ||||
.y = { SN_COORD, -203, 6803, 75 }, | .y = { SN_COORD, -203, 6803, 75 }, | ||||
.o = { SN_ORIENT, | .o = { SN_ORIENT, | ||||
-MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION, 0 }, | -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION, 0 }, | ||||
}, | }, | ||||
}; | }; | ||||
▲ Show 20 Lines • Show All 486 Lines • Show Last 20 Lines |
last member (size) value should be 0 for pressure.
To adjust max member you may use compatibility events. When I slide index finger over Synaptics touchpad surface it reports ABS_PRESSURE varying between 80 and 90. I think Apple device should behave similarly. Also keep in mind that out-of-bounds values are generally allowed in evdev