我通过 adb 将我们所有的 android 设备与 WiFi 连接起来。我正试图在一小时内获得正常运行时间。我现在得到的是几秒钟。
adb connect 172.16.100.2
adb shell cat /proc/uptime > "C:\TimeLog.txt"
(or just adb shell uptime)
adb disconnect
结果是
258521.25 1019421.93
(or uptime: 2 days, 23:59:00, idle time: 11 days.....)
我所需要的只是每小时的正常运行时间,我不需要第二部分时间......
我也试过
adb shell awk '{print int($1/3600)":"int(($1%3600)/60)":"int($1%60)}' /proc/uptime
但/system/bin/sh: aws: not found
我还能在 Android 上使用 adb 或 shell 来获得正常运行时间吗?
另外我应该使用什么命令在 Android 上设置日期/时间?