quo / ithc-linux

Linux driver for Intel Touch Host Controller
37 stars 7 forks source link

Weird behavior on Nixos and Sway #10

Closed aacebedo closed 2 years ago

aacebedo commented 2 years ago

Hi

First thanks a lot for your amazing work !

I've compiled ithc on nixos. When I load the module with insmod, the ithc module appears in lsmod but it is also listed in hid. Mouse clicks are working even if I do not use iptsd. I thought that when hid was not passed as an option it would not have worked. However it is acting weird:

NP-chaonay commented 2 years ago
  • but other not (firefox)

idk if that about XWayland

aacebedo commented 2 years ago

I do not use XWayland. For firefox I had to add "MOZ_USE_XINPUT2=1" as an environment variable to enable the scrolling. However the other issues are still there unfortunately.

NP-chaonay commented 2 years ago

MOZ_USE_XINPUT2

I think that is weird becuase xinput is part of X11, so it should not work on pure Wayland.

And in firefox, you have to force export program env variable for it to use in pure wayland that without X11 support, in that case you should be able to use firefox with touch event without set MOZ_USE_XINPUT2. (I have tested on this, as I tell)

aacebedo commented 2 years ago

You were right. the firefox package of nix I was using relies on Xwayland. I switched to the wayland version and the environment variable is not needed. anymore. The others behaviors are still here though. I do not have another touch enabled device to check if it is related to sway or not.

qzed commented 2 years ago

When I load the module with insmod, the ithc module appears in lsmod but it is also listed in hid.

That means the ithc module depends on the hid module. Which sounds correct.

Regarding differences with/without IPTSd: Without IPTSd, only single-touch will work. The Surface touch controller requires processing for multi-touch, which is done by IPTSd. It can work in a fallback mode if IPTSd is not present, in which case only single-touch will work.

Impossible to hold a mouse press when drop and dragging

That could be due to bad IPTSd processing. That still has some kinks. You could try lighter or stronger presses and see if that makes a difference. Could be either noise-related problems or the palm-detection heuristic going wrong.

I can move some sway floating windows with the floating modifier (foot) but other not (firefox)

That's a compositor/desktop env issue. As @NP-chaonay said, most likely X11/Xwayland related. Especially window decorations for Xwayland apps seem to cause problems, whereas Wayland apps seem to work.

NP-chaonay commented 2 years ago

could aacebedo gives model you are using, this seem to be 1 of useful info.

aacebedo commented 2 years ago

I am using a SP7+

@qzed lighter presses or using nails definitely work better. Also noticed that thumb presses are less efficient too.

For firefox and the floating modifier, I am sure now that XWayland is not ran anymore but I still can't move a floating window with the modifier pressed. But I think you are right it is related to the WM.

Is there any specific values for the iptsd configuration to improve touch detection ?

NP-chaonay commented 2 years ago

I am using a SP7+

@qzed lighter presses or using nails definitely work better. Also noticed that thumb presses are less efficient too.

For firefox and the floating modifier, I am sure now that XWayland is not ran anymore but I still can't move a floating window with the modifier pressed. But I think you are right it is related to the WM.

Is there any specific values for the iptsd configuration to improve touch detection ?

take a look at /etc/ipts, you can just restart iptsd service to reapply settting

nhatminhhp1999 commented 2 years ago

I am using a SP7+ @qzed lighter presses or using nails definitely work better. Also noticed that thumb presses are less efficient too. For firefox and the floating modifier, I am sure now that XWayland is not ran anymore but I still can't move a floating window with the modifier pressed. But I think you are right it is related to the WM. Is there any specific values for the iptsd configuration to improve touch detection ?

take a look at /etc/ipts, you can just restart iptsd service to reapply settting

So, is there any update for xwayland? or fix

NP-chaonay commented 2 years ago

I am using a SP7+ @qzed lighter presses or using nails definitely work better. Also noticed that thumb presses are less efficient too. For firefox and the floating modifier, I am sure now that XWayland is not ran anymore but I still can't move a floating window with the modifier pressed. But I think you are right it is related to the WM. Is there any specific values for the iptsd configuration to improve touch detection ?

take a look at /etc/ipts, you can just restart iptsd service to reapply settting

So, is there any update for xwayland? or fix

idk about this however, and cannot be sure if this from xwayland or wm or wayland itself, but probably last 2