Go to TogaWare.com Home Page. GNU/Linux Desktop Survival Guide
by Graham Williams
Duck Duck Go



CLICK HERE TO VISIT THE UPDATED SURVIVAL GUIDE

ADB Android Debug Bridge

20200121 The Android Debug Bridge is an application that runs on a computer to communicate with a USB connected Android device. Begin by changing settings on the Android device, under Developer options, to enable USB debugging. Then connect the device and click OK on the popup seeking permission for remote access. If in the device listing below it says unauthorised instead of device then the popup on the device has probably not provided the right permissions. Sometimes re-plugging the device will do the trick to show the popup on the device.

On Ubuntu install the command line application:

$ wajig install adb

$ adb devices
List of devices attached
bf0546056101270a02	device

Start up a shell running on the Android device connected via a daemon which is started up if it is not already running:

$ adb shell

Common GNU/Linux shell commands can now be utilised to navigate the device's operating system.

herolte:/ $ ls
[...]
1|herolte:/ $ cd storage/emulated/0
[...]
herolte:/storage/emulated/0 $ ls
[...]
Here, herolte is the code name for the Samsung Galaxy S7.

Type Ctrl-d or the exit command to exit from the shell.

If the daemon is not running it will automatically start up with the message:

* daemon not running; starting now at tcp:5037
* daemon started successfully

In the following circumstance, do as suggested—check for the confirmation dialog on the device:

$ adb shell
error: device unauthorized.
This adb server's $ADB_VENDOR_KEYS is not set
Try 'adb kill-server' if that seems wrong.
Otherwise check for a confirmation dialog on your device.

See https://developer.android.com/studio/command-line/adb for details.


Support further development by purchasing the PDF version of the book.
Other online resources include the Data Science Desktop Survival Guide.
Books available on Amazon include Data Mining with Rattle and Essentials of Data Science.
Popular open source software includes rattle and wajig.
Hosted by Togaware, a pioneer of free and open source software since 1984.
Copyright © Togaware Pty Ltd. . Creative Commons ShareAlike V4.