adb connect mobile phone command, print memory

adb forward --remove-all

adb tcpip 5555
prompts
restarting in TCP mode port: 5555
==========xxxxxx
After adb connect 192.168.3.221,
it prompts
connected to 192.168.3.221:5555
==========xxxxxx
connected

adb shell ps |grep “golden”

adb shell dumpsys meminfo 9593

adb shell dumpsys cpuinfo

If more than one device and emulator appears
, enter adb devices and display
List of devices attached

DG4064b7ac4408 device

emulator-5556 device
1. If you want to select the first device to operate, execute the command adb -s DG4064b7ac4408 shell to enter the device operation

  1. If you do not want to enter the device shell mode, execute the adb -s DG4064b7ac4408 command (such as adb -s DG4064b7ac4408 shell input keyevent 3)

3. If there is only one emulator and one mobile phone connected to the computer; you can use adb -e to indicate the operating emulator (Emulator); you can use adb -d to indicate the operating device (Device)

实战:
rex@iMac ~ % adb forward --remove-all
adb: error: more than one device/emulator
rex@iMac ~ % adb devices
List of devices attached
RZ8M530LDXK device
192.168.3.221:5555 device

rex@iMac ~ % adb devices
List of devices attached
RZ8M530LDXK device
192.168.3.221:5555 device

rex@iMac ~ % adb -s RZ8M530LDXK shell
a10:/ $
Direct input: dumpsys meminfo

Concise command:
print memory:

adb devices
adb -s RZ8M530LDXK shell
dumpsys meminfo
dumpsys meminfo com.slotslimited.fatcatcasino.android -d
Specific documentation:
https://developer.android.com/studio/command-line/dumpsys?hl=zh-cn#meminfo

Guess you like

Origin blog.csdn.net/qq983985955/article/details/128018837