Wi-Fi Preferred Network Offload Scanning

Wi-Fi preferred network offload (PNO) scans are low-powered Wi-Fi scans that occur at regular intervals when a device is disconnected from Wi-Fi and the screen is off. PNO scans are used to find and connect to saved networks. These scans are scheduled by the framework using the NL80211_CMD_START_SCHED_SCAN command. For more information, see nl80211.h.

Optimizing power usage with device mobility information

On devices running Android 9 or lower, when the device is disconnected from Wi-Fi and the screen is off, PNO scans occur at 20 second intervals for the first three scans, then slow down to one scan every 60 seconds for all subsequent scans. PNO scanning stops when a saved network is found or the screen is turned on.

Android 10 introduces an optional API method named setDeviceMobilityState() in WifiManager that increases the interval between PNO scans based on the device's mobility state to reduce power consumption.

The possible mobility states are:

If the device is stationary, the Android framework increases the interval between PNO scans from 60 seconds to 180 seconds to reduce power consumption. This optimization is made on the assumption that the device is unlikely to find any new networks in PNO scans when the device is not moving.

If the device is in any other mobility state or if the method isn't called, the device uses the default PNO scan behavior.

Implementation

To implement this power-optimizing feature on a device running Android 10 or higher, derive the device mobility information and call the setDeviceMobilityState() method from a custom system app.