wacom/live: fix physical maximums
This way, udevadm shows on the Slate: E: ID_INPUT_HEIGHT_MM=148 E: ID_INPUT_TABLET=1 E: ID_INPUT_WIDTH_MM=216 Fixes #84
This commit is contained in:
parent
ee15b474fd
commit
18221dfd58
|
@ -75,14 +75,14 @@ wacom_live_rdesc_template = [
|
||||||
0x09, 0x30, # ..Usage (X) 45
|
0x09, 0x30, # ..Usage (X) 45
|
||||||
0x75, 0x10, # ..Report Size (16) 47
|
0x75, 0x10, # ..Report Size (16) 47
|
||||||
0x95, 0x01, # ..Report Count (1) 49
|
0x95, 0x01, # ..Report Count (1) 49
|
||||||
0x55, 0x0e, # ..Unit Exponent (-2) 51
|
0x55, 0x0d, # ..Unit Exponent (-3) 51
|
||||||
0x65, 0x11, # ..Unit (Centimeter,SILinear) 53
|
0x65, 0x11, # ..Unit (Centimeter,SILinear) 53
|
||||||
0x46, 0xec, 0x09, # ..Physical Maximum (2540) 55
|
0x47, 'width', # ..Physical Maximum (TBD) 55
|
||||||
'width', # ..Logical Maximum (TBD) 58
|
0x27, 'width', # ..Logical Maximum (TBD) 58
|
||||||
0x81, 0x02, # ..Input (Data,Var,Abs) 61
|
0x81, 0x02, # ..Input (Data,Var,Abs) 61
|
||||||
0x09, 0x31, # ..Usage (Y) 63
|
0x09, 0x31, # ..Usage (Y) 63
|
||||||
0x46, 0x9d, 0x06, # ..Physical Maximum (1693) 65
|
0x47, 'height', # ..Physical Maximum (TBD) 65
|
||||||
'height', # ..Logical Maximum (TBD) 68
|
0x27, 'height', # ..Logical Maximum (TBD) 68
|
||||||
0x81, 0x02, # ..Input (Data,Var,Abs) 71
|
0x81, 0x02, # ..Input (Data,Var,Abs) 71
|
||||||
0x05, 0x0d, # ..Usage Page (Digitizers) 73
|
0x05, 0x0d, # ..Usage Page (Digitizers) 73
|
||||||
0x09, 0x30, # ..Usage (Tip Pressure) 75
|
0x09, 0x30, # ..Usage (Tip Pressure) 75
|
||||||
|
@ -628,9 +628,9 @@ class WacomProtocolBase(WacomProtocolLowLevelComm):
|
||||||
rdesc = wacom_live_rdesc_template[:]
|
rdesc = wacom_live_rdesc_template[:]
|
||||||
for i, v in enumerate(rdesc):
|
for i, v in enumerate(rdesc):
|
||||||
if v == 'width':
|
if v == 'width':
|
||||||
rdesc[i] = [0x27, list(int.to_bytes(w, 4, 'little', signed=True))]
|
rdesc[i] = list(int.to_bytes(w, 4, 'little', signed=True))
|
||||||
elif v == 'height':
|
elif v == 'height':
|
||||||
rdesc[i] = [0x27, list(int.to_bytes(h, 4, 'little', signed=True))]
|
rdesc[i] = list(int.to_bytes(h, 4, 'little', signed=True))
|
||||||
|
|
||||||
uhid_device = UHIDDevice(fd)
|
uhid_device = UHIDDevice(fd)
|
||||||
uhid_device.rdesc = list(flatten(rdesc))
|
uhid_device.rdesc = list(flatten(rdesc))
|
||||||
|
|
Loading…
Reference in New Issue