Android 12 WIFI扫描流程

本文详细探讨了Android 12中Wi-Fi扫描的流程,涉及多个关键组件,包括ConcreteClientModeManager、ActiveModeWarden、ScanRequestProxy、WifiScanner、WifiScanningServiceImpl等。从frameworks到service,再到implementation层,解析了Wi-Fi扫描的请求、管理、实现和服务交互过程。
摘要由CSDN通过智能技术生成

packages/modules/Wifi/service/java/com/android/server/wifi/ConcreteClientModeManager.java
frameworks/opt/net/wifi/service/java/com/android/server/wifi/ActiveModeWarden.java
packages/modules/Wifi/service/java/com/android/server/wifi/ScanRequestProxy.java
packages/modules/Wifi/framework/java/android/net/wifi/WifiScanner.java
packages/modules/Wifi/service/java/com/android/server/wifi/scanner/WifiScanningServiceImpl.java
frameworks/base/packages/SettingsLib/src/com/android/settingslib/wifi/WifiTracker.java
packages/modules/Wifi/framework/java/android/net/wifi/WifiManager.java
packages/modules/Wifi/service/java/com/android/server/wifi/WifiServiceImpl.java
packages/modules/Wifi/service/java/com/android/server/wifi/ScanRequestProxy.java
packages/modules/Wifi/service/java/com/android/server/wifi/scanner/WifiScannerImpl.java
modules/Wifi/service/java/com/android/server/wifi/scanner/WificondScannerImpl.java
packages/modules/Wifi/service/java/com/android/server/wifi/WifiNative.java
frameworks/base/wifi/java/src/android/net/wifi/nl80211/WifiNl80211Manager.java

wifi打开后,状态机已切换到ConnectModeState
ConcreteClientModeManager.java =>ConcreteClientModeManager$ConnectModeState ->enter():updateConnectModeState(mConnectRoleChangeInfoToSetOnTransition.role,WIFI_STATE_ENABLED, WIFI_STATE_ENABLING);
                                 -->updateConnectModeState(ClientRole role, int newState, int currentState)//wifi状态发生改变,触发广播:WifiManager.WIFI_STATE_CHANGED_ACTION
---->ActiveModeWarden.java =>ActiveModeWarden$ClientListener ->onStartedOrRoleChanged(ConcreteClientModeManager clientModeManager):updateClientScanMode();
                             -->updateClientScanMode():
                                mScanRequestProxy.enableScanning(scanEnabled, scanningForHiddenNetworksEnabled);
-------->ScanRequestProxy.java => enableScanning(boolean enable, boolean enableScanningForHidde
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值