Android Studio does not see the AVD

DarkGranit picture DarkGranit · Dec 16, 2014 · Viewed 7.7k times · Source

I have a problem related to the Android Studio.

  1. I create AVD with Android Studio AVD Manager and its configuration looks like this

http://imgur.com/awg59Lg

  1. I go back on the previous screen where I am supposed to select this device as Prefer Android Virtual Device

http://imgur.com/uj6FMCn

As you can see the box is empty. If I try to run the deice via the Android Studio AVD Manager it just doesn't start. No error message or anything

If I try to run it via the AVD manager that goes with the android sdk it starts in a normal way, but then I can not upload my app to it, because Android Studio does not see it.

I have installed the following

  1. jdk-8u25-windows-x86 in the following location D:\Programs\Java\jdk1.8.0_25
  2. jre1.8.0 that goes with the package mentioned in point 1 in D:\Programs\Java\jre1.8.0_25
  3. android-studio-bundle-135.1641136 the Android Studio itself in H:\AndroidIDE\Android Studio
  4. SDK that goes with the package mentioned in point 3 in H:\AndroidIDE\sdk
  5. JAVA_HOME set to D:\Programs\Java\jdk1.8.0_25

When I create avd via AVD manager in Android Studio its location on my file system is H:\Users.android\avd\Nexus_5_API_21_x86.avd (Have in mind that my user files are directly stored in H:\Users without my username being part of the path

When I am creating AVD from Android Studio the standalone AVD manager that goes with the SDK can see this AVD. When I create the AVD from Android Studio AVD manager the AVD manager that goes with the SDK can see the image as well.

Still problem remains that my Android Studio can not see those AVD and I can not select them from the emulator list when I am configuring my Run configuration.

I have tried this configuration on two different OS Windows 7 64bit and Windows 7 32bit. The result remains the same (of course I have installed different packages to match the OS architecture)

I would be very grateful if someone can help me. Because so far this Google Android Studio is a total disappointment. Surprisingly frustrating to install and configure it

Answer

Piotr Kopczyński picture Piotr Kopczyński · Dec 16, 2014

Is API of AVD appropriate for your project? Have you tried any other configurations?

Keep these points in mind when you are selecting a system image target for your AVD:

  • The API Level of the target is important, because your application will not be able to run on a system image whose API Level is less than that required by your application, as specified in the minSdkVersion attribute of the application's manifest file. For more information about the relationship between system API Level and application minSdkVersion, see Specifying Minimum System API Version.
  • You should create at least one AVD that uses a target whose API Level is greater than that required by your application, because it allows you to test the forward-compatibility of your application. Forward-compatibility testing ensures that, when users who have downloaded your application receive a system update, your application will continue to function normally.
  • If your application declares a uses-library element in its manifest file, the application can only run on a system image in which that external library is present. If you want to run your application on an emulator, create an AVD that includes the required library. Usually, you must create such an AVD using an Add-on component for the AVD's platform (for example, the Google APIs Add-on contains the Google Maps library).

http://developer.android.com/tools/devices/index.html