我无法在Vscode中调试我的flutter应用程序,然后调试consol返回:
无法找到开发设备;请为 有关安装其他组件的信息。
我可以在此之后显示我的仿真器:
颤动的仿真器
我可以运行:
颤动的仿真器-launch 4.7_wxga_api_22
flutter医生-v:
[✓] Flutter (Channel stable, v1.7.8+hotfix.4, on Linux, locale en_US.UTF-8)
• Flutter version 1.7.8+hotfix.4 at /home/ZZZ/Dev/Flutter/flutter
• Framework revision 20e59316b8 (10 days ago), 2019-07-18 20:04:33 -0700
• Engine revision fee001c93f
• Dart version 2.4.0
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at /media/ZZZ/B0B8B687B8B64C1A/Dev_ubuntu/android-sdk-linux/
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-28, build-tools 28.0.3
• ANDROID_HOME = /media/ZZZ/B0B8B687B8B64C1A/Dev_ubuntu/android-sdk-linux/
• Java binary at: /usr/local/android-studio/jre/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b16-5323222)
• All Android licenses accepted.
[✓] Android Studio (version 3.4)
• Android Studio at /usr/local/android-studio
• Flutter plugin version 37.1.1
• Dart plugin version 183.6270
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b16-5323222)
[✓] VS Code (version 1.36.1)
• VS Code at /usr/share/code
• Flutter extension version 3.2.0
[✓] Connected device (1 available)
• Android SDK built for x86 • emulator-5554 • android-x86 • Android 5.1.1 (API 22) (emulator)
• No issues found!
我的操作系统是Ubuntu 18.04,我想使用模拟器进行调试,请帮助我。
您有3个选项:
-
您可以在Android Studio中打开模拟器,然后从VSCODE进行调试。
-
您还可以检查机器中是否安装了ADB(Android调试桥(。
-
否则您可以在真实设备中运行应用程序。
我的问题是通过此命令
解决的flutter config --android-sdk <sdk-location>
链接