Over a million developers have joined DZone.

Android Emulator Can’t Find AVD

· Java Zone

Learn more about the advantages of moving from a monolithic to microservices architecture.  Brought to you in partnership with IBM.

I ran into a small gotcha recently when creating a new Android project in Eclipse. The first time I went to run it on an AVD, I received an error in the console output:

[2011-08-09 19:14:46 - Emulator] emulator: ERROR: unknown virtual device name: 'avd'
[2011-08-09 19:14:46 - Emulator] emulator: could not find virtual device named 'avd'

The first few results in Google didn’t turn up any useful information. The culprit turned out to be buried in the Eclipse UI.

  1. If the Package Explorer view isn’t already active, activate it by selecting Window > Show View > Package Explorer.
  2. In the Package Explorer view, right-click on your project and select Run As > Run Configurations.
  3. In the right half of the Run Configurations window, select the small Target tab.
  4. On the far right side of the window, use the scrollbar to scroll to the bottom of the Target tab’s contents.
  5. Find the text box labeled Additional Emulator Command Line Options. It probably has a value like this: -cpu-delay 0 -no-boot-anim -avd avd.
  6. Change the value of the text box to look like -cpu-delay 0 -no-boot-anim -avd AVD Name where AVD Name (which defaults to simply avd) is the name of the AVD you’ve created for this project. In other words, if you open the Android SDK and AVD Manager window (Window > Android SDK and AVD Manager), the value you should use in place of AVD Name within this text box is the same value that appears in the AVD Name column of that window for the desired AVD. So, if your AVD is named MyProjectAVD, the value of the text box should be -cpu-delay 0 -no-boot-anim -avd MyProjectAVD.


From http://matthewturland.com/2011/08/09/android-emulator-cant-find-avd/


From Idea to Application gives you the architecture to quickly build, manage and run a range of applications (web, mobile, big data, new smart devices, etc.) on an open-standard, cloud-based platform. See why developers are using IBM Bluemix. Brought to you in partnership with IBM.


The best of DZone straight to your inbox.

Please provide a valid email address.

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}