An ANR is usually the result of doing too much work on the UI thread...
>From the log it looks like this is happening in main.  So, figure out what
you are doing that takes a lot of time and move it to a different thread.

Thanks,
Justin Anderson
MagouyaWare Developer
http://sites.google.com/site/magouyaware


On Fri, Jun 1, 2012 at 2:33 AM, Yefta Meliala <abuymil...@gmail.com> wrote:

> Hi, i am developing an android application and i need help to solve my
> problem on my application.
> My application is consist of 2 activity,  main.java and
> CobaGesture.java.
>
> Main,java has a start button that run startActivity(new
> Intent(main.this, CobaGesture.class));
> CobaGesture.java has a back button that run finish();
> startActivity(new Intent(CobaGesture.this, main.class));
>
> When the app running, i press the start button the activity changed to
> CobaGesture, and when i press back button in CobaGesture the activity
> back to main. But, when i press start again the app is forced close
> and here's logcat of the error:
>
>
> //when i press the start button for the second time
> 06-01 14:59:51.836: INFO/InputDispatcher(65): Application is not
> responding: Window{4079d900 coba.gesture/coba.gesture.main
> paused=false}.  5006.2ms since event, 5005.3ms since wait started
> 06-01 14:59:51.836: INFO/WindowManager(65): Input event dispatching
> timed out sending to coba.gesture/coba.gesture.main
> 06-01 14:59:51.926: INFO/Process(65): Sending signal. PID: 2730 SIG: 3
> 06-01 14:59:51.926: INFO/dalvikvm(2730): threadid=4: reacting to
> signal 3
> 06-01 14:59:51.957: WARN/ActivityManager(65): Activity destroy timeout
> for HistoryRecord{4068bea0 coba.gesture/.CobaGesture}
> 06-01 14:59:51.996: INFO/dalvikvm(2730): Wrote stack traces to '/data/
> anr/traces.txt'
> 06-01 14:59:52.025: INFO/Process(65): Sending signal. PID: 65 SIG: 3
> 06-01 14:59:52.025: INFO/dalvikvm(65): threadid=4: reacting to signal
> 3
> 06-01 14:59:52.435: INFO/dalvikvm(65): Wrote stack traces to '/data/
> anr/traces.txt'
> 06-01 14:59:52.435: INFO/Process(65): Sending signal. PID: 122 SIG: 3
> 06-01 14:59:52.435: INFO/dalvikvm(122): threadid=4: reacting to signal
> 3
> 06-01 14:59:52.556: INFO/dalvikvm(122): Wrote stack traces to '/data/
> anr/traces.txt'
> 06-01 14:59:52.576: DEBUG/dalvikvm(65): GC_CONCURRENT freed 993K, 47%
> free 4456K/8327K, external 2036K/2548K, paused 13ms+31ms
> 06-01 14:59:52.605: INFO/Process(65): Sending signal. PID: 125 SIG: 3
> 06-01 14:59:52.605: INFO/dalvikvm(125): threadid=4: reacting to signal
> 3
> 06-01 14:59:52.656: INFO/dalvikvm(125): Wrote stack traces to '/data/
> anr/traces.txt'
> 06-01 14:59:53.676: DEBUG/dalvikvm(65): GC_EXPLICIT freed 231K, 46%
> free 4535K/8327K, external 2036K/2548K, paused 257ms
>
> //error log
> 06-01 14:59:54.406: ERROR/ActivityManager(65): ANR in coba.gesture
> (coba.gesture/.main)
> 06-01 14:59:54.406: ERROR/ActivityManager(65): Reason:
> keyDispatchingTimedOut
> 06-01 14:59:54.406: ERROR/ActivityManager(65): Load: 0.62 / 0.35 /
> 0.46
> 06-01 14:59:54.406: ERROR/ActivityManager(65): CPU usage from 8027ms
> to -2ms ago:
> 06-01 14:59:54.406: ERROR/ActivityManager(65):   85% 2730/
> coba.gesture: 78% user + 6.6% kernel / faults: 27 minor
> 06-01 14:59:54.406: ERROR/ActivityManager(65):   13% 65/system_server:
> 5.9% user + 7.2% kernel / faults: 1 minor 1 major
> 06-01 14:59:54.406: ERROR/ActivityManager(65):   0.2% 41/adbd: 0% user
> + 0.2% kernel / faults: 13 minor
> 06-01 14:59:54.406: ERROR/ActivityManager(65): 100% TOTAL: 84% user +
> 15% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65): CPU usage from 1849ms
> to 2454ms later:
> 06-01 14:59:54.406: ERROR/ActivityManager(65):   72% 2730/
> coba.gesture: 69% user + 3.3% kernel / faults: 4 minor
> 06-01 14:59:54.406: ERROR/ActivityManager(65):     72% 2826/Thread-10:
> 69% user + 3.3% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65):     1.6% 2735/Compiler:
> 0% user + 1.6% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65):   25% 65/system_server:
> 8.6% user + 17% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65):     13% 99/
> InputDispatcher: 6.8% user + 6.8% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65):     10% 76/
> SurfaceFlinger: 1.7% user + 8.6% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65):     1.7% 65/
> system_server: 1.7% user + 0% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65):     1.7% 74/Binder
> Thread #: 1.7% user + 0% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65):     1.7% 230/Binder
> Thread #: 0% user + 1.7% kernel
> 06-01 14:59:54.406: ERROR/ActivityManager(65): 100% TOTAL: 78% user +
> 21% kernel
>
> what is the meaning of the error? what caused the error?
> thanks in advance.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to