New android developer, need help getting emulator to run HelloWorld - android

I just got the bignerdranch android book, and already, I cant get my emulator to work. This is not exclusive to Big Nerd Ranch, since even the default hellworld wont run... I get the following in my console box.
[2013-12-18 13:17:40 - HelloWorld] ------------------------------
[2013-12-18 13:17:40 - HelloWorld] Android Launch!
[2013-12-18 13:17:40 - HelloWorld] adb is running normally.
[2013-12-18 13:17:40 - HelloWorld] Performing com.example.helloworld.HelloActivity activity launch
[2013-12-18 13:17:40 - HelloWorld] Automatic Target Mode: launching new emulator with compatible AVD
'Nexus_API_17'
[2013-12-18 13:17:40 - HelloWorld] Launching a new emulator with Virtual Device 'Nexus_API_17'
[2013-12-18 13:17:56 - Emulator] creating window 0 0 577 1025
[2013-12-18 13:17:56 - Emulator] eglMakeCurrent failed
[2013-12-18 13:18:23 - Emulator] eglMakeCurrent failed
[2013-12-18 13:18:23 - Emulator] FrameBuffer::post eglMakeCurrent failed
[2013-12-18 13:18:24 - Emulator] eglMakeCurrent failed
[2013-12-18 13:18:24 - Emulator] FrameBuffer::post eglMakeCurrent failed
I have tried redownloading eclipse, I have tried both 32 and 64 bit versions. I have tried making the emulator different rams, different phones, different sdk versions. I have tried running as admin as well. I am out of ideas on what I can do.
PS: I have also scoured the web looking for solutions, and did just try the end ADB task, then relaunch eclipse and try again.. no success

Please checkout how much ram size you define for emulator; it should be greater than or equal to 256MiB. You can also verify this in the logcat files.

FIXED IT! So the way I got it to work for me, and this is simply so that other people can read this in the future if they have the same issue, is:
1) I had to switch to 32bit instead of 64.
2) I had to run the emulator (which still throws errors), and wait for it to load fully.
3) After it loaded fully, I then run the emulator a second time while the first is still opened.
4) I get the following errors:
[2013-12-19 15:20:35 - Emulator] WARNING: Data partition already in use. Changes will
not persist!
[2012-09-02 15:20:35 - Emulator] WARNING: Cache partition already in use. Changes will
not persist!
followed by:
[2013-12-19 15:21:46 - HelloWorld] New emulator found: emulator-5554
[2013-12-19 15:21:46 - HelloWorld] Waiting for HOME ('android.process.acore') to be
launched...
5) Then you close the first emulator and the new one opens and runs the app...

Related

Need help, honeycomb emulator launch fails

When I run my application with Honeycomb emulator, it is showing the following error
[2013-01-25 17:56:54 - Demo] Launching a new emulator with Virtual Device 'Honeycomb'
[2013-01-25 17:57:07 - Emulator] Failed to create Context 0x3005
[2013-01-25 17:57:07 - Emulator] emulator: WARNING: Could not initialize OpenglES emulation, using software renderer.
[2013-01-25 17:57:08 - Demo] New emulator found: emulator-5556
[2013-01-25 17:57:08 - Demo] Waiting for HOME ('android.process.acore') to be launched...
[2013-01-25 17:58:24 - Demo] emulator-5556 disconnected! Cancelling 'android.demo.com.MainActivity activity launch'!
But other applications are running fine in other emulators like Gingerbread.
Did anyone face this problem? Please help me solve this.
may be this will help You
Go to the location C:\users\ur_pc_name\.android\cache and delete all the file

Android Emulator on Eclipse Not Working

