Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android Emulator can't edit hardware

Recently I updated to API 12 . Besides the problem with not founding the emulator when the SDK is installed to C:\Program Files\Android\android-sdk , which I solved by moving the android-sdk to C:\ , I have another problem: when creating a new emulator, I can't add new hardware to it from the Eclipse wizard, the emulator has only "Abstracted LCD density" and "Max VM application heap size" and when I press "New..." nothing happens. Do you have the same problem? How do I solve it ?

like image 252
Andrei Catinean Avatar asked Jul 08 '11 05:07

Andrei Catinean


People also ask

How do I increase RAM on my emulator?

Go to Tools->Android->AVD Manager , there's something like pencil to edit your AVD click on that, then in the pop-up window click Show Advanced Settings and there you can change the RAM size.


1 Answers

I found a solution to your problem. You can edit the config.ini file of an AVD by hand. Go to the folder where your AVD is stored (usually in the folder <userprofile>\.android\avd\<avdname>\) and open the config.ini file in a text editor. The text editor should be capable of reading files in unix formatting (e.g. Windows Wordpad).

Below are some example hardware properties you can add:

  • hw.sdCard=yes
  • sdcard.size=256M
  • hw.audioInput=yes
  • hw.audioOutput=yes
  • hw.camera=yes
  • hw.camera.maxVerticalPixels=480
  • hw.camera.maxHorizontalPixels=640
  • hw.sensors.proximity=yes
  • hw.gps=yes
  • hw.accelerometer=yes
  • hw.gyroscope=yes

Make sure you close the Android AVD Manager before making any changes to the config.ini.

EDIT: A strange thing just happened. The "new" button in the Android SDK and AVD manager has just started to work again on my computer. The only thing I did was try out my own solution described above and quit and restart the manager. So maybe only a restart is necessary!?

like image 121
THelper Avatar answered Oct 21 '22 11:10

THelper