当前位置:网站首页>Flutter真机运行及模拟器运行
Flutter真机运行及模拟器运行
2022-08-05 04:58:00 【WEB前端李志杰】
一、如果有条件还是建议真机运行,因为性能及热更新的速度比模拟器要好很多。真机运行也比较简单。
二、没有条件需要使用模拟器的,根据个人经验来看比较推荐夜神及网易MuMu两款模拟器。
1、真机运行:
1、所有手机助手必须关闭,且不能在后台运行;
2、手机需开启USB调试功能;
3、数据链连接。
2、模拟器运行:
常见模拟器有:Android Studio(太耗内存了,性能也不怎么样)、夜神、网易MuMu、逍遥模拟器、天天模拟器……
Flutter引用在模拟器上运行,需要模拟器与相关程序服务器连接,每个模拟器连接程序及端口号稍有不同,但基本都大同小异。
具体连接方式可在模拟器官网的常见问题或者使用文档中搜索adb即可找到对应的信息(IP地址及端口号)。
1、下载安装夜神模拟器(或者其他模拟器)
2、进入到模拟器安装目录的bin目录下,我电脑夜神模拟器的安装目录D:\Program Files\Nox\bin。
3、运行模拟器后再CMD窗口中输入adb_server.exe connect 127.0.0.1:7555 出现如下图所示则表示运行成功 。

个人比较推荐的是夜神模拟器或者网易MuMu(我更喜欢网易MuMu)。
例如:夜神模拟器在常见问题中搜索adb即可找到如下图所示文档内容。

点击第一个,即可在文档中找到对应的adb程序及服务器地址和端口号。

3、Visual Studio Code项目启动
1、安装Visual Studio Code编辑器;
2、安装Dart、Flutter两个插件;

4、Android Studio项目启动
1、安装Android Studio编辑器;
2、安装Dart、Flutter两个插件(必须要装),Dart Helper,FlutterJsonBeanFactory辅助开发工具;

3、如果用Android Studio第一次打开项目如果如下图所示,则请先使用命令的形式Flutter pub get获取依赖之后使用 Flutter run运行项目。

5、相关学习资源链接;
新手程序员最好的学习网站——B站,没有之一。
Dart中文网:https://www.dartcn.com/
Flutter中文官网:https://flutter.cn/
Flutter教程:https://book.flutterchina.club/
Flutter教程(深入点的):https://guoshuyu.cn/home/wx/
Java SDK安装:https://blog.csdn.net/qq_16221009/article/details/123420830
Android SDK、Dart SDK及Flutter SDK安装:https://blog.csdn.net/qq_16221009/article/details/123472018
Flutter SDK安装、切换版本及常见问题整理:https://blog.csdn.net/qq_16221009/article/details/125981120
6、往期内容已全部收录在专栏中:
边栏推荐
- overloaded operator
- 8.04 Day35-----MVC三层架构
- JeeSite New Report
- Is the NPDP certificate high in gold content?Compared to PMP?
- 1007 Climb Stairs (greedy | C thinking)
- [CISCN2019 South China Division]Web11
- bytebuffer internal structure
- After controlling the export file in MySQL, it becomes \N. Is there any solution?
- AUTOCAD——标注关联
- C++ core programming
猜你喜欢
随机推荐
【cesium】加载并定位 3D Tileset
Flutter 父子组件如何都能收到点击事件
Flutter learning - the beginning
[CISCN2019 South China Division]Web11
Machine Learning Overview
人性的弱点
数字_获取指定位数的小数
基于Web的商城后台管理系统的设计与实现
After controlling the export file in MySQL, it becomes \N. Is there any solution?
Redis - 13. Development Specifications
Flutter学习三-Flutter基本结构和原理
C#关于set()和get()方法的理解及使用
[Geek Challenge 2019]FinalSQL
The production method of the powered small sailboat is simple, the production method of the electric small sailboat
write the story about us
开发属于自己的node包
什么是ASEMI光伏二极管,光伏二极管的作用
请写出SparkSQL语句
Error creating bean with name ‘configDataContextRefresher‘ defined in class path resource
Flutter learning three-Flutter basic structure and principle









