android application development - android

whenever I run an android application there comes the emulator but it does not show the output.
At runtime this warning is showed.
[2012-02-18 10:31:15 - Emulator] Warning: No DNS servers found
the console part shows the following messages
2012-02-18 11:26:52 - LunchList ------------------------------
2012-02-18 11:26:52 - LunchList Android Launch!
2012-02-18 11:26:52 - LunchList adb is running normally.
2012-02-18 11:26:53 - LunchList Performing apt.tutorial.LunchList activity launch
2012-02-18 11:26:53 - LunchList Automatic Target Mode: launching new emulator with compatible AVD 'secondAVD'
2012-02-18 11:26:53 - LunchList Launching a new emulator with Virtual Device 'secondAVD'
2012-02-18 11:27:15 - Emulator emulator: WARNING: Unable to create sensors port: Unknown error
2012-02-18 11:27:16 - LunchList New emulator found: emulator-5554
2012-02-18 11:27:16 - LunchList Waiting for HOME ('android.process.acore') to be launched...
2012-02-18 11:29:15 - LunchList emulator-5554 disconnected! Cancelling 'apt.tutorial.LunchList activity launch'!

Close your eclipse and AVD both and start again everything will be fine.

try to run in your command prompt:
adb kill-server
adb start-server
this is to restart the Android Debug Bridge.
If you have any problem running the command above, try to check if adb in in your path environment variable.

Try to remove BackCamera and Snapshot from Emulator, it worked for me.

Related

Why is the emulator in eclipse restarting?

I am following http://developer.android.com/training/basics/firstapp/running-app.html
and trying to run my first android app on the emulator on my PC.
The emulator is running (started from eclipse)
I managed to lauch myFirst App via eclipse as described, although in this tutorial it should be added you have to wait minutes before the emulator is up and running.
Now my problem is that when I modify myFirstApp, and wnat to test it, that eclipse keeps starting a new emulator:
[2012-10-15 19:32:44 - MyFirstApp] ------------------------------
[2012-10-15 19:32:44 - MyFirstApp] Android Launch!
[2012-10-15 19:32:44 - MyFirstApp] adb is running normally.
[2012-10-15 19:32:45 - MyFirstApp] Performing com.example.myfirstapp.MainActivity activity launch
[2012-10-15 19:32:45 - MyFirstApp] Automatic Target Mode: Preferred AVD 'Hobbit' is not available. Launching new emulator.
[2012-10-15 19:32:45 - MyFirstApp] Launching a new emulator with Virtual Device 'Hobbit'
This is extremely annoying, because of the performance penalty to launch a complete emulator.
But what is even more frustrating that I get back the very first version of MyFirstApp in this new emulator.
When I restart myself the emulator from scratch I see this in the console:
[2012-10-15 19:55:42 - MyFirstApp] New emulator found: emulator-5554
[2012-10-15 19:55:42 - MyFirstApp] Waiting for HOME ('android.process.acore') to be launched...
[2012-10-15 19:56:57 - MyFirstApp] emulator-5554 disconnected! Cancelling 'com.example.myfirstapp.MainActivity activity launch!'
Why? The emulator is still running at this point. This cannot be the normal way of working. Can anybody help me out?
Go to Run -> Run Configuration in eclipse. Select your application and update the target tab at right side to "Always prompt to pick device"
If the emulator is running and doesnt show in Devices then try to reset adb.
In eclipse: Device tab-> Dropbown - > reset abd

Stuck while installing sample helloAndroid application in emulator

i m new to android,done with installing android, emulator is also gets started, but stuck somewhere ...
it says
[2012-01-25 12:28:22 - HelloAndroid] Android Launch!
[2012-01-25 12:28:22 - HelloAndroid] adb is running normally.
[2012-01-25 12:28:22 - HelloAndroid] Performing com.example.helloandroid.HelloAndroidActivity activity launch
[2012-01-25 12:28:27 - HelloAndroid] Uploading HelloAndroid.apk onto device 'emulator-5554'
[2012-01-25 12:28:27 - HelloAndroid] Installing HelloAndroid.apk...
No success or failure message appears.
Do help, how to proceed further
Thanks in advance
Is the emulator listed in the devices tab in the DDMS perspective?
I had a problem when it was not visible and the applications I built didn't show up in the emulator. I found this solution:
http://developmentality.wordpress.com/2010/09/13/android-disappearing-emulator-restart-adb-server/
I added the platform-tools path to the windows path and then simply type
adb kill-server
adb devices
in the command line. This makes the emulator appear in the devices list and I can subsequently debug my applications by pressing F11.

My Android emulator won't launch and there are no errors, any ideas?

When I try to run my application as an Adroid App this is what my console reports:
[2011-10-22 15:21:32 - HelloWorldAndroid] ------------------------------
[2011-10-22 15:21:32 - HelloWorldAndroid] Android Launch!
[2011-10-22 15:21:32 - HelloWorldAndroid] adb is running normally.
[2011-10-22 15:21:32 - HelloWorldAndroid] Performing Hello.World.MyHelloWorld activity launch
[2011-10-22 15:21:32 - HelloWorldAndroid] Automatic Target Mode: launching new emulator with compatible AVD 'Android_1.5_Emulator'
[2011-10-22 15:21:32 - HelloWorldAndroid] Launching a new emulator with Virtual Device 'Android_1.5_Emulator'
When I open the AVD Manager says that it is valid. When I click start I get a quick loading screen and then it closes and thats it. I have changed the launch action in the configuration. I have deleted and recreated the emulator and the Android project. I am also using Ubuntu 11.10. Does anyone have ideas on the problem?
Try launching the emulator manually with adb and see if an error is reported. You could also try
adb kill-server
adb start-server
This worked for me. adb kill-server then adb start-server then cd ..\tools then emulator -avd <avd-name>. See also My Android emulator won't launch and there are no errors, any ideas?

Cannot run Android apps with eclipse on OS X 10.6

Running Eclipse 3.5.2 (Classic) in OS X 10.6.7 with the ADT plugin. I have the SDK installed and have run the SDK and AVD Manager to install all available platforms and tools. I have an AVD setup with Android 2.2 as the target API, and have configured the example 'Hello, Android' app for Android 2.1 Update 1, so compatibility should not be an issue. When I Run the application, it starts up the emulator, but gives me an error before the android startup animation appears. Here is the output in the Console window of Eclipse:
[2011-04-10 06:45:40 - HelloAndroid] ------------------------------
[2011-04-10 06:45:40 - HelloAndroid] Android Launch!
[2011-04-10 06:45:40 - HelloAndroid] adb is running normally.
[2011-04-10 06:45:40 - HelloAndroid] Performing com.twopoint7.testing.HelloAndroid activity launch
[2011-04-10 06:45:40 - HelloAndroid] Automatic Target Mode: launching new emulator with compatible AVD 'testDroid'
[2011-04-10 06:45:40 - HelloAndroid] Launching a new emulator with Virtual Device 'testDroid'
[2011-04-10 06:46:04 - Emulator] 2011-04-10 06:46:04.613 emulator[997:903] Warning once: This application, or a library it uses, is using NSQuickDrawView, which has been deprecated. Apps should cease use of QuickDraw and move to Quartz.
[2011-04-10 06:46:04 - HelloAndroid] New emulator found: emulator-5554
[2011-04-10 06:46:04 - HelloAndroid] Waiting for HOME ('android.process.acore') to be launched...
[2011-04-10 06:47:22 - HelloAndroid] emulator-5554 disconnected! Cancelling 'com.twopoint7.testing.HelloAndroid activity launch'!
Any advice on what might be going wrong would be greatly appreciated. I've found lots of posts (here and on other forums) that seem to indicate the NSQuickDrawView vs. Quartz warning seems to be a problem across the board but doesn't have a solution yet. I'm more concerned with the "emulator-5554 disconnected..." bit and the fact that I can't seem to run any apps in the emulator. Any other info I can provide which would be helpful? Any insight?
Thanks in advance for your time!
I guess you need to reset your adb after launch the emulator. In eclipse, go to window -> show view -> other -> device(under android folder).
In the device view, find and reset adb. Then run your apps.

emulator: ERROR: the user data image is used by another emulator. aborting

[2011-02-09 23:59:11 - Timerproject] ------------------------------
[2011-02-09 23:59:11 - Timerproject] Android Launch!
[2011-02-09 23:59:11 - Timerproject] adb is running normally.
[2011-02-09 23:59:11 - Timerproject] Performing acarin.timetracker.project.ezhil.Timerproject activity launch
[2011-02-09 23:59:11 - Timerproject] Automatic Target Mode: Preferred AVD 'MA_AVD_2.3.1' is not available. Launching new emulator.
[2011-02-09 23:59:11 - Timerproject] Launching a new emulator with Virtual Device 'MA_AVD_2.3.1'
[2011-02-09 23:59:31 - Timetracker] New emulator found: emulator-5554
[2011-02-09 23:59:31 - Timetracker] Waiting for HOME ('android.process.acore') to be launched...
[2011-02-10 00:01:40 - Timetracker] HOME is up on device 'emulator-5554'
[2011-02-10 00:01:40 - Timetracker] Uploading Timetracker.apk onto device 'emulator-5554'
[2011-02-10 00:01:40 - Timetracker] Installing Timetracker.apk...
[2011-02-10 00:04:11 - Timetracker] Failed to install Timetracker.apk on device 'emulator-5554!
[2011-02-10 00:04:11 - Timetracker] (null)
[2011-02-10 00:04:11 - Timetracker] Launch canceled!
i run the Timerproject but another timetrack project is only running the same timetracker project also doest responding
just close the already running emulator and start a new emulator more over if that doesn't works too close the eclipse too
If you're running Eclipse, and you've started the app from within (using Run As->Android App), then it should reuse the existing AVD. If it can't find it, then it will try to start another emulator and fail with the error you're seeing. Check the system Path environment variable and make sure it's including the SDK directory. If it doesn't then you'll see this error (I had the same problem; turned out I misspelled Program Files as Program Fiiles).
Hope this helps.
Open command prompt browse your adb path like
cd C:\Program Files\Android\android-sdk\platform-tools
type the command
adb kill-server && adb start-server
this will resolve your problem

Categories

Resources