NetBSD-Users archive

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

Re: HUION tablet

On Fri, 19 May 2023, adr wrote:
The parameters reported are correct, and the movements on the tablet
correspond to the screen, but when I touch the tablet with the
stylus the behaviour is odd (I can't really describe it, when using
azpainter if I move the stylus fast the lines are dotted, but in
the wm the behaivour doesn't correspond exactly as a repeated

I found the problem. The report descriptor I made needed padding.
The system were reading the first bytes corresponding to the
descriptor and treating the rest as another report with wrong

The driver detects the tablet correctly, the debugging info shows
that the pressure is read:

[    60.431] UsbTabletReadInput sending to Stylus
[    60.431] UsbTabletSendEvents Stylus x=19766 y=3625 pressure=0 buttons=0 xTil
t=0 yTilt=0 proximity=1, invert=0, eraser=0
[    60.431] UsbTabletSendEvents: motion
[    60.431] UsbTabletReadInput reading fd=13 len=11
[    60.431] UsbTabletReadInput len=-1
[    60.431] UsbTabletReadInput END   pInfo=0xf34817f03700 priv=0xf34817eeb780
[    60.435] UsbTabletReadInput BEGIN device=/dev/uhid3 fd=13
[    60.435] UsbTabletReadInput reading fd=13 len=11
[    60.435] UsbTabletReadInput len=11
[    60.435] UsbTabletReadInput sending to Stylus
[    60.435] UsbTabletSendEvents Stylus x=19559 y=3607 pressure=35 buttons=0 xTi
lt=0 yTilt=0 proximity=1, invert=0, eraser=0
[    60.435] UsbTabletSendEvents: motion
[    60.435] UsbTabletReadInput reading fd=13 len=11
[    60.435] UsbTabletReadInput len=-1
[    60.435] UsbTabletReadInput END   pInfo=0xf34817f03700 priv=0xf34817eeb780
[    60.439] UsbTabletReadInput BEGIN device=/dev/uhid3 fd=13
[    60.439] UsbTabletReadInput reading fd=13 len=11
[    60.439] UsbTabletReadInput len=11
[    60.439] UsbTabletReadInput sending to Stylus
[    60.439] UsbTabletSendEvents Stylus x=19353 y=3592 pressure=270 buttons=0 xT
ilt=0 yTilt=0 proximity=1, invert=0, eraser=0
[    60.235] UsbTabletSendEvents Stylus x=24382 y=5022 pressure=400 buttons=0 xTilt=0 yTilt=0 proximity=1, invert=0, eraser=0
[    60.235] UsbTabletSendEvents: motion
[    60.235] UsbTabletReadInput reading fd=13 len=11
[    60.235] UsbTabletReadInput len=-1
[    60.235] UsbTabletReadInput END   pInfo=0xf34817f03700 priv=0xf34817eeb780
[    60.237] UsbTabletReadInput BEGIN device=/dev/uhid3 fd=13
[    60.237] UsbTabletReadInput reading fd=13 len=11
[    60.237] UsbTabletReadInput len=11
[    60.237] UsbTabletReadInput sending to Stylus
[    60.237] UsbTabletSendEvents Stylus x=24382 y=5007 pressure=554 buttons=1 xTilt=0 yTilt=0 proximity=1, invert=0, eraser=0

Note how the button 1 is activated when the pressure exceeds the threshold.
But applications (azpainter, drawing) don't detect the pressure...

I'll take a look at the driver an how applications use the xinput2
extension. So close...


Home | Main Index | Thread Index | Old Index