- Open and Download Termux (Do not download from Play Store as it is not up-to-date)
- Enable Wireless Debugging on your Android phone
- Open Termux and run
pkg update && pkg install android-tools termux-api
(if failed, runapt update && apt install android-tools termux-api
instead) - Open Settings > System > Developer Options > Wireless Debugging. Open the app switcher then tap and hold the Settings app icon. Select "Split top", then select Termux as the bottom half.
- Tap on "Pair device with pairing code" and a window will appear. Go to Termux and run
adb pair localhost:12345
replacing 12345 with the port number shown in the window (192.168.x.x:12345). Enter the pairing code when prompted, the pairing window will close automatically. - Run
adb connect localhost:23456
replacing 23456 with the port number shown under "IP address & Port" (192.