This article will explain how to install and collect ADB logs on an android device.
- Windows device
- USB cable
- Download SDK Platform Tools to your Windows device from Android website.
- Unzip the folder by right-clicking the downloaded zip file and selecting Extract all as seen below.
- Start Command prompt. You can do so by pressing the Windows button on your keyboard or selecting the Windows menu from the toolbar. Once the menu is open you can either select Command Prompt from the menu or simply type cmd for it to match it with the application as seen below on Windows 11.
- On your Android device activate “Developer options” from “Settings > About phone > Software information” by tapping “Build number” for many times until a notification appears on the screen saying that developer mode is being turned on. This would also make Developer options to appear under Settings as seen below.
- Connect the device to your PC with a USB cable. Worth noting that the cable should be connected directly to the computer and not via a hub for example for it to function properly.
- On your Android device enable ”USB debugging” from the device “Settings > Developer options > USB debugging” and allow the action as seen below.
- Type Adb logcat -v threadtime >logcat.txt to command prompt.
- Press Ctrl+C to stop the log from running and you will now see the following on your screen.
- Logcat.txt file will now appear in the folder where you have installed Platform Tools.
When connecting the device to your PC with a USB cable make sure that the cable is connected directly to the computer and not via a hub for example for it to function properly.
If USB debugging has been disabled from the server ADB will not work properly.