ADB Help with one part! - G2 and Desire Z Q&A, Help & Troubleshooting

So I'm reading through the guide "ADB For Noobs" and I'M STUCK. I can't figure out this one part... it says
Find the "Path" variable in the list of variables that it shows (you might need to scroll), and then double-click on that entry to edit it. Add the full path of the "tools" and "platform-tools" folders of the SDK to your path. e.g. if the SDK has been installed in "c:\Program Files\android-sdk-windows", then add to your Path "c:\Program Files\android-sdk-windows\tools;c:\Program Files\android-sdk-windows\platform-tools"
I'm confused what I'm supposed to add.... Can someone direct me please?
I'm using windows xp btw.

Related

getting adb to work???

I followed this
(Setting up the Android SDK
Download the file from above
Unzip to your desktop
Take the "android-sdk-windows" folder and move it to the root of your hard drive (C:\)
Right click on My Computer and click properties
Select the Advanced Tab or Advanced System Setting (Vista/Windows 7)
Select Environment Variables...
Press New
For Variable Name type: adb
For Variable Value type: C:\android-sdk-windows\tools)
and when I try to do this
(1. Run SDK Setup.exe
2. If it gives you an error go to settings and click on "Force http//....."
3. Select all options and let it download and install)
I have issues cause I dont have the SDK Setup.exe I have searched for it and can not find it, please help thanks Davey
also I installed the windows version
http://developer.android.com/sdk/index.html
If you've added the tools folder to your path, you don't need to install anything, just type "adb <command>" in the cmd prompt and you're good to go.
if you talking about this
For Variable Name type: adb
For Variable Value type: C:\android-sdk-windows\tools)
yes i have done it and it still wont work. I have my phone is debugging and on charge only and when i open the cmd and type in adb it gives me is not recoginzied as an internal or external command, operable program or batch file,
then when i type (android-sdk-windows\tools) it gives me the system cannot find the path specified. I am lost
ok So on my other computer I got some progress, I opened sdk manager and got it all updated and the only real problem i am having now is (this is dumb) but I dont know my sdk name, like when it says
cd C:\**your sdk name**\tools (Press Enter)
I have been trying C:\android-sdk-windows\tools
thanks for the help! Davey
thank you I got it running now!!!!!! I did what you said and added it to the path not just a new varibable, thank you very much!!!

G2; How to initiate/ launch adb

