Tablet restarts when I launch app from Eclipse - java

My tablet restars once in two or three times when I launch my app from Eclipse. Since nothing appears on Logcat or Error Log, I cannot post any clue. I just wonder what kind of codes can cause such behaviour, so I can check if I have written something wrong.
The problem is again, I launch my app on my tablet from Eclipse, then tablet just restarts instead of launching app. This happens once in every two or three launch. Has any of you encountered such a problem?

Updated
clear log from device
adb logcat -c
run the app let tablet restart when back capture the log in text file and check whats happening.
adb shell logcat > log.txt

Related

Updated Android Studio, Logcat not working on one Android device anymore but still works on my other Android device

I googled this a lot so I believe it is appropriate to create a new question.
I updated Android Studio recently and my main Android device (ZTE, not an emulator) stopped reporting to Logcat. This device has never had a problem reporting to Logcat.
I tried all the steps from restarting my Android, to restarting Logcat, to restarting Android Studio, to Invalidate Catches / Restart... to refreshing the gradle to even resetting the Android device to factory settings. I of course checked the Logcat filters and the developer options on the phone like a 100 times.
The part which is weird to me is my other Android device (HTC) still reports to Logcat just fine with no problems at all. This means its not Android Studio, its the ZTE phone itself.
Does anyone have an idea why my ZTE wont report to Logcat anymore but my HTC has no problem reporting to Logcat after updating Android Studio? By the way I'm 99% sure its not the developer options on the ZTE as they match the developer options on the HTC exactly.
You can fix the following loop through this
Restart logcat
Change the log level to Debug (or anything else) and back to Verbose.
unplugging and plugging back in the device
running adb kill-server && adb start-server
Close Android Studio and launch ddms on the command line.
Restart Android Studio
And finally restarting the computer if all else fails.
The problem is intermittent, I think Android Studio is just buggy.
Try changing to no filters
It is also one alternative
It does not look like studio issue. Can you try changing the device USB configuration to MTP and authorise the device and toggle debugging option turning on/off.

Trouble running android wear app on emulator

I cannot seem to run this application which is supposedly ready to go to run on the Android Wear emulator.
Appreciate if someone can help me as to why this app does not actually get deployed to Watch emulator. I can see that the unaligned APK gets generated though.
I am following this guide:
http://toastdroid.com/2014/07/18/developing-watchfaces-for-android-wear/
Code is available at:
https://github.com/twotoasters/watchface-template
To install watchface you need to generate signed APK and push it to phone that is connected to that emulator, and install it there. After 1-2 minutes watchface should appear on the Wear device - if doesn't sync apps by companion app.
Also make sure that package for phone contains 'wear' part.
The key here is that you're using the emulator. If you run WatchfaceActivity.java from the Wear module on the emulator, you will see the watch appear on screen, but as an activity that can be dismissed.
If you then try to select it as the default watch face, you will be met with a black screen. I have only seen the emulator display the custom watch face (as a watch face, not a running activity) once and it seemed to have been a fluke.
The best way to develop custom watch faces is to run them as stand alone activities until it appears to be done, then go through the trouble of exporting a signed APK and run it on a real device connected to a real watch. At that point you can fix any small issues that remain.
please run you application on phone which has 4.3 or above platform.
install Android wear launcher apk on phone .
then connect wear emulator and phone using adb command.
adb -d forward tcp:5601 tcp:5601

Android Phone (HTC ADR6300VW) freezes but doesn't crash, logcat doesn't print stack trace

Android freezes right when it is supposed to crash and the app becomes completely nonresponsive. The Eclipse Logcat doesn't show any errors or print the stack trace, though it does show system and warning outputs. I tested other apps and they crash and print their stack trace in the logcat. This happens in multiple different places in the app where it should crash. The debugger attaches successfully.
I am using async tasks for networking and backend work but the errors that cause crashing happen on the main thread.
Update1 The app crashes properly and logcat prints a stack trace when running on an emulator. Resetting ADB from console does not solve problem, though it does recognize that adb is attached to the device. Unchecking and then re-checking "Android debugging" does not solve problem. I'm guessing the problem lies with the phone?
Update2 Factory resetting the phone didn't solve it.
Update3 I tested on another Android phone, a Galaxy S4, and it crashed and printed a stack trace properly. The problem device is a HTC ADR6300VW running Gingerbread (API 10).

I can not see my log in Android

I put the following excerpts log in my Android application:
Log.w (TAG_NAME, "Hello Log - Warning!");
System.out.println ("CardapioWeb: xml downloaded:" + xmlBaixadoComSucesso);
When running the application in Eclipse, I can smoothly view these logs in Eclipse LogCat Tab.
The problem occurs when I install the application on a real phone (Galaxy S4 for example). I export the system log using various apps, but does not appear in that log no one of my excerpts.
My log is not displayed in a real cell, only in Android Emulator . I need something to enable the log show?
Thanks'
Starting with Android 4.1, applications can only see their own log statements. You wrote that you used various apps to export the logs, so that may be the reason why you don't see it.

Android Processing programming will not run application on device. How do I fix this?

I'm currently working with Processing, and I would like to code an android app. I have succeeded in being able to launch may application in the android emulator, but I am not able to get it to launch on my Galaxy 2.0 tab. I click run device, but every time I do I get a message at the end that says "waiting for device to become available". I'm thinking that I may need to point Processing to my android tablet somehow. Any ideas as to what I'm doing wrong. I'm on Windows 7.
It means your device is not being detected in the eclipse debugger tool. Did you check in Tab "Developer Options", make sure USB debugging is enabled. please refer other links you may get answer.
Click here
Device not detected in Eclipse when connected with USB cable

Categories

Resources