I need a frequent wifi scan on my android application (I\'m trying to build a local indoor positioning system based on wifi RSSI values). IF I call wifi.startScan() I have o
I've been trying the same thing and I came to the following conclusion. It's not possible on 2.1 and higher. I've got no clue on lower versions because my app had to run on 2.1 and higher.
-Changed stuff inside the Android SDK so it will enable active scanning
-Traced it back to the driver resulting in the following conclusion: The driver will set the wifi module in passive mode every time. I've been looking to change this inside the driver but there was no setting inside the drive to achieve this.
Bottom line: Not possible.
I don't think you can. It is a device and/or OS version dependend setting. On the Nexus One for example it takes roughly a second to scan whereas on the G1 it takes significantly longer (or get fresh results after a few scans). If I recall correctly, some Android Version (< 2.0) did not issue a fresh scan everytime startScan()
was called but might have reused the old result. But I might be mistaken on that one.