How to enable MacBook to recognize android devices - android

For Windows, Google provides USB Driver but Google USB Driver is not compatible with Mac OS and I read that anything did not need to Mac OS and Linux.
I've already set "USB Debugging ON" on my android device.
Followings are my development environment.
OS: Mac OS 10.6.8
Android Device: Google Nexus S
Android OS: 4.0.3
IDE: Eclipse SDK 3.7.2
The application I make uses camera, so I need to debug with devices.

It should just work.
I would imagine there's something else going on. Plug your phone in and try listing it from the command line:
$ adb devices
If it's not, try restarting the adb server:
$ adb kill-server
$ adb start-server
After you restart the server, if the device still isn't listed, unplug then plug in again to a different USB port. Failing that, restart the system.
Once the device appears when using the $ adb devices command, try obtaining a shell:
$adb shell
If that fails, I would make sure your SKD is up to date as well as the ADT Eclipse plugin.

I've had similar issues too and it seemed like it was related to the USB hubs not working properly. Trying resetting your PRAM and see if that helps.

Your Android device needs to be in Developer Mode.
Go to Settings > About phone and tap many times on the Build-Number.
See here: http://www.gottabemobile.com/2013/11/09/disable-sms-text-google-hangouts/

Related

ADB and Xcode not detect connected devices, after update to Catalina mac os

I have updated my mac mini os to Catalina. After that Android Studio and Xcode not detect connected devices. "adb devices" command not showing any devices.
But, in Android Studio, it detects my device (on troubleshoot mode). But, it was saying, not recognized as Android device. Usb debugging is already enabled. Need help on this Catalina issue.
So far I tried:
Xcode command line tools installed.
Xcode updated.
Android Studio updated.
Android SDK updated.
Tried connecting with different cables.
I think the problem is from the OS, when I see the console log. I see an error
adb#(null): AppleUSBHostUserClient::start: missing entitlement com.apple.appledfr.client
waiting for a patch from apple
For adb it started working again, after i tried to set up the sdk path again ,
export ANDROID_HOME=~/Library/Android/sdk
I did the "Revoke USB debugging authorizations" from the Developer options on the phone and run Xcode so it would install some updates.
Once I did that, it offered up the usual "did you want to allow debugging on this device" option, and everything was back to normal.
After Mac OSX is upgraded, then open Xcode to install the components. Then connect your android phone through USB rather than double type-c. After that, do the "Revoke USB debugging authorizations" from the Developer options on the phone. Then adb devices list will show the connected phone.
Using zsh, I added
ANDROID_HOME=~/Library/Android/sdk
to my .zprofile file (if you don't have one, just create it with touch .zprofile in your home directory) and rebooted.
1) go to and install www.android.com/filetransfer
2) then revoke the USB debugging authorizations on android device
3) make sure you are running the old bash (in Catalina), to do this: chsh -s /bin/bash
4) unplug Android device from USB cable
5) restart Mac Catalina
6) plug back in Android device
7) run terminal (bash)
8) adb devices
it should show up, note: I had tried to run the Android File Transfer app after installing it, but it never would run. With that said, it seems to try and run something when it detects the cable being plugged in. Disclaimer: I don't know if this will work for you, but these are the steps I ran through to get it to work for me

Ecilpse won't recognize my device after upgrading to Kitkat (4.4.2)

I just upgraded my Android device to 4.4.2 and now Eclipse will not be able to choose a running Android device when I want to run my project. The Android Device Chooser shows my device up with a serial number as "????????????" and Target as "unknown" and State as "??". Additionally, I have enabled Developer Options with USB Debugging.
what os are you using. i see that on my linux box with some devices. i normally kill adb and restart it as root and the devices shows up and works correctly. found that solution years ago on stack overflow or something like that. not sure if the same thing is needed with windows/osx. on linux, assuming adb is in your path:
$ killall adb
$ sudo adb devices
otherwise os you're trying to connect it to and the specific device information would probably be helpful in tracking it down.
I have a few suggestions. Try them in this order until it works.
Reboot the phone.
Try turning off and then back on "USB Debugging" on your phone (in Developer Options probably).
open cmd > go to the your Android SDK directory > type cd platform-tools > type ./adb kill-server > then finally type ./adb start-server
References:
Eclipse - Target "unknown" in Android device chooser
Android device chooser - My device seems offline
The solution for my device after updating was to completely uninstall the device driver from device manager and reinstalling it. I am using windows and my mobile was shown as Android Phone and not as Nexus 7. Home it helps someone.

