Click here to Skip to main content
15,882,017 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all,

Is there any solution to measure the WI-FI signal strength in C sharp .net, or in any other language?

Help will be highly appreciated.
Posted
Updated 30-Jan-11 1:23am
v2

Here is a nice option on CodePlex:
Managed Wifi API[^]

and here is the Google search[^] :)

Use the Managed Wifi API like this:
static void Main(string[] args) 
{     
  WlanClient client = new WlanClient();     
  foreach ( WlanClient.WlanInterface wlanIface in
                 client.Interfaces )
    {
      Wlan.WlanAvailableNetwork[] networks = 
            wlanIface.GetAvailableNetworkList( 0 );
      foreach ( Wlan.WlanAvailableNetwork network in networks )
      {
        Console.WriteLine( 
           "Found network with SSID {0} and Siqnal Quality {1}.", 
             GetStringForSSID(network.dot11Ssid), 
             network.wlanSignalQuality);
      }
   }
}

static string GetStringForSSID(Wlan.Dot11Ssid ssid)
{
  return Encoding.ASCII.GetString(ssid.SSID, 0, (int) ssid.SSIDLength); 
} 

The above code, by Taylor Leese, was copied from here[^].

Regards
Espen Harlinn
 
Share this answer
 
v2
Comments
Sergey Alexandrovich Kryukov 30-Jan-11 13:18pm    
How interesting! - my 5.
--SA
Espen Harlinn 30-Jan-11 14:18pm    
Thanks SAKryukov!
MCY 30-Jan-11 14:12pm    
good one
Espen Harlinn 30-Jan-11 14:19pm    
Thanks MCY
If only you had done an internet search before asking, you might have found this[^], which purports to do what you want.
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 30-Jan-11 13:20pm    
From this codelet, I couldn't see where MSNdis_80211_ReceivedSignalStrength comes from.
--SA
Henry Minute 30-Jan-11 17:23pm    
It is in System.Management I believe.
Sergey Alexandrovich Kryukov 30-Jan-11 19:15pm    
Yes, I could see it, but the code sample is still incomplete.
Thank you.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900