Debug with Chrome Dev Tools in Android Mobile
Instructions
Setup your phone first
- Launch the Settings application on your phone.
- Tap the About Phone option generally near the bottom of the list (this is hidden behind the “System” option in Google’s latest Android Oreo version).
- Then tap the Build Number option 7 times to enable Developer Mode. You will see a toast message when it is done.
- Now go back to the main Settings screen and you should see a new Developer Options menu you can access.
- Go in there and enable the USB Debugging mode option.
Configure your pc then
- Open Windows explorer and browse to where you extracted the contents of this ZIP file (provided in the bottom)
- Then open up a Command Prompt from the same directory as this ADB binary. This can be done by holding Shift and Right-clicking within the folder then click the “open command prompt here” option. (Some Windows 10 users may see “PowerShell” instead of “command prompt”.)
- Connect your smartphone or tablet to your computer with a USB cable. Change the USB mode to “file transfer (MTP)” mode. Some OEMs may or may not require this, but it’s best to just leave it in this mode for general compatibility.
- In the Command Prompt window, enter the following command to launch the ADB daemon:
adb devices
-
On your phone’s screen, you should see a prompt to allow or deny USB Debugging access. Naturally, you will want to grant USB Debugging access when prompted (and tap the always allow check box if you never want to see that prompt again).
- Make sure both your adb host computer and Android device are on the same Wifi network.
- Connect the Android device with the computer using your USB cable. As soon as you do that, your host computer will detect your device and adb will start running in the USB mode on the computer. You can check the attached devices with adb devices whereas ensure that adb is running in the USB mode by executing adb usb.
$ adb usb $ adb devices
-
Restart adb in tcpip mode with this command:
adb tcpip 5556
-
Find out the IP address of the Android device. There are several ways to do that:
- Go to Settings -> About phone/tablet -> Status -> IP address.
- Go to the list of Wi-fi networks available. The one to which you’re connected, tap on that and get to know your IP.
- Try $ adb shell netcfg. -
Now that you know the IP address of your device, connect your adb host to it.
$ adb connect 192.168.1.67:5556 $ adb devices
----
View local web server from cell phone:
Go to Port Forward
a) on the left input set the default port (3333)
b) on the right input set the local domain, with the port, like patients.local:80
Then, on the cellphone, check computerIP:3333
---
You can download ADB Android Tools from here: https://xman.gr/downloads/ADB_Android_Tools.zip
https://www.xda-developers.com/install-adb-windows-macos-linux/
http://codetheory.in/android-debug-bridge-adb-wireless-debugging-over-wi-fi/
Leave a comment