OESF Portables Forum

Model Specific Forums => Gemini PDA => Gemini PDA - Linux => Topic started by: Kiriririn on June 16, 2018, 03:28:30 pm

Title: Touchscreen as touchpad - relative mouse input
Post by: Kiriririn on June 16, 2018, 03:28:30 pm
A video is worth 1000 words:

https://www.youtube.com/watch?v=bsJn3eMvG7w (https://www.youtube.com/watch?v=bsJn3eMvG7w)

tl;dw this technique changes the touchscreen from an absolute mode touchscreen (which is too fiddly for full linux desktop use) into a relative mode touchpad like on most laptops


Easy mode:Hard mode:

(Instead of installing mtrack from debian repos, there is an improved version that must be built from source...)
Title: Touchscreen as touchpad - relative mouse input
Post by: shinkamui on June 17, 2018, 12:32:33 am
Thank you for this!  Its an excellent start.  Still needs some tweaking, but you've more than got the ball rolling on a very popular request!
Title: Touchscreen as touchpad - relative mouse input
Post by: Kiriririn on June 17, 2018, 07:07:01 am
Quote from: shinkamui
Thank you for this!  Its an excellent start.  Still needs some tweaking, but you've more than got the ball rolling on a very popular request!

Yeah still need to figure out a way to do dragging that doesn't emit a click before doing so, though I reckon this will either require two fingers or add click latency

Edit: it's possible but fiddly by holding with one finger and moving a second
Title: Touchscreen as touchpad - relative mouse input
Post by: mithrandir on June 17, 2018, 09:14:57 am
Thx. Very nice work!
Now we have to get this switchable via hotkey... Which seems not no be that easy because of the currently required restart.

Are the different mouse clicks (right,left,middle) already handled somehow? What about scrolling?
Title: Touchscreen as touchpad - relative mouse input
Post by: Kiriririn on June 17, 2018, 10:34:33 am
Quote from: mithrandir
Thx. Very nice work!
Now we have to get this switchable via hotkey... Which seems not no be that easy because of the currently required restart.

Are the different mouse clicks (right,left,middle) already handled somehow? What about scrolling?

Not sure how you'd go about switching it, personally I don't see a need for any other mode than this but your needs may be different

Right click is two finger tap, scrolling is two finger scroll, left click is just tap, left click drag is hold then move a second finger, not sure about middle mouse but it should be configurable as 3 finger tap or similar

Scrolling a bit shit and left click drag doesn't work unless you install the latest version ('hard mode' above)
Title: Touchscreen as touchpad - relative mouse input
Post by: mifritscher on June 18, 2018, 01:39:39 am
Switching would be nice for applications like xournal or other painting applications. Perhaps this possible by not replacing, but addding the driver and then disable always one of them via xinput?

Bit its ndeed a good start!
Title: Touchscreen as touchpad - relative mouse input
Post by: mithrandir on June 18, 2018, 06:47:58 am
Quote from: mifritscher
Switching would be nice for applications like xournal or other painting applications. Perhaps this possible by not replacing, but addding the driver and then disable always one of them via xinput?

Bit its ndeed a good start!

Tried yesterday, but no success so far. Some applications, i.e.,Chrome work better with the "simple" touch interface. Also for the desktop itself the simple interface seems better with a window manager optimized for touch (unsure which one to use). But many applications or parts of it are nearly unusable without control of the mouse pointer. Therefore switching would be great.
Title: Touchscreen as touchpad - relative mouse input
Post by: psionlover on June 25, 2018, 07:07:19 pm
Quote from: Kiriririn
A video is worth 1000 words:

https://www.youtube.com/watch?v=bsJn3eMvG7w (https://www.youtube.com/watch?v=bsJn3eMvG7w)

tl;dw this technique changes the touchscreen from an absolute mode touchscreen (which is too fiddly for full linux desktop use) into a relative mode touchpad like on most laptops
Thanks very much, this makes the gebian much better to handle. I only don't get a grip on the dragging, sometimes it works but mostly not.
Title: Touchscreen as touchpad - relative mouse input
Post by: Kiriririn on June 26, 2018, 06:51:06 am
Quote from: psionlover
Quote from: Kiriririn
A video is worth 1000 words:

https://www.youtube.com/watch?v=bsJn3eMvG7w (https://www.youtube.com/watch?v=bsJn3eMvG7w)

tl;dw this technique changes the touchscreen from an absolute mode touchscreen (which is too fiddly for full linux desktop use) into a relative mode touchpad like on most laptops
Thanks very much, this makes the gebian much better to handle. I only don't get a grip on the dragging, sometimes it works but mostly not.

The most consistent dragging is by holding one finger and moving another.

Annoyingly the synaptics-style 'double tap but drag rather than releasing the second tap' gesture doesn't work right in mtrack as it emits the first tap, preventing dragging anything that might react to a single tap.
Title: Touchscreen as touchpad - relative mouse input
Post by: psionlover on June 27, 2018, 01:07:47 pm
Quote from: Kiriririn
The most consistent dragging is by holding one finger and moving another.
Dooesn't work with my version of fingers   But found a more consistent workaround for my fingers: Alt + tap-drag  
Title: Touchscreen as touchpad - relative mouse input
Post by: abgd on July 10, 2018, 09:33:08 pm
Works really well. Thanks very much for this tip.
Title: Touchscreen as touchpad - relative mouse input
Post by: Varti on July 11, 2018, 04:48:18 am
Quote from: abgd
Works really well. Thanks very much for this tip.
Thanks from me too, I'll definitively use it once I'll install Gemian.

Varti
Title: Touchscreen as touchpad - relative mouse input
Post by: Alexi Pistonrod on September 19, 2018, 03:46:47 pm
Quote from: Kiriririn
A video is worth 1000 words:

https://www.youtube.com/watch?v=bsJn3eMvG7w (https://www.youtube.com/watch?v=bsJn3eMvG7w)

tl;dw this technique changes the touchscreen from an absolute mode touchscreen (which is too fiddly for full linux desktop use) into a relative mode touchpad like on most laptops


Easy mode:
  • sudo apt install xserver-xorg-input-mtrack
  • Edit /usr/share/X11/xorg.conf.d/40-libinput.conf, find:
    Code: [Select]
    Section "InputClass"
            Identifier "libinput touchscreen catchall"
            MatchIsTouchscreen "on"
            MatchDevicePath "/dev/input/event*"
            Driver "libinput"
    EndSection
    Replace with:
    Code: [Select]
    Section "InputClass"
            Identifier "libinput touchscreen catchall"
            MatchIsTouchscreen "on"
            MatchDevicePath "/dev/input/event*"
            Driver "mtrack"
            Option "ScrollDistance" "40"
            Option "FingerLow" "1"
            Option "FingerHigh" "2"
            Option "Sensitivity" "1.8"
            Option "BottomEdge" "0"
            Option "SwipeDistance" "100"
            Option "ScaleDistance" "40"
            Option "ButtonMoveEmulate" "false"
            Option "ClickTime" "25"
            Option "MaxTapMove" "55"
            Option "EdgeBottomSize" "0"
    EndSection
  • sudo systemctl restart sddm or reboot
  • Recommended to disable acceleration in the LXQT mouse settings GUI
Hard mode:

(Instead of installing mtrack from debian repos, there is an improved version that must be built from source...)
  • Config edit as above
  • Enter a suitable empty directory
  • Install the standard debian build tools
  • sudo apt install xserver-xorg-dev libmtdev-dev xutils-dev
  • git clone https://github.com/p2rkw/xf86-input-mtrack (https://github.com/p2rkw/xf86-input-mtrack)
  • cd into the downloaded folder
  • ./configure --prefix=/usr
  • dpkg-buildpackage -uc -us
  • cd ..
  • sudo dpkg -i xserver-xorg-input-mtrack_0.5.0_arm64.deb
  • sudo systemctl restart sddm or reboot
  • Recommended to disable acceleration in the LXQT mouse settings GUI



Thanks for this , applied it and it is great however there seem to be many many options we can use to tweak the driver and I am not clear how to click and drag accurately.

How much have you experimented with the settings?
Title: Touchscreen as touchpad - relative mouse input
Post by: Kiriririn on September 19, 2018, 07:55:19 pm
Quote from: Alexi Pistonrod
Thanks for this , applied it and it is great however there seem to be many many options we can use to tweak the driver and I am not clear how to click and drag accurately.

How much have you experimented with the settings?

For click and drag, touch and hold with one finger, then add a second finger anywhere on the screen and drag with the second finger, keeping the first finger stationary

Unfortunately the 'synaptics-style' click and drag (where you double tap but start dragging on the second tap) doesn't work reliably as it emits a click from the first tap (presumably to avoid input lag)
Title: Touchscreen as touchpad - relative mouse input
Post by: gemini_user_j on November 03, 2018, 12:35:02 pm
Quote from: Kiriririn
  • Edit /usr/share/X11/xorg.conf.d/40-libinput.conf, find:
This is amazing!

I have two practical questions, if anyone knows:

1) Is it possible to switch between original behaviour, and the one you enabled by switching between two versions or the file I quoted above?

2) Is it possible to flip the scrolling direction?
Title: Touchscreen as touchpad - relative mouse input
Post by: ArchiMark on February 13, 2019, 05:16:12 pm
Installed, but have problem getting the button in lower left corner of screen to work now.

I can get taskbar to be visible (it is set to auto-hide to get more vertical height on screen) and can select the button in lower left (it turns blue color), but I cannot get it open up to see all the program selections by tapping on it with finger.

Is there a way to do this with finger tap or is there a key combination to get it open up or ???

Also, is there way to calibrate cursor on screen. It is far off from my finger tap.

Thanks for any help.

Mark
Title: Touchscreen as touchpad - relative mouse input
Post by: Kiriririn on February 15, 2019, 02:51:32 pm
Quote from: ArchiMark
Installed, but have problem getting the button in lower left corner of screen to work now.

I can get taskbar to be visible (it is set to auto-hide to get more vertical height on screen) and can select the button in lower left (it turns blue color), but I cannot get it open up to see all the program selections by tapping on it with finger.

Is there a way to do this with finger tap or is there a key combination to get it open up or ???

Also, is there way to calibrate cursor on screen. It is far off from my finger tap.

Thanks for any help.

Mark

The whole point of this is to disconnect your cursor from your finger so you can see what youre aiming at and make finer mouse-like actions

It sounds like you're still trying to use the touchscreen like a touchscreen. This behaves more like the Teamviewer or MS RDP apps on Android if youve used those
Title: Touchscreen as touchpad - relative mouse input
Post by: ArchiMark on February 15, 2019, 03:44:27 pm
Quote from: Kiriririn
Quote from: ArchiMark
Installed, but have problem getting the button in lower left corner of screen to work now.

I can get taskbar to be visible (it is set to auto-hide to get more vertical height on screen) and can select the button in lower left (it turns blue color), but I cannot get it open up to see all the program selections by tapping on it with finger.

Is there a way to do this with finger tap or is there a key combination to get it open up or ???

Also, is there way to calibrate cursor on screen. It is far off from my finger tap.

Thanks for any help.

Mark

The whole point of this is to disconnect your cursor from your finger so you can see what youre aiming at and make finer mouse-like actions

It sounds like you're still trying to use the touchscreen like a touchscreen. This behaves more like the Teamviewer or MS RDP apps on Android if youve used those


Thanks for your help!

Now I get understand the concept....

Will try it again....

Not familiar with apps you mention....I don't use Android...

 
Title: Touchscreen as touchpad - relative mouse input
Post by: peter on June 14, 2019, 02:31:08 am
The "Easy Mode" fix worked perfectly for me with TP2, but I cannot get it to work with TP3.  (I haven't tried building from source yet.)  Can anyone confirm if this works with the latest Gemian image?

Thanks!
Title: Touchscreen as touchpad - relative mouse input
Post by: peter on June 17, 2019, 04:35:15 pm
Quote from: peter
The "Easy Mode" fix worked perfectly for me with TP2, but I cannot get it to work with TP3.  (I haven't tried building from source yet.)  Can anyone confirm if this works with the latest Gemian image?

Thanks!

Never mind.  I feel pretty stupid, but when I went to remove mtrack prior to building from source, I discovered that it wasn't installed.  sudo apt install fixed the PEBCAK.
Title: Touchscreen as touchpad - relative mouse input
Post by: geminifrench on April 01, 2020, 12:20:44 pm
my debian install has 2 week max.

I have made :
apt install xserver-xorg-input-mtrack
and replace the code in  /usr/share/X11/xorg.conf.d/40-libinput.conf.
systemctl restart sddm, made logout.

after that, the touchscreen not working at all. The mouse still working.
if i restore the 40-libinput.conf and loging again, it works normaly.

An idea of problem ?



edit :
there is a file 50-mtrack.conf in same directory. Maybe help.

edit 2 :
i have made "hard mode" with compilation, the problem is not solved. Just the file 50-mtrack.conf has disappeared.
Title: Re: Touchscreen as touchpad - relative mouse input
Post by: LittleHouse75 on May 03, 2021, 12:58:21 pm
I realize it's three years later, but I got natural scrolling to work by adding these configurations:

Code: [Select]
        Option "ScrollDownButton"       "4"
        Option "ScrollUpButton"         "5"
        Option "ScrollLeftButton"       "7"
        Option "ScrollRightButton"      "6"


... as noted here:

https://github.com/BlueDragonX/xf86-input-mtrack/issues/113
Title: Re: Touchscreen as touchpad - relative mouse input
Post by: kentborg on April 10, 2022, 02:23:41 pm
Anyone done this recently?

This worked for me several years ago, but I am re-deploying my Gemini and it get a frozen pointer from the mtrack driver.

Suggestions?

Thanks,

-kb

P.S. Why did OESF delete my account? Sure, I haven't been active but…annoying.
Title: Re: Touchscreen as touchpad - relative mouse input
Post by: Varti on April 15, 2022, 03:15:58 am
P.S. Why did OESF delete my account? Sure, I haven't been active but…annoying.
Hi,

we don't have the policy of deleting inactive accounts, we only delete the spambots ones, or they are deleted by the users themselves. Please check your PM, I'll see what has happened to your account.

Varti