I've been following the instructions found at http://developer.android.com/training/basics/firstapp/running-app.html to run the Hello World app on Eclipse's AVD, but the AVD does not launch and I get the following messages:
[2013-01-20 00:20:59 - MyFirstApp] ------------------------------
[2013-01-20 00:20:59 - MyFirstApp] Android Launch!
[2013-01-20 00:20:59 - MyFirstApp] adb is running normally.
[2013-01-20 00:20:59 - MyFirstApp] Performing com.example.myfirstapp.MainActivity activity launch
[2013-01-20 00:21:00 - MyFirstApp] Automatic Target Mode: launching new emulator with compatible AVD 'TestAVD'
[2013-01-20 00:21:00 - MyFirstApp] Launching a new emulator with Virtual Device 'TestAVD'
[2013-01-20 00:21:48 - Emulator] Failed to create Context 0x3005
[2013-01-20 00:21:48 - Emulator] emulator: WARNING: Could not initialize OpenglES emulation, using software renderer.
[2013-01-20 00:21:48 - Emulator] Failed to allocate memory: 8
[2013-01-20 00:21:48 - Emulator]
[2013-01-20 00:21:48 - Emulator] This application has requested the Runtime to terminate it in an unusual way.
[2013-01-20 00:21:48 - Emulator] Please contact the application's support team for more information.
Also, an error window popped up saying that the ARM emulator exe has stopped working. Any thoughts?
OP of this thread has similar error message,
emulator: WARNING: Could not initialize OpenglES emulation, using software renderer
Hope it helps!
Check 2 things:
That you are using 512MB of RAM (the emulator doesn't work properly
with more)
Try turning 'Host GPU' off
Try running emulator from the command line with GPU option and make sure that it is working or not.
-gpu off
Even if it result into the error, go to the eclipse, Right Click on the project and select run my projects as an "Android application". Emulator should start.
You can also give a try with enabling/disabling GPU emulation option for the selected emulator from the AVD manager.
To enable/disable GPU emulation :
Goto AVD manager -> select android virtual device -> click on Edit ->
Hardware tab -> enable/disable GPU emulation.
Hope it will work.
I got this error when trying to run an emulator with a higher resolution than I had my display set to.

Android emulator is not starting for hello word

I'm just starting to learn android programming.
I downloaded the ADT and went through the manual for the hello world! project.
But when I want to run my project I see this in console:
[2013-01-12 19:34:20 - HelloWorld] ------------------------------
[2013-01-12 19:34:20 - HelloWorld] Android Launch!
[2013-01-12 19:34:20 - HelloWorld] adb is running normally.
[2013-01-12 19:34:20 - HelloWorld] Performing com.example.helloworld.MainActivity activity launch
[2013-01-12 19:34:20 - HelloWorld] Automatic Target Mode: Preferred AVD 'Nexus7' is not available. Launching new emulator.
[2013-01-12 19:34:20 - HelloWorld] Launching a new emulator with Virtual Device 'Nexus7'
[2013-01-12 19:34:20 - Emulator] emulator: ERROR: No initial system image for this configuration!
I'm using MAC OSX
Tell me if more information is needed!
Thanks!
Among the SDKs installed, your PC seems to be missing the system image required for the AVD to start.
Go to the SDK manager and check if the components have been downloaded properly or not.
For further details, check here.

Eclipse with Android SDK failure to run blank project

I have downloaded ADT Bundle with everything included http://developer.android.com/sdk/index.html. When I create Android Applicatio and I want to run I get sth like that. How to make it running.
[2012-11-21 10:18:00 - Test2] ------------------------------
[2012-11-21 10:18:00 - Test2] Android Launch!
[2012-11-21 10:18:00 - Test2] adb is running normally.
[2012-11-21 10:18:01 - Test2] Performing com.example.test2.MainActivity activity launch
[2012-11-21 10:18:01 - Test2] Automatic Target Mode: launching new emulator with compatible AVD 'Test'
[2012-11-21 10:18:01 - Test2] Launching a new emulator with Virtual Device 'Test'
[2012-11-21 10:18:01 - Emulator] WARNING: Data partition already in use. Changes will not persist!
[2012-11-21 10:18:01 - Emulator] WARNING: Cache partition already in use. Changes will not persist!
[2012-11-21 10:18:01 - Emulator] Failed to allocate memory: 8
[2012-11-21 10:18:01 - Emulator]
[2012-11-21 10:18:01 - Emulator] This application has requested the Runtime to terminate it in an unusual way.
[2012-11-21 10:18:01 - Emulator] Please contact the application's support team for more information.
While running your android app, it will loaded in new emulator. we cant able to run multiple emulator with single instance. Goto->Task Manager->adb(in running processes)->give end task->restart your eclipse and run your emulator.
Data partition already in use: This problem is based on your system RAM size and emulator ram size(allocating ram size while creating AVD) . If two emulator running in same instances,
the memory error will occur.

Problems launching a virtual machine using the android avd manager [duplicate]

