20

I tried to develop app using Flutter(using Android studio IDE).Add flutter plugin & flutter SDK in studio and Everything is configured but emulator / real time device are not listed. Its shows error like "Unable to list devices: Unable to discover Android devices. Please run "flutter doctor" to diagnose potential issues" android studio with flutter

Ref link : https://flutter.io/setup-windows/#android-setup

https://flutter.io/get-started/test-drive/#androidsstudio

9
  • Can you please try if executing adb kill-server on the command line helps? Also check if adb devices lists the available devices. Mar 11, 2018 at 17:07
  • Do you have any emulators running? Or a physical device connected to your machine? If yes, then do flutter devices from the terminal and post the output Mar 11, 2018 at 17:15
  • Emulater and device also running but device list not show there
    – Vadivel
    Mar 11, 2018 at 17:19
  • @ Günter Zöchbauer after execute adb devices C:\Users\Vadivel>adb devices List of devices attached emulator-5556 device ZY223J8XGG device
    – Vadivel
    Mar 11, 2018 at 17:21
  • I fixed this problem, thanks all
    – Vadivel
    Mar 12, 2018 at 9:10

5 Answers 5

64

configure flutter in terminal to detect Android SDK and Android Studio:

$ flutter config --android-sdk /path/to/android/sdk
$ flutter config --android-studio-dir /path/to/android/studio

then restart Android Studio/Intellij. source: https://github.com/flutter/flutter-intellij/issues/2113#issuecomment-383412308

2
  • entered this command and restarted studio and start worked fine
    – Black_Zerg
    Feb 7, 2019 at 9:55
  • This answer helped me, too, and it seems likely that it's the most common issue.
    – sindrenm
    Aug 6, 2019 at 17:58
2

If you configure flutter and android sdk both perfectly and you do not show the avd device list in android studio.

It's very simple way to show android emulator device list.

First create a new Android Emulator if already create you run the AVD manager then you can show the instead of emulator name

Before: https://i.stack.imgur.com/6np0m.png

After: https://i.stack.imgur.com/fiCYe.png

0

May be there is no AVD's to list down. And if emulator runnig, intelliJ will grab it.

In Android Studio, you can create a AVD using AVD Manager or using Terminal. Here is how you can do that using Terminal,

First, go to the android sdk installed directory -> tools

and copy the path and in the terminal type cd and paste the path and press enter. Now yo are in the tools directory.

Next, using terminal type:

emulator -list-avds - to list created AVD's(You should be in tools directory to run this command).

If there is a device type emulator -avd <name>. else you can create a one:

type cd bin then,

Use:

avdmanager create avd -n name -k "sdk_id" [-c {path|size}] [-f] [-p path]

As a example:

avdmanager create avd -n Nexus -d 23 -k system-images;android-23;google_apis;x86

Then again go back to tools directory by typing cd .. and type emulator -list-avds. This command will list your created AVD.

To run a AVD type:

emulator -avd <name>

About AVD.

0

Had the same problem after moving avd's to another disk.

I managed to solve by making ANDROID_HOME system variable to point to the android sdk path.

0

For mac users,

It was working fine yesterday. In my case I had this in .bash_profile

ANDROID_HOME = Library/Android/sdk 

I changed it to,

ANDROID_HOME = /Users/rana.singh/Library/Android/sdk 

.bash_profile has

export ANDROID_HOME=/Users/rana.singh/Library/Android/sdk
export PATH=$PATH:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools

It worked.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.