user854301
user854301

Reputation: 5503

How to create avd using device definition?

I want to create android virtual device for Google Nexus from the console. Now I'm using command

android -s create avd -n %avd_name% -t 1 -p %work_dir%\devices\%avd_name% -f -s 480x800

The result is not the same as if I've craeted it in the sdk manager. I wonder, how I could create avd based on device defenition "Galaxy Nexus" from the console.

enter image description here

Upvotes: 1

Views: 1245

Answers (2)

Javier Rojano
Javier Rojano

Reputation: 982

You can use the avdmanager to list all the device definitions available on your system

$ avdmanager list devices

Then you can use the device index or id to create the avd.

For example, the following command creates a new avd named "nexus9" using the x86 system image for API level 25 based on the google nexus 9 definition

avdmanager create avd -n google9 -k "system-images;android-25;google_apis;x86" -d "Nexus 9"
  • -n avd name
  • -k sdk id
  • -d device definition

Upvotes: 2

user1835052
user1835052

Reputation: 455

use the below command

   android create avd -n <name> -t <targetID> --skin  720 x 1,280 

   adb emu window scale 0.19

This may be help... Try this

Upvotes: 0

Related Questions