4

When I use flutter run command it shows the following message:

Multiple devices found: Chrome (web) • chrome • web-javascript • Google Chrome 88.0.4324.146 Edge (web) • edge • web-javascript • Microsoft Edge 86.0.622.51 [1]: Chrome (chrome) [2]: Edge (edge) Please choose one (To quit, press "q/Q"): 

Also this is the result of flutter emulators command:

3 available emulators: Nexus_5x • Nexus_5x • Google • android Pixel_2_API_29 • Pixel 2 API 29 • Google • android pixel_xl • pixel_xl • Google • android To run an emulator, run 'flutter emulators --launch <emulator id>'. To create a new emulator, run 'flutter emulators --create [--name xyz]'. You can find more information on managing emulators at the links below: https://developer.android.com/studio/run/managing-avds https://developer.android.com/studio/command-line/avdmanager 

Is it possible to add Android emulators to the list of flutter run command beside chrome and edge browsers?

1
  • 1
    Try flutter run -d pixel_xl. Or create a debug configuration. Commented Feb 5, 2021 at 21:26

4 Answers 4

7

You should:

  • Retrieve the list of the available emulators
flutter emulators 
  • Launch the emulator
flutter emulators --launch Nexus_5x 

Then when you run flutter run you should see your new android emulator.

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

Comments

2
  • Download Android SDK and make initial setup.

  • Relaunch VSCode and clean the project:

    flutter clean 
  • if this didn't help, try to update licences:

    flutter doctor --android-licenses 

Comments

2

The flutter devices command shows "available devices". Emulators that have not been started are not "available" until they've been started.

If you're using VS Code, you may find it better to use the built-in device management and debugging rather than using the terminal. In the status bar in the bottom right corner it should show your "active device" and if you click on it, it will let you switch to another device. That list shows emulators even if they're not started, and selecting one will automatically start it.

Device/Emulator list

Comments

0

select from View Menu --> command palette Then select Flutter emulator enter image description here

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.