3

I know how to debug over wifi, but the problem is that my usb cable is broken.

Is there any chance I can use adb tcpip 5555 with literally no cable?

Rafaela Lourenço
  • 1,126
  • 16
  • 33
user3121362
  • 85
  • 1
  • 12
  • 1
    You need an usb cable to do the first connection. If you enabled the tcpip connection once, it will keep listening until you disable `USB debugging` or `Developer options` or restart the phone. So if you didn't made any of those, you will be able to connect over wifi without the cable. But if the device is not listening to tcpip anymore, you will need a cable to enable it again – Eduardo Herzer Jan 30 '18 at 11:13
  • 1
    anyway, debugging over wifi is terribly slooooooow (and when I say "slow", I mean really slow)....... – Massimo Jan 30 '18 at 11:20
  • Unless your phone supports wireless charging, you will need to buy a cable anyway to charge it... – Eduardo Herzer Jan 30 '18 at 11:22
  • 1
    @Massimo: It isn't slow for me, and I have a heavy app with lots of native code. I guess it depends on the performance of your Wi-Fi hardware. – Violet Giraffe Jan 30 '18 at 11:30
  • yeah i know it need a usb cable for first connection, but is possible to do it with out any usb cable? – user3121362 Jan 30 '18 at 11:43
  • @user3121362 I guess only with rooted phone, like Asha's answer – Eduardo Herzer Jan 30 '18 at 11:45

1 Answers1

2

if your phone is rooted, then download a terminal app from GP and run following commands:

su
setprop service.adb.tcp.port 5555
stop adbd
start adbd

and then use adb connect "ip_address" from your machine for wireless debugging.

If your phone is not rooted, then there is no other way except connecting usb cable and write on your computer's terminal:

adb tcpip 5555
adb connect "ip_address"
Asha H
  • 21
  • 2