Running android app in samsung device

Environment:
My system Os is Windows XP
IDE is eclipse juno
Usb connector is Nokia
Now I want to run android application in the device. For that I follow the below commands
1) adb kill-server
2) adb start-server
3) adb devices
But it is not showing the device name in the list of attached devices, it is showing only emulators. Can you give me any suggestions to resolve my problem?
Go to Settings->Applications->Development.
Check on USB Debugging.
and install the drivers and Kies samsung software in your PC.
If you develop in a linux environment, drivers are not needed. Try dual-boot or booting a live distro if you are not comfortable giving up windows.

Adb can't find my device

I was developing an android application from Eclipse, connecting my Acer ICONIATAB A 500, with Android 3.0.1. And I did not have any problem.
Now I'm trying to developing the same application on Acer ICONIATAB A 501, with Android 3.2
and my ADB can't find the new device, while Windows can find it! I set in my tablet Debug USB option active, and I installed the appropriate driver on Windows.
I installed even the last Google USB driver (Rev. 7)
I tried to list the device find form adb with command
adb devices
from command line, but List of devices attached is empty.
What can i do?
execute these line
adb kill-server
adb start-server
if it is mobile device check that in settings, developers options , debugging mode is checked or not
You need to install LGUnitedMobileDriver package from the LG website, even though Windows 7 automatically installed USB drivers for the phone.
Try to update your Android-SDK on your computer (in Eclipse or whatever IDE you are using), this helped me solve a similar Problem.

Why does adb return offline after the device string?

