为什么在尝试使用 Android 模拟器和 Eclipse 进行调试时,调试器未附加?
我无法在模拟器上调试任何应用程序,它们都挂在“应用程序...正在等待调试器附加。这以前不是问题。我曾尝试调试几个月前编写的应用程序,并且即使那些无法附加到调试器,
我也进行了搜索并找到了此问题的常见解决方案,例如: 使用权限“android.permission.SET_DEBUG_APP” 并在这个问题中找到应用程序标签 android:debuggable="true" 附加调试器 - android 问题但经过检查,发现我的应用程序已经设置了这些设置。
我还确保在“设置”>“应用程序”>“开发”下选中“USB 调试”设置。我也经常检查 Eclipse 的新更新。 我想我在 eclipse 更新后开始遇到这个问题。有没有人找到这个问题的解决方案? 我一直在开发一个非常酷的应用程序,并且能够创建 UI,但确实需要能够进行调试,因为我将实现以前从未实现过的东西,并且没有调试将是一个重大挫折并减慢我的速度。
I can't debug any of my applications on my emulator, they all hang at "Application... is waiting for the debugger to attach. This wasn't a problem before. I have tried to debug apps that I programmed months ago and even those fail to be attached to the debugger.
I have searched around and found common solutions to this problem such as:
Using permission "android.permission.SET_DEBUG_APP"
and having the application tag android:debuggable="true" found in this question
Attaching debugger - android problem but after checking, found my apps already have these settings set.
I have also made sure 'USB debugging' setting is checked under Settings>Applications>Development. I also always check new updates for eclipse.
I think I started having this problem after an eclipse update. Has anyone found a solution to this issue?
I have been working on a really cool app and been able to create the UI, but really need to be able to debug as I will be implementing things I haven't before and no debugging would be a major set back and slow me down.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我最近从 Android 工具 15 开始就遇到了这个问题。我发现的解决方法是在启动 eclipse 之前启动模拟器。然后它似乎工作正常。
I have had this problem lately since Android tools 15. The workaround I found is to lanch the emulator before you launch eclipse. Then it seems to work fine.
根据 android 消息来源,操作系统将处于无限循环中并旋转,直到调试器空闲足够长的时间。您可以通过按暂停调试按钮、等待 1.5 秒并按恢复按钮来强制调试器空闲。之后调试器应该附加。
According to android sources os will sit and spin in infinite loop until debugger idle long enough. You could force debugger to idle by pressing pause debug button, waiting 1,5 sec and pressing resume. After that debugger should attach.
尝试确保您的“线程”窗格未显示。正如@arcadoss提到的,调试器需要空闲一段时间,并且线程窗格不断刷新其视图中的线程。
Try making sure your Threads pane isn't displaying. As @arcadoss metioned the debugger needs to be idle for a period of time, and the threads pane constantly refreshes the threads in its view.