Interesting Question... Anyone!?!?!

  • Thread starter Thread starter David Pope
  • Start date Start date
D

David Pope

I have a Samsung Pocket PC mobile phone. It has built-in WiFi.

I've developed an application that runs on the phone.

How can I specify which connection my mobile application should use when
connecting to the internet? Let's say the mobile phone is connected via a
data connection AND WiFi?

Let's say I want to use WiFi if it's connected?

Thanks,

david
 
It will choose based on the 'cost' associated with the connection. If your
dial-up data connection is slower than WiFi, it will use WiFi; if your other
connection is faster (plug-in 100BaseT Ethernet), it will use that. The
'cost' is based, basically, on speed, though; it doesn't know anything about
real cost for WiFi bandwidth or GSM, etc.

You can test which is being used if you connect to a server and the server
checks which IP address the incoming connection originated from. Each of
your available data connections has an IP and you can look at the device and
see which was used. If you aren't behind a firewall/proxy, you can visit
www.showmyip.com with the browser and it will tell you what your IP is.

Paul T.
 
If you're creating a socket, you can bind to a particular IP address, thus
selecting which interface the connection will be created on, yes. That's
the only way I can think of to do it.

Paul T.
 
Back
Top