android app won't install - android

I recently bought a couple of books on android programming and have been having a terrible time getting anything to work. I finally got one of the books sample code to show up. I noticed that when it worked that in the eclipse console it showed installation logging. In everything else I've tried it never gets to that point. All I ever get is what is shown below. Does anyone know why it doesn't continue to the installation point?
I also noticed that in the code that does work, there's a folder structure in the bin directory that matches the src directory.
src>com.deitel.doodlz
bin>com>deitel>doodlz - contains all the class files
In my project, there is no folder structure like this in my bin directory. Is there something else I need to do besides just hitting the run button? Do I have to do some type of build first? Thanks.
[2012-03-12 21:21:52 - Now2] ------------------------------
[2012-03-12 21:21:52 - Now2] Android Launch!
[2012-03-12 21:21:52 - Now2] adb is running normally.
[2012-03-12 21:21:52 - Now2] Performing my.android.stuff.Now2Activity activity launch
[2012-03-12 21:21:52 - Now2] Automatic Target Mode: Preferred AVD 'android_2_3_3' is not available. Launching new emulator.
[2012-03-12 21:21:52 - Now2] Launching a new emulator with Virtual Device 'android_2_3_3'
[2012-03-12 21:21:57 - Emulator] emulator: WARNING: Unable to create sensors port: Unknown error
[2012-03-12 21:21:57 - Emulator] emulator: emulator window was out of view and was recentered
[2012-03-12 21:21:57 - Emulator]

Related

Emulator doesn't start in eclipse

I've tried to find answers and similar problems, but nothing has fixed the problem.
I created a project and wanted to run the emulator to check if everything is working fine. But the emulator doesn't start up. It gives the following ouput, in console:
[2015-01-08 10:20:06 - MTNInfoHub] ------------------------------
[2015-01-08 10:20:06 - MTNInfoHub] Android Launch!
[2015-01-08 10:20:06 - MTNInfoHub] adb is running normally.
[2015-01-08 10:20:06 - MTNInfoHub] Performing com.mtninfohub.MainHub activity launch
[2015-01-08 10:20:33 - MTNInfoHub] Launching a new emulator with Virtual Device 'test'
[2015-01-08 10:20:33 - Emulator] ko:Could not create temp file for system partition image: %s,size=0x%llx
[2015-01-08 10:20:33 - Emulator]
Please help me.
Running on centos, 32 bit architecture
Had this problem with Android Studio. To fix it, I just ran Android Studio as administrator.

NAND error in Hello World project in the official Android developer tutorial

I'm working on the Hello World project at http://developer.android.com/resources/tutorials/hello-world.html
The trouble comes when I run the application. The sequence of messages I get is something like:
[2012-04-30 15:13:19 - HelloAndroid] ------------------------------
[2012-04-30 15:13:19 - HelloAndroid] Android Launch!
[2012-04-30 15:13:19 - HelloAndroid] adb is running normally.
[2012-04-30 15:13:19 - HelloAndroid] Performing com.example.helloandroid.HelloAndroid activity launch
[2012-04-30 15:13:19 - HelloAndroid] Automatic Target Mode: launching new emulator with compatible AVD 'my_avd'
[2012-04-30 15:13:19 - HelloAndroid] Launching a new emulator with Virtual Device 'my_avd'
[2012-04-30 15:13:25 - Emulator] NAND: could not write file /tmp/android-jhsu/emulator-7iTL7m, File exists
What exactly is stopping the process from executing properly? What do I need to do to fix this?
UPDATE 1:
OK, I tried your suggestions about clearing the avd.
I went into my android_sdk_linux directory and entered "tools/android list avd". The output was:
Available Android Virtual Devices:
Name: my_avd
Path: /home/jhsu/.android/avd/my_avd.avd
Target: Android 4.0.3 (API level 15)
ABI: armeabi-v7a
Skin: WVGA800
So I entered "tools/emulator -avd my_avd -wipe-data". The output was:
NAND: could not write file /tmp/android-jhsu/emulator-5FHEn7, File exists
But I looked in the /tmp/android-jhsu directory and saw no file at all, not even a hidden file.
Where do I go from here?
I was able to fix it exporting ANDROID_TMP
export ANDROID_TMP=/home/myuser
For me at least, I'd let my disk run out of space without realizing it.
It was just coincidence that this was the first item that failed.
It's a real disturbing situation when error can't completely describe problem in detail!
finally I figured out all this kind of error messages ("File Exists" and "There is no space") are due to small amount of mounted space on /tmp folder.
in Linux try mount and you'll see specified parameters of tmpfs and /tmp
changing $ANDROID_TMP value is not a proper solution and even doesn't work at all.
try editing fstab
sudo gedit /etc/fstab
and increase /tmp size to a larger value that makes sense to you (like:1500M)
then reboot system
PS: It's not IDE-dependent (Eclipse or Android-Studio) but something that deal with AVD Emulator

