Hi i am using a MotoG2nd Generation updated to Android Lolliop,
Under Android adb Section from google's guide , it says
$ adb usb restarting in USB mode
$ adb devices
List of devices attached
######## device
$ adb tcpip 5555
restarting in TCP mode port: 5555
$ adb connect #.#.#.#
connected to #.#.#.#:5555
$ adb devices
List of devices attached
#.#.#.#:5555 device
I followed these steps and ADB over WiFi works perfectly ,
However the problem is once i restart android studio or turn off and turn on my wifi in my device the connection is lost and ADB connect DEVICE IP command no longer works , i need to use the USB cable and walk through the entire process again , i would like adb to always listen to my phone in my Home Wifi network ,
Any other cons in using ADB over WiFi rather than USB , i find WiFi better cause the USB cable is sometimes flaky and Cables seem old fashioned considering the fact that most file transfers or other operations can be accomplished over LAN (WiFi) instead these days ,
Please help!