Created
June 16, 2020 15:54
-
-
Save MrCrambo/d65dc36bef8189ac0898d8815502200c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
final WifiManager wifimanager = (WifiManager) getApplicationContext().getSystemService(WIFI_SERVICE); | |
wifimanager.registerScanResultsCallback(getMainExecutor(), new WifiManager.ScanResultsCallback() { | |
@Override | |
public void onScanResultsAvailable() { | |
List<ScanResult> results = wifimanager.getScanResults(); | |
for (ScanResult result : results) { | |
System.out.println(result.BSSID); | |
} | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment