diff options
author | Michael Plass <mplass@google.com> | 2017-08-09 14:13:48 -0700 |
---|---|---|
committer | Michael Plass <mplass@google.com> | 2017-08-17 10:30:50 -0700 |
commit | fac6568cbb329e06b22bfe07993acb263f3762ab (patch) | |
tree | 7dd948b4b35f3a69d0261d1af3092e92f5eeaa07 /service | |
parent | f7443e9d5cab764fbe57581c48e9df65e7790adb (diff) |
Wifi connection hysteresis
Making an automatic connection should not happen unless the RSSI
is a little bit above the level at which a connection is considered
to be "bad", to avoid flapping back and forth between wifi and cell.
Bug: 64422319
Test: Unit tests, manual
Change-Id: I9a148f2d66ea835d19696eb6317b682f6756f002
Diffstat (limited to 'service')
-rw-r--r-- | service/java/com/android/server/wifi/WifiConnectivityManager.java | 4 | ||||
-rw-r--r-- | service/java/com/android/server/wifi/WifiNetworkSelector.java | 10 |
2 files changed, 7 insertions, 7 deletions
diff --git a/service/java/com/android/server/wifi/WifiConnectivityManager.java b/service/java/com/android/server/wifi/WifiConnectivityManager.java index 47c77e203..de63b251a 100644 --- a/service/java/com/android/server/wifi/WifiConnectivityManager.java +++ b/service/java/com/android/server/wifi/WifiConnectivityManager.java @@ -559,9 +559,9 @@ public class WifiConnectivityManager { mConnectionAttemptTimeStamps = new LinkedList<>(); mMin5GHzRssi = context.getResources().getInteger( - R.integer.config_wifi_framework_wifi_score_bad_rssi_threshold_5GHz); + R.integer.config_wifi_framework_wifi_score_entry_rssi_threshold_5GHz); mMin24GHzRssi = context.getResources().getInteger( - R.integer.config_wifi_framework_wifi_score_bad_rssi_threshold_24GHz); + R.integer.config_wifi_framework_wifi_score_entry_rssi_threshold_24GHz); mBand5GHzBonus = context.getResources().getInteger( R.integer.config_wifi_framework_5GHz_preference_boost_factor); mCurrentConnectionBonus = context.getResources().getInteger( diff --git a/service/java/com/android/server/wifi/WifiNetworkSelector.java b/service/java/com/android/server/wifi/WifiNetworkSelector.java index 57779ad08..8fdf080cc 100644 --- a/service/java/com/android/server/wifi/WifiNetworkSelector.java +++ b/service/java/com/android/server/wifi/WifiNetworkSelector.java @@ -570,15 +570,15 @@ public class WifiNetworkSelector { mLocalLog = localLog; mThresholdQualifiedRssi24 = context.getResources().getInteger( - R.integer.config_wifi_framework_wifi_score_low_rssi_threshold_24GHz); + R.integer.config_wifi_framework_wifi_score_low_rssi_threshold_24GHz); mThresholdQualifiedRssi5 = context.getResources().getInteger( - R.integer.config_wifi_framework_wifi_score_low_rssi_threshold_5GHz); + R.integer.config_wifi_framework_wifi_score_low_rssi_threshold_5GHz); mThresholdMinimumRssi24 = context.getResources().getInteger( - R.integer.config_wifi_framework_wifi_score_bad_rssi_threshold_24GHz); + R.integer.config_wifi_framework_wifi_score_entry_rssi_threshold_24GHz); mThresholdMinimumRssi5 = context.getResources().getInteger( - R.integer.config_wifi_framework_wifi_score_bad_rssi_threshold_5GHz); + R.integer.config_wifi_framework_wifi_score_entry_rssi_threshold_5GHz); mEnableAutoJoinWhenAssociated = context.getResources().getBoolean( - R.bool.config_wifi_framework_enable_associated_network_selection); + R.bool.config_wifi_framework_enable_associated_network_selection); mStayOnNetworkMinimumTxRate = context.getResources().getInteger( R.integer.config_wifi_framework_min_tx_rate_for_staying_on_network); mStayOnNetworkMinimumRxRate = context.getResources().getInteger( |