I have installed and set up Eclipse and the plugin ADT in order to work with Android SDK. So far so good. But when I try to launch a VM(virtual Machine) for any android platform that I choose (for example: android 3.2) I just get the skin launched together with a keyboard console and phone buttons, it seems to boot up to a state and then does nothing but displays the android logo on the main vm screen and that's all it does - no more!, no VM functionality!, what's going on? Have I missed out some step? Please help...
Have been waiting sometimes over 10 mins in each case for the emulator to start.
I launched/ran an Android project test sample; 'hello world' from the eclipse environment after installing the ADT plugin for Android These are the error messages I had displayed in the console ddms:
[2012-04-30 14:31:20 - HelloAndroid]
[2012-04-30 14:31:20 - HelloAndroid] Android Launch!
[2012-04-30 14:31:20 - HelloAndroid] adb is running normally.
[2012-04-30 14:31:20
- HelloAndroid] Performing com.example.helloandroid.HelloAndroidActivity activity launch
[2012-04-30 14:31:20 - HelloAndroid] Automatic Target Mode: launching
new emulator with compatible AVD
'leighs_basic_hardware_secound_virtual_device'
[2012-04-30 14:31:20 -
HelloAndroid] Launching a new emulator with Virtual Device
'leighs_basic_hardware_secound_virtual_device'
[2012-04-30 14:31:40 -
Emulator] Warning: No DNS servers found
[2012-04-30 14:31:52 -
Emulator] emulator: emulator window was out of view and was recentered
[2012-04-30 14:31:52 - Emulator]
[2012-04-30 14:31:53 - HelloAndroid]
New emulator found: emulator-5554
[2012-04-30 14:31:53 - HelloAndroid]
Waiting for HOME ('android.process.acore') to be launched...
[2012-04-30 14:49:03 - HelloAndroid] HOME is up on device
'emulator-5554' [2012-04-30 14:49:03 - HelloAndroid] Uploading
HelloAndroid.apk onto device 'emulator-5554'
[2012-04-30 14:49:03 -
HelloAndroid] Installing HelloAndroid.apk...
[2012-04-30 14:51:38 -
HelloAndroid] Failed to install HelloAndroid.apk on device
'emulator-5554!
[2012-04-30 14:51:38 - HelloAndroid] (null)
[2012-04-30 14:51:39 - HelloAndroid] Launch canceled!
At no point have I have anything but the Android logo displayed on my emulator. I have tried various platform emulators - none of them are performing!
A second lot of errors I received back on a test run after I checked the user data wiped in the Run configuration menu was: result
: [2012-04-30 17:20:27 - Emulator] Failed to allocate memory: 1455
[2012-04-30 17:20:27 - Emulator]
[2012-04-30 17:20:27 - Emulator] This
application has requested the Runtime to terminate it in an unusual
way.
[2012-04-30 17:20:27 - Emulator] Please contact the application's
support team for more information.
Bench mark results of my computer using Novabench incase anyone wants to check, are:
30/04/2012 17:45:59 Microsoft Windows 7 Starter Intel Atom N550
1.50GHz # 1500 MHz Graphics Card: Intel(R) Graphics Media Accelerator 3150
1014 MB System RAM (Score: 78) - RAM Speed: 1610 MB/s
CPU Tests (Score: 70) - Floating Point Operations/Second: 24110532 -
Integer Operations/Second: 43813828 - MD5 Hashes Generated/Second:
159380
Graphics Tests (Score: 1) - 3D Frames Per Second: 3
Hardware Tests (Score: 6) - Primary Partition Capacity: 87 GB - Drive
Write Speed: 14 MB/s
Do you Run your project or only start an emulator? After starting emulator, click Run button and select "Run as Android project".
I am not sure how long you waited, but starting the emulator the first time (before you have a snapshot) can take quite a long time. Depending on you hardware it can take more than 10 minutes to launch.
I had a similar issue which was solved by creating a new emulator and running it. You can check progress in Devices view through DDMS. Sometimes, this problem may occur when a snapshot enabled emulator hangs because of error, which can be solved by starting the emulator with user data wiped.
Emulator thread automatically cuts off if for some time you have not done any activity on it..
so.. keep running your app to keep emulator on LIVE!
My advice - if you having an android phone.. please usb debug it and Debug your application on your phone... You will feel relieved from the long durations of the emulator........ to run!! :)

Categories

Resources