[Android][adb]Android real machine wifi debugging

Connect wifi specific steps


  1. First make sure that both the computer and the mobile phone are connected to the same local area network

  2. Turn on USB debugging, connect the computer and mobile phone with a data cable

  3. Use adb to view connected Android devices

    如果在 devices 里边没有看到连接的手机,说明连接不成功,看一下 usb 调试开没开,有没有驱动程序啥的

  4. Command adb -s [device id] tcpip [port]is a need to specify the port number wifi connection device

    • device id: The id of the device that needs to be connected, that is, the string seen in the second step

    • port: the port number used for the connection, specify according to your own wishes, I use 8888

    Example:adb -s 98899a4558304e384f tcpip 8888

    If you only connect one device, you don’t need to specify -s to act on that device, that isadb tcpip 8888

  5. Command adb connect [phone ip]:[port]connected devices

    • phone ip: The ip address of the mobile phone currently connected to the LAN.

    • adb shell netcfg

    • port: the port number set in the previous step

    Example:adb connect 10.10.10.60:8888

Guess you like

Origin blog.csdn.net/xfb1989/article/details/111611415
Recommended