ok,,,noob here.. but not a dummy. I want to load music on my sd card. I have downloaded everything I think I'm supposed to have.. SDK, adb, drivers eclipse java program...I'm running vista 32 and have created C:\program files\Android\android-sdk-windows. I have extracted all files I think all the drivers. I have spent some considerable time (wee hours ..) I can start the sdk .exe and the java eclipse but how do I use it to connect to my usb connected phone? I want to load data onto my sd card. BTW I have temprooted with VISIONary r14.
The cmd prompt window that comes up with the sdk .exe does not respond to typing in it. Commands typed into the computer's cmd prompt are not recognized. Or maybe I'm typing the wrong thing. I can't navigate to the android folder, to find my usb'd phone. I have read a lot of posts here trying to figure this out..I'm really at wits end anybody please help!!! I thought there'd be a desktop lauch icon..haha.
There's a guide for using ADB in the dev forum: http://forum.xda-developers.com/showthread.php?t=865685
If you are just trying to put music on your SD card though, I don't think you need to do all of this. Just mount the SD card once your phone is connected to your computer (there will be an option that appears in your notification drawer to do this). Your SD card will then show up as a drive on your computer...
I saw that guide..Step 4 doent apply on vista.."My Computer" and the path that is described is not on Vista, or anything similar. I can't "update your Path variable." It did not say HOW TO LAUNCH! What is it application that I need to work from for adb? I have read every post I could find here..and that one maybe four or 5 times. I want to use adb I can see and browse my SD card as drive F..thanks..I still want to run adb.. I cant type into the sdk cmd pane.
captmack007 said:
I saw that guide..Step 4 doent apply on vista.."My Computer" and the path that is described is not on Vista, or anything similar. I can't "update your Path variable." It did not say HOW TO LAUNCH! What is it application that I need to work from for adb? I have read every post I could find here..and that one maybe four or 5 times. I want to use adb I can see and browse my SD card as drive F..thanks..I still want to run adb.. I cant type into the sdk cmd pane.
Click to expand...
Click to collapse
Whoa whoa whoa! If all you want to do is load music on your phone and your using Windows, either just install Doubletwist on it. It's kind of like iTunes for everything. Or just make a music folder and load your music onto that. No adb needed.
Now, about adb; there is no program to run. You don't really need to set your path either, it just makes things easier. Just cd to the sdk tools folder.
Sent from my HTC Vision
It's not all i want to do...i should not have mentioned it.
cd to the ??
If I wish to make an adb command, what and where do I go/do to do that....on a vista puter....thnkx
I can see tghe adb android interface is there ...I figured out to right click on "computer" "manage", which opens Computer Manager. There in the left column is "Device Manager" clicked on that and I see the Android Phone listed, with subcatagory android adb interface. and down at the bottom under "Portable Devices" HTC is shown. All drivers are showing up and say they are functioning properly.
appreciate the help..
captmack007 said:
It's not all i want to do...i should not have mentioned it.
cd to the ??
appreciate the help..
Click to expand...
Click to collapse
Oh I see. You first mentioned simply putting music on your phone and the next thing you've got a full development emvironment! Lol!
Cd to the tools folder of the android sdk. (Bear with me as I haven't done this on windows in a good long while). For example, open command prompt, then type "cd C:\androidsdk\tools", where the androidsdk part is whatever the sdk is called.
Sent from my HTC Vision
Once you have the android sdk on your computer- change the folder name to something simple so typing is easier. You'll also want to edit the enviornment variables (google is your friend, but I'll post a link tomorrow to help). The latest sdk is missing a dll file - I'm sure one of us can upload it, I just don't remember which one it is right now.
Now that you've got that done open command prompt an type:
cd c:\where\you\put\it (the sdk)
Then type:
adb devices
Or
adb start-server
If you get an error it means you did something wrong.
"cd C:\androidsdk\tools
I'll ad that to the list of command that do nuttin...lol
I downloaded all the sh*t I was told in these threads to dowload...yeah..everything to create an app. lol
I still am waiting to read or be informed of the precise command line that will let me into adb... tfn
thks KCRic... I will give that a shot.. nice tip on renaming the folder..I did not type cd C: first.. (the tuts I've been rackin my brain on did not say that..
I had read that it was missing and found it downloaded it and put it in tools..
the edit the environment variables is what I can't find where to do that.. thanks.
I added the missingAdbWinApi.dll and AdbWinUsbApi.dll and Adb.exe (of course) into the tools folder...
I renamed the folder in Programs\Android..."android-sdk-windows" simply "sdk"
I typed in:
cd c:\program files\Android\sdk\tools
I got in..opened a port..gave me my phones serial #
so this is where adb commands are made? (stupid question perhaps)
I thought the other cmd screen that opens with the sdk.exe was it. And I cant type anything there anyway.
If you have got "adb devices" to show you your phone's serial number, then adb is working find, and you can start using the other adb commands.
Sent from my HTC Desire Z
captmack007 said:
I renamed the folder in Programs\Android..."android-sdk-windows" simply "sdk"
I typed in:
cd c:\program files\Android\sdk\tools
I got in..opened a port..gave me my phones serial #
so this is where adb commands are made? (stupid question perhaps)
I thought the other cmd screen that opens with the sdk.exe was it. And I cant type anything there anyway.
Click to expand...
Click to collapse
Just type "adb", no quotes, and that will give you an output of all the adb commands.
captmack007 said:
I renamed the folder in Programs\Android..."android-sdk-windows" simply "sdk"
I typed in:
cd c:\program files\Android\sdk\tools
I got in..opened a port..gave me my phones serial #
so this is where adb commands are made? (stupid question perhaps)
I thought the other cmd screen that opens with the sdk.exe was it. And I cant type anything there anyway.
Click to expand...
Click to collapse
Yeah you're up and running now. If you typed adb devices or adb usb and got it to list your phones serial # then it's connected and running.
As far as adb commands, you can type adb help to get a list of some and they're pretty easy. Some of them are:
adb push <path\to\file> <where\to\push> - copies files to your phone
adb pull <path\to\file> <where\to\put\it> - copies files from the phone to your computer
adb remount - remounts your device
adb reboot - self explanatory
adb install <path\to\file> - self explanatory
adb start-server - starts adb service
adb kill-server - kills adb process (I always type this in when I'm done, sometimes it doesn't terminate and causes issues)
adb shell <linux type command> - runs command in the device shell
adb shell [enter] - operates in the devices shell until you type {exit}
Once you enter the shell you can type {su} to enter superuser. All commands in the shell are in linux format so if you're unfamiliar with that then do some reading.
HERE is a link that should help with adb also.
KCRic said:
As far as adb commands, you can type adb help to get a list of some and they're pretty easy. Some of them are:
adb push <path\to\file> <where\to\push> - copies files to your phone
adb pull <path\to\file> <where\to\put\it> - copies files from the phone to your computer
adb remount - remounts your device
adb reboot - self explanatory
adb install <path\to\file> - self explanatory
adb start-server - starts adb service
adb kill-server - kills adb process (I always type this in when I'm done, sometimes it doesn't terminate and causes issues)
adb shell <linux type command> - runs command in the device shell
adb shell [enter] - operates in the devices shell until you type {exit}
Once you enter the shell you can type {su} to enter superuser. All commands in the shell are in linux format so if you're unfamiliar with that then do some reading.
HERE is a link that should help with adb also.
Click to expand...
Click to collapse
Apologies if you've seen it already, but most of that is covered in the adb guide on the dev forums, with that link also - http://forum.xda-developers.com/showthread.php?t=865685
Thanks for the great info... Now I'm standing at the gate (maybe the precipice..lol)
As far as completing the pathway...
I found (through excrutiating trial and error) the Vista path for step 4 on that tut.
So under "Environment Variables" there are two editable windows, and the bottom with the "Path" that the tut says to edit says to ad the path to the tools folder and the platform folders...
The question is, when I double click to edit the Path line,(C:\Program Files\JavaFX-sdk1.3....) it changes to a different path (~1C:\Program Files\Quicktime\QTSystem\
So am I to delete that line and ad a new path or ad to the Quicktime line..
ty
The existing path was probably just too long to show up on the screen (so you saw the beginning of the line initially and the end of the line when you tried to edit it). Just add a semi-colon and then the path you want to add. You don't want to delete what you already have there since it might mess with other software installed on you computer.
So for example:
...C:\Program Files\Quicktime\QTSystem\;C:\android-sdk-windows\tools
Quicktime and android are both separatefolders under program files... so....no.. that's not it. I don't even know why java showsthere... my sdk is in C:/Program Files/Android/sdk/tools...
p.s. how you do backslash on this keyboard....lol
Sent from my T-Mobile G2 using XDA App
The path is simply a listing of directories separated by semi-colons. When executing a command, Windows will check the local directory you are in first for the program, and then parse through the directories listed in your path. This is why this step is even needed (it allows you to run adb.exe from any directory instead of always having to change to the tools directory). This is also why I said it's not a good idea to simply delete what is already there. You just want to add the tools directory where adb.exe is located to the existing listing.
So in your case, the end of the path variable will look like this:
...C:\Program Files\Quicktime\QTSystem\;C:\Program Files\Android\sdk\tools
Alternatively, you could stick it in the beginning of the path (so double-click to edit the variable, hit Home to go to the beginning, and add the directory there with a semi-colon). It should look like this in your case:
C:\Program Files\Android\sdk\tools;C:\Program Files\JavaFX-sdk1.3...
And there is no backslash on the G2 hardware keyboard (as you noticed), but you can access it by hitting the Alt key and then space to pull up a dialog box of additional symbols.
Word of advice to anyone reading this:
When adding the adb to your path make sure and don't put a space after the the semicolan. When I set mine up I spent 4 hours trying to figure out why it wasn't working, and it was the stupid space lol.
I haven't looked at the wiki since I did it back in October so maybe they've updated it to be clearer but just want to throw it out there.
Sent from my HTC Vision using XDA App

Installing SDK

guys i really need help installing SDK, for some reason it cannot detect "adb" command after installation
That's most likely because you haven't added the install location to either to path (windows xp) or envoirnment variable (win vista/7). What OS do you run?
mstrk242 said:
That's most likely because you haven't added the install location to either to path (windows xp) or envoirnment variable (win vista/7). What OS do you run?
Click to expand...
Click to collapse
window 7dsfsdfdsf
The platform tools folder under where android sdk installed (depends on where you chose when you setup), needs to be added to the envoirnment variables under windows 7. Go to the control panel, system properties, and advanced. On the bottom is where you'll see the envoirnment variables. Add the directory to the local path, and then you should be good. (Provided all other install steps were successful, of course.)
mstrk242 said:
The platform tools folder under where android sdk installed (depends on where you chose when you setup), needs to be added to the envoirnment variables under windows 7. Go to the control panel, system properties, and advanced. On the bottom is where you'll see the envoirnment variables. Add the directory to the local path, and then you should be good. (Provided all other install steps were successful, of course.)
Click to expand...
Click to collapse
ok i found it but not sure what to add, i install everything under c: drive (c:/android-sdk-windows)
EDIT: nvm got it thanks!
G1_enthusiast said:
ok i found it but not sure what to add, i install everything under c: drive (c:/android-sdk-windows)
Click to expand...
Click to collapse
Ok, on the envoirment variables page, on the bottom, scroll down to path
then edit
do not delete what's already in there, add
;c:\android-sdk-windows\platform-tools;
right at the end of it (so it's ;, the path... i believe it's under the folder platform-tools. you might want to check the folder to make sure the adb file is in there. I haven't done it on windows in a while though, but that should be the folder.)
You'll have to close and re-open any command prompts you have open after making this change, so the new path takes affect. Just open a command prompt and type adb. If you get command not found it's not correct.

[Q] SDK Not working (Can't find Java?)

Well I'm obviously doing well because I can't even get the SDK to work...
This is what I've done:
Went to the website, downloaded the executable version of the SDK.
Went to install it, was told I needed the Java JDK.
Installed Java JDK.
Installed the SDK and a command prompt opens for all of two seconds, closes and leaves me going... whatttt!??!
So I did a search, and have tried to do the following (in no particular order):
Step #1: Open up a command prompt.
Step #2: Use the cd command to move to wherever you installed your Android SDK.
Step #3: Run tools\android.
I get the following message:
'SearchForJava' is not recognized as an internal or external command, operable program or batch file.
WARNING: Java not found. In order to properly use the Android Developer Tools, you need a suitable version of Java JDK installed on your system.
We recommend that you install the JDK version of Java SE, available here:
http://www. oracle.com/techwork/java.javase/downloads
You can find the complete Android SDK requirements here:
http://developer.android.com/sdk/requirements.html.
So I don't really understand why it says it can't find it if I obviously have it installed and it wouldn't have let me install the SDK without verifying I did indeed have the JDK.
I did more searching and then decided to do this:
edit \tools\android.bat
find "%jar_path%;%swt_path%\swt.jar"
modify to "%tools_dir%\%jar_path%;%tools_dir%\%swt_path%\swt.jar"
save, and run SDK Manager.exe again
Again, nothing.
I then tried resetting the path.
Select Computer from the Start menu
Choose System Properties from the context menu
Click Advanced system settings > Advanced tab
Click on Environment Variables, under System Variables, find PATH, and click on it.
In the Edit windows, modify PATH
I deleted everything that was there and put the path to the java files(?) C:\program files\java\jdk1.7.0_02\bin
I tried running the SDK again and got nothing.
I then downloaded the zip version of the SDK tried all of the above and didn't work.
I then read somewhere that if you just make a new user account and install the SDK exe file that it would work, but it didn't.
So anyone have any idea about what I can do? I'm so lost and frustrated! Would it help if I installed Eclipse? (is it a way to bypass Java? it's driving me nuts)
Thank you so much!
So
Well... now I have a different error haha. Here's what I did:
I uninstalled everything, the java jdk and jre and all of that. I uninstalled the Android SDK.
I reinstalled the Java programs, reinstalled Android SDK, that didn't work
I then went and modified the path again, deleted all of the other stuff and put C:\program files\java\jdk1.7.0_02\bin
That didn't work.
I then went and edited the android.bat (as above) that didn't work, I then did a cd in the command prompt, typed: tools/android and got this error message:
Error: Unable to access jarfile lib\achrquery.jar
'xcopy' is not recognized as an internal or externam command, operable program or batch file.
Error: SWT folder ' ' does not exist.
Please set Android_SWT to point to the folder containing swt.jar for your platform
So now what?
Er
Did you put a ; before and after the java path?
I did that now, but still the same error
I then went and modified the path again, deleted all of the other stuff and put C:\program files\java\jdk1.7.0_02\bin
Click to expand...
Click to collapse
This is bad, now your comp does not find basic programs like xcopy so it sure won't work, get back your PATH variable as it was, then at the add a";" and the path to your jdk/bin folder, it should work. if not post again and we'll try to help.
I went to my other computer, copied what I had in the path, put it on this computer and this is the error message:
Error: Unable to access jarfile lib\archquery.jar
Invalid number of parameters
ERROR: SWT folder ';C:\Program Files\Android\tools\lib\x86_64;' does not exist.
Please set ANDROID_SWT to point to the folder containing swt.jar for your platfo
rm.
I've also downloaded a new swt.jar in case the one I had was corrupt or something
Well, I managed to get the SDK to work.. I installed it on another computer 0_o hahaha
I'll try and figure out what went wrong if anyone's interested but yeah.. that was a pain!

SDK help

when i tried to run sdk , got this error
C:\>android-sdk-windows\tools
'android-sdk-windows\tools' is not recognized as an internal or external command
,
operable program or batch file.
C:\>
can somebody help me to solve this error
i am on windows xp
what do you want to do?if you want to use the program inside the tools folder you should enter the folder. you can make a shortcut file by make a new txt file in tools folder, type cmd.exe then save the file. change the extension to *bat. in this way anytime you open the *bat file you'll enter tools folder in cmd automatically.
The folder you cd should have adb in it. Otherwise it won't work
Sent from my GT-S5360 using XDA
Define more clearly !
The error you have mentioned isn't from sdk, its a cmd error & is trying to inform you that the command you entered isn't an executable(script or binary), its just a simple path to which you can cd not execute.
You can just find the windows executable(like *.exe, *.bat, *.cmd,.. etc) you are trying to execute & double click
Like the default location for Sdk Manager : "C:\Program Files\Android\android-sdk\SDK Manager.exe"
yup...thats right. but the *exe command only work if executed from cmd. he has solve this problem anyway. mod can close it now.
He didn't mentioned about gui or command-line. So replied that way.
That's not sdk error,....
Sent from my Nexus One using Tapatalk

Categories

Resources