How to install an apk on my Emulator if I get: Snapshot storage already in use?

This is the error message I have met when I run my app, and my logcat is empty
-08-09 11:19:22 - TestCity] ------------------------------
[2011-08-09 11:19:22 - TestCity] Android Launch!
[2011-08-09 11:19:22 - TestCity] adb is running normally.
[2011-08-09 11:19:22 - TestCity] Performing com.pack.android.TestCityActivity activity launch
[2011-08-09 11:19:22 - TestCity] Automatic Target Mode: launching new emulator with compatible AVD 'my_device'
[2011-08-09 11:19:22 - TestCity] Launching a new emulator with Virtual Device 'my_device'
[2011-08-09 11:19:24 - Emulator] WARNING: Data partition already in use. Changes will not persist!
[2011-08-09 11:19:24 - Emulator] ko:Snapshot storage already in use: C:\Documents and Settings\Ram\.android\avd\my_device.avd/snapshots.img
I had the same problem. Turned out to be caused (in part) by leftover lock files from a previous run (which may explain why ntc's 'wipe user data' fix didn't work for me).
Look in the folder shown in the error message (that is, without the snapshots.img bit).
You should see several folders ending in .lock
each folder may contain a file called 'pid'. If so, delete the 'pid' files.
That allows the emulator to start, but it stuck at the plain text 'android' stage,
so I deleted the various .img files and tried again and the emulator started OK.
Check if the Built-in (type of emulator) is the same in your Graphical Layout. You should configure the same type (but version can be different).
Try to kill your ADB-server using adb kill-server
Then restart your server. More info over here
If all fails, create a new AVD.
If you are using Eclipse ADT, just press 'Clean...' from Project menu. Then run again. Worked for me.
just kill avd process from task manager and restart your eclipse.

Running first Android application - error message

I am getting this error when I am trying to launch my first Hello World Android application. I am doing the tutorial based on Sams Teach Yourself Android Application Development in 24 Hours.How can I resolve this?
[2011-08-18 02:33:28 - droidapp] ------------------------------
[2011-08-18 02:33:28 - droidapp] Android Launch!
[2011-08-18 02:33:28 - droidapp] adb is running normally.
[2011-08-18 02:33:28 - droidapp] Performing com.droid.app.DroidappActivity activity launch
[2011-08-18 02:33:28 - droidapp] Automatic Target Mode: Preferred AVD 'firstdroid' is not available. Launching new emulator.
[2011-08-18 02:33:28 - droidapp] Launching a new emulator with Virtual Device 'firstdroid'
[2011-08-18 02:33:30 - Emulator] invalid command-line parameter:
Files\Android\android-sdk\tools/emulator-arm.exe. [2011-08-18 02:33:30
- Emulator] Hint: use '#foo' to launch a virtual device named 'foo'.
[2011-08-18 02:33:30 - Emulator] please use -help for more
information
Change the path of the SDK your path to Program Files\Android\android-sdk tools/emulator-arm.exe. Put the SDK directly in the drive, that is, d:\Android\android-sdk-tools\emulator-arm.exe.
Note: also remove spaces from the path by renaming the folder name.
Use Eclipse and the Android plugin to make this via a graphical user interface. That would be better for a newcomer.

Emulator not opening in Android

When I am running my app on emulator it dont open and gives the following Error.
[2011-01-08 16:16:56 - AudApp] ------------------------------
[2011-01-08 16:16:56 - AudApp] Android Launch!
[2011-01-08 16:16:56 - AudApp] adb is running normally.
[2011-01-08 16:16:56 - AudApp] Performing com.a1technology.AppingActivity activity launch
[2011-01-08 16:17:00 - AudApp] Launching a new emulator with Virtual Device 'avd_2.3'
[2011-01-08 16:17:00 - Emulator] emulator: ERROR: the user data image is used by another emulator. aborting
In : yourusername.android\avd\youremulatorname\
the folders:
cache.img.lock, sdcard.img.lock and userdata-qemu.img.lock
are created when the emulator starts and should be deleted when it closes. If the exit wasn't clean for some reason, then they aren't deleted. Delete them manually and it should fix your problem.
I solved the problem by restarting Eclipse with no emulator running.

Categories

Resources