Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>as all OEMs use different custom WiFi drivers or security supplicants (like Odyssey or others instead of MS Security) and not all use ZeroConfig you need a general approach.</p> <p>One option is using the System State notifications for network. But in the past I found that these are unreliable. The same was with using connection manager (CM). CM does sometimes report a working connection where there is no one. Has to do something with caching or so.</p> <p>Checking a working connection is possible using a ping. A ping verifies that the stack is usable and that the host is reachable. Other options, as for example checking the WiFi access point association or the local IP address does not really mean you can reach the host you need.</p> <p>On my web site is an easy to use background worker class that implements a ping as example for a blocking function: <a href="http://www.hjgode.de/wp/2010/06/01/mobile-development-easy-to-use-background-thread-with-gui-update/" rel="nofollow">http://www.hjgode.de/wp/2010/06/01/mobile-development-easy-to-use-background-thread-with-gui-update/</a></p> <p>In your main code you start the background thread, subscribe to its event and you will get the event fired, when the ping has finished. Then you can check the response (number of pings returned) and start or wait your action to your host.</p> <p>Remember to include some logic for suspend/resume of the device. The WiFi is normally switched off for suspend and you need to restart your logic to access your host.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload