• I'm trying to figure out how (or if it's possible) to accept the 'Force Close' dialog via the adb shell when an Android app crashes with a hard error (specifically out_of_memory). I'm hoping to basica...


I'm trying to figure out how (or if it's possible) to accept the 'Force Close' dialog via the adb shell when an Android app crashes with a hard error (specifically out_of_memory). I'm hoping to basically loop an app with a bash script, so when it crashes I want to start it running again. The missing step here is that I can't simulate pressing the 'Force Close' button that shows up in the middle of the dialog.
At the same time, the process doesn't seem to actually be running (trying to kill the PID doesn't work), so it's a bit of a weird situation because it seems to have already stopped, but launching it again (via adb shell am ...) just gives me 'current task has been brought to the front'.
Any thoughts would be appreciated!
解决方案
However to kill the process you should use
am force-stop: force stop everything associated with .
am kill: Kill all processes associated with . Only kills.
processes that are safe to kill -- that is, will not impact the user
experience.
for example:

展开全文
• I am getting an error when i try to run my projectddms]ADB rejected shell command (ls -l ): closedI can not understand why this happens and how it'll be solved.This shows every time when run project.I...


I am getting an error when i try to run my project
ddms]ADB rejected shell command (ls -l ): closed
I can not understand why this happens and how it'll be solved.
This shows every time when run project.
I tried :
1) Close emulator and start it again.
2) Restart eclipse.
解决方案
I think what happens is that the adb's connection with the emulator breaks or becomes faulty, so android launches a new emulator although you have already an existing emulator for the same platform running. One way you can try to correct this problem is Go to DDMS-->Devices Tab-->Click the option "Reset adb" (which is the last option) . You will then see some error report in the console, but after a minute your emulator would be ready to be used . See if this works for you.

展开全文
• This is my idea of what I want to do, simply execute the following commands but instead right after the line "adb shell" it stops, no other command can be triggered, whatever it is.adb connect 192.168...


This is my idea of what I want to do, simply execute the following commands but instead right after the line "adb shell" it stops, no other command can be triggered, whatever it is.
su
rm /data/system/locksettings.db
rm /data/system/locksettings.db-wal
rm /data/system/locksettings.db-shm
PAUSE
reboot
解决方案
adb shell command alone with out any extra parameters starts the shell in the interactive mode. Meaning it just sits there waiting for user input indefinitely. Your script never gets past that line.
What you really want is:
adb shell su 0 rm /data/system/locksettings.db
adb shell su 0 rm /data/system/locksettings.db-wal
adb shell su 0 rm /data/system/locksettings.db-shm
PAUSE

展开全文
• 关闭 APP Adb shell input keyevent 3 APP 退到后台运行 Adb shell dumpsys cpuinfo|findstr packagr 查看 APP 的 CPU Adl shell ps|findstr package 查看 APP 的进程 ( 同时可以看到 pid 号） Adb shell ...


转载于:https://www.cnblogs.com/winterhai/p/11050742.html
展开全文
• ## android abd

千次阅读 2010-11-29 17:43:00
仅仅通过USB接口来管理abd. 如果不只是用USB接口来管理则返回错误. -e 仅仅通过模拟器实例来管理adb. 如果不是仅仅通过模拟器实例管理则返回错误. -s  通过模拟器/设备的允许的命令...
• 先将手机关机（注意需要首先在设置菜单中，关闭“快速启动”功能，或者关机后拔下电池，超过2秒后再重新插入），然后同时按下音量下键以及开机键（平板请同时按下音量上键及开机键），并保持10秒钟以上时间，就可以...
• ABD — android debug bridge 简略介绍 文章目录ABD — android debug bridge 简略介绍一、abd是什么？二、组成部分三、adb 常用命令 一、abd是什么？ adb 全称 android debug bridge ，翻译：安卓调试桥 可以用...
• 3.4. 关闭app：adb shell am force-stop 包名 4. 从电脑上发送文件到设备 adb push <本地路径> <远程路径> 用push命令可以把本机电脑上的文件或者文件夹复制到设备(手机) 5. 从设备上下载文件到电脑 adb ...
• 仅仅通过USB接口来管理abd. 如果不只是用USB接口来管理则返回错误. -e 仅仅通过模拟器实例来管理adb. 如果不是仅仅通过模拟器实例管理则返回错误. -s  通过模拟器/设备的允许的命令号码来发送命令来...
• 仅仅通过USB接口来管理abd. 如果不只是用USB接口来管理则返回错误. -e 仅仅通过模拟器实例来管理adb. 如果不是仅仅通过模拟器实例管理则返回错误. -s  通过模拟器/设备的允许的命令号码来发送...
• [2016-08-04 10:06:15 - DeviceMonitor] Adb connection Error:远程主机强迫关闭了一个现有的连接。 [2016-08-04 10:06:16 - DeviceMonitor] Connection attempts: 1 解决方法: 我的解决方式是下载一个360手机...
• function QMPlugin.Close3g() --关闭流量 os.execute(“svc data disable”) end function QMPlugin.Open3g() --开启流量 os.execute(“svc data enable”) end function QMPlugin.Openwifi() --开启wifi os...
• 通过主策略限制端口https://jingyan.baidu.com/article/d621e8da0abd192865913f1f.html关闭135、139、445服务...
• 但是当你单击开始菜单上的电源按钮来关闭你的Windows 10时，你可能并没有真正关闭Windows 10。当然，Windows 10确实经历了关闭的过程，结果看上去你的计算机确实已经关闭了。但事实并非如此。这是一个比较旧的...
• https://jingyan.baidu.com/article/d621e8da0abd192865913f1f.html
• ITK:对给定LabelMap的所有LabelObject应用形态学关闭操作内容提要输出结果C++实现代码 内容提要 对给定LabelMap的所有LabelObject应用形态学关闭操作。 详细说明： 读取的图像转换为LabelMap 在LabelMap的所有Label...
• 设置--应用管理--更多应用--搜索“系统更新”--点进去选“通知管理”--关闭所有开关即可。

千次阅读 2016-05-25 13:47:29