1

I'm brand new to Android dev and have some n00b questions about AVD.

Is Google's emulator the best to use? It takes forever and a day to load.

Also, every time I make changes to the code and hit "run" in Eclipse it spawns off a new emulator. Is there a way to get the AVD currently running to reload the app instead?

Thanks in advance for your help!

UPDATE:

  • I completely blew away the SDK and AVDs and re-installed.
  • Disabling the boot animation made a HUGE difference in start-up time. I had to edit the run configuration to find and enable this option.
  • I had to also edit the run config to specifically launch my app on start, otherwise it defaults to home where I'd have to unlock, navigate to apps, and click to start. Big time saver there.
  • Enabling snapshots only caused the emulator to crash. Had to manually delete the AVD (via terminal 'android delete avd -n {name}' and recreate it (Eclipse wouldn't allow me to delete it), otherwise it wouldn't start again.
  • I can now leave the emulator running in the background. Clicking the run button now re-installs the app without rebooting the emulator. Woot!

The HelloWorld tut should really be called HelloBaldness. Pretty much blew the entire day wrestling with these ridiculously frustrating issues.

Thanks to all who responded!

manafire
  • 5,984
  • 4
  • 43
  • 53

2 Answers2

6

The link in the comment is a good start, but there are so many answers it may be hard to find the best options. By far the biggest startup time decrease I've had is by disabling the boot animation. Do the following:

  1. Open your project in eclipse
  2. Select your Android project and choose Project -> Properties from the menu
  3. On the left-hand side select Run/Debug Settings
  4. Highlight your project name and click "Edit"
  5. On the next dialog, select the "Target" tab
  6. At the bottom of the tab select "Disable boot animation"

There may be other tweaks that give you slightly better performance, but that one is by far the best.

Unfortunately, I don't know exactly why you get a new emulator every time. I've had this happen once and if recall correctly there was some error text that explained the problem in the output window in the Debug Perspective.

Mike Marshall
  • 7,788
  • 4
  • 39
  • 63
1

Loading the emulator is like booting an Os or booting an android mobile phone.

when ever you are running the android application, just check the 'adb devices' command in the terminal to confirm that the emulator is still running or not. else just do 'adb kill-server' and 'adb start-server' without closing the emulator. it will reduce your booting time of the emulator. Now RunAs.. Android Application.

Padma Kumar
  • 19,893
  • 17
  • 73
  • 130