开发者

android emulation on virtual box in eclipse

I have android running on virtualbox, to use it as a second cell phone with an bluetooth usb stic开发者_StackOverflowk, to connect it with a real device.

I have 2 Questions:

  1. Is it possible to get access with DDMS in eclipse like the real device to the virtual box version?

  2. How can i install in .apk package on the virtual box android?

I hope somoeone can help me.

Thanks!


  1. Press Alt+F1, type netcfg write down the IP address and press Alt+F7.
  2. Run adb connect <virtual_machine_ip> in terminal on your host machine.

You should then see the device in ADT and be able to run your applications on it.

Edit: This will work if you are set up to use bridged or host-only adapters: for NAT you must set up port forwarding first:

  1. cd to your VirtualBox folder on Windows: (C:/Program Files/Oracle/VirtualBox)
  2. set up a port forwarding rule via command line like so: VBoxManage modifyvm <name_of_your_android_vm> --natpf1 adb,tcp,*,5555,*,5555
  3. Run your vm
  4. Connect to your VM by typing adb connect localhost:5555
  5. Launch your application in Eclipse and you will see localhost:5555 as an available AVD
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