0

my system which I develop MAUI on is not enough for running android emulator, so I decided to run android emulator on another Computer and debug my project remotely on it, I use this help to make a connection between computers, then when I build my project to debug it, visual studio recognize the emulator, install the app on it, and shows the splash screen, but after some minute, it shows this error and debuger agent can not connect:

[monodroid-debug] Trying to initialize the debugger with options: --debugger-agent=transport=dt_socket,loglevel=0,address=10.0.2.2:36845,embedding=1

[mono] debugger-agent: Unable to connect to 10.0.2.2:36845

I should notice that the port is random

in this documentation of developer.android it shows that

10.0.2.2 is Special alias to your host loopback interface (127.0.0.1 on your development machine)

how should I fix it to can debug remotely in my development machine?

Sepehr Estaki
  • 331
  • 5
  • 19
  • Can the answer in [the question which has the similar error as yours](https://learn.microsoft.com/en-us/answers/questions/382625/xamarin-forms-debugger-agent-unable-to-connect.html) help you? – Liyun Zhang - MSFT Jan 05 '23 at 09:45
  • @LiyunZhang-MSFT: it says we should set the ip of the emulator host to 10.0.2.2, but in my case it's not the solution, my emulator host is in the network by default – Sepehr Estaki Jan 07 '23 at 05:07
  • You can report this to the visual studio community, because we can't make sure if the VS supports the android emulator remote debugging or not. – Liyun Zhang - MSFT Jan 09 '23 at 09:17

0 Answers0