Home
last modified time | relevance | path

Searched refs:WifiScanner (Results 1 – 25 of 37) sorted by relevance

12

/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/scanner/
DSupplicantWifiScannerTest.java27 import android.net.wifi.WifiScanner;
61 .addBucketWithBand(10000, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN, in backgroundScanSuccessSingleBucket()
62 WifiScanner.WIFI_BAND_24_GHZ) in backgroundScanSuccessSingleBucket()
68 expectedBandScanFreqs(WifiScanner.WIFI_BAND_24_GHZ)), in backgroundScanSuccessSingleBucket()
71 expectedBandScanFreqs(WifiScanner.WIFI_BAND_24_GHZ)) in backgroundScanSuccessSingleBucket()
83 WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN in backgroundScanMaxApExceeded()
84 | WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT, in backgroundScanMaxApExceeded()
85 WifiScanner.WIFI_BAND_24_GHZ) in backgroundScanMaxApExceeded()
99 expectedBandScanFreqs(WifiScanner.WIFI_BAND_24_GHZ)) in backgroundScanMaxApExceeded()
111 WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN in backgroundScanSuccessWithFullScanResults()
[all …]
DBackgroundScanSchedulerTest.java29 import android.net.wifi.WifiScanner;
30 import android.net.wifi.WifiScanner.ScanSettings;
94 WifiScanner.WIFI_BAND_BOTH, 30000, 0, 20, in singleRequest()
95 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT in singleRequest()
111 WifiScanner.WIFI_BAND_BOTH, 7500, 0, 20, in singleRequestWithoutPredefinedBucket()
112 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT in singleRequestWithoutPredefinedBucket()
128 requests.add(createRequest(WifiScanner.WIFI_BAND_BOTH, 30000, 0, 20, in fewRequests()
129 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT)); in fewRequests()
130 requests.add(createRequest(WifiScanner.WIFI_BAND_5_GHZ_DFS_ONLY, 14000, 0, 20, in fewRequests()
131 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT)); in fewRequests()
[all …]
DChannelHelperTest.java29 import android.net.wifi.WifiScanner;
56 WifiScanner.ScanSettings scanSettings = createRequest(WifiScanner.WIFI_BAND_BOTH, in scanSettings_band()
57 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in scanSettings_band()
66 WifiScanner.ScanSettings scanSettings = createRequest(channelsToSpec(5150, 2400), in scanSettings_channels()
67 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in scanSettings_channels()
76 WifiScanner.ScanSettings scanSettings = createRequest(WifiScanner.WIFI_BAND_5_GHZ, in bucketSettings_band()
77 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in bucketSettings_band()
87 WifiScanner.ScanSettings scanSettings = createRequest(channelsToSpec(2400, 5100), in bucketSettings_channels()
88 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in bucketSettings_channels()
110 .addChannels(any(WifiScanner.ScanSettings.class)); in setUp()
[all …]
DWifiScanningServiceTest.java30 import android.net.wifi.WifiScanner;
126 private WifiScanner.ScanSettings generateValidScanSettings() { in generateValidScanSettings()
127 return createRequest(WifiScanner.WIFI_BAND_BOTH, 30000, 0, 20, in generateValidScanSettings()
128 WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in generateValidScanSettings()
159 WifiScanner.ScanData... expected) { in verifyScanResultsRecieved()
161 WifiScanner.CMD_SCAN_RESULT); in verifyScanResultsRecieved()
165 private void assertScanResultsMessage(int listenerId, WifiScanner.ScanData[] expected, in assertScanResultsMessage()
167 assertEquals("what", WifiScanner.CMD_SCAN_RESULT, scanResultMessage.what); in assertScanResultsMessage()
170 ((WifiScanner.ParcelableScanData) scanResultMessage.obj).getResults()); in assertScanResultsMessage()
175 WifiScanner.CMD_SINGLE_SCAN_COMPLETED); in verifySingleScanCompletedRecieved()
[all …]
DScanScheduleUtilFilterTest.java30 import android.net.wifi.WifiScanner;
31 import android.net.wifi.WifiScanner.ScanData;
32 import android.net.wifi.WifiScanner.ScanSettings;
58 WifiScanner.WIFI_BAND_24_GHZ, 30000, 0, 20, in reportFullResultTrueForBandsWithNoBucketInfo()
59 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT in reportFullResultTrueForBandsWithNoBucketInfo()
69 WifiScanner.WIFI_BAND_24_GHZ, 30000, 0, 20, in reportFullResultFalseForBandsWithNoBucketInfo()
70 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT in reportFullResultFalseForBandsWithNoBucketInfo()
81 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT in reportFullResultTrueForChannelsWithNoBucketInfo()
92 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT in reportFullResultFalseForChannelsWithNoBucketInfo()
103 WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT in reportFullResultTrueForChannelsWithBucketDefinitlyScanned()
[all …]
DKnownBandsChannelHelperTest.java30 import android.net.wifi.WifiScanner;
79 WifiScanner.ScanSettings testSettings = createRequest(channelsToSpec(2400, 2450, 5100), in fewChannels()
80 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in fewChannels()
91 WifiScanner.ScanSettings testSettings = createRequest(WifiScanner.WIFI_BAND_24_GHZ, in band()
92 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in band()
120 WifiScanner.ChannelSpec[] channels = in testBand()
134 testBand(CHANNELS_24_GHZ, WifiScanner.WIFI_BAND_24_GHZ); in channels24Ghz()
142 testBand(CHANNELS_5_GHZ, WifiScanner.WIFI_BAND_5_GHZ); in channels5Ghz()
150 testBand(CHANNELS_DFS, WifiScanner.WIFI_BAND_5_GHZ_DFS_ONLY); in channelsDfs()
162 testBand(expectedChannels, WifiScanner.WIFI_BAND_BOTH); in channels24GhzAnd5Ghz()
[all …]
DNoBandChannelHelperTest.java30 import android.net.wifi.WifiScanner;
49 private static final int ALL_BANDS = WifiScanner.WIFI_BAND_BOTH_WITH_DFS;
73 WifiScanner.ScanSettings testSettings = createRequest(channelsToSpec(2400, 2450, 5100), in fewChannels()
74 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in fewChannels()
85 WifiScanner.ScanSettings testSettings = createRequest(WifiScanner.WIFI_BAND_24_GHZ, in band()
86 10000, 0, 20, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN); in band()
116 for (int band = WifiScanner.WIFI_BAND_24_GHZ; in eachBandValue()
117 band <= WifiScanner.WIFI_BAND_BOTH_WITH_DFS; ++band) { in eachBandValue()
118 WifiScanner.ChannelSpec[] channels = in eachBandValue()
147 WifiScanner.ScanSettings testSettings = createRequest(channelsToSpec(), in emptySettings()
[all …]
DBaseWifiScannerImplTest.java28 import android.net.wifi.WifiScanner;
29 import android.net.wifi.WifiScanner.ScanData;
112 .addBucketWithBand(10000 /* ms */, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN, in singleScanSuccess()
113 WifiScanner.WIFI_BAND_24_GHZ) in singleScanSuccess()
116 doSuccessfulSingleScanTest(settings, expectedBandScanFreqs(WifiScanner.WIFI_BAND_24_GHZ), in singleScanSuccess()
126 .addBucketWithChannels(20000, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN, 5650) in singleScanSuccessWithChannels()
140 WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN in singleScanSuccessWithFullResults()
141 | WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT, in singleScanSuccessWithFullResults()
142 WifiScanner.WIFI_BAND_24_GHZ) in singleScanSuccessWithFullResults()
145 doSuccessfulSingleScanTest(settings, expectedBandScanFreqs(WifiScanner.WIFI_BAND_24_GHZ), in singleScanSuccessWithFullResults()
[all …]
DSupplicantPnoScannerTest.java27 import android.net.wifi.WifiScanner;
123 expectedBandScanFreqs(WifiScanner.WIFI_BAND_24_GHZ), new HashSet<Integer>(), in pauseResumeHwDisconnectedPnoScanForSingleScan()
193 expectedBandScanFreqs(WifiScanner.WIFI_BAND_24_GHZ), new HashSet<Integer>(), in delayedHwDisconnectedPnoScanFailure()
265 .addBucketWithBand(10000, WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN, in createDummyScanSettings()
266 WifiScanner.WIFI_BAND_24_GHZ) in createDummyScanSettings()
371 WifiScanner.ScanData[] scanData = mScanner.getLatestBatchedScanResults(true); in expectSuccessfulSwPnoScan()
372 WifiScanner.ScanData lastScanData = scanData[scanData.length -1]; in expectSuccessfulSwPnoScan()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/scanner/
DKnownBandsChannelHelper.java19 import android.net.wifi.WifiScanner;
32 private WifiScanner.ChannelSpec[][] mBandsToChannels;
35 mBandsToChannels = new WifiScanner.ChannelSpec[8][]; in setBandChannels()
39 mBandsToChannels[1] = new WifiScanner.ChannelSpec[channels2G.length]; in setBandChannels()
42 mBandsToChannels[2] = new WifiScanner.ChannelSpec[channels5G.length]; in setBandChannels()
45 mBandsToChannels[3] = new WifiScanner.ChannelSpec[channels2G.length + channels5G.length]; in setBandChannels()
49 mBandsToChannels[4] = new WifiScanner.ChannelSpec[channelsDfs.length]; in setBandChannels()
52 mBandsToChannels[5] = new WifiScanner.ChannelSpec[channels2G.length + channelsDfs.length]; in setBandChannels()
56 mBandsToChannels[6] = new WifiScanner.ChannelSpec[channels5G.length + channelsDfs.length]; in setBandChannels()
60 mBandsToChannels[7] = new WifiScanner.ChannelSpec[ in setBandChannels()
[all …]
DChannelHelper.java19 import android.net.wifi.WifiScanner;
40 protected static final WifiScanner.ChannelSpec[] NO_CHANNELS = new WifiScanner.ChannelSpec[0];
50 public abstract boolean settingsContainChannel(WifiScanner.ScanSettings settings, int channel); in settingsContainChannel()
56 public abstract WifiScanner.ChannelSpec[] getAvailableScanChannels(int band); in getAvailableScanChannels()
61 public abstract int estimateScanDuration(WifiScanner.ScanSettings settings); in estimateScanDuration()
123 public void addChannels(WifiScanner.ScanSettings scanSettings) { in addChannels()
124 if (scanSettings.band == WifiScanner.WIFI_BAND_UNSPECIFIED) { in addChannels()
137 if (bucketSettings.band == WifiScanner.WIFI_BAND_UNSPECIFIED) { in addChannels()
149 public boolean containsSettings(WifiScanner.ScanSettings scanSettings) { in containsSettings()
150 if (scanSettings.band == WifiScanner.WIFI_BAND_UNSPECIFIED) { in containsSettings()
[all …]
DWifiScanningServiceImpl.java30 import android.net.wifi.WifiScanner;
31 import android.net.wifi.WifiScanner.BssidInfo;
32 import android.net.wifi.WifiScanner.ChannelSpec;
33 import android.net.wifi.WifiScanner.PnoSettings;
34 import android.net.wifi.WifiScanner.ScanData;
35 import android.net.wifi.WifiScanner.ScanSettings;
116 b.putIntegerArrayList(WifiScanner.GET_AVAILABLE_CHANNELS_EXTRA, list); in getAvailableChannels()
180 replyFailed(msg, WifiScanner.REASON_NOT_AUTHORIZED, "Not authorized"); in handleMessage()
186 if (msg.what == WifiScanner.CMD_GET_SCAN_RESULTS) { in handleMessage()
194 replyFailed(msg, WifiScanner.REASON_INVALID_LISTENER, "Could not find listener"); in handleMessage()
[all …]
DNoBandChannelHelper.java19 import android.net.wifi.WifiScanner;
40 public boolean settingsContainChannel(WifiScanner.ScanSettings settings, int channel) { in settingsContainChannel()
41 if (settings.band == WifiScanner.WIFI_BAND_UNSPECIFIED) { in settingsContainChannel()
54 public WifiScanner.ChannelSpec[] getAvailableScanChannels(int band) { in getAvailableScanChannels()
59 public int estimateScanDuration(WifiScanner.ScanSettings settings) { in estimateScanDuration()
60 if (settings.band == WifiScanner.WIFI_BAND_UNSPECIFIED) { in estimateScanDuration()
83 if (band != WifiScanner.WIFI_BAND_UNSPECIFIED) { in addBand()
95 if (band != WifiScanner.WIFI_BAND_UNSPECIFIED) { in containsBand()
148 bucketSettings.band = WifiScanner.WIFI_BAND_BOTH_WITH_DFS; in fillBucketSettings()
152 bucketSettings.band = WifiScanner.WIFI_BAND_UNSPECIFIED; in fillBucketSettings()
DSupplicantWifiScannerImpl.java23 import android.net.wifi.WifiScanner;
88 private WifiScanner.ScanData mLatestSingleScanResult =
89 new WifiScanner.ScanData(0, 0, new ScanResult[0]);
212 public WifiScanner.ScanData getLatestSingleScanResults() { in getLatestSingleScanResults()
292 WifiScanner.ScanData[] results = getLatestBatchedScanResults(/* flush = */ true); in pauseBatchedScan()
357 int reportEvents = WifiScanner.REPORT_EVENT_NO_BATCH; // default to no batch in processPendingScans()
365 & WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN) != 0) { in processPendingScans()
366 reportEvents |= WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN; in processPendingScans()
369 & WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT) != 0) { in processPendingScans()
370 reportEvents |= WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT; in processPendingScans()
[all …]
DWifiScannerImpl.java21 import android.net.wifi.WifiScanner;
98 public abstract WifiScanner.ScanData getLatestSingleScanResults(); in getLatestSingleScanResults()
128 public abstract WifiScanner.ScanData[] getLatestBatchedScanResults(boolean flush); in getLatestBatchedScanResults()
161 public abstract boolean setHotlist(WifiScanner.HotlistSettings settings, in setHotlist()
172 public abstract boolean trackSignificantWifiChange(WifiScanner.WifiChangeSettings settings, in trackSignificantWifiChange()
DBackgroundScanScheduler.java22 import android.net.wifi.WifiScanner;
23 import android.net.wifi.WifiScanner.ScanData;
24 import android.net.wifi.WifiScanner.ScanSettings;
199 int reportEvents = WifiScanner.REPORT_EVENT_NO_BATCH; in createBucketSettings()
205 WifiScanner.ScanSettings setting = mScanSettingsList.get(i); in createBucketSettings()
207 if ((requestedReportEvents & WifiScanner.REPORT_EVENT_NO_BATCH) == 0) { in createBucketSettings()
208 reportEvents &= ~WifiScanner.REPORT_EVENT_NO_BATCH; in createBucketSettings()
210 if ((requestedReportEvents & WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN) != 0) { in createBucketSettings()
211 reportEvents |= WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN; in createBucketSettings()
213 if ((requestedReportEvents & WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT) != 0) { in createBucketSettings()
[all …]
DHalChannelHelper.java19 import android.net.wifi.WifiScanner;
42 int[] channels24G = mWifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_24_GHZ); in updateChannels()
44 int[] channels5G = mWifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_5_GHZ); in updateChannels()
46 int[] channelsDfs = mWifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_5_GHZ_DFS_ONLY); in updateChannels()
DHalWifiScannerImpl.java20 import android.net.wifi.WifiScanner;
80 public WifiScanner.ScanData getLatestSingleScanResults() { in getLatestSingleScanResults()
111 public WifiScanner.ScanData[] getLatestBatchedScanResults(boolean flush) { in getLatestBatchedScanResults()
153 public boolean setHotlist(WifiScanner.HotlistSettings settings, in setHotlist()
164 public boolean trackSignificantWifiChange(WifiScanner.WifiChangeSettings settings, in trackSignificantWifiChange()
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/
DScanTestUtil.java24 import android.net.wifi.WifiScanner;
25 import android.net.wifi.WifiScanner.ScanData;
43 when(wifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_24_GHZ)) in setupMockChannels()
45 when(wifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_5_GHZ)) in setupMockChannels()
47 when(wifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_5_GHZ_DFS_ONLY)) in setupMockChannels()
51 public static WifiScanner.ScanSettings createRequest(WifiScanner.ChannelSpec[] channels, in createRequest()
53 WifiScanner.ScanSettings request = new WifiScanner.ScanSettings(); in createRequest()
54 request.band = WifiScanner.WIFI_BAND_UNSPECIFIED; in createRequest()
63 public static WifiScanner.ScanSettings createRequest(int band, int period, int batch, in createRequest()
71 public static WifiScanner.ScanSettings createRequest(int band, int period, int maxPeriod, in createRequest()
[all …]
DWifiConnectivityManagerTest.java32 import android.net.wifi.WifiScanner;
33 import android.net.wifi.WifiScanner.PnoScanListener;
34 import android.net.wifi.WifiScanner.PnoSettings;
35 import android.net.wifi.WifiScanner.ScanListener;
36 import android.net.wifi.WifiScanner.ScanSettings;
96 private WifiScanner mWifiScanner;
129 WifiScanner mockWifiScanner() { in mockWifiScanner()
130 WifiScanner scanner = mock(WifiScanner.class); in mockWifiScanner()
134 final WifiScanner.ScanData[] scanDatas = new WifiScanner.ScanData[1]; in mockWifiScanner()
764 assertEquals(settings.band, WifiScanner.WIFI_BAND_5_GHZ_WITH_DFS); in checkSingleScanSettingsWhenConnectedWithLowDataRate()
[all …]
DWifiStateMachineTest.java39 import android.net.wifi.WifiScanner;
317 @Mock WifiScanner mWifiScanner;
776 ArgumentCaptor<WifiScanner.ScanSettings> scanSettingsCaptor = in verifyScan()
777 ArgumentCaptor.forClass(WifiScanner.ScanSettings.class); in verifyScan()
778 ArgumentCaptor<WifiScanner.ScanListener> scanListenerCaptor = in verifyScan()
779 ArgumentCaptor.forClass(WifiScanner.ScanListener.class); in verifyScan()
782 WifiScanner.ScanSettings actualSettings = scanSettingsCaptor.getValue(); in verifyScan()
814 verifyScan(WifiScanner.WIFI_BAND_BOTH_WITH_DFS, in scan()
815 WifiScanner.REPORT_EVENT_AFTER_EACH_SCAN in scan()
816 | WifiScanner.REPORT_EVENT_FULL_SCAN_RESULT, null); in scan()
[all …]
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/
DWifiConnectivityManager.java29 import android.net.wifi.WifiScanner;
30 import android.net.wifi.WifiScanner.PnoSettings;
31 import android.net.wifi.WifiScanner.ScanSettings;
125 private final WifiScanner mScanner;
239 private class PeriodicScanListener implements WifiScanner.ScanListener {
277 public void onResults(WifiScanner.ScanData[] results) { in onResults()
299 private class SingleScanListener implements WifiScanner.ScanListener {
344 public void onResults(WifiScanner.ScanData[] results) { in onResults()
382 private class PnoScanListener implements WifiScanner.PnoScanListener {
436 public void onResults(WifiScanner.ScanData[] results) { in onResults()
[all …]
DFrameworkFacade.java27 import android.net.wifi.WifiScanner;
80 public WifiScanner makeWifiScanner(Context context, Looper looper) { in makeWifiScanner()
81 return new WifiScanner(context, IWifiScanner.Stub.asInterface( in makeWifiScanner()
/frameworks/opt/net/wifi/tests/wifitests/src/android/net/wifi/
DWifiScannerTest.java29 import android.net.wifi.WifiScanner.BssidInfo;
30 import android.net.wifi.WifiScanner.BssidListener;
57 private WifiScanner mWifiScanner;
72 mWifiScanner = new WifiScanner(mContext, mService, mLooper.getLooper()); in setUp()
88 WifiScanner.CMD_SET_HOTLIST, in verifySetHotlistMessage()
109 verify(mBssidListener).onFailure(eq(WifiScanner.REASON_DUPLICATE_REQEUST), anyString()); in testStartTrackingBssidsDuplicateListeners()
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/util/
DApConfigUtilTest.java24 import android.net.wifi.WifiScanner;
236 when(mWifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_5_GHZ)) in updateApChannelConfigWith5GBandNoChannelAllowed()
253 when(mWifiNative.getChannelsForBand(WifiScanner.WIFI_BAND_5_GHZ)) in updateApChannelConfigWithoutChannelsForBandSupported()

12