Android: Retrieve logcat before crash (reboot) on a real device

后端 未结 6 840
陌清茗
陌清茗 2021-01-13 09:47

I am developing an application and during my testing on a real device I have found that it will crash and cause the phone to reboot (worrying I know...)

Is there any

6条回答
  •  北荒
    北荒 (楼主)
    2021-01-13 10:32

    From slashfoo's blog, (check the logcat page for exact syntax) hook up your computer to start off the logcat process in the background. adb shell nohup logcat -f /dev/[your sdcard] -n60 -r3600

    Although it means logcat will be saved to the sdcard but every time you reboot, you must perform the procedure again.

提交回复
热议问题