Take the 2-minute tour ×
Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. It's 100% free, no registration required.

I just installed eclipse along with the tools for developing android apps tonight; so I'm new to both of them. Anyway, my emulator takes about 5 or more minutes to load each time, and generally comes up with errors. And it is always really big, like as tall as my laptop screen, and about half as wide.. Any help?

share|improve this question
1  
Shouldn't this be on SO as a development question? –  JonnyP Apr 14 '11 at 19:22
2  
Since the question is about the emulator its on the fence leaning towards being on-topic. –  Daniel Apr 14 '11 at 19:23
    
@Daniel: This is definitely a developer question, and doesn't belong here, but on StackOverflow.com –  Jonas Apr 17 '11 at 14:07
5  
@Jonas I'm only saying this because I have seen other emulator questions before with similar arguments: the question can be answered the same for a developer and a power-user. No part of his question asks for help with programming or java code. Now based on the OP comment on my answer its pretty obvious he's a dev but a non-dev user could ask this very same question in order to test out Android before buying a device. This approach to emulator questions was decided before I found this site. –  Daniel Apr 17 '11 at 21:24
    
You could actually make quite a good argument that this is just a PC software/hardware issue and belongs on SuperUser... –  GAThrawn Apr 18 '11 at 15:26
add comment

6 Answers

If you're doing development in Eclipse, you don't need to turn off the emulator. If the debug/run button in Eclipse is set up properly, then Eclipse will close the current instance of your program inside the emulator, install your new program to the emulator, and start the program on the currently running emulator -- all without rebooting the emulator.

Yes, the emulator booting still takes 5 minutes, but it's not that bad since you only boot the emulator once a day (and booting up Eclipse at the start of the day takes roughly the same amount of time anyway).

share|improve this answer
    
Thank you, I didn't even think about; but it makes sense. –  James Litewski Apr 14 '11 at 19:06
    
I'm another newbie to Android Dev and Eclipse.. when you say "If the debug/run button in Eclipse is set up properly..." what do you mean? I'm suspecting mine is not setup 'properly' because it reboots the emulator every time. Thanks –  FOR Feb 3 '12 at 12:45
    
Found answer to my follow-up question here: stackoverflow.com/questions/506777/… Leaving trail for anyone else that may wonder the same. –  FOR Feb 3 '12 at 13:21
add comment

Lie Ryan makes a good point that once you start the emulator you don't need to close it when you are done testing a build. Leave it open and each time you run or debug your app it will automatically be re-loaded and launched.

If you are having trouble with the size of the emulator you can modify the settings and have it display the actual size of the device you are trying to emulate. This can be done by opening up the "Android SDK and AVD Manager", select the AVD you want to manage and click "Start". This will bring up the dialog on the right (in the screen shot below). Check the "Scale display to real size" and then you need to modify the Screen Size field and the "Monitor dpi" field. The "Screen Size" will be the size of the screen for the device you are emulating and "Monitor dpi" will relate to your monitor's dpi. You may have to play around with this for a bit 'cause it took me a couple attempts to get it right.

SDK and AVD Manager

Hope this helps

share|improve this answer
    
So, I guess all I have to do is open it from there, and then click to run the program once it loads? –  James Litewski Apr 14 '11 at 19:07
    
@James It depends on how you have your project "Run Configuration"/"Debug Configuration". If they are set to manual then you will be prompted to select a currently running device or emulator or launch a new one. If its not manual then you will need to set the emulator you are running as the default so that it will install/run the program there. –  Daniel Apr 14 '11 at 19:31
    
Why the downvote? –  Daniel Apr 18 '11 at 19:56
add comment

I think there is nothing to do to accelerate the emulator, it is just really slow.

You'd better use a real device for tests, if possible.

share|improve this answer
    
Well, a real device is nowhere near my budget right now.. Do you at-least know how to make the emu smaller? So it's like a regular devices size? –  James Litewski Apr 14 '11 at 9:23
    
Launch the "android" command (in sdk/tools). In the "Android SDK and AVD Manager" dialog, there is a "New..." button to create a new machine. A dialog called "Create new Android Virtual Device" appears. In its "Skin" section you can specify the resolution you want. –  Nicolas Raoul Apr 14 '11 at 9:27
    
Thanks for your help. –  James Litewski Apr 14 '11 at 9:28
add comment

If you're using a multicore machine, you could try to force the emulator to use more cores. The Android emulator uses a single core by default, and on some processors it can be really slow. However, this decreases the stability of the emulator.

To do this, launch the emulator and press Ctrl+Shift+Esc to open Task Manager. Go to the Processes tab and right-click the emulator.exe process, select Set Affinity and select additional cores. Note that you have to do this every time you launch the emulator.

I did this on my old dev machine (Q9650, Win2008, 8GB DDR2 800MHz RAM) and it improved the speed a little, but crashed about once a day on average.

share|improve this answer
add comment

In addition to the other great answers here, this is sort of an obvious answer.

Anyhow, I figured I'd add it to the list here. If you increase hardware specs on the development computer your running this on (most specifically RAM or hard disk spindle speed) you'll see an increase in the speed at which the Emulator starts up and runs.

My development computer had 2GB of DDR2667 and when I went to 4GB of DDR800 I had a noticible increase in the speed of emulator startup and operations.

share|improve this answer
    
Development box? –  James Litewski Apr 14 '11 at 19:24
    
Development Box = A computer bought or built to be used specifically for software development. That doesn't mean it can't be used for anything else but development is its purpose. –  Daniel Apr 14 '11 at 21:56
    
Oops. Yeah I let geek-speek get into that one. Edited! –  Mat Nadrofsky Apr 18 '11 at 14:31
add comment

There is a feature build into the Emulator, named Snapshot. Snapshot, basically saves an image of the emulator (in it's current state) when you close it. Then next time, you can start it from the same place. The emulator will start almost immediately, since it doesn't need to go through the boot process. Using Snapshot, I consistently can start my emulator in less than 5 seconds (as opposed to 60 - 90 seconds to start it without).

Basically, when you create the AVD (create your emulator image) - there is a section titled: "Snapshot". Make sure this is checked ("enabled"). You can also go back and edit an AVD to enable this if you missed it the first time.

Next time you start the emulator, the "Snapshot" options will be enabled. Select "Launch from snapshot" if you want to start from a saved image, and select "Save to snapshot" to save whatever state your emulator is in when you close it.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.