I have fixed this problem before but I can't now and I need a permanent fix. Everything has been going fine in Android Studio when it comes to testing my app. I now run into the problem "The selected device is incompatible." when I go to run the app. I'd like to know how I can keep it from reading my phone's API as 1 rather than changing my minSDK to cater to this problem, if possible.
EDIT: Literally just found a fix, not sure if it is permanent. I just restored my defaults in Development Options, turned USB Debugging off and on again and that did the trick.
All I had to do was turn off USB debugging, then turn it back on and it worked immediately. I didn't have to reboot or change any other settings.
Not sure if this helps. I had a similar issue using my MotoG 2nd generation with Android Studio on Ubuntu. I switched the settings as how my phone was connected from MTP to PTP. That worked for me.
I had a very similar issue,
Usually whenever I connect the android device for usb debugging, the device will prompt me asking for the permission from to access from the development PC
In my case, for some reason, I didnt get this prompt and hence, I got this error. I have turned off developer options & USB debugging, turned on again. Then, I got the prompt and the issue is solved
Related
I connect my phone Realme 6s (RMX2002) to my device and the USB debugging is enabled.
Android Studio recognized & connected but doesn't show the app project in flutter like in the photo
So, any suggestions to figure this out?
You need to check your USB cable. They are in two types, one of which only supports phone charging.
I can't quite understand what you're asking here, but according to your photo, no device is selected to debug on.
My advice is to (save) =) and restart Android Studio. Make sure that the RSA fingerprint for your computer is accepted on the phone. Try restarting your phone and reconnecting. Double check that USB debugging is enabled.
I cannot tell what is really going on, it may be an issue with the ADB. Check your Event Log to make sure the ADB debug bridge started successfully.
If you simply try to run your app on an emulator, issues of this kind will be promptly visible.
If you can ascertain that it is not an issue with ADB, Android Studio, or your phone, it is probably a driver issue with your computer, if you are on Windows.
Try this link: https://www.thecustomdroid.com/oppo-realme-usb-drivers/ to install the USB drivers for your computer.
Cheers!
I a had also problem with USB debugging and it was the cable's fault.
An alternative option is to use wireless debugging. A step-by-step guide for Android studio can be found here: https://link.medium.com/UQJWZrfFqob
I never had problems using Android Studio, while debugging directly on device or via emulator. Today after a long time, i tried to install it on my workstation and it looks like there are unidentified problems, that I didn't find anywhere on google ...
Emulator:
I tried 981234912849821 different settings but i can't start an emulation, it worked only ONE time. When i opened it again, it didn't work again D:
The emulator always starts, then crashes saying:
qemu-system-i386.exe has stopped working
I tried to use it with Graphics: Software - GLES 2.0 and this is the result:
I became bored about it, so i tried to directly use my phone and i discovered that android studio wasn't finding it, even by changing type of usb connection ...
Do you have any idea about this problem guys? ^^
PS: Don't flag it as duplicate, I already saw the answers on who has these problems but nothing worked for me :\
You need an ADB driver for your phone installed on your system. Also make sure that under the Developer Settings in Settings of your phone, USB Debugging is enabled.
Note: If you cannot find Developer Settings, just go to > Settings> About Phone> tap on Build Number for 7 times> then just go back to the settings and you'll see the Developer options.
And regarding the emulator, you might want to buff the resolution and the ram of the virtual device and try again.
I'm testing on a Nexus 5, with Android Studio, on a Mac. I used to be able to just plug my phone into my laptop, but lately when I go to run my app, it doesn't detect my phone.
In order to fix this, I have to go into the phone's Developer Options -> Select USB configuration -> toggle between all the modes until one of them works. Before it would just be MTP, but for some reason it seems to be pretty random which one actually does the trick now.
USB debugging is on. I haven't revoked any debugging authorizations... I know this isn't a huge problem, because I can just mess around with it to make it work, but it's super annoying since it does this every time my laptop goes to sleep, close Android studio, or unplug my phone.
I had the same problem, I simply changed the USB cable and then everything was working fine. Hope this helps...
I am trying to connect my android device on mac to test application I developed.
First I installed USB driver, then I activated in my phone the developer option by tapping on Build Number and then tick USB debugging option.
Once I did all those steps when I connect my android mobile, my Mac still not recognize my device.
Any idea to solve it?
Maybe it's your USB cable, try another one.
There are two types of USB cables:
for supplying power only
for supplying power and data
I after few research and testing of existing solutions, I found mine, my issue was released while I have installed Android file Transfer for Mac
I experienced the same problem with a Moto X and my Macbook Pro. I tried many of the suggestions (installed Android File Transfer, tried different usb ports on my computer, Settings => Storage => USB computer connection => toggled between MTP and PTP, etc.). None of these other recommendations helped.
It finally worked when I tried a different micro-usb cable.
Bizarre. You definitely want to first enable Developer Options first by going to Settings => About Phone => tapping Build number 7 times to display Developer Options. From there, you want to enable USB debugging.
I found this solution to be helpful to resolve this problem
Connect your Android to your Mac via USB.
Unlock your Android's screen. ...
Swipe down to open the Android Notification Panel.
Tap the USB option in the Notification Panel.
Tap "File transfer" or "MTP."
Click the Go menu and select "Applications."
Double-click "Android File Transfer."
https://discussions.apple.com/thread/250023078
I had this problem. The only solution was to reboot my computer. Then it started working again.
Just to add my experience here. I had a similar problem with my mac book pro and my Google Pixel 1 device. For me when running adb devices locally, I was no longer showing my device on the list. I would see any emulators I had running, but not my physical device.
My solution and steps:
Go to the "Settings App"
Go to "Developer Options"
Revoke USB debugging Authorizations
Toggle Developer Options off / on
My device then prompted me to allow debugging from my computer and everything continued to work as expected. adb devices resulted in showing my connected device.
Hopefully, this will help someone else if the above does not.
Make sure to have debugging by usb enable on your device.
It is an option inside "Developer options"
I've recently (2018) started to have this issue, and have found the only way to get my device connected is to use a USB hub. I have not been able to track down a root cause but will edit this answer if I can find a solution rather than a workaround.
I connected my Android deceive with my mac:
1) If you use Android studio, you may update to latest version of 1.0.2 or 1.1 preview, because lower version have some problem with ADB connection.
2) You may restart your IDE once again.
3) You may go to settings -- storage -- three docs on the right up corner -- USB computer connection -- enable MTP
I have an HTC U11 and a MacBook Pro (2017). It used to work most of the time, but I experienced issues with it once or twice. Then a restart of the Mac solved the problem.
Recently I was not able to USB debug. adb devices gave nothing, even though my phone said I'm USB debugging (even asked if I wanted to).
After trying many things the solution was to connect my phone and run HTC Sync Manager (I also had to update it). Then it magically started to woek.
I hope it helps somebody.
check your android sdk tools, install your sdk-plateform-tools package.then it is ok
For me what fixed the problem is
i clicked on the notification "USB for file transfer" in the
notification panel on the phone
Clicked on "Transferring images"
Than I clicked on "Transferring files / Android Auto" and it was fixed.
I just upgraded my phone to 4.2.2, but now i cannot use it in eclipse anymore.
I tried rebooting the device, reset my debug-settings but I cannot get it to work anymore.
I saw it is already a registered issue. There are some new security enhancements, so there should be a dialog (see here at bottom) but this dialog doesn't appear. I don't have several accounts on the phone, which is pointed out in the issue..
Anyone any suggestions?
EDIT: Look at accepted answer below, this should cover all cases. In my case, there were some packages missing, which weren't shown in the Android SDK Manager. I just found the Packages -> Reload in the Android SDK Manager... And I thought this happens automatically
You need three things in order to make sure this update goes smoothly:
Make sure your device is actually running 4.2.2 and the problem is not something else
Your SDK is updated to the latest tools. The adb binary in all but the latest version does not support the 4.2.2 security enhancements.
You are on the main account of your device in case of multiple user accounts.
Connect your Device to your computer and execute adb devices (make sure USB debugging is enabled). You should see something like this:
3tiu52839ry082j3 offline
Right about now, there should be a dialog on your device that looks something like:
Check the Always allow from this computer box if you want and click OK.
That's about it.
Some other things to check:
Make sure your USB cable isn't broken. Sometimes, the smaller cables break inside the main one, and your device may charge but have no data connection. Try with a different cable, or try accessing files on the device over USB (this will go fine if your cable is fine)
Make sure you're using the newest version of adb. Even after I updated my SDK tools, I couldn't get my device authorized when using adb. I eventually figured out that the Nvidia install of the NDK and SDK tools had updated my PATH variable to use the adb from that install, which wasn't the latest update. By using the adb in my newly updated install, I was able to get it all working.
For me it was solved by changing Nexus 7 tablet to "Camera(PTP)" mode.
Check out this blog post on how to do it.
After USB connection of Nexus 7 and confirming digest on Nexus 7, also connecting through TCP/IP with ADB worked.
Wierdly, unchecking and rechecking the "Allow USB Debugging" option popped me the window and selecting "ok" solved my problem.
If none of the solutions worked for you then Reset ADB.
Go to Devices ---Click the right most down arrow----Select Reset ADB from the list.
I had tried everything suggested here and suggested in every log/blog that I could find in google, but still no go. The USB cable is known to be good. ADB is version 1.0.31 (as shown with , USB Debugging is enabled in the Nexus 7 tablet, the SDK was updated to the very latest tools as available on 1-mar-2013 for 4.2.2/API 17. I had tried both Media and Camera modes for USB, rebooted windows, rebooted device over and over again, re-installed latest google USB driver, etc. etc. but ADB Devices still showed nothing.
I hard reset the Nexus 7 tablet thinking that maybe the screen to allow usb debugging had appeared but got hit with cancel. But that didn't work either.
What finally worked was:
going into windows control panel | Device Manager,
selecting NEXUS under Portable devices,
then in the Driver tab clicking on update and manually selecting the Google USB driver (the check feature said it was up to date). Previously, the date shown was in 2006, afterwards a date in 2012 (but more on this in a moment).
That didn't fix anything though.
So then I switched USB from MEDIA device to Camera device - THEN it wanted to install driver software, so I let it do that. Afterwards, I noticed that the driver for the Nexus was back with the 2006 version, BUT then ADB DEVICES FINALLY SHOWED OFFLINE!!!! HALLELUJAH AND the Nexus was displaying the Dialog to allow USB debugging, and it now all works.
What I am not sure of is what step actually solved the problem. I don't think it was necessary to hard reset the Tablet, but the fiddling with the device driver wasn't a very convincing solution either - I don't think the driver was corrupt - but maybe it had to be changed to get the right driver associated with the tablet when connected as a Camera Device. In any event, it is necessary to connect the tablet as a Camera device for ADB to work...
Restarting device or enabling USB debugging did not solve my problem.
However I changed USB PC Connection to "Camera(PTP)" mode and adb devices showed the device id of the phone.
After reading a lot post talking about this particular problem, I actually solved it by resetting user permissions on files (that were owned by root): ${HOME}/.android/adbkey and ${HOME}/.android/adbkey.pub
Go to Device Manager and uninstall your device and remove from USB
HAve you CMD opend and make sure you are at least in ADB Help.
Connect device to USB and continue with steps provided by Raghav Sood - few answers ahead of me.
Worked for me just fine
I tried with this custom build and it works for me. Now I can see my logcat in Eclipse again.
https://github.com/khaledev/ADT/releases
Download the zip file then in Eclipse menu Help > Install New Software... > Add > Archive... Just pick the downloaded zip and do the rest of the install process.