Android Enthusiasts
Q&A for enthusiasts and power users of the Android operating system
Latest Questions
3
votes
1
answers
5220
views
how can I usb tether between two android phones
I want to access the internet connection of my first android phone with my second android phone, via usb. I am sensitive to wifi/network radiation emissions, so I want to connect the first phone via wifi or 3G network to the internet, and have internet access through a long usb cable, from my second...
I want to access the internet connection of my first android phone with my second android phone, via usb.
I am sensitive to wifi/network radiation emissions, so I want to connect the first phone via wifi or 3G network to the internet, and have internet access through a long usb cable, from my second phone, set on airplane mode.
I have a Galaxy S2 HD LTE SHV-120S Android version 4.0, rooted and stable
The second phone I have yet to purchase.
Are there apps to enable this? Drivers?
Babak Kardan
(161 rep)
Mar 25, 2015, 04:11 AM
• Last activity: Jul 29, 2025, 09:22 PM
0
votes
0
answers
57
views
Tethering USB reaching LAN
I have a rooted Pixel with Android 12. It is connected to a router to share the connection via tethering USB. Phone -- ISP IP = random -- tethering interface (rndis0) = IP random Router -- IP client random -- LAN IP 192.168.178.1 I would like my phone to reach my LAN. At the moment, pinging 192.168....
I have a rooted Pixel with Android 12. It is connected to a router to share the connection via tethering USB.
Phone -- ISP IP = random
-- tethering interface (rndis0) = IP random
Router -- IP client random
-- LAN IP 192.168.178.1
I would like my phone to reach my LAN.
At the moment, pinging 192.168.178.1 from the phone doesn't work.
Is it possible to do it without fixing the random IPs above?
zizzani
Nov 30, 2024, 10:58 AM
• Last activity: Jul 26, 2025, 04:35 AM
23
votes
13
answers
378132
views
USB internet option for tethering greyed out. How to fix it?
Under `Settings` → `Wireless and networks`, USB internet **will not** highlight nor will it let me activate it. Therefore, I can't connect my smartphone to the PC. Is there an alternate way to check **why** this is occurring and fix it?
Under
Settings
→ Wireless and networks
, USB internet **will not** highlight nor will it let me activate it. Therefore, I can't connect my smartphone to the PC.
Is there an alternate way to check **why** this is occurring and fix it?
LDS
(231 rep)
Oct 4, 2015, 11:58 PM
• Last activity: Jul 9, 2025, 10:17 PM
3
votes
1
answers
11997
views
How to run a script in background from adb shell?
I have a problem with USB tethering on my rooted Nougat phone (LineageOS). After some time phone stops USB tethering. To fix that I run the following script like this: adb shell su nohup sh tether.sh & exit exit tether.sh #!/system/bin/sh service list while true; do if ! pidof -s dnsmasq > /dev/null...
I have a problem with USB tethering on my rooted Nougat phone (LineageOS). After some time phone stops USB tethering. To fix that I run the following script like this:
adb shell
su
nohup sh tether.sh &
exit
exit
tether.sh
#!/system/bin/sh
service list
while true;
do
if ! pidof -s dnsmasq > /dev/null
then
echo -n "Connectivity lost at "
date -u +%FT%TZ
echo "Waiting 3 seconds..."
sleep 3
echo "Calling ConnectivityManager.setUsbTethering(false)"
service call connectivity 33 i32 0 2>&1
sleep 3
echo "Calling ConnectivityManager.setUsbTethering(true)"
service call connectivity 33 i32 1 2>&1
echo "Waiting 3 seconds..."
fi
sleep 3
done
Problem: If I use
nohup
my call to service call connectivity
fails with service not found. And I put service list
on top of the script which returns Found 0 services:
. However the same commands work when ran directly from adb shell; su
.
Why service call
doesn't work inside this background script? Does it need the same tty
to work?
Nazar554
(188 rep)
Aug 27, 2019, 08:33 PM
• Last activity: Jun 17, 2025, 06:35 PM
1
votes
2
answers
5462
views
Default mode with USB, charging + USB Tethering?
Is there anyway to make it so that my phone, when connected with a USB Data Cable to a computer automatically turns on USB Tethering? Currently using Cyanogenmod 13. I tried changing the option in Developer Options to `RNDIS` however it doesn't seem to work (by that I mean it doesn't seem to do what...
Is there anyway to make it so that my phone, when connected with a USB Data Cable to a computer automatically turns on USB Tethering?
Currently using Cyanogenmod 13.
I tried changing the option in Developer Options to
RNDIS
however it doesn't seem to work (by that I mean it doesn't seem to do what USB Tethering does), and it doesn't hold when I unplug and plug back in.

