I want to use a TCP service running on my phone that needs its current IP to be known. So when the phone is connected to its internet as alone, I can know its IP.

However to speed up this task, I need to make a local network connection with my phone and know its local IP.

The USB/Wi-Fi tethering by phone with PC does all that along with sharing its internet connection, however in this scenario, I don't want its internet. I am already connected with LAN on my PC. and have no internet plan on my phone.