Android问题:手机关机时调试 [英] Android issue : Debug when phone off

查看:123
本文介绍了Android问题:手机关机时调试的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

要在手机重新启动时调试BroadcastReceiver,
我尝试过一些方法,但无法正常工作并链接如下

To Debug BroadcastReceiver when phone restart, I've tried Some Method but doesn't works and link as follow

如何调试BOOT_COMPLETE广播接收机的强制关闭崩溃?强制关闭崩溃

推荐答案

可能这不是最好的方法,但我有一个类似的问题而在启动接收器onReceive方法的开始,我使用了30秒的睡眠功能,所以我有时间在DDMS透视图中进入进程列表,并将我的应用程序置于调试模式,因此第一个实际指令中的断点的onReceive方法。
希望这个帮助

probably this is not the best way, but i had a similar problem and i used a sleep function of 30 seconds just at the beginning of the boot receiver onReceive method, so i had the time to go to the process list in DDMS perspective and put my app in debug mode, so the breakpoint on the first real instruction of the onReceive method it went hitted. hope this help

这篇关于Android问题:手机关机时调试的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