5

I'm having problems with setting up my Mobile phone (Samsung Galaxy J5) to work as my Test-Device for flutter in android studio. I in-between managed to start my app on my phone but always lost connection after a while. Today it won't start up at all without any changes in the settings. The output in the console of android studio looks as follows

Launching lib/main.dart on SM J510FN in debug mode...
Initializing gradle...
Resolving dependencies...
Gradle task 'assembleDebug'...
Built build/app/outputs/apk/debug/app-debug.apk.
error: device '933fecf1' not found
Installing build/app/outputs/apk/app.apk...
Error: ADB exited with exit code 255
adb: error: failed to get feature set: device '933fecf1' not found

error: device '933fecf1' not found
- waiting for device -
Error launching application on SM J510FN.

I've seen the android studio losing connection to my phone while trying to install the app.apk. As the connection hasn't been steady at any point since I started getting in touch with flutter and android studio I guess there might be an issue with the adb but I have no clue how to track it down.

Flutter Doctor

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel beta, v1.0.0, on Mac OS X 10.14.2 18C54, locale de-DE)
[✓] Android toolchain - develop for Android devices (Android SDK 28.0.3)
[✓] iOS toolchain - develop for iOS devices (Xcode 10.1)
[✓] Android Studio (version 3.3)
[✓] Connected device (1 available)

• No issues found!
3
  • try adb kill-server and check if the output of adb devices -l prints anything suspicious. Commented Jan 24, 2019 at 13:53
  • add kill-server didn't help. adb devices -l shows: List of devices attached 933fecf1 device usb:337641472X product:j5xnltexx model:SM_J510FN device:j5xnlte transport_id:30 Commented Jan 24, 2019 at 13:56
  • Some people reported similar issue a while back but not obvious solution github.com/flutter/flutter/issues/14604 Commented Jan 24, 2019 at 13:58

7 Answers 7

5

I was able to find the solution for my problem and want to share nevertheless it seems it a little too simple: I was using a defect USB cable. Changing to a newer cable solved all connection problems immediately.. Thanks for the help anyway!

Sign up to request clarification or add additional context in comments.

1 Comment

Didn't help for me (
4

For me it was solved as I disabled "Use libusb backend" for "Android Debug Bridge (adb) in the settings: screenshot

Comments

0

My problem's gone (on Windows 10) after I installed google USB drivers from tools -> SDK Manager in Android Studio, turned off USB Powers saving in Control Panel -> Power Management and turned off "Allow the computer to turn off this device to save power" in all my USB-Controllers in Windows device manager.

Comments

0

This is a pretty old topic, but the problem seems to still be here. In my case after update of platform-tools (macosx). None of above, and all other advices (like manually adb kill-server, adb start-server, adb -d install... etc - didn't work)

The only way I've found - is do downgrade the platform-tools back. I've used the link like this: https://dl.google.com/android/repository/platform-tools_r28.0.0-darwin.zip But it can be reformatted to any version and any platform.. for example: https://dl.google.com/android/repository/platform-tools_r26.0.0-windows.zip

And after that, everything starts to work as before.

Comments

0

Case 1 -When I connect my device and started the flutter project run, the device automatically asks to enable debug mode even I have enabled it already. And then I press ok device disconnects and in few seconds it connects automatically.

Case 2 -When I connect my device and started the flutter project run, the device is connected and disconnect continually.

Case 3-When I connect my device and started the Native project run, the device is connected and the native project runs in the device.

I checked all most all the solutions in stack-over-flow and medium. But nothing worked for me.

But there are two solutions I have recognized.

  1. Start/Open a native project and then start/open your flutter project. then the device won't disconnect.
  2. Start/Open your flutter project if the device is disconnecting from any of the above three cases. restart the android studio and check if it is working, if not restart again...

Comments

0

I use.
Android Studio Arctic Fox | 2020.3.1 Build #AI-203.7717.56.2031.7583922, built on July 26, 2021 Runtime version: 11.0.10+0-b96-7249189 amd64 VM: OpenJDK 64-Bit Server VM by Oracle Corporation Windows 10 10.0 GC: G1 Young Generation, G1 Old Generation Memory: 1280M Cores: 20 Registry: external.system.auto.import.disabled=true Non-Bundled Plugins: com.thoughtworks.gauge, org.jetbrains.kotlin, org.intellij.plugins.markdown

I was have same problem I use Samsung Galaxy A 10. I download Android USB Driver for Windows v.1.7.43. I installed this drivers.

And problem was deasappear.

Comments

-2

If your using USB cable then try with a new cable or use ADB WiFi plugin

1 Comment

There is already an accepted answer which is basically what you suggested. Please read the previous answers and see if you are contributing a new solution or an improvement to an existing answer.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.