user_odoo
user_odoo

Reputation: 2358

FMX debugging Can't bind address, Address already in use

First time debugging from PC to Mobile Phone work fine, when try again get error.

Any solution how fix this when try more debugging.

enter image description here

Upvotes: 2

Views: 3203

Answers (3)

Ömer Gözlek
Ömer Gözlek

Reputation: 66

With Delphi 10.3.3, it is enough to restart the device. After restarting the device problem goes away. It seems after the cancelation of code execution of the project debugged, the debugging service on Android continues to run. At this point, when new debugging started, IDE tries to run a new service with the same id of previous running service.

Upvotes: 2

Freddie Bell
Freddie Bell

Reputation: 2287

Add -debugport=54321 to Run->Parameters Parameters. By the way, the "inconsistent certificates" message is because the apk on the device was compiled with a different version of Delphi than the one you are using right now. You will have to uninstall it from the phone first. You can also use -cleaninstall in the Run->Parameters Parameters field.

Upvotes: 5

Dalija Prasnikar
Dalija Prasnikar

Reputation: 28516

There is no easy and fast solution.

You may need to:

  1. Restart IDE
  2. Kill adb.exe
  3. Restart Windows
  4. Restart device

Sometimes you will be able to debug again after doing only some of the above steps, however often you will need to do all of them.

Since every try takes plenty of time, I found out that complete Windows restart + device restart is the fastest thing to do.

Upvotes: 2

Related Questions