adb shell命令

编程入门 行业动态 更新时间:2024-10-24 23:28:07

1、logcat:

遇到报错信息:

logcat: Unexpected EOF!

This means that either the device shut down, logd crashed, or this instance of logcat was unable to read log
messages as quickly as they were being produced.

If you have enabled significant logging, look into using the -G option to increase log buffer sizes.

查看一下logcat缓冲区大小:

D:\work\test\log>adb shell logcat -g
main: ring buffer is 256 KiB (3 MiB consumed), max entry is 5120 B, max payload is 4068 B
system: ring buffer is 256 KiB (251 KiB consumed), max entry is 5120 B, max payload is 4068 B
crash: ring buffer is 256 KiB (15 KiB consumed), max entry is 5120 B, max payload is 4068 B
kernel: ring buffer is 256 KiB (245 KiB consumed), max entry is 5120 B, max payload is 4068 B

先修改为5MB大小试试:

D:\work\test\log>adb shell logcat -G  5M

D:\work\test\log>adb shell logcat -g
main: ring buffer is 5 MiB (4 MiB consumed), max entry is 5120 B, max payload is 4068 B
system: ring buffer is 5 MiB (238 KiB consumed), max entry is 5120 B, max payload is 4068 B
crash: ring buffer is 5 MiB (15 KiB consumed), max entry is 5120 B, max payload is 4068 B
kernel: ring buffer is 5 MiB (239 KiB consumed), max entry is 5120 B, max payload is 4068 B

2、设置Android系统的时间(用win10系统验证)。

先设置年月日

adb shell date  %date:~0,4%-%date:~5,2%-%date:~8,2% set

在设置时分秒

adb shell date %time:~0,2%:%time:~3,2%:%time:~6,2% set

验证:

D:\>adb shell date
Sat Nov 27 12:41:25 GMT 2021

更多推荐

adb shell命令

本文发布于:2023-06-10 16:29:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/620841.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:命令   adb   shell

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!