To get the impression of networking capabilities in WP7 I was going to build a simple ping app that would display the result of ICMP ping request to a certain host.
However, not only the System.Net.NetworkInformation.Ping
class is missing, System.Net.Sockets
namespace is missing as well.
After a short research I found out that there are only two ways of communication in WP7: WebClient
class that works with http(s) requests and WCF-client that works with SOA services.
Does that mean that I can't ping hosts directly from the phone? The only possible solution I see is implementing a separate WCF service on a dedicated server that will do the pinging for the phone, which looks like an overkill and has certain flaws.
You won't be able to do this until sockets come to the WP7 platform as there isn't going to be any other way to send an ICMP packet.
The phones may not respond to pings back from a server either - we'll have to see on that. If they don't I doubt there would be anyway to change this on unhacked devices.
Pinging to a target host from a server on behalf of a phone isn't going to be too helpful either since unfortunately it won't reflect the latency between phone and target host in any way.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With