-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adb devices is not working straight after pairing #1
Comments
Hi, great job. And then how to connect to device without using ip:port? Connect via _adb-tls-connect hostname |
@SuperSandro2000 does this adb pair not doing that? |
Can you share more context ? |
no, you need to run |
Can I express my thoughts? The function called connect (which calls exec adb pair) should be renamed to pair. And a new function called connect should be added (which calls exec adb connect). And then in function startDiscover:
|
But you have to use the connection port to connect, not the pairing port. |
Maybe we can do this: const portscanner = require('portscanner')
const {exec} = require("child_process");
portscanner.findAPortInUse(36000, 49999, '192.7.1.1', (error, port) => {
console.log('AVAILABLE PORT AT: ' + port)
exec(`adb connect 192.7.1.1:${port}`, (error, stdout, stderr) => {
if(!error) {
console.log("connected")
} else {
console.log("oopsie")
}
});
}) But it can be slow. Or entering first 2 digits of the port? |
why not use the port from the android device? function main() {
console.log(
"[Developer options]->[Wireless debugging]->[Pair device with QR code]"
);
if (process.argv.length < 3) {
console.log("Usage: adb-wifi <port>");
return;
}
showQR();
startDiscover();
} |
did you solved it same for me... spinner is not stopping |
You can try checking if the same issue occurs with this project to fix it: |
After pairing the adb devices daemon is started but the device is not appearing there. I still need to run
adb connect 10.20.30.40:37890
. Could this be automated?PS Thanks for this! wireless adb stops the pairing process so fast that it was a real hazzle to type in the port and code fast enough.
The text was updated successfully, but these errors were encountered: