heinst
heinst

Reputation: 8786

List adb devices on network

I have a few devices enabled for over the air debugging. Is it possible to list the adb devices on the network? Something similar or to the same effect as adb devices but for devices that are enabled for over the air debugging.

Upvotes: 8

Views: 11893

Answers (2)

heinst
heinst

Reputation: 8786

If you do these steps exactly and run the adb devices command, the android device should appear under the List of Attached Devices. First open a command window and make sure you are either in the same directory as adb or have adb in your PATH variable. Then execute the following list of commands:

$adb usb 
restarting in USB mode


$ adb devices
List of devices attached
######## device

$ adb tcpip 5555
restarting in TCP mode port: 5555

Get the IP address of your android device. (Usually under System settings then Network settings, you can look up how to get the IP address on your specific device). The IP address should look something like 12.34.56.78 (this could vary though). Once you have the IP address continue with the following commands:

$ adb connect 12.34.56.78
connected to 12.34.56.78:5555

Remove the USB cable from the device

$ adb devices
List of devices attached
12.34.56.78:5555 device

Source

Upvotes: 11

rupps
rupps

Reputation: 9887

That's not possible with the Android SDK, as it would involve a huge network scan without any clue, just blind-pinging port 5555 of every possible address on the network.

But probably you can do it with a network scanner that looks for port 5555 open.

Upvotes: 0

Related Questions