I found below the values ββin http://androidxref.com/5.0.0_r2/xref/packages/apps/Bluetooth/src/com/android/bluetooth/gatt/ScanManager.java showing the keyword "SCAN_MODE_BALANCED":
private static final int SCAN_MODE_LOW_POWER_WINDOW_MS = 500; private static final int SCAN_MODE_LOW_POWER_INTERVAL_MS = 5000; private static final int SCAN_MODE_BALANCED_WINDOW_MS = 2000; private static final int SCAN_MODE_BALANCED_INTERVAL_MS = 5000; private static final int SCAN_MODE_LOW_LATENCY_WINDOW_MS = 5000; private static final int SCAN_MODE_LOW_LATENCY_INTERVAL_MS = 5000; private static final int SCAN_MODE_BATCH_LOW_POWER_WINDOW_MS = 1500; private static final int SCAN_MODE_BATCH_LOW_POWER_INTERVAL_MS = 150000; private static final int SCAN_MODE_BATCH_BALANCED_WINDOW_MS = 1500; private static final int SCAN_MODE_BATCH_BALANCED_INTERVAL_MS = 15000; private static final int SCAN_MODE_BATCH_LOW_LATENCY_WINDOW_MS = 1500; private static final int SCAN_MODE_BATCH_LOW_LATENCY_INTERVAL_MS = 5000;
Also exit ScanManager.ScanNative.configureRegularScanParams (). The two parameters scanWindow and scanInterval are set according to the scan settings ( ScanSettings.SCAN_MODE_LOW_POWER , ScanSettings.SCAN_MODE_BALANCED , ScanSettings.SCAN_MODE_LOW_LATENCY ), converted to BLE units, and then passed to gattSetScanParameters.
Hope this helps.
source share