2

I'm trying to run the "Hello, World" example found here http://developer.android.com/resources/tutorials/hello-world.html I followed the steps exactly, when I launch it I get this output

[2011-03-07 18:34:46 - SDK Manager] Created AVD 'my_avd' based on Android 3.0,
[2011-03-07 18:34:46 - SDK Manager] with the following hardware config:
[2011-03-07 18:34:46 - SDK Manager] hw.lcd.density=160
[2011-03-07 18:34:46 - SDK Manager] hw.keyboard.lid=no
[2011-03-07 18:34:46 - SDK Manager] vm.heapSize=48
[2011-03-07 18:34:46 - SDK Manager] hw.ramSize=256
[2011-03-07 18:34:51 - HelloAndroid] ------------------------------
[2011-03-07 18:34:51 - HelloAndroid] Android Launch!
[2011-03-07 18:34:51 - HelloAndroid] adb is running normally.
[2011-03-07 18:34:51 - HelloAndroid] Performing com.example.helloandroid.HelloAndroid      activity launch
[2011-03-07 18:34:51 - HelloAndroid] Automatic Target Mode: launching new emulator with compatible AVD 'my_avd'
[2011-03-07 18:34:51 - HelloAndroid] Launching a new emulator with Virtual Device 'my_avd'
[2011-03-07 18:34:55 - Emulator] emulator: emulator window was out of view and was recentred
[2011-03-07 18:34:55 - Emulator] 
[2011-03-07 18:34:56 - HelloAndroid] New emulator found: emulator-5554
[2011-03-07 18:34:56 - HelloAndroid] Waiting for HOME ('android.process.acore') to be launched...
[2011-03-07 18:54:55 - HelloAndroid] HOME is up on device 'emulator-5554'
[2011-03-07 18:54:55 - HelloAndroid] Uploading HelloAndroid.apk onto device 'emulator-5554'
[2011-03-07 18:54:55 - HelloAndroid] Installing HelloAndroid.apk...
[2011-03-07 18:57:52 - HelloAndroid] Failed to install HelloAndroid.apk on device  'emulator- 5554!
[2011-03-07 18:57:52 - HelloAndroid] (null)
[2011-03-07 18:57:54 - HelloAndroid] Launch canceled!

A fullscreen window opens up with blinking "Android" text, after a very long time it boots into the emulator. However it doesn't display the Hello World program.

My questions 1) How do I run my program? 2) Is there any faster way to sped up the emulator? I don't want to wait everytime I need to run the program

Thank you for the help.

Edit: I'm on Ubuntu 10.04 and Eclipse Galileo

Tim
  • 21
  • 1
  • 1
  • 3
  • I think you should rename your question... it is not that it can't find android.process.acore, it just isn't installing the apk correctly for some reason. – Jon Willis Mar 08 '11 at 03:26

5 Answers5

3

You need to increase the ADB connection time out. It defaults to 5 seconds which is too short for the big app. You find the dialog Menu: Windows -> Preferences -> Android.

enter image description here

stacker
  • 68,052
  • 28
  • 140
  • 210
0

This has happened to me in the past, it was solved by simply attempting the install again once the emulator was booted up properly. Give that a shot. If that doesn't work:

  1. Ensure the emulator you've created is equal to the targeted sdk you've set for the app.
  2. Look for any null pointers in the app, maybe a typo?
  3. Ensure that the emulator supports all the features you require in the application (probably not the case with hello world)
  4. try a clean + re-build of the app, then try to install it once you've done that.
Lukas Knuth
  • 25,449
  • 15
  • 83
  • 111
providence
  • 29,135
  • 13
  • 46
  • 62
  • Could you elaborate? What do you mean by "attemping the install again once the emulator was booted". Should I start the emulator via the AVD manager, and once it boots keep it running and try to launch my program? – Tim Mar 08 '11 at 03:18
  • Well you could do it like that. I mean that once the emulator has booted up hit run in eclipse again. That has solved it for me 95% of the time. – providence Mar 08 '11 at 04:20
  • @Tim, has any of this worked? Let us know, perhaps we can help more. – providence Mar 08 '11 at 18:17
0

I ran into this issue multiple times and have solved it 99% of the time by running the Emulator and letting it get stable -- once it was stable I clicked 'Run' again -- SUCCESS!

If you're still having issues, check what programs are currently running in your computer's background. When an install failed, I exited PowerISO which I had running, tried again, and it installed successfully!

Good luck! =)

Xezuka
  • 1,011
  • 1
  • 8
  • 10
0

I'm also new to android and I'm still running into into this problem (running SDK 3, Version: 10.0.0.v201102162101-104271). I've tried this procedure with mixed results: Eclipse isn't talking to the emulator FAQ. It's not clear to me whether or not it's OK to have multiple copies of an app on the (emulator?) target. I wouldn't think so but, while I have seen this output in my /data/app directory (see below) it's possible that was a transient state.

root@android:/data/app # ls
ls
ApiDemos.apk
CubeLiveWallpapers.apk
GestureBuilder.apk
SoftKeyboard.apk
WidgetPreview.apk
com.example.helloandroid-1.apk
com.example.helloandroid-2.apk
vmdl-206041726.tmp

I think that, by observing the logcat output, most of the times that I've seen that failure there was a failure to uninstall the older version of the app. But, being a newbee, I can't be sure.

I read that you can go into the /data/app directory (run 'adb shell' then 'cd /data/app') and delete the ...helloandroid-x.apk file before attempting to install the new apk. I haven't tried that approach yet.

Finally you can uninstall using this approach: adb uninstall com.example.helloandroid

If this helps you'll be luck not to run into the problem I'm having now, which is: I can't get the app to start from eclipse so I can't debug/step through code.

Rich Ramos
  • 141
  • 1
  • 10
0

This seams to be a common problem since there are more then 100 posts out there (which I found on Googles first site) which cover this problem.

It seams that this is just something that you can't really answer because it seams that there is an individual solution to this problem. See the previous questions:

Also, there seams to be another working solution out there (at least for some people).

Community
  • 1
  • 1
Lukas Knuth
  • 25,449
  • 15
  • 83
  • 111