How and why are you trying to connect to the remote machine? If we know this, we can say something. To find the computer over the internet independently, it must have the static(dedicated) IP address.
Actually, I have build a web application there customer can get the quotation about products and clients do not want to get online everytime so thats why he wants a sms system and a sms Alert message will be sent him on mobile if any customer has a query about products. So thats why GSM modem and fixed / private IP address will be provided for this system.
Through this private IP Address i want to access gsm modem which is attached Client machine's usb/serial port. There gsm modem will send the message to the client's mobile.
Hope you will understand my point of view and give the good idea / code hint how can i do this.