Evan Carroll
(4661 rep)
Nov 15, 2016, 07:43 PM
• Last activity: May 16, 2025, 10:18 AM
5
votes
1
answers
8549
views
USB tethering is constantly disconnected automatically
I'm using a Samsung Galaxy A7 2016 on Android 7.0. I use USB tethering to access the internet on my PC, but after enabling USB tethering and using it for about 5 minutes, it disconnects, and I should enable it again on my Android phone. The USB cable is not broken (It doesn't have any problem with c...
I'm using a Samsung Galaxy A7 2016 on Android 7.0. I use USB tethering to access the internet on my PC, but after enabling USB tethering and using it for about 5 minutes, it disconnects, and I should enable it again on my Android phone.
The USB cable is not broken (It doesn't have any problem with charging). I bought it about one month ago.
What should I do to stop disconnecting automatically?
Fox
(51 rep)
Oct 21, 2021, 04:36 PM
• Last activity: Apr 2, 2025, 12:04 PM
0
votes
2
answers
3466
views
Using USB Tethering with USB-to-Ethernet adapter
I live in an area without any high-speed internet access. Currently, I am using a cell phone hotspot connected through a wireless-to-wired bridge to my home wired/wireless networks. I would like to increase my bandwidth using multiple cell services/hotspots and have not found the complete answer. I...
I live in an area without any high-speed internet access. Currently, I am using a cell phone hotspot connected through a wireless-to-wired bridge to my home wired/wireless networks. I would like to increase my bandwidth using multiple cell services/hotspots and have not found the complete answer.
I have a TP-Link ER605 and am able to hook a cellphone directly to the USB WAN port on that device and it works to provide Internet service. I am attempting to connect a second cellphone to an RJ45 WAN port on the ER605 using a USB-to-Ethernet adapter, but have not found any combination that allows the 'USB Tethering' option to be enabled.
I have the following phones:
- TCL 30 XL (Android 12)
- Moto X4 (Android 9)
Both of these devices work to provide Internet service when directly connected to the ER605 with a standard USB cable.
I have tried two USB to Ethernet Adapters:
- uni USB C to Ethernet adapter (Amazon link )
- Smays USB C OTG Ethernet adapter (Amazon link )
Neither of these adapters enables the USB Tethering option, either plugged into an ER605 port or to a port on a Windows machine.
What are the cellphone/adapter requirements needed to support this configuration?
Bill
(1 rep)
Mar 10, 2024, 04:10 PM
• Last activity: Jan 11, 2025, 12:34 PM
1
votes
0
answers
204
views
Accessing client device connected to Android phone via Ethernet Tethering
I have an Android phone which I can share its internet connection via Ethernet tethering through an adapter (Ethernet to USB-C adapter). The device (camera) which is connected to the phone is able to utilise the internet connection successfully. I want to access the device from my Android phone usin...
I have an Android phone which I can share its internet connection via Ethernet tethering through an adapter (Ethernet to USB-C adapter). The device (camera) which is connected to the phone is able to utilise the internet connection successfully.
I want to access the device from my Android phone using its local IP address in the web browser of my Android phone since that device (camera) has a webapp running on it which allows accessing its features and configurations. However when I type in the local IP address (or the local host name) of the device in the browser it times out (the IP address is correct and I have double checked this multiple ways).
1. is this possible on Android?
2. how can I achieve this?
3. is this a DNS problem? (my Android "Private DNS Mode" is set to "Automatic" which is the default option.
I can achieve this using a laptop running windows without any issues but being able to use a mobile phone is a lot more convenient, as it means I won't have to carry a laptop with me.
anonymous
(111 rep)
Jul 8, 2024, 06:26 PM
0
votes
0
answers
817
views
All tethering options greyed out, why?
On my Samsung Galaxy A-24, when I open in Settings Mobile Hotspot and Tethering section, all options are grayed out, such as `Mobile Hotspot` , `Bluetooth tethering`, `USB tethering`, etc. The phone has a working mobile data conection (at this moment turned on) and is connected to the laptop via a U...
On my Samsung Galaxy A-24, when I open in Settings Mobile Hotspot and Tethering section, all options are grayed out, such as
Mobile Hotspot
, Bluetooth tethering
, USB tethering
, etc. The phone has a working mobile data conection (at this moment turned on) and is connected to the laptop via a USB-C cable (with scrcpy working over USB.).What can I do to share my data connection to the laptop? Maybe it depends on the mobile data provider?
Alexander Gelbukh
(186 rep)
May 2, 2024, 06:38 PM
1
votes
0
answers
1243
views
USB tethering & charging
I am experiencing weird problem related to charging my Android phone. Most of the time I have phone connected to laptop and use it as 4G/5G modem. I noticed that compared with older phones it draws more power from wall. Unfortunately USB ports on laptop provide only small power. I haven't measured i...
I am experiencing weird problem related to charging my Android phone. Most of the time I have phone connected to laptop and use it as 4G/5G modem. I noticed that compared with older phones it draws more power from wall. Unfortunately USB ports on laptop provide only small power. I haven't measured it but guess it is 500 mA. It is sufficient to power the phone and also charge it. But the charging is very slow in the range 1-3 % / hour. Therefore I bought USB hub with charging functionality and inserted it between android phone and laptop. This USB hub have external 2A power input. Now the charging speed is acceptable (10-15% / hour). It is not super fast but its OK. But there are two problems:
1. If i physically disconnect USB hub from laptop and connect phone to one of USB ports, it starts charging. After about second or two charging stops. Disconnecting and connecting cable again doesn't help. But I noticed that if I reconnect USB cable that is powering hub, charging successfully starts. What is the reason for this behavior ? This is not cricitical problem for me. I can connect the phone directly to USB wall charger and there is no problem with this. But I would like to understand this.
2. Second more sinister problem is that sometimes while tethering internet connection in above configuration the phone charging stops. For a few months I thought that this is random problem which happened several times per month. After few months experience I think it is somehow related to USB headset I am using for internet calls. This problem with charging happened twice when I had long internet call. After few hours I noticed that phone battery charge level dropped 15-20 %. It is not a big deal when the battery is new. It could be problem when the battery will become older. The phone will then shutdown which is not acceptable because I use it to connect to my employer while I am working from home. It is probable that phone battery aging is accelerated in this configuration because the battery is most of the time fully charged. This problem with occasionaly not charging happens whether there is USB hub between phone and laptop or not (so the phone is connected to laptop directly). To me it seems as serious bug. Battery powered devices like this phone are on market more than 10 years so I its weird that manufacturers were not able to tune out such basic functionality. All the software functions, nice graphics and frequent updates are of no use if you cannot power the device. What is the reason for this behavior and is there some workaround for it ?
My hardware configuration:
Samsung Galaxy A33 5G SM-A336BZKGEEE
Laptop HP ENVY 15-as103nc
AXAGON HUE-S2BP 4-Port USB 3.0 CHARGING Hub (with 2A power source)
USB repeater AXAGON ADR-205, 5 m
Headset Behringer BH470U
My software configuration:
One UI 6.0
Android 14
Core version 5.10.177-android12-9-27775596-abA336BXXS8DXA1
Windows 10 Pro 22H2
The phone has charging limited to 85% by using android function. I had enabled developer options and set automatic tethering (it is not fully automatic - I have to unlock screen to enable usb tethering). Don't know if this is related to above problems or not.
**P.S. 21.4.2024** Adding some photos of USB hub. It is named "charging hub" but it cannot charge phone sometimes even without computer.
Today I experienced with second USB hub from Vention which supports Power Delivery. The result is that I am not able to use tethering at all. Charging of phone when this USB hub is disconnected from computer is functioning in very limited set of cases. I must connect charger output to input marked with a lightning bolt symbol and phone must be connected to fixed USB-C output. For example when I connect phone to one of USB-A outputs I am not able to charge it. So it seems it is no problem of hub but phone. Or I have bad luck and bought two hubs from two different manufacturers which are broken. This is how this second hub looks like:




truthseeker
(11 rep)
Feb 10, 2024, 07:58 AM
• Last activity: Apr 21, 2024, 05:34 PM
0
votes
0
answers
594
views
VPN not working on laptop connected through Android phone USB tethering
I used to connect my laptop to the internet via USB tethering from my android phone (running android 6), and then connect to my organization's VPN. I got myself a new phone, and realized that it blocks VPN connections. Apparently this issue has been discussed [before][1] but that was ~7 years ago, a...
I used to connect my laptop to the internet via USB tethering from my android phone (running android 6), and then connect to my organization's VPN.
I got myself a new phone, and realized that it blocks VPN connections. Apparently this issue has been discussed before but that was ~7 years ago, and the solutions offered do not work for me. In particular, the "APN protocol" is already set to IPV4.
What is the most recommendable way of getting VPN to work in a laptop connected to the internet with a modern android (in my case it's android 13) through USB tethering or wifi hotspot?
fbaroni
(1 rep)
Apr 5, 2024, 03:03 PM
0
votes
2
answers
1797
views
Hotspot or USB tethering not functioning on Xiaomi Redmi Note 9 Pro on Android 11
My Xiaomi Redmi Note 9 Pro on Android 11 was updated to the latest MIUI. When I activate the hotspot or USB tethering, when connecting from my PC or other phones, it does not let me surf or use the internet. In my Windows 10, I enter the IP config command and everything comes out well configured, ei...
My Xiaomi Redmi Note 9 Pro on Android 11 was updated to the latest MIUI. When I activate the hotspot or USB tethering, when connecting from my PC or other phones, it does not let me surf or use the internet.
In my Windows 10, I enter the IP config command and everything comes out well configured, either by tethering or by hotspot, but I do not navigate in any way.
Help, please.
Ricardo Sanchez
(1 rep)
Dec 29, 2021, 12:39 AM
• Last activity: Feb 16, 2024, 05:51 PM
3
votes
0
answers
399
views
How to share Ethernet through USB tether as WiFi hotspot?
I have a situation where I have internet via Ethernet on a Windows PC and I want to share it via WiFi but said PC has no WiFi card. So the idea is to use USB tethering (RNDIS) and then use a WiFi hotspot to share the RNDIS. Android phone is rooted and has Termux, so tools like `iptables` should be a...
I have a situation where I have internet via Ethernet on a Windows PC and I want to share it via WiFi but said PC has no WiFi card.
So the idea is to use USB tethering (RNDIS) and then use a WiFi hotspot to share the RNDIS. Android phone is rooted and has Termux, so tools like
iptables
should be accessible.
The PC with the internet could run Linux too and run iptables
, but I prefer Windows if possible.
Dennis M
Jan 6, 2024, 07:30 PM
• Last activity: Jan 12, 2024, 04:34 PM
2
votes
0
answers
366
views
How can I permanently change my USB tethering IP address?
Question is: How can I permanently change my USB tethering IP address? Using Android 11 with a known problem of changing IPs. Only answer I found is https://android.stackexchange.com/questions/213514/how-can-i-permanently-change-my-hotspot-tethering-ip-address by @irfan-latif . It would be best to c...
Question is: How can I permanently change my USB tethering IP address?
Using Android 11 with a known problem of changing IPs.
Only answer I found is https://android.stackexchange.com/questions/213514/how-can-i-permanently-change-my-hotspot-tethering-ip-address by @irfan-latif .
It would be best to comment there, but I do not have 50 points...
Problem is that I could not make fixed Android IP when tethering USB. I have rooted Andorid with Magisk, which I understood is a requirement.
With Method 2, I added to /etc/init/usbd.rc (there it is said any .rc file) this, changing to rndis0:
on property:init.svc.hostapd=running
exec - -- /system/bin/sleep 2
exec u:r:magisk:s0 -- /system/bin/ip address add 192.168.43.100/24 dev rndis0
But I do not see it working, also 'ip address' on Android does not show that range.
Note: there is a related question at https://android.stackexchange.com/questions/225643/how-to-make-ethernet-work-on-android-over-otg/225741#225741 .
Anyone may also help with mentioning this question there, hopefully mr. Latif would notice.
TimSO
(21 rep)
Dec 15, 2023, 01:21 PM
• Last activity: Dec 15, 2023, 01:24 PM
2
votes
0
answers
209
views
How to make device on Wi-Fi hotspot discoverable to USB tethering connected PC?
My goal is to make the device (Quest 2) on `192.168.254.x` (Wi-Fi hotspot) discoverable to my PC on `192.168.96.x` (USB Tethering), because I want to set up ALVR and make my Quest 2 and my PC on different subnets talk to each other. Right now, I'm testing with **laptop - rooted phone with Termux - P...
My goal is to make the device (Quest 2) on
192.168.254.x
(Wi-Fi hotspot) discoverable to my PC on 192.168.96.x
(USB Tethering), because I want to set up ALVR and make my Quest 2 and my PC on different subnets talk to each other.
Right now, I'm testing with **laptop - rooted phone with Termux - PC** configuration. I tried ip route add 192.168.254.13 via 192.168.96.20
command,
where 192.168.254.13
is my Laptop with Ubuntu and 192.168.96.20
is my PC with Windows 11. My PC does not respond to pings from my laptop, but the laptop does ping the gateway which is 192.168.96.19
, and is getting responses.
I'm probably doing something wrong, but can't figure out what exactly. I don't have much network knowledge and I have a basic Linux understanding, so any answer/tutorial will be appreciated.
I don't need any internet access when on Quest, but I would still want internet on my PC.
speedyes
(21 rep)
Nov 18, 2023, 02:04 PM
• Last activity: Nov 19, 2023, 04:50 AM
1
votes
1
answers
326
views
USB tether to router and then connect to the WiFi of the router no longer possible on recent Android versions?
I have somewhat of an unusual problem that wasn't a problem a few months ago, I had an Xperia X with Android 8 on it, and I used it to provide Internet (4G) for my devices using a router. It worked like so: 1. Connect to the router's USB 2. Configure router 3. Enable USB Tethering from the phone 4....
I have somewhat of an unusual problem that wasn't a problem a few months ago, I had an Xperia X with Android 8 on it, and I used it to provide Internet (4G) for my devices using a router. It worked like so:
1. Connect to the router's USB
2. Configure router
3. Enable USB Tethering from the phone
4. Internet
This is the usual method, of course. The thing is, I have a NAS attached to the router as well, and I used to enable the WiFi on my phone (with USB Tethering on), and sync/connect with the NAS without losing Internet connection.
I upgraded to a Pixel and then a Samsung running Android 11, 12, and now 13, and there seems to be a change in what WiFi is. It's now related to the "Internet" instead of being a networking means that can be used to get files from a local server offline. Now because of this change, whenever I connect to the WiFi network of the router, I lose Internet (on Samsung) or simply the WiFi wouldn't even connect unless I disable the data (Pixel).
Is there a solution to restore the old behavior or at least workaround it?
Reda Lazri
(111 rep)
Feb 26, 2023, 05:57 PM
• Last activity: Aug 5, 2023, 06:11 AM
7
votes
1
answers
5773
views
USB Tethering option (to share internet connection with PC) is greyed out
> Most probably these question+answer will be deleted as duplicates, so please **do not vote here**. But if the answer is useful - add your upvote here: https://android.stackexchange.com/a/252613/251126 in order to bubble a good (my hehe) answer there For years I used my phone as a backup connection...
> Most probably these question+answer will be deleted as duplicates, so please **do not vote here**. But if the answer is useful - add your upvote here: https://android.stackexchange.com/a/252613/251126 in order to bubble a good (my hehe) answer there
For years I used my phone as a backup connection to the internet (and you know - airports...)
Today I connected my phone to the laptop with my factory-default cable and tried to enable tethering - but the USB Tethering button in the menu was disabled.
How to make it enabled?
----
I checked the cable (several), and I use one that does the trick with another phone.
Recently I updated Android to v12
mksm
(261 rep)
Aug 2, 2023, 08:07 PM
• Last activity: Aug 4, 2023, 06:41 AM
0
votes
0
answers
1009
views
Is there a way to have a static IP address on PC if I'm using USB tethering?
I need a static IP address on my PC. It uses a USB tethered phone (Xiaomi Redmi Note 10) for internet connection, so I'm not sure how to go about that. I tried to assign one through network settings on PC but that failed. Could I root my phone and install some third-party app to change my network se...
I need a static IP address on my PC. It uses a USB tethered phone (Xiaomi Redmi Note 10) for internet connection, so I'm not sure how to go about that. I tried to assign one through network settings on PC but that failed.
Could I root my phone and install some third-party app to change my network settings? If so, what apps do I need to get? Are there any methods other than the one I've mentioned that could work as well?
My knowledge on messing with Android devices is extremely poor, and I'm not that much more knowledgeable on computer networks, so I apologize in advance for any clueless-ness.
PolarBee
(1 rep)
Jun 6, 2023, 01:28 AM
5
votes
1
answers
13817
views
Why can't I access Google and other sites when tethering my phone?
When I tether my phone, I can't access Google or Gmail (other sites, too). cmd: ping http://www.google.com; Ping request could not find host... --- ## **List of problem sites/applications:** ## Sites: - https://www.google.com; http://www.google.co.jp; - https://encrypted.google.com - https://www.gma...
When I tether my phone, I can't access Google or Gmail (other sites, too).
cmd: ping http://www.google.com ; Ping request could not find host...
---
## **List of problem sites/applications:** ##
Sites:
- https://www.google.com ; http://www.google.co.jp ;
- https://encrypted.google.com
- https://www.gmail.com
- https://search.yahoo.com , same issue.
- Also, https://play.google.com .
- Further, https://github.com .
- Dang! https://www.freelancer.com .
- https://www.sugarsync.com .
- https://www.dropbox.com .
- Parts of http://www.titanpad.com (i.e., login); makes me curious as to whether or not it's a language-blocking issue.
Apps:
- ET Naver Line (a.k.a. LINE) (jp.naver.android.npush)
I experience this on various sites and apps; however the above are sites tested as working over emobile (separate modem)--the URLs should be correct. I would change the question title, but I have a support request in with the developers to contact me via this site for a resolution.
---
## **Device info:** ##
Phones:
- Softbank Fujitsu Arrows 301F; 4.1-Jelly Bean.
- Softbank Aquos 104SH; 4.0-Icecream Sandwich.
- Connected via USB, debugging mode enabled, in MTP mode.
- Phone's DNS: Google DNS; OpenDNS.
PC's:
- PC OS: Windows 7 SP 1 (please request any hardware specs).
- Connection methods tested: chrome latest, IE10 latest, cmd (ping), telnet.
- PC's DNS: OpenDNS; Google DNS; no DNS.
Non-specific:
- Tethering software: EasyTether lite (no root).
---
## **Known error messages:** ##
*Via Chrome:*
> This webpage is not available
>
> Reload Less Google Chrome could not load the webpage because www.google.co.jp took too long to respond. The website may be down, or you may be experiencing issues with your Internet connection. Check your Internet connection. Check any cables and reboot any routers, modems, or other network devices you may be using. Allow Chrome to access the network in your firewall or antivirus settings. If it is already listed as a program allowed to access the network, try removing it from the list and adding it again. If you use a proxy server... Check your proxy settings or contact your network administrator to make sure the proxy server is working. If you don't believe you should be using a proxy server: Go to the Chrome menu > Settings > Show advanced settings... > Change proxy settings... > LAN Settings and deselect "Use a proxy server for your LAN". Error code: ERR_CONNECTION_TIMED_OUT
*Via IE 10:*
*Via CMD:*
> Ping request could not find host https://www.google.com . Please check the name and try again.
*Via Telnet:*
> Connecting To https://www.google.com...Could not open connection to the host, on port 23: Connect failed
*Via LINE:*
> Unable to login due to network issues. Please check your connection and try again.
---
## **Question summary:** ##
Why am I experiencing these issues (not being able to connect to the above-mentioned websites), and how can these issues be resolved? Can you help me test what I think is causing the issues?
---
## **Proposed causes:** ##
1. **Perhaps the reason I cannot access these sites is because they are in use by the phone?** If that is the case, I am not sure how to test it. So far, when I "force-stop" and "disable" an app like LINE, I still cannot connect. So, I thought: *it's possible that the phone is reserving the app's networking info, somehow.* **So, I went so far as to uninstall Line from my phone and reset the phone and PC. Still unable to use Line on the PC. Furthermore; Skype works simultaneously on PC and Phone.**
2. **Perhaps it's a PC or OS issue?** I still have yet to tether my phones to a different PC or OS.
3. **Perhaps it's a DNS issue?** I still have yet to test this, but I believe I get a similar error with OpenDNS when trying to access localhost.
4. **"Activate EasyTether or use it with UDP and secure sites BLOCKED**? This message appears at the top of Easy Tether's settings screen. I'm very curious to know whether or not this is the cause. It seems highly likely.
Wolfpack'08
(669 rep)
Jan 14, 2014, 12:19 AM
• Last activity: Apr 1, 2023, 03:20 PM
1
votes
0
answers
2204
views
Ethernet over USB + ADB | Dynamically switch between Host and Peripheral mode in OTG
**Problem:** I own an android device in a remote location that I use to run various tests and operations. I need to be able to send ADB commands while also connect the phone to a **wired** internet connection. For various reasons, I cannot connect the device to WiFi, nor can I root the device. Due t...
**Problem:**
I own an android device in a remote location that I use to run various tests and operations. I need to be able to send ADB commands while also connect the phone to a **wired** internet connection. For various reasons, I cannot connect the device to WiFi, nor can I root the device. Due to USB Enumeration structure, if I connect a USB hub to the phone with an Ethernet port and a USB connection to a PC, the options are either Phone in Host + Internet but no ADB, or phone in Peripheral mode with ADB but no ethernet connection.
**What I have tried:**
- Setting
adb tcpip 5555
to enable ADB over a network connection (TCP mode). This means connecting the phone through USB, setting adb tcpip 5555
to enable ADB over network, and then disconnecting the USB and replacing the connection with the Ethernet dongle in host mode. This works fine **until the phone is rebooted** and then manual intervention is needed.
- Various USB dongle/hub set ups.
- LADB workaround where the phone connects to itself through wireless ADB, then sets the adbd to TCP mode, etc. For this, I need a WiFi network so it does not meet the requirements. It's also very flaky.
**What I want to do:**
I'm wondering if I can purchase a Raspberry Pi or some other microcontroller, and implement a solution using *Session Request Protocol (SRP)* and/or *Host negotiation Protocol (HNP) described in On-The-Go (OTG)* as follows:
- Connect Android device using USB-C (as OTG cable) to companion device.
- Connect companion device to internet through ethernet port
- Setup states
1. Software in Android/external code detects when adbd is in USB mode, and renegotiates the connection to Android being in device mode. Companion uses USB connection to send adb tcpip 5555
.
2. Once adbd is set to TCP mode, software (using getprop
) checks that phone accepts ADB over network, and renegotiates the usb connection such that the Android is now Host, and accepts the companion device as an Ethernet dongle, and internet flows to the device.
This way, the network connection to the device (including sending ADB commands) remains stable even after device reset. There are also power considerations, but they are secondary.
K-man
(111 rep)
Mar 5, 2023, 07:36 PM
Showing page 1 of 20 total questions