How to debug in Android Studio using adb over WiFi

后端 未结 15 2021
有刺的猬
有刺的猬 2020-12-04 06:32

I\'m able to connect to my phone using adb connect, and I can adb shell also.

But when I go to Run->Device Chooser, there are no devices there.

What should I

15条回答
  •  情歌与酒
    2020-12-04 07:00

    Here are simple steps to implement Android App debugging using ADB over wifi:

    Required: You need to connect android device and computer to the same router via wifi. You can use Android Wifi tethering also.

    Step 1: Connect Android device via USB (with developer mode enabled), and check its connection via adb devices.

    Step 2: Open cmd/terminal and the path of your ../sdk/platform-tools.

    Step 3: Execute command adb devices.

    Step 4: Execute command adb -d shell (for device) OR adb -e shell (for emulator). Here you will get the shell access to the device.

    Step 5: Execute command ipconfig (Windows command) or ifconfig (Linux command) and check the ip-address of it.

    Step 6: Not disconnect/remove device USB and execute command adb tcpip 5000, to open tcpip socket port 5000 for adb debugging. You can open it on any port which is not currently occupied.

    Step 7: Now execute command adb connect :. eg: adb connect 192.168.1.90:5000 (where ip-address is device's wifi address and port which you have opened).

    Now, run adb device and check the debugging device is now connected wirelessly via wifi.

    Happy Coding...!

提交回复
热议问题