简体   繁体   English

适用于Mosync IDE的Genymotion Android Emulator插件

[英]Genymotion Android Emulator Plugin for Mosync IDE

i've been trying to develop an Android application for some time now but the problem i keep facing is finding a suitable emulator to run a demo of the application (I think the default Android SDK emulator is crap). 我一直在尝试开发一个Android应用程序,但我一直面临的问题是找到一个合适的模拟器来运行应用程序的演示(我认为默认的Android SDK模拟器是废话)。 Anyway i did some research and came across the genymotion android emulator which is faster than any other emulators i have tired so far. 无论如何,我做了一些研究,并遇到了genymotion机器人模拟器,这比我迄今为止累了的任何其他模拟器都要快。 I then went on to search for a plugin for my Mosync IDE which is an IDE built on eclipse that allows you to develop native, web or hybrid apps using htnl5, css, javscript, c/c++. 然后我继续为我的Mosync IDE搜索插件,这是一个基于eclipse构建的IDE,允许您使用htnl5,css,javscript,c / c ++开发本机,Web或混合应用程序。 Anyway i installed the plugin with the MosyncIDE the same way you install any new software in any eclipse based IDE and it installed fine. 无论如何,我使用MosyncIDE安装插件的方式与在任何基于eclipse的IDE中安装任何新软件的方式相同,安装得很好。 The problem i have now is that i am able to run the emulator okay but when i try to run my application inside that emulator i am unable to locate the genymotion virtual device in the list. 我现在的问题是,我能够运行模拟器好,但当我尝试在该模拟器中运行我的应用程序时,我无法在列表中找到genymotion虚拟设备。 I have been fiddling with my configuratin settings for days now without any results, i do not own an android phone so testing it directly on one is not an option for me, i would like someone to help me out with this problem thank you. 我一直在摆弄我的configuratin设置几天没有任何结果,我没有自己的Android手机所以直接在一个测试它不是我的选择,我希望有人帮我解决这个问题谢谢你。

Please note that i am able to run the app normally with the default androidsdk emulator. 请注意,我可以使用默认的androidsdk模拟器正常运行应用程序。

[What i have been trying soo far] This is what i do currently, i start the genymotion emulator within the IDE. [我一直在尝试的东西]这是我目前所做的,我在IDE中启动genymotion模拟器。 I go to run configurations. 我去运行配置。 I choose Android Emulator. 我选择了Android Emulator。 I hit "Refresh AVD list" Then i choose the android emulator i want from the list, the problem is i can't find the genymotion emulator i started within that list. 我点击“刷新AVD列表”然后我从列表中选择我想要的android模拟器,问题是我找不到我在该列表中启动的genymotion模拟器。

Ok. 好。 The thing is that Genymotion device is not considered as an emulator but like a real device plugged on USB. 问题是Genymotion设备不被视为模拟器,而是像插入USB的真实设备。 You won't find it on the AVDs list but on the "running Android devices". 您不会在AVD列表中找到它,而是在“运行Android设备”上找到它。

You first have to check if the running Genymotion VM is connected TO ADB: Run adb devices on a console. 首先,您必须检查正在运行的Genymotion VM是否已连接到ADB:在控制台上运行adb devices It should show you something like this: 它应该显示这样的事情:

List of devices attached
192.168.56.101:5555     device

The Genymotion device is shown as it's IP address. Genymotion设备显示为IP地址。 If the Genymotion device is shown on this list, it should also appear on the list of available devices when you hit the "run" button of your IDE. 如果Genymotion设备显示在此列表中,当您点击IDE的“运行”按钮时,它也应出现在可用设备列表中。 Like in this picture (done with Eclipse IDE). 就像在这张图片中一样(用Eclipse IDE完成)。 在此输入图像描述

If it is not shown on the list, read my previous answer. 如果列表中没有显示,请阅读我之前的答案。

So you installed the Genymotion Eclipse plugin isn't it? 所以你安装了Genymotion Eclipse插件不是吗? And it seems that adb devices does sometimes not display your Genymotion device. 并且似乎adb devices有时不会显示您的Genymotion设备。

When the VM boots into the Genymotion player, it executes: 当VM引导进入Genymotion播放器时,它会执行:

adb connect <VM's IP address>

This connects the device to adb, so you are able to debug your apps with it. 这会将设备连接到adb,因此您可以使用它调试应用。

Sometimes, it appears that the connection is lost and you have to run adb connect <VM's IP address> again. 有时,似乎连接丢失,您必须再次运行adb connect <VM's IP address> You have to do it manually for now. 你现在必须手动完成。

You can get the IP of your running device using the Genymotion Shell with the command devices list 您可以使用Genymotion Shell和命令devices list获取正在运行的设备的IP

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM