Use of ADB WIFI


First of all, make sure that the computer and the mobile phone are in the same local area network. The specific steps are as follows. The adb command must be able to run

1. Install the ADB WIFI plugin in Android Studio. After successful installation, restart Android Studio. (For those who have not installed plugins, please search by yourself)

2. Connect the mobile phone to the computer via USB, in Android Studio, click Tools->Android->ADB WIFI->ADB USE to WIFI

3. Then unplug the USB and run it.

In step 2, there may be a problem that the IP of the mobile phone cannot be connected.

Solution: Connect the phone in Android Studio Terminal, the command is as follows:

1
adb connect 192.168.1.201
1
2
C:\workspace\android>adb connect 192.168.1.201
unable to connect to 192.168.1.201:5555: cannot connect to 192.168.1.201:5555: 由于目标计算机积极拒绝,无法连接。 (10061)

 If the above problems occur, first

1
adb tcpip 5555
1
2
C:\workspace\android>adb tcpip 5555
restarting in TCP mode port: 5555

 Then execute the previous command

1
2
C:\workspace\android>adb connect 192.168.1.201:5555
connected to 192.168.1.201:5555

 If connected appears, the connection is successful.


Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325163367&siteId=291194637