emulator launched but not detected by android studio

前端 未结 6 1679
情话喂你
情话喂你 2021-01-12 05:42

I\'m a beginner in Flutter and I\'ve an emulator opened/powered on and android studio doesn\'t detect it. 1

hence I can\'t run any program because \"no device is ru

相关标签:
6条回答
  • 2021-01-12 06:19

    In a windows platform I did:

    If you have ran flutter doctor and there is no issues and if you can run your flutter app in cmd or using VSCode:

    Just try to open Android Studio or IntelliJ as administrator by right clicking on the icon. This may list down devices and solve your problem.

    The reason may be you have cloned flutter repository or you don't have right permission in flutter installed directory.

    0 讨论(0)
  • 2021-01-12 06:21

    For me (on a Mac) I had the Android SDK installed in a custom location so I needed to set the ANDROID_HOME environment variable. In the terminal you can check what this value is with:

    echo $ANDROID_HOME
    

    I added the Android SDK to my .bash_profile (might be a different file if you are using Linux or Windows) for both ANDROID_HOME and PATH.

    # already had these
    export PATH="$PATH":"/opt/android-sdk/tools"
    export PATH="$PATH":"/opt/flutter-sdk/bin"
    
    # added this
    export ANDROID_HOME="/opt/android-sdk"
    

    Replace /opt/android-sdk with wherever yours is.

    Then I updated the variables with

    source .bash_profile
    

    Testing with flutter doctor showed it was working.

    flutter doctor
    

    I restarted Android Studio and the emulator worked.

    0 讨论(0)
  • 2021-01-12 06:37

    25 June 2020

    Android Studio device list shows "loading" and no devices connected. Thus, I opened emulator but I cannot run flutter on emulator on Android Studio. After 5 hours I found that the reason is the new Flutter version.

    I solved with choose different version of Dart and Flutter!

    You need to download 1.17.3 version. Quick download link: Dowloand Flutter SDK 1.17.3 Version

    And switch Stable Channel & Dart: 2.8.4, this is important. Also, if you want, you can check all versions of Flutter SDK: Flutter Versions

    On MacOS, just write terminal: flutter channel stable

    @canerkaseler

    0 讨论(0)
  • 2021-01-12 06:37

    Run flutter doctor command to check whats the problem.

    In terminal, run the flutter devices command to verify that Flutter recognizes your connected Android device. Check your flutter plugin whether it is up to date.

    And read this flutter run: No connected devices , You may find the solution.

    0 讨论(0)
  • 2021-01-12 06:38

    The last version of Flutter 1.17.5 (release the 2th, July) solved this issue for me.
    Just flutter upgrade

    0 讨论(0)
  • 2021-01-12 06:40

    I had same problem.

    CMD: flutter devices
    No devices detected.
    
    CMD: device emulators
    Device emulator-5554 is offline.
    

    In Android virtual device manager, I cold boot emulator and it started working.

    0 讨论(0)
提交回复
热议问题