I use "adb devices" to get following result. Only one device is connected to PC by USB, but we get 8 lines of result.
Could anyone suggest the reason?
WH96TNE00361 offline
WH96TNE00361 offline
WH96TNE00361 offline
WH96TNE00361 offline
WH96TNE00361 offline
WH96TNE00361 offline
WH96TNE00361 offline
WH96TNE00361 offline
Try the following:
Unplug the usb and plug it back again.
Go to the Settings -> Applications -> Development of your device
and uncheck the USB debugging mode and then check it back again.
Restart the adb on your PC.
adb kill-server
and then
adb start-server
Restart your device and try again.
To complete the previous answers, another possible solution is to change the USB socket in which your cable is plugged in.
I had this problem (with the classical answer about using adb kill-server / start-server not working) and it solved it.
Actually, it took some time to find that because Windows was correctly recognizing the device in my first socket. But not ADB. As Windows was recognizing the device, I had no real need to test other USB physical sockets. I should have.
So you can try to plug the cable in all your USB physical sockets directly available on your computer. It did worked for me. Sometimes the USB sockets are not managed the same way by a computer.
Beginning from Android 4.2.2, you must confirm on your device that it is being attached to a trusted computer. It will work with adb version 1.0.31 and above.
adb kill-server
adb start-server
that solved my problem
I've had a similar issue with one of my phones.
I was unable to connect and use usb debugging on any of my computers.
In the end, I had to restart the usb debugging on the phone manually [doing so using the Developer menu was not enough].
There's only one command you have to run on your phone [I did it using Terminal Emulator app]:
adb usb
And that was it.
Hope this helps someone in the future.
You may also try downloading newest version of adb http://developer.android.com/tools/help/adb.html
Reboot the device. This always fixes it on Mac OS, whereas adb kill-server does not.
On my Galaxy Nexus with Android 4.2.2, I had the same problem initially, 'adb devices' was showing the device but with offline status (USB debugging was initially active on my device).
These are the steps I took to remedy the situation :
Disable USB debugging (Device not connected to PC)
Re enable USB debugging
Now connect to your PC, now a pop up on the device (not on PC) will ask you for authenticating the PC, Thats it...
adb devices now lists both device id and no offline.
I post here my question just in case is helpful for somebody else.
My problem was that my colleague was connected to the same device and I was not able to connect to the same device.
Note: I had this problem with Amazon Fire TV connecting over Wifi.
There are 2 solutions:
Easy to "drop" his connection (sorry buddy :)
Restart the device
adb kill-server
adb start-server
adb connect device-ip
A bit more difficult but two clients can use the same device (use different TCP ports)
Please look at this answer
For me with Android 4.1.1 only rebooting device works
Run SDk Manager and install Android SDK Tools and Android SDK Platform-tools updates. ADB must be updated to a new version for 4.2.x
I had the same issue and none of the other answers worked. It seems to occur frequently when you connect to the device using the wifi mode (running command 'adb tcpip 5555'). I found this solution, its sort of a workaround but it does work.
Disconnect the usb (or turn off devices wifi if your connected over wifi)
Close eclipse/other IDE
Check your running programs for adb.exe (Task manager in Windows). If its running, Terminate it.
Restart your android device
After your device restarts, connect it via USB and run 'adb devices'. This should start the adb daemon. And you should see your device online again.
This process is a little lengthy but its the only one that has worked everytime for me.
Had this on client's machine it turned out he had an out of date version of adb installed via website offering adb and fastboot. The client in question didn't want to install the whole SDK because of perceived bloat :S .
So if you're seeing offline make sure you've downloaded and using the latest adb. I ended up emailing him adb executable.
Also worth checking that the adb you are using is the correct one in the Path. i.e on Mac
$ which adb
/Users/me/dev/adt-bundle-mac-x86_64/sdk-macosx/platform-tools/adb
if non of the steps work from the above. my device still offline after connected through wifi. i did the following:
go to your device...
go to settings.
go to developer options.
Allow adb debugging in charge mode only.
repeat the steps as you always do . which is:
a. connet your usb on chargemode only.
b. open command write:
- adb tcpip 4455
- adb connect 192.168.1.11:4455
b. disconnect usb.
now everythings work for me .
make sure the device is set for usb debugging
Have the adb client running (e.g. via "adb usb" or adb start-server"
LEAVE the device connected via usb!!!
AND THEN reboot the device.
This always brings my Motorola MB525 "online" again, after adb complains it would be "offline". I'm using OSX btw.
I made adb working on Android 4.4.2 with GT-N8010 (Samsung tablet) after setting device in authorized mode once upgraded adb to SDK version.
~/local/opt/Android/Sdk/platform-tools/adb
Android Debug Bridge version 1.0.32
While It did not work using :
adb version
Android Debug Bridge version 1.0.31
Shiped in Ubuntu LTS version :
apt-cache show android-tools-adb | grep Version
Version: 4.2.2+git20130218-3ubuntu23
This link may help then
Can't connect Nexus 4 to adb: unauthorized
After wasting hours on it, I have updated my version of adb and now adb devices shows my device online and I can run the app on it again.
also make sure adb isn't running in your processes automatically. If it's there right click open file location, figure out what is starting it, kill it with fire. Run the updated adb from an updated android sdk platform tools. This was the issue with mine, hope it helps someone.
What did me in is was that multiple unrelated software packages just happened to install adb.exe -- in particular for me (on Windoze), the phone OEM driver installation package "helpfully" also installed adb.exe into C:\windows, and this directory appears in %PATH% long before the platform-tools directory of my android SDK. Unsurprisingly, the adb.exe included in the phone OEM driver package is MUCH older than the one in the updated android sdk.
So adb worked just fine for me until one day something caused me to update the windows drivers for my phone. Once I did that, absolutely NOTHING would make my phone status change from "offline" -- but the problem had nothing to do with the driver. It was simply that the driver package had installed a different adb.exe - and a MUCH older one - into a directory with higher precedence.
To fix my installation I simply altered the PATH environment variable to make the sdk's adb.exe have priority.
A quick check suggested to me that "lots" of different packages include adb.exe, so be careful not to insert an older one into your toolchain unintentionally.
I must really be getting old: I don't ever remember such a stupid issue taking so endlessly long to uncover.
Check that the ADB version that you are running is newer than the version of the OS on the connected devices. For me, updating the ADB helped to get the device online.

Categories

Resources