I genymotion emulator and my phone connected , I want to run and debug my application over wifi , I found the instruction to do so but I get this error when I enter this code :
adb tcpip 5555
I get this error : error: more than one device/emulator
How can I make my device as default or something like that to solve this problem ?
If there\'s only one emulator running or only one device connected, the adb command is sent to that device by default. If multiple emulators are running and/or multiple devices are attached, you need to use the -d, -e, or -s option to specify the target device to which the command should be directed.
If multiple devices are connected you can select the device to connect to by specify it's serial number. This is documented on the scrcpy help page. Therefore you can start one scrcpy instance per device.
You can send commands to a specific device, according to docs:
$ adb devices
List of devices attached
emulator-5554 device
emulator-5555 device
$ adb -s emulator-5555 do_your_command
Also, if only one is emulator or a real device you can just attach -e
or -d
and send the command to it:
If you have multiple devices available, but only one is an emulator, use the -e option to send commands to the emulator. Likewise, if there are multiple devices but only one hardware device attached, use the -d option to send commands to the hardware device.
Do following thing which will help you,
You getting the message just because you are connected more than one device.
Run commands
adb devices
after the fire above command, you get the list of the device, From the list select your device id which not emulator and fire following command
adb -s f725aa8b7ce4(deviceId) tcpip 5555
and after this fire
adb connect yourIp 5555
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With