Table of Contents

Use adb

Android Debug Bridge (adb) is a versatile command-line tool that lets you communicate with a device.

Install adb tool

Linux

Install the adb tool on PC Host:

sudo apt-get update
sudo apt-get install android-tools-adb

Add permission and configuration files

Add permission and configuration details after installation.

Add permission

sudo useradd -G plugdev $USER

Write configuration files

Create a .rules file:

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

Write the following to the .rules file:

SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", MODE="0666"

Restart udev service

sudo /etc/init.d/udev restart

Windows

  • Download and install the USB driver
    • VIM1/2/3/3L/4/1S
      • Download the USB driver and extract it to somewhere.
      • Double click dpscat.exe to install the driver. Please note there is no GUI display.
      • Double click dpinst64.exe to install the driver.
    • Edge1/2
      • Download the USB driver and extract it to somewhere.
      • Double click DriverInstall.exe to install the driver.
  • Download the platform tools
  • Unzip the platform tools file to the easily accessible directory, such as C:\platform-tools

When executing the adb command in the cmd terminal, you need to enter the C:\platform-tools directory, otherwise it will prompt that the adb command cannot be found.

Use adb

ADB over Wi-Fi/LAN

adb connect 192.168.1.120
adb shell

ADB over USB

adb shell
  • If you android device is a phone, you must enable developer mode
  • When you try to debug your Android device with adb devices, a notification will appear that you must accept
  • If your Android device is a Khadas SBC, developer mode is enabled by default