Take the 2-minute tour ×
Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. It's 100% free, no registration required.

Regarding the answer to my previous question of Android's idle Wi-Fi use, it seems like a huge waste of battery life to have Wi-Fi constantly scanning and draining battery. So it seems it would be better to turn Wi-Fi off.

However, I'd still want my Android to connect automatically to my home network, for podcast sync and other large transfers. This woudn't need to be immediate, since I usually spend a long time at home.

I do know there are apps that give me a Wi-Fi toggle widget, but I don't want to be constantly switching Wi-Fi on and off manually. I know it's only a minor bother, but it just seems silly to have to do that since it would be pretty easy to have logic that does it for me.

Question: Are there any applications that would periodically (say, once ever 15 mins) turn Wi-Fi on just to do a quick network discovery, then in case a known Wi-Fi is found keep it on as long as I am in range?

Further: Any pointers as to how hard such an app would be to write? For example in GNU/linux it would probably be easy to do with just a very simple shell script running on background - does Android work like that too, or is it a much harder task?

(I expect this would in any case require rooting the system, but that's understandable and not a problem.)

share|improve this question

1 Answer 1

up vote 1 down vote accepted

One solution to this problem: use a tasking program such as Locale or Tasker and create certain conditions that will enable your wifi (essentially writing a script as you described).

For example: Use GPS and determine if I'm at my home (I believe you can use real GPS, which will consume quite a bit of power, or base it off of which cell tower you are connected to, which you would already know anyways if not in airplane mode).

Or you could even setup certain times of the day you know you will be at home, or work, or wherever you regularly have wifi.

share|improve this answer
Thanks for the suggestion! In case there's no simple way to do what I describe, basing Wi-Fi activity on cell tower -based location would indeed be a very good alternative. –  Ilari Kajaste Sep 18 '11 at 19:24
In fact, looking through the documentation it seems it might be possible to use Tasker even for exactly what I wanted to do - turn Wi-Fi on periodically to check if there are networks in range, and keep on if there are. I'll have to try and see. –  Ilari Kajaste Sep 22 '11 at 20:39
Did you get this working in Tasker? Any other apps that could solve this problem too? –  Simon B. Jan 5 at 7:12

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.