Results 1 to 3 of 3
Thread: [How To] Install ADB and Logcat
-
05-01-2011, 02:51 PM #1
[How To] Install ADB and Logcat
So everyone has been asking how they can help and the best way to help dev's is to capture a log of the issue happening and submit it to us. This tutorial will teach you how to install and capture a log cat for us.
Please Read the Tutorial all the way through before trying to install this. Directions in the a step MAY appear after the screenshot in that step.
Windows Tutorial
1. Download the Android SDK HERE for your operating system. For this tutorial we want to use android-sdk_r10-windows.zip (yes ignore the "recommended" one) Please remember where you have downloaded this ZIP file to.

Once the SDK is downloaded we will need to install it. To make this easier lets just move the android-sdk_r10-windows zip to your desktop for the time being. You can move it elsewhere once it is installed and running.
2. Unzip the the file to the desktop. When complete you should see

3. Now we are going to click on the "SDK Manager.exe" This should first bring up a command prompt window followed by the screen seen below. We want to hit Cancel

4. Once you press cancel you should get to a screen that looks like

UPDATE: use the most recent one
You want to check the box next to "SDK Platform Android 3.0, API 11, Revision 1" as seen in the screenshot above.
See the Next post belowLast edited by wowthatisrandom; 11-15-2011 at 01:06 PM.
-
The Following User Says Thank You to wowthatisrandom For This Useful Post:
Marhey (08-15-2011)
-
05-01-2011, 03:00 PM #2
5. Once Complete click "Install Selected" and follow the the wizard through the installation. When its finished you should be at a screen that looks similar to

We are now done installing the SDK so you can close the window above as well as the command prompt window.
6. Now in your android-sdk_r10-windows folder you should navigate to the platform-tools folder. When inside you should see the following

If you have gotten to this point we the Android SDK as well as ADB installed! Good job so far!
Now that all the installation stuff is out of the way, I am now going to walk you through using ADB to create a log.
How to use ADB to create a logcat
1. On your computer click Start---> Run... as shown in the image below

2. Once you click on Run... you should get a box that looks similar to the one shown below. Please type "cmd" (without the quotes) and press enter

-
The Following User Says Thank You to wowthatisrandom For This Useful Post:
Marhey (08-15-2011)
-
05-01-2011, 03:21 PM #3
3. Once you have pressed enter you should make it to a screen that looks like the top image(cmd prompt) in the screenshot below.

This part is probably the trickiest part, so please pay attention. We need to set the command prompt to the correct folder that has ADB. Notice in the bottom image (The folder) in the screenshot above the path is located at the top of the window, it looks like a web address minus the www. in the screenshot above the path is "C:\Documents and Settings\TFPOS3\Desktop\android-sdk_r10-windows\android-sdk-windows\platform-tools" Copy this ENTIRE path by highlighting and pressing ctrl + C.
3.5 Once we have the path copied to the clipboard, we are going to click back into the cmd prompt window and type the following (without the quotes)
"cd " yes there is a space after the d. Once that is done we r going to right click and choose paste. the end result should be "cd C:\Documents and Settings\TFPOS3\Desktop\android-sdk_r10-windows\android-sdk-windows\platform-tools" as seen in the screenshot above. Then press enter.
At this point you should be at the command line should be sitting like
C:\Documents and Settings\TFPOS3\Desktop\android-sdk_r10-windows\android-sdk-windows\platform-tools>
4. Before we can logcat we need to make sure your phone has USB debugging mode turned on. To do this turn on your phone, go to your homescreen, press menu--> settings, choose Programs at the top, choose Development Settings from that menu and turn on USB Debugging mode. The screenshot below shows debugging turned on.

Now there are 2 different approaches to the logcat i will be showing you how to do both in this tutorial. Neither one is more correct than the other it is 100% personal preference. Feel free to try both and see where you get. I'm going to label them as 5a and 5b.
5a. Logcat inside of the cmd prompt window.
make sure your phone is plugged in and usb debugging mode is enabled (step 4). once this is done we are going to type the following command
adb logcat
This should initiate the logcat and your command prompt will begin to fill with a bunch of text (it makes no difference whether or not you understand it, we do that is all that matters).
Important: once the logcat is running, please RECREATE the bug/issue you are having. to stop the logcat on your keyboard press ctrl+c.

once this is done please RIGHT CLICK choose Select All then press "Enter" on your keyboard this will copy the entire log to the clipboard. Once this is complete visit logcat.miui.us (this is not setup yet but will be shortly, in the meantime feel free to use www.pastebin.com) and paste your log there and submit. then grab the link from the address bar (something like http://logcat.miui.us/1234567) and paste it in the forum with your bug.
5b. Logcat to text file
update for those of you who are not comfortable with command prompt you can use this script created by CaptSk1ttles (thanks man!). just download the script and click it... it will create a logcat.txt file for you and put it in your sdk folder. if you want to do it manually continue reading.
make sure your phone is plugged in and usb debugging mode is enabled (step 4). once this is done we are going to type the following command
adb logcat > logcat.txt
This should initiate the logcat it will appear as tho nothing is happening, this is correct!!
Important: once the logcat is running, please RECREATE the bug/issue you are having. to stop the logcat on your keyboard press ctrl+c.
what you have just done is created a text file of the log. The text file will be located ...\android-sdk_r10-windows\android-sdk-windows\platform-tools

Once this is complete post the logcat.txt file along with your bug in the correct forum and we will look into it.
Thanks so much for reading and please let me know if you have any questions.
A mac tutorial will not be too far behind.Last edited by wowthatisrandom; 05-02-2011 at 07:12 PM.
-
The Following 3 Users Say Thank You to wowthatisrandom For This Useful Post:
BenRad (09-21-2011), Marhey (08-15-2011), outlawbishop (07-13-2011)
Bookmarks