Reputation: 5917
I'm trying to deploy a Capacitor 3 app to a virtual Android device using the command line. I have both a Pixel 3a running as an emulator and also a physical device connected. In Android studio, both appear and I can deploy to both. Also adb devices
shows both phones.
However, npx cap run android --list
only shows the physical device.
Is there some setting I need to enable to show the emulated device as well?
Thank you :-)
Upvotes: 3
Views: 3894
Reputation: 2125
For me it was a complete abstract reason. Took me hours to find out:
I have Native Instruments Audio Plugins installed on my computer. Native Instruments installs a Updater Daemon which is running on port 5562. This is detected from adb as emulator. And capacitor run android --list
does not work anymore if this emulator is detected by adb.
More infos here: https://community.native-instruments.com/discussion/26509/ntkdaemon-uses-adb-ports
I had to stop the Native instruments service, then everything works
Upvotes: 0
Reputation: 1151
I had a similar issue that I could fix by setting the SDK Platform Version from 31 to 30 in Android Studio SDK Manager. The reason why no virtual devices showed up, was that at the time Capacitor only supported version 30 and not 31.
Upvotes: 5