Software Development

Save battery life and customize tasks for your Android device with Tasker

Saving battery life is a must for business users and IT pros when it comes to an essential tool -- your smartphone. Derek Schauland recommends Tasker to help optimize Android devices.

For many business users and IT pros, myself included, our smartphones are essential to the way we work and must always be available. I have noticed with the HTC EVO Android phone that battery consumption is a huge concern, and this doesn't mean just under heavy usage. With all the additional capabilities, including Wi-Fi, GPS, and 3 and 4G, the battery can quickly fade. Then I found Tasker in the Android Market. It takes a little getting used to and some planning to get it just right for you, but can make a world of difference in terms of battery life as well as customize other features of your phone.

What is Tasker?

Tasker is an application that runs in the background and monitors certain conditions on your Android device. When one of the chosen conditions is met, actions you have selected can be executed. In reality, it works as a set of macros for an Android phone. The conditions are almost infinite and actions can be really anything you can imagine.

Started off slow and still learning

When I downloaded Tasker, I was reading a post about battery life on the HTC EVO while trying to find a way to get it under control. After some investigating, I found a way to keep things working smoothly by reducing consumption. I created a task that checks the orientation of the phone. If the phone is face down, it switches to airplane mode. This way, when the phone is placed face down, the constant search for a signal goes away, improving battery life.

Figure A

Tasker's interface

While the idea of Airplane Mode is great, there are things that still need to get my attention while my phone is face down. Simply ignoring incoming calls or texts is not the best way to go through the work day. For this I created a similar task that only runs between 8am and 6pm and when the phone is face down. When this is true, Tasker sets Airplane Mode to On to conserve battery, but also toggles Airplane Mode off every 10 minutes to check for new alerts.

One last task I discovered recently with regard to battery usage relates to signal strength. If I am in an area where I know there is zero signal strength for my phone, which happened while attending an event in Seattle recently, the phone should not be looking for a signal and draining the battery. The first day of the event, I went to breakfast and in the hour or so I was in the basement conference area, my phone was over half way to a dead battery.

Using Tasker, I created a task that triggers when signal strength is zero and switches on Airplane Mode. When this condition is no longer true, Airplane Mode is switched off.

What other things can Tasker do?

Tasker can do almost anything you might imagine. It can send text messages based on your location, or enable your phone's GPS radio when you open an application (think Google Maps or Foursquare). The really cool thing about Tasker is that it allows the user to dream up new things to try.

Sometimes you need a quick way to mute a phone when you are heading into a meeting. For me, the best way was to create a widget for a task and use it as a shortcut for the action.

I created a new task that set all media volume to 0 and turned on vibrate and assigned it to a widget on the home screen. This way, I tap the widget and vibrate is enabled in one click rather than several to turn the volume down.

I also use Google Voice as my primary phone number, and because the signal isn't so great where my desk is located, I have Google ring my desk phone. Ringing that phone for every call I may receive isn't exactly the best idea, if the call is not during my working hours.

With a plug-in for Tasker (actually a plugin for a similar application that also works with Tasker), I can create a task that will adjust my Google Voice settings when the conditions are met. This task checks to see if I am near the Wi-Fi in my office. If so, it sets GV to ring my desk phone. I added an exit task, an action occurring when the conditions are no longer true, to turn off the ringing of my desk phone when I am not near the Wi-Fi.

Figure B

The details of a task for Google Voice

Almost anything that can be done on an Android device can be managed by Tasker. There is a 30-day free trial to get you started.

Creating a task

To get you started with the trial application, complete the steps below to create two widgets, the first to silence audio and enable vibrate ,and the second to restore audio:

  1. Select the Add button on your Android device.
  2. Select Widget.
  3. Scroll through the list of widgets and select Task.
  4. In the task selection popup, select New Task.
  5. Enter a name for the task, shown in Figure C.

Figure C

Naming your task

  1. Click OK. The next dialog will prompt you to add tasks to perform and create your widget.
  2. Click the + to view the available actions to take.
  3. Select the Audio group of actions.
  4. Select Silent Mode.
  5. In the Mode selection box, choose Vibrate shown in Figure D.

Figure D

Setting the phone to vibrate

  1. Click Done.
  2. Click the icon select button shown in Figure E.
  3. Choose the Icon you like for the widget from an application or built in collection.
  4. Tap Make Widget.

Figure E

Choose an icon for your widget

Once the widget is created, you will be prompted to place it on your home screen. After that, touching the widget will mute the phone and set it to vibrate.

Are there other applications that do these things?

I have tested one other application that can do some of the things Tasker can do called Locale, and some of its features are solid.  One in particular is the plug-ins being created for the application.  The greatest thing about Locale plug-ins is that they also work with Tasker.

Both of these applications are available in the Android Market. When I purchased Tasker, it was approximately $6 US, well worth the price once you see all of the things it does and allows you to automate.

About

Derek Schauland has been tinkering with Windows systems since 1997. He has supported Windows NT 4, worked phone support for an ISP, and is currently the IT Manager for a manufacturing company in Wisconsin.

9 comments
waynesreed
waynesreed

You said "Using Tasker, I created a task that triggers when signal strength is zero and switches on Airplane Mode. When this condition is no longer true, Airplane Mode is switched off." How does it know when the signal strength is no longer zero if you are in airplane mode? Do you have it check every 10 minutes?

chaapala
chaapala

I read somewhere, maybe on a Samsung/Android forum, that it is better to change wireless settings to "never sleep" to save power. I've made that change, and I believe my battery life are improved. I think here is why: If the wireless goes to sleep, then the phone lights up the 3G radio. When those connections change (IP address changes), it appears, observed via OSMonitor, that a number of services get very active re-establishing connections. That's gotta take juice every time wireless sleeps.

v941726
v941726

its not worth the hassle. its not intuitive at all. in fact it seems counter intuitive. juice defender is better for saving battery and more.

OldHenry
OldHenry

It's not this bad on IPhones, Blackberrys, Windows Mobile, or Windows Phone 7.

sonicsteve
sonicsteve

I've tried to save battery with a task killer and they do help. Killing things like games adn the camera after use are big for me. However using the Quick settings app Making sure that Wifi and 3G networking is turned off when you don't need them helps far more. Turn them back on when you need them, off when you don't, I get 3 days out of my phone this way.

bblackmoor
bblackmoor

I have a Tasker job that mutes alarms and notifications at night, but turns up the ringer volume. Very handy.

chaapala
chaapala

The answer to the obvious question is I'm running a Motorola Droid on Verizon.

T3CHN0M4NC3R
T3CHN0M4NC3R

And have you use an Android phone? It's not all Android phones have bad battery life. I've been using HTC Desire since last August and my battery usually last me almost 48 hours depending on usage. For all I know, the rest of the smartphones are similar.

Editor's Picks