Scan all wifi devices near the phone

Ulle Tad picture Ulle Tad · Oct 19, 2013 · Viewed 13.9k times · Source

Company http://renewlondon.com/ have the terminal stations that collect all near by mac addresses

enter image description here

Can I via iOS SDK, and Android SDK,do the same thing?

Answer

Ciril picture Ciril · Oct 19, 2013

You can access the wifi data using 'WifiManager' and after the scanning the scanresult contain all the data like

BSSID The address of the access point.

SSID The network name.

capabilities Describes the authentication, key management, and encryption schemes supported by the access point.

frequency The frequency in MHz of the channel over which the client is communicating with the access point.

level The detected signal level in dBm.

timestamp Time Synchronization Function (tsf) timestamp in microseconds when this result was last seen.

about the wifi devices. if you need more related to coding, I think I can help you...

Sample code

WifiManager wManager;
List<ScanResult> wifiList; 

wManager = (WifiManager) getSystemService(Context.WIFI_SERVICE);
// Inside BroadcastReceiver()
wifiList = wManager.getScanResults();
for (int i=0; i<wifiList.size(); i++){
     ScanResult scanresult = wifiList.get(i);                        
     System.out.println("SSID: "+ssid);
     System.out.println("RSSI: "+scanresult.level);
     System.out.println("Frequency: "+scanresult.frequency);
     System.out.println("BSSID: "+scanresult.BSSID);
     System.out.println("Capability: "+scanresult.capabilities);
}

Also checkout the BroadcastReceiver().