Why .apk file is not running on the real device - android

I have developed an Android app. That app is running on the emulator perfectly. My application gets data from webservices. when I run the applicaton on a real device, I am getting force close.
I do not understand what the reason is. I came to know that we can debug our application by running on real device. I don't know exactly how to do it.
I found some link for using a real device for debugging http://developer.android.com/tools/device.html. But in this link it is given that usbdrivers are required for connecting the device to a PC. I am using Samsung Galaxy y . I did not found any drivers for that model (GT-S5360). Can anybody please help me.

Except from device debugging you can also have a look at the device generated log. There are many applications that allows you to do do, CatLog being one.

You should have the Android SDK.
http://developer.android.com/sdk/index.html
Activate USB Debugging on your device and run adb logcat in a command line on the host.
http://www.groovypost.com/howto/mobile/how-to-enable-usb-debugging-android-phone/
If you use eclipse, you can do all this the same way as on the emulator.
http://developer.android.com/tools/building/building-eclipse.html

Related

Get LogCat From Android Device Manually

My phone cannot connect to the android ADB but I need to check its logs since it seems to be getting unique errors from an app I made. aLogcat app is outdated and getting "bug reports" from developer options is unreadable for me.
Is there any way for me to get a logcat report of my app while I'm running an application on it?
Edit: I use a droid Mini phone and it won't connect to eclipse. After installing the specific driver for the device it worked.
First of all, consider making ADB work for your device. Provided this is totally impossible, consider using ACRA. If you don't want to integrate fully with it, check their logcat collection code.

USB Debugging issue on Android after rooting up my phone: "CreateJavaVM failed: dvmGcStartup failed"

I was working on Android Platform and I use my HTC Sensation for checking whatever I have developed directly on my phone via USB debugging instead of using that heavy emulator and everything was working perfect. But last week I rooted my phone and installed some custom ROM. After this problem arises that now when I connect my phone Eclipse does recognize it but when I run the developed app on eclipse it doesn't load on the phone.
USB debugging is enabled on phone.
Can you please tell me what is the problem ?
Here is the error I get in the LogCat but I dunno what it is:
I think it is all your ROM's mistake. A little bug in your ROM. I advise you to change to a new ROM. Most probably it will get rid of this error.

Android: How to find out reason for "Unfortunately [...] has stopped"?

when I run my Android application with an emulator, it works perfectly, and so it does on my phone, but on another phone, trying to run the app, I always get the "Unfortunately [...] has stopped" error. How can I find out the reason for this error (Using the emulator, I could look it up in LogCat, but not on a real phone)??
Thanks in advance!
On a real phone, you can use the tool aLogCat to view logs on the device itself. You can also connect it to your computer via USB and use the adb logcat tool, and the logs will be visible from the computer's shell window.
Adb logcat could also be used over a wireless network with a tool like WiFi ADB, should you prefer wireless methods.
Android Remote Stacktrace is a quite useful library/script that allows you to easily add a way for a phone to send its crash logs your way.
Simplest would in this case probably be to add it to a test version you put on the other phone. Since it's not being actively developed (afaik), you may not want to put it in a normal store release build.

How can i start my app written with libgdx on my android device?

I have written some codelines with libgdx in eclipse and want to run them on my android device.(It's a tablet)
But i cant find out how to do this.
I even cant run it on the android emulator provided by the android sdk. I get an error that the app stopped unexpectedly.
The app is working fine with the desktop launcher...
I hope someone can explain me how to get it working on the emulator or on my android device.
I saw somewhere that simply connecting my device via usb should be enough that eclipse is able to create an temporary app on the device, but this also didnt work.
Regards
1st of all, download SamsungKies[latest], to get and install proper USB Drivers. Its important that it should be the latest, cuz there was a bug in the previous versions.
Now that you have the drivers, simply connect your device to your machine IN USB DEBUGGING MODE.
Go to your main activity, and run.
If it launches in an emulator, close the emulator, and again in main activity, select run configurations -> Android Applications -> target -> always prompt to pick device.
Run again, and it should install and run in your phone/tablet.
NOTE:The activity closes in emulator because, by default, the emulator doesn't support OpenGLES emulation, its too heavy for your CPU.
i know its kinda late, but i hope it helps others:)

Debugging on the Device

I have a problem - my app works fine on the simulator, but on the device it crashes. Is there a way to debug an app that is running on the phone?
Thanks a lot.
Yes, it's perfectly possible. Just use Eclipse and register your device for debug use.
The procedure is a little bit different with each device, but you will basically need to put your device USB connection in debug mode and run your program/project within Eclipse IDE.

Categories

Resources