【发布时间】:2018-01-03 13:13:50
【问题描述】:
我想知道我的 android 应用程序的错误,所以我尝试使用 logcat 查看它的日志并按照以下步骤操作:-
You need to use adb server.
1. Connect your android with your laptop/pc
2. Go to developer options and turn on the stay awake and USB debugging options. (Your phone)
3. In your terminal, type "sudo adb kill-server" and then "sudo adb start-server".
4. Type "adb devices" (this should give list of devices connected)
List of devices attached
you_device_name device
5. "cd" to your folder where you have made your build.
6. Type "buildozer android debug deploy run logcat > logcat.txt"
this saves the logs (for the entire process) in a file logcat.txtx in the same folder and also deploys you app on the phone.
Go through it and find your error.
7. keep your phone awake.(do not lock it).
但是当我运行第 6 步时,它会说:-
error: device 'adb' not found
- waiting for device -
我在互联网上搜索了很多次,最后我在这里发帖寻求解决方案
【问题讨论】:
-
运行
adb devices时会发生什么?您的设备是否检测到正确的权限?你能发布输出吗? -
@SrinivasSuresh 这是结果:- root@kali:~# adb devices 连接的设备列表 * 守护程序未运行。现在在端口 5037 上启动它 * * 守护进程已成功启动 * efeb26190903 设备
-
很好,您确定您已启用 USB 调试并关闭了设备上的 RSA 指纹弹出窗口,对吗?如果是这样,当您连接设备并运行
adb logcat时会发生什么? -
@SrinivasSuresh 在运行 adb logcat 连续日志或任何数据时,是的,我启用了 USB 调试,但不确定 RSA 指纹弹出
-
但我正在执行上面给出的第 6 步
标签: adb logcat android-logcat buildozer usb-debugging