Install Android ADB on Ubuntu Linux

To install Android ADB (Android Debug Bridge) on Ubuntu, you can follow these steps:

Identify the Vendor ID:

Connect your Android device to your computer and run the following command to identify the vendor ID:

lsusb

Look for the line that corresponds to your Android device. The vendor ID is the first part of the ID after ID, for example, 18d1 for Google.

Update Your Package List: Open your terminal and update the package list to ensure you have the latest information on the newest versions of packages and their dependencies.

sudo apt update

Install ADB: You can install the ADB package using the following command:

sudo apt install android-tools-adb

Verify Installation: After installation, you can verify that ADB is installed correctly by checking its version:

adb version

Add Your User to the Plugdev Group (Optional): This step ensures that you can use ADB without root permissions. It’s especially useful when working with devices.

sudo usermod -aG plugdev $USER

Then, log out and log back in to apply the changes.

Set Up Udev Rules (Optional): To communicate with your Android device over USB, you might need to set up udev rules. Create a new udev rules file:

sudo nano /etc/udev/rules.d/51-android.rules

Add the following line to the file, replacing xxxx with your device’s USB vendor ID (you can find a list of these IDs online or in the documentation for your device):

SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", MODE="0666", GROUP="plugdev"

Save and close the file, then reload the udev rules:

sudo udevadm control --reload-rules

Now, you should have ADB installed and configured on your Ubuntu system. You can connect your Android device and start using ADB commands.

Disabling the track stick in Linux

xinput list
 ⎡ Virtual core pointer                    	id=2
 ⎜   ↳ Virtual core XTEST pointer              	id=4
 ⎜   ↳ Wacom Graphire2 4x5 eraser              	id=9
 ⎜   ↳ Wacom Graphire2 4x5 cursor              	id=10
 ⎜   ↳ Wacom Graphire2 4x5                     	id=11
 ⎜   ↳ AlpsPS/2 ALPS DualPoint TouchPad        	id=14
 ⎜   ↳ Macintosh mouse button emulation        	id=15
 ⎜   ↳ DualPoint Stick                         	id=13
 ⎣ Virtual core keyboard                   	id=3
     ↳ Virtual core XTEST keyboard             	id=5
     ↳ Video Bus                               	id=6
     ↳ Power Button                            	id=7
     ↳ Sleep Button                            	id=8
     ↳ AT Translated Set 2 keyboard            	id=12

The device I want to disable has id 13. Use xinput to list its properties:

xinput -list-props 13

Device ‘DualPoint Stick’:
Device Enabled (117): 0
[…several lines removed…]

xinput -set-prop 13 117 0

Once I knew the solution, I could easily find other posts that mentions it. But what good is that?🙂

Actually, the device is is dynamically allocated, and can change. So a better command to disable the stick is:

xinput -set-prop "DualPoint Stick" "Device Enabled" 0

References
https://cederlys.wordpress.com/2010/07/13/disabling-the-track-stick-in-ubuntu/