adb via wifi - Xiaomi Redmi 8 Questions & Answers

Hello,
i'm a beginner.
i have a Xiomi Note 8.
is is possible to send command adb (for exemple) to my phone from a linux computer without wired connection but only a wifi connection?
thanks

alceste38 said:
Hello,
i'm a beginner.
i have a Xiomi Note 8.
is is possible to send command adb (for exemple) to my phone from a linux computer without wired connection but only a wifi connection?
thanks
Click to expand...
Click to collapse
No

I'm a little late to answer your question at the time you asked it, but if it still helps the OP, non-rooted Android 10 and below allowed wireless adb connections AFTER a USB connection was first
established (adb start-server && adb tcpip 5555 && adb connect [IP]:5555), but that changed (for the better) in non-rooted Android 11 and above with the new new Developer options Wireless debugging random port assignments (adb connect [IP]:[PORT] or adb pair [IP]:[PORT] [PIN]) such that the adb wireless connection never needs USB cable ever again.

Related

Need help trying to unlock bootloader on HTC One

So last night I tried unlocking my bootloader so I could root my HTC One, but I've had one issue. Whenever I get to the part where you make the back up of my apps I get the following message "adb: unable to connect for backup". My phone is conncected, and I have USB debugging enabled. I also checked the device status and it keeps reporting it as offline. I don't quite know what to do, if anyone can help it'll be appreciated.
First off, I barely know anything with regards to phones as I still learning. However, last night had a similar issue and ended up having to use cmd prompt to navigate to adb and then used it to see the device.
MrTechie890 said:
So last night I tried unlocking my bootloader so I could root my HTC One, but I've had one issue. Whenever I get to the part where you make the back up of my apps I get the following message "adb: unable to connect for backup". My phone is conncected, and I have USB debugging enabled. I also checked the device status and it keeps reporting it as offline. I don't quite know what to do, if anyone can help it'll be appreciated.
Click to expand...
Click to collapse
New security enhancements in android 4.2.2 builds (and above) require the end user to explicitly grant adb access to any connecting computers before that connecting machine can successfully issue any adb commands to your device. When you connect a 4.2.2 (and above) android device to your machine (with USB debugging enabled) for the first time, you should be prompted with a confirmation message to allow or disallow USB debugging. This message will display your computers unique RSA key fingerprint and provide you a checkbox to “Always allow from this computer”. Check this box and select ‘OK’. Your device should no longer be listed as ‘offline’
If you don’t see this prompt then you should try the following:
With your device connected via usb and the toolkit running, toggle USB debugging off/on in Settings > ‘Developer Options’ and see if the prompt comes up
Also try unplugging and re-plugging the usb connection.
BD619 said:
New security enhancements in android 4.2.2 builds (and above) require the end user to explicitly grant adb access to any connecting computers before that connecting machine can successfully issue any adb commands to your device. When you connect a 4.2.2 (and above) android device to your machine (with USB debugging enabled) for the first time, you should be prompted with a confirmation message to allow or disallow USB debugging. This message will display your computers unique RSA key fingerprint and provide you a checkbox to “Always allow from this computer”. Check this box and select ‘OK’. Your device should no longer be listed as ‘offline’
If you don’t see this prompt then you should try the following:
With your device connected via usb and the toolkit running, toggle USB debugging off/on in Settings > ‘Developer Options’ and see if the prompt comes up
Also try unplugging and re-plugging the usb connection.
Click to expand...
Click to collapse
I've already done this. I had usb debugging enable since I started this. I even tried unplugging and replugging multiple times while trying to do this. Are there any other settings I need to enable?
MrTechie890 said:
I've already done this. I had usb debugging enable since I started this. I even tried unplugging and replugging multiple times while trying to do this. Are there any other settings I need to enable?
Click to expand...
Click to collapse
You have to help us with a little more info -- ADB and Fastboot just *have* to work or you'll get nowhere:
1) What OS are you using? Version included;
2) Plug in your phone, open a command window in the appropriate place and type: adb devices
Tell us the output.
If you don't get a device listed, either your drivers are bogus on your machine and need to reload, or you're not getting USB debugging setup correctly (not sure how you miss that, so I'd think the former).
tdhite said:
You have to help us with a little more info -- ADB and Fastboot just *have* to work or you'll get nowhere:
1) What OS are you using? Version included;
2) Plug in your phone, open a command window in the appropriate place and type: adb devices
Tell us the output.
If you don't get a device listed, either your drivers are bogus on your machine and need to reload, or you're not getting USB debugging setup correctly (not sure how you miss that, so I'd think the former).
Click to expand...
Click to collapse
The version of android I'm using is 4.3, for my computer I'm using OSX 10.9, and the code that is listed when I search for my device through adb is FA3A8S902431.
MrTechie890 said:
The version of android I'm using is 4.3, for my computer I'm using OSX 10.9, and the code that is listed when I search for my device through adb is FA3A8S902431.
Click to expand...
Click to collapse
Then try this:
adb backup
That should create a backup file called: backup.ab
tdhite said:
Then try this:
adb backup
That should create a backup file called: backup.ab
Click to expand...
Click to collapse
Still get the same issue I've been getting. I typed that command in, it just tells me all the options for adb, and I then retried the other command I was using and squat.
MrTechie890 said:
Still get the same issue I've been getting. I typed that command in, it just tells me all the options for adb, and I then retried the other command I was using and squat.
Click to expand...
Click to collapse
I know you don't want to read this, but you'll need to read all about Macs and this issue. A quick Google on "adb unable to connect for backup mac" brings up all sorts of folks fighting exactly what you are. I don't have a Mac -- use Linux almost exclusively, but it all appears related to either usb debugging, or a connection timeout setting.
tdhite said:
I know you don't want to read this, but you'll need to read all about Macs and this issue. A quick Google on "adb unable to connect for backup mac" brings up all sorts of folks fighting exactly what you are. I don't have a Mac -- use Linux almost exclusively, but it all appears related to either usb debugging, or a connection timeout setting.
Click to expand...
Click to collapse
For me, doing it on Linux wouldn't be a huge issue but since I have a mac as my primary machine I'm trying to make due with it.
I think I just firgured it out actually. I just had to install the android sdk, I was using the abd files provided from a tutorial. anyhow, thanks for trying to help tdhite.

ADB Not Working

MY ADB has stopped Working
It happened after Installing the CWM And TWCR
Well What happened it was saying ADB was outdated while installing but it installed CWM and TWCR
Now if i enable ADB in the phone the windows doesnt read that there is a mobile nor anything detected not even charging
When i disable ADB I can see my phone charging and i can transfer files
I don't know what to do and I am very worried ...
Hope If any1 could help...
Tried installing ADB drivers and the Android SDK .. No luck
I think the problem is in the phone as it doesnt allow me to connect to the PC with ADB on
I read this http://forum.xda-developers.com/showthread.php?t=1917741
and found that ro.debuggable=0 in the Deafult.prob While it is enabled ...
And there is a question too how can i backup it so if i eddit it and get a bootloop I want to be able to restore using CWM or TWCR
John98Zakaria said:
MY ADB has stopped Working
It happened after Installing the CWM And TWCR
Well What happened it was saying ADB was outdated while installing but it installed CWM and TWCR
Now if i enable ADB in the phone the windows doesnt read that there is a mobile nor anything detected not even charging
When i disable ADB I can see my phone charging and i can transfer files
I don't know what to do and I am very worried ...
Hope If any1 could help...
Tried installing ADB drivers and the Android SDK .. No luck
I think the problem is in the phone as it doesnt allow me to connect to the PC with ADB on
I read this http://forum.xda-developers.com/showthread.php?t=1917741
and found that ro.debuggable=0 in the Deafult.prob While it is enabled ...
And there is a question too how can i backup it so if i eddit it and get a bootloop I want to be able to restore using CWM or TWCR
Click to expand...
Click to collapse
Can you use adb over other computers?
Also, try ADB over network. Goto Settings > Developer Options and turn "ADB over network" on. If prompted with a warning, press OK. Then you will see an ip address with a port number under ADB over Network setting. Now open cmd (or Terminal in Linux) and cd to the directory where the ADB files are present. Then type
Code:
adb connect <ipaddress>
Of course, replace <ipaddress> with the ip that you see in the Developer Options under ADB over network. It should be something like "192.168.1.2:5555", enter the whole thing. Then see if you are successfully connected by typing
Code:
adb devices
.
If you are using windows go to control panel and look for "hardware" or more specifically "drivers". It is somewhere there, just look around and you will find it. Then enable adb and connect phone. Then Select your device name from the list and right-click and select appt. drivers.
ayushag96 said:
Can you use adb over other computers?
Also, try ADB over network. Goto Settings > Developer Options and turn "ADB over network" on. If prompted with a warning, press OK. Then you will see an ip address with a port number under ADB over Network setting. Now open cmd (or Terminal in Linux) and cd to the directory where the ADB files are present. Then type
Code:
adb connect <ipaddress>
Of course, replace <ipaddress> with the ip that you see in the Developer Options under ADB over network. It should be something like "192.168.1.2:5555", enter the whole thing. Then see if you are successfully connected by typing
Code:
adb devices
.
If you are using windows go to control panel and look for "hardware" or more specifically "drivers". It is somewhere there, just look around and you will find it. Then enable adb and connect phone. Then Select your device name from the list and right-click and select appt. drivers.
Click to expand...
Click to collapse
Thanks for the reply I can't use ADB anywere ..
The phone doesn't even appear in the PC with ADB debuging enabled not even a connected sound or anything ..
I tried Wifi Kontect on the playstore as I didnt find "ADB over Network" But ADB wont connect....
Any Other solutions ... I dont mind if i have ADB over wifi the important thing is to have any ADB connection
www .mediafire .com/convkey/fb15/db3ykaaldgkqsd66g.jpg?size_id=5
www .mediafire .com/convkey/93e0/49f47ps6s9nbeyj6g.jpg
Remove spaces so you can see the images I cant post links yet
Fixed
I have fixed my probem thanks to @sijav !
Installing
http://forum.xda-developers.com/showthread.php?t=1687590
Fixed everything ! even after un-installing the app

How to force glass to update?

I revived a glass unit from the home try before you by program. The Version is XE13 and I want to update it to XE16 but it won't update and it says it's up to date. The micro USB port will charge but won't connect to my PC so any idea guys?
Sent from my iPhone using Tapatalk
Not really related, but could you dump the rom if it first?
(im not sure how easy this part would be without a working usb port, you would normally simply "adb pull /system" if it worked)
I doubt that there is an ota for it to begin with, they likely never made a patch for it since it isnt public.
(unless the glass team's policy differs from the standard android one) they generally do not make otas for combinations that they would not expect in the wild
Normally if this were a nexus device, the course of action would be to just use the factory image, but like you mentioned the usb port isnt able to be detected by a pc.
If you can root it without using the usb port, it might be possible to manually get CWM loaded on it and update with a manually made update zip. But without a usb port, if anything goes wrong then it would be very difficult to recover from that.
XxCyberHackerxX said:
I revived a glass unit from the home try before you by program. The Version is XE13 and I want to update it to XE16 but it won't update and it says it's up to date. The micro USB port will charge but won't connect to my PC so any idea guys?
Click to expand...
Click to collapse
Almost positive you can't just force an update. From what I read, the Glass unit should update whenever it's plugged in and on WiFi, but I couldn't get my try-on Glass to update no matter what.
One thing that "should" work is to just push the update OTA through adb, but doing this through USB would prove... difficult. Wireless ADB didn't seem possible either unless you hooked Glass up via USB at least once to enable it.
Can you provide me instructions about wireless abd? Thanks In advance!
Sent from my iPhone using Tapatalk
XxCyberHackerxX said:
Can you provide me instructions about wireless abd? Thanks In advance!
Sent from my iPhone using Tapatalk
Click to expand...
Click to collapse
https://coderwall.com/p/vq-eaw
How to get the IP address of Google Glass:
In ADB, run adb shell netcfg and get the IP adress of wlan0
Now, to access ADB, you need to open up port 5555: adb tcpip 5555
Now, to connect your ADP via TCP, execute this command: adb connect IP you got from step-1
And then, start accessing the ADB Shell by typing: adb shell
And boom, that’s it. You’re now accessing ADB via TCP. Unplug your usb and type adb devices to check.
To go back to usb mode type adb usb
Click to expand...
Click to collapse
And: http://www.the4cast.com/2013/04/how-to-fetch-the-ip-address-of-google-glass-for-adb/
Basically, you need to just get the IP of Glass (when connected to WiFi) and then do adb connect ADDRESS. Everything I see though says you had to of hooked the device to the computer at least once though to activate wireless ADB, but I could be wrong (I didn't venture too far into it at the time).
Since Debug mode is enabled by-default on those units, maybe you don't need the initial USB connection.
I hope not lol otherwise I'm screwed but is it safe to do a update over adb wifi?
Sent from my iPhone using Tapatalk
Is there anyone who could help step wise instruction on how to update glass to latest firmware?

Note 5 Wireless ADB

Anyone got a clue how to enable ADB over WIFI on Note 5? It is normally found in Developer Settings but I am not able to find it on Note 5. Did Samsung remove this feature?
aakaashjois said:
Anyone got a clue how to enable ADB over WIFI on Note 5? It is normally found in Developer Settings but I am not able to find it on Note 5. Did Samsung remove this feature?
Click to expand...
Click to collapse
Hi there,
If you are using a stock ROM there isn't an option to enable ADB via Wi-Fi from the device developer settings.
You can still run ADB over Wifi, but you need to connect the device to usb and then run the following adb commands:
Code:
adb tcpip 5555
disconnect the device from USB
Code:
adb connect <wifi-device-ip-address>
For more info on ADB:
developer.android.com/tools/help/adb.html#wireless
Thanks,
Matt
mhills said:
Hi there,
If you are using a stock ROM there isn't an option to enable ADB via Wi-Fi from the device developer settings.
You can still run ADB over Wifi, but you need to connect the device to usb and then run the following adb commands:
Code:
adb tcpip 5555
disconnect the device from USB
Code:
adb connect <wifi-device-ip-address>
For more info on ADB:
developer.android.com/tools/help/adb.html#wireless
Thanks,
Matt
Click to expand...
Click to collapse
Thank You. Never knew this was could be done without toggling the ADB over WIFI switch.
Hi there,
After i enter
adb connect 192.168.1.117
Click to expand...
Click to collapse
I got:
unable to connect to 192.168.1.117:5555
Click to expand...
Click to collapse
Dont know why?
Thanks,
Dangkita
To know if device is connected to ADB type adb devices
Have you made sure you was connected from USB? I believe you have to first set it up then u can use adb by wifi. You can check by typing
Code:
adb devices
---------- Post added at 07:37 PM ---------- Previous post was at 07:26 PM ----------
Anyone know if there is any other way to connect ADB to be used by wifi? My usb on my phone doesn't work only shows that it is charging. From all of the test I've done I believe it's a issue from the phone. Even after i reformat the phone and upgrade firmware still got the issue. I'm not rooted and if there is a way to root with out using usb that would be some great information. Thanks.
I did 0808 changed to correct one still not fixed. And can't even get the menu to change from charge to mass storage. The drivers on my computer is not the problem. I've tested other note 5 that I got and they work great. I tested this phone on other computers with nothing working.

A Magisk script to set ADB TCPIP port at startup without bricking my phone?

Hi guys. I've got a very old phone (LG K11 2017) running Android 7.1 Nougat. Currently I need to boot my phone, get to my home screen, fire up 'MTK Easy Su' in order to get temporary root access, then launch a terminal emulator and from there set up a port to ADB, stop it and then start it again. All of that is required so I can use SCRCPY over wi-fi.
It does not have the 'ADB over Wi-Fi' option under development options.
It's a chore to keep doing that, and it defeats the purpose of benefiting from the convenience of just leaving your phone away to charge while you're back at the desk and launching SCRCPY from your computer.
So I'd like to make a startup script that:
#1 Sets ADB port to 7612:
setprop service.adb.tcp.port 7612
#2 Stops ADB
stop adbd
#3 And finally, starts it up again:
start adbd
If that isn't done, the phone will just refuse connections from my computer:
~$ adb connect 192.168.1.101:7612
failed to connect to '192.168.1.101:7612': Connection refused
Question is, would that be possible to achieve with Magisk? If so, how?
Thanks in advance.
Came across this post googling the same question. It's may be quite late, but nevertheless you can achieve this by adding your commands into magisk's boot script:
Bash:
cat > /data/adb/service.d/adb.sh <<EOF
stop adbd
setprop service.adb.tcp.port 7612
start adbd
EOF
chmod +x /data/adb/service.d/adb.sh

Categories

Resources