Invoke the right mouse button function by long press on the resistive touch screen

SunSun
edited February 6 in TFT-LCD & Touch Screen

In Raspberry Pi Raspbian system, how to invoke the right mouse button function by long press on the resistive touch screen?

1. In Raspbian system, you have to install the driver of the resistive screen first to make sure the touch can work properly.

2. Open the 99-calibration.conf file by executing the following command code

sudo nano /etc/X11/xorg.conf.d/99-calibration.conf

3. Add the following code to the 99-calibration.conf file:

   Option "EmulateThirdButton" "1"
   Option "EmulateThirdButtonTimeout" "1000"
   Option "EmulateThirdButtonMoveThreshold" "300"

Before adding:

After adding:


Press Ctrl+X to exit


Confirm saving by pressing the Y key

Press Enter to confirm saving the file name.


4. Execute the following command code to reboot the Raspberry Pi :

  sudo reboot

5. Long press the resistive touch screen, you can trigger the right mouse button function. The effect is as follows:


Note: If you can't find the 99-calibration.conf file, please install the latest driver and confirm whether it is a resistive touch screen, this method is only for resistive touch screen, capacitive screen is not applicable.

Tagged:
Sign In or Register to comment.