I am working on an Ionic app from a few years back, Ionic CLI 4.4.0, in VSCode (1.65.0). I finally got the environment working again. I can build it to the Android device (Samsung A21s). I could not get the usual Samsung USB driver to work with my device (could be the USB port) but found I can deploy via WiFi. I can attach to the device via WiFi, and get the debug output, but all breakpoints are "unbound" so I cannot step through the code.
Any pointers? Thank you.
Related
Problem pairing Android Studio to Device by Wi-Fi
I managed to pair an Android Device to Android Studio via Wi-Fi using a QR code. But then I got a "Default Activity Now Found" error when I tried to run my program to the device, I went through the steps to fix that error. And that led me to not only cleaning and rebuilding the project but when I restarted Visual Studio, I thought I would remove and re-add the listing in Device Manager.
And this is where the problem is. Since I removed the device listing in Device Manager, I have not been able to get it back. I have been trying both the QR code as well as the pairing code. The Android cell lists the computer. But each method I have tried to get Android Studio to recognize the cell, it fails. It says it may take up to 2 minutes to complete but it will say that there is an error pairing the device. It does not matter if I the computer name from the list of paired devices on the android or not.
The address and port number appear on the page for Wireless debugging on the Android device. When I try to use it in the Ubuntu OS where I am using Android Studio with:
(adb connect ip_address:port_number)
adb connect 192.168.0.13:37049
It states:
failed to connect to '192.168.0.13:37049' Connection refused
When I try to
adb tcpip 37049 it says:
error: no device/emulators found
I'm trying to connect my android device to android studio to run flutter but keep having this issue:
The result should be like this:
But instead, I can't open the device option on my android studio:
When I run flutter doctor there is no error and the device I plug in show up.
The machine I'm using is Asus TUF A15 which runs AMD Ryzen 5 4600H processor.
Can anyone please show me the way to enable this option?
Thank you in advance!
Enable developer options and USB debugging on your android device. More information can be found on the Android documentation here.
Plug your phone into your computer with a USB cable. Allow your computer to access your device if prompted.
In your terminal, run flutter devices to verify that Flutter recognizes your devices
Run flutter run to start your Flutter app or use the function available in Android Studio.
You should also try another USB cable, another Android device, or even another USB port on your computer. (Something simple, but can easily get overlooked)
I am using Cordova and want to debug the app on my Android device.
When I am plugging the device I have to accept MTP permission - I did so.
I also enabled developer USB mode in the device settings.
When I run the next command:
cordova run android
The app is getting installed in the device in 50% success rate.
I don't know why, but sometimes its just working and the app pops up and sometimes its just not working.
I have tried to reconnect the USB, after 10 times of doing so, it works and then again start to get corrupt.
It's a new brand original samsung cable that I am using.
I am using Android file transfer in my Mac in order to make this working (without this, it does not working at all).
I have two questions, one related to Cordova and one related to the Android device USB:
How to make the device reachable for the Mac so I can transfer data without interruptions?
Is there any option to tell Cordova to build WIRELESS? I know it's possible using Ionic with --livereload flag. However I don't use Ionic with this project.
I have tried to do cordova run android -- --live-reload (in the cordova project) but this doesn't really doing something - it does not response when there is change in the build or something.
You already enable development mode. You are facing 50% success rate. I didnt get your main issue.
I have suggestion and step which you can follow to make work as I always do.
Step 1) Enable development mode
Step 2) Authenticated the connect device.
- When you connect first you will get authentication confirmation in device.
Step 3) Check connected or not(most recommend command when you connect, just cross chekc and sometime this command properly your device by starting adb server which is required to run application in android)
adb devices
(Open terminal and typpe this command)
Note : Make sure connected device show in terminal and authenticated.
I want to be able to create Android-Apps on my very old laptop. Since it can't run Android Studio I figured I could run it on my home computer and use RDS to access the PC with the laptop.
Now the problem was how to connect my Phone to my laptop and have it recognized by Android Studio on the PC. Since my laptop is in the same network as my PC (VPN) I managed to replicate this solution. I can run adb devices (since I've set the environment variable ANDROID_ADB_SERVER_ADDRESS I don't need the -H-flag) in the terminal and get my phone in the resulting list. However, when I try running the app in Android Studio no device is found.
So I am thinking that Android Studio uses an integrated ADB that ignores environment variables or some commands that don't support remote usage. Does anyone have an idea what I can do to have my Phone recognized by Android Studio and not just by adb on the PC? I don't want to manually load and start my apps every time I debug.
My app works perfectly fine on the Android Emulator, but as soon as I try to run the command meteor run android-device it throws the following error ERROR: Failed to deploy to device, no devices found.
I have tried to run several apps including Meteor's official Local Market App, no luck yet.
USB Debugging is enabled on the both devices and they were connected to my mac via USB port. Before Meteor 1.2 update, everything was working fine with the same devices.
Can anyone advice me on this please? I've looked up online, couldn't find any recent solutions.
UPDATE it was rather ridiculously silly problem, that was fixed as soon as I used the original charging cable instead of fancy portable cables...
it was rather ridiculously silly problem, that was fixed as soon as I used the original charging cable instead of fancy portable cables...