FORUMS
Remove All Ads from XDA

[GUIDE] Tasker

371 posts
Thanks Meter: 39
 
By skulk3r, Senior Member on 28th December 2010, 10:44 AM
Post Reply Email Thread
Tasker is a very powerful program for Android devices that lets users have complete control over the automation of their phones.
I have seen a lot of fragmented threads about different profiles and requests for help. So I have decided to make a thread to collect profiles and advice for people from different devices to use (hopefully in an easy to understand English!). Also, I'm not a huge Tasker wiz! I just hope that everyone can contribute in one place for everyone at xda. So please send me/the contributor a PM if you see a post that is wrong.

Contents:
Post #2 - Links to submitted guides/profiles
Post #3 - Basics of Tasker

*Disclaimer*
I do not have ownership (whole or part thereof) of the Tasker Android Application. This guide is for educational purposes only. I, or any contributor to the guide, is not responsible for any faults (software or hardware) resulting from following the instructions set out in this guide.
Tasker is available from the Android Market or in trial form from the website

Admins: If this thread is unnecessary please delete and let me know, thanks.

Submission of Profiles:
If you have a profile that you would like to share, please put it into this standard form so that people can more easily understand what to do:

##(example 1)##
Profile: "Wifi at home"
Context:
  • Variable "HOME" [matches] "1"
  • Wifi-near [(SSID of home/work/school wireless network)]
Activity:
  • Wifi [ON]
  • Mobile Data [OFF]
  • Mobile APN Enabled [OFF]
Exit Activity (if any):
  • Wifi [TOGGLE]
  • Mobile Data [ON]
  • Mobile APN Enabled [ON]
##(end example 1)##

OR if you want to submit a walk-through as well:

##(example 2)##
  1. Tap Context
  2. Add
  3. Application
  4. Google Maps
...etc
##(end example 2)##

Absolute Beginners:
If you are completely new to Tasker, you need to check out the Tasker website and wiki.
The program may seem unwieldy and complicated at first for those who do not have programming experience - I certainly found it a little intimidating at first - but once you play around with it, it helps a lot. The guides on the wiki and on the website are a little confusing, so hopefully this thread will help decode some of the settings/profiles into plain English.
The wiki is worth checking out for the walkthroughs and downloadable profiles - so take your time to check it out!

duckredbeard has also pointed out that there is a google group for Tasker which is supported by the developer himself. So if you need some trouble shooting, check that out too.
The Following 18 Users Say Thank You to skulk3r For This Useful Post: [ View ] Gift skulk3r Ad-Free
 
 
28th December 2010, 10:45 AM |#2  
skulk3r's Avatar
OP Senior Member
Thanks Meter: 39
 
More

...slowly building more. post to contribute!
The Following 3 Users Say Thank You to skulk3r For This Useful Post: [ View ] Gift skulk3r Ad-Free
28th December 2010, 10:46 AM |#3  
skulk3r's Avatar
OP Senior Member
Thanks Meter: 39
 
More
Here are some basics that every beginner needs to know (or if you just need reminding).

Profile:
Not much explanation needed. A profile contains all the required settings for a particular purpose - it is usually recommended that you give your profile a name that makes sense (e.g.: "Wifi at home" for turning on/off your wifi when you are near your house). A profile has:
  1. Contexts
  2. Tasks
  3. Exit Tasks (not always)

Contexts:
A Context is basically an on/off switch for your Tasker profile - something that tells Tasker that a certain thing has happened/is happening and so Tasker should do something about it. When you tap "new" in Tasker and have given your profile a name, you will be given some choices for your Context. A Context can be:
  • Application (profile is activated by the opening of an app)
  • Time (this can be through a time interval or a set time frame)
  • Day (profile activation based on which day/month you are on)
  • Location
  • State (of your phone)
  • Event (something that has happened to the phone)
Tasks:
Once your profile has been triggered by your Context, you want it to do something - this can be switching on Wifi, or locking your phone, or turning on the GPS, launch an application, etc. You have amazing control over what your phone does! You will need to explore the different options in order to understand the kind of control you have.
Exit Tasks:
An exit task tells Tasker what to do once your Context is no longer true (e.g.: you are no longer near your wifi network). You can tell Tasker to switch things back on that you might have turned off (or vice versa). You do not need to have an exit task, but sometimes it is useful. You CANNOT have an Exit Task if your Context is an Event.

Monitoring your context:
Some contexts (like "Location") require Tasker to recognise when it is in a certain area or not - this is how Tasker does it.

To find a wifi network using the "Wifi-Near" context, Tasker switches on your wifi briefly (specified in "Menu -> Preferences -> Monitor -> Wifi Timeout Seconds") and scans the wifi networks available. After the specified amount of seconds has passed, Tasker will then switch off the Wifi scanning. Tasker begins scanning for wifi networks again after another time interval (specified in "Menu -> Preferences -> Monitor -> Wifi Scan Seconds"). Obviously the more you scan the more battery you use, but also the more responsive Tasker will be. And obviously the shorter amount of time you spend scanning for networks, the more battery you save, but you also have a lower chance of connecting to a network. Tasker can only do this wifi-scanning if you have set your Wifi to [TOGGLE] or [ON] - it will not do it if you have set your Wifi to [OFF].

GPS is a much more accurate way to find your location, but obviously much more battery intensive. Settings are much the same as the Wifi ones and are found in "Menu -> Preferences -> Monitor". Tasker can only update your GPS location if you have set your GPS to [TOGGLE] or [ON] - it will not do it if you have set your GPS to [OFF].

Network Location is the least battery intensive, but also the least accurate. Tasker checks your network location according to the time specified in "Menu -> Preferences -> Monitor -> Network Location Check Seconds".


...more to come.
The Following 2 Users Say Thank You to skulk3r For This Useful Post: [ View ] Gift skulk3r Ad-Free
28th December 2010, 10:46 AM |#4  
skulk3r's Avatar
OP Senior Member
Thanks Meter: 39
 
More
--just in case--
The Following User Says Thank You to skulk3r For This Useful Post: [ View ] Gift skulk3r Ad-Free
28th December 2010, 01:56 PM |#5  
skulk3r's Avatar
OP Senior Member
Thanks Meter: 39
 
More
Using GPS only when needed:
In normal use, apps like Weather, Places, Latitude, etc, only need to know which suburb/cell tower you are using. If you have your GPS switched on, then it becomes a huge waste of battery. Here is how to set it so that your GPS switches on when you use a GPS app, and then to switch it off again when you exit that app.

Profile: "GPS on"
Context:
  • Application
  • Google Maps
  • Locations
  • Navigation
  • ...etc
Tasks:
  • GPS [ON]
Exit Tasks:
  • GPS [OFF]
The Following 4 Users Say Thank You to skulk3r For This Useful Post: [ View ] Gift skulk3r Ad-Free
29th December 2010, 09:31 AM |#6  
skulk3r's Avatar
OP Senior Member
Thanks Meter: 39
 
More
Automagically switching wifi on and off

The Easy Way:
Profile: "Wifi at home"
Context:
- Wifi-Near [(Set as your work/home/school/etc SSID and MAC address - do this by long-pressing on the dialog box for Tasker to scan for you)]
Tasks:
- Wifi [ON]
Exit Tasks:
- Wifi [OFF]

This method has Tasker checking for your wifi network according to the settings you placed in:
"(Tasker Home Screen) Menu -> Preferences -> Monitor"
However, this theoretically leads to more battery usage because Tasker is always checking for your wifi network even when you are nowhere near your wifi network. You could always have it check your location using your GPS, but this is even worse for your battery. A way to reduce this battery drain is to lower your "Wifi/GPS Timeout" setting and increase your "Wifi/GPS Scan" setting. This will cause Tasker to check for wifi networks/GPS location for a smaller duration and less frequently - the downside is that Tasker will be less responsive when you enter into your wifi network (eg: if you set Tasker to check once every 10 minutes, then you might have to wait 10 minutes before Tasker kicks this profile into gear)

Slightly more complicated way:
This requires 2 profiles.

Profile 1: "Home"
Contexts:
- Cell Near [(press 'scan' to let Tasker find out what cell towers are near you)]
Tasks:
- Set variable "%HOME" = [1] (this is a variable i defined myself)
- Wifi [TOGGLE]
Exit Tasks:
- Set variable "&HOME" = [0]
- Wifi [OFF]

Profile 2: "Wifi at home"
Contexts:
- Variable "%HOME" matches [1]
- Wifi-Near [(SSID of home/work/school/etc)]
Tasks:
- Wifi [ON]
- Mobile Data [OFF]
- Mobile APN Enabled [OFF]
Exit Tasks:
- Wifi [TOGGLE]
- Mobile Data [ON]
- Mobile APN Enabled [ON]

(you can also enable Auto-Sync if you wish)

Explanation:
This method can theoretically save battery and increase the responsiveness of Tasker. It does it by only enabling the Wifi-scanning when you are within a certain cell-tower(s) area. Since checking for your location via the mobile network does not require much battery (and also since your phone is automatically doing it for your weather app anyway), you can set your Network Scan time to something quite low (I have it at 15 seconds). Once you are in the general area, then Tasker begins to look for your wifi network. Because you are not always searching for the wifi network, you can increase the frequency of the searches and also increase the duration of the search.
This does require a bit of testing - I find that it works quite well, but that could just be my area. Have a go and see what you find.
The Following 5 Users Say Thank You to skulk3r For This Useful Post: [ View ] Gift skulk3r Ad-Free
29th December 2010, 03:52 PM |#7  
TopShelf10's Avatar
Senior Member
Flag Boston
Thanks Meter: 353
 
Donate to Me
More
dont mean to cut down your efforts here, but: http://tasker.wikidot.com/
The Following User Says Thank You to TopShelf10 For This Useful Post: [ View ] Gift TopShelf10 Ad-Free
29th December 2010, 10:43 PM |#8  
Junior Member
Thanks Meter: 1
 
More
It will be nice to use this thread as a helpful discussion area on programming tasker as their does not to be such a place on the tasker wiki site.

Maybe you can help to achieve this state.

Is it possible to have several IF variables?

Ie.
Between hours 21:00 - :06:30 Reduce phone ringer to 2
If Location (network operator) = Home
and Power is connected
and phone has been idle for 30mins.

I have been playing with Tasker but having no programing experience it is difficult for my brain to wrap around how I would achieve this.

any hints?
30th December 2010, 06:08 AM |#9  
skulk3r's Avatar
OP Senior Member
Thanks Meter: 39
 
More
Quote:
Originally Posted by TopShelf10

dont mean to cut down your efforts here, but: http://tasker.wikidot.com/

yeah, I'm aware of the wiki - but the wiki doesn't answer all the questions and I feel it isn't organised very well (not that this would be organised any better). Plus, a forum opens things up to discussion and sharing, which I'm sure a lot of people will appreciate. feel free to contribute!
The Following 3 Users Say Thank You to skulk3r For This Useful Post: [ View ] Gift skulk3r Ad-Free
30th December 2010, 06:10 AM |#10  
skulk3r's Avatar
OP Senior Member
Thanks Meter: 39
 
More
Quote:
Originally Posted by Daft Templar

It will be nice to use this thread as a helpful discussion area on programming tasker as their does not to be such a place on the tasker wiki site.

Maybe you can help to achieve this state.

Is it possible to have several IF variables?

Ie.
Between hours 21:00 - :06:30 Reduce phone ringer to 2
If Location (network operator) = Home
and Power is connected
and phone has been idle for 30mins.

I have been playing with Tasker but having no programing experience it is difficult for my brain to wrap around how I would achieve this.

any hints?

I believe that if you put all of those 'variables' into one profile and make them all contexts, then you would be able to do that. But don't forget to set your task priorities properly!

Have you tried:

Code:
Profile: (profile name)
Contexts:
 - Time [21:00-06:30]
 - Wifi-Near [(your home SSID)] (also see my post about how to reduce wifi-searching to increase battery life)
 - Power [Any/AC/USB]
Tasks:
 - Ringer Volume [Level 2, (Sound, Display if you want as well - good for debug)]
Exit Tasks:
 - Ringer Volume [(whatever you like your volume level to be at)]
I am not sure how to do your "Phone Idle" condition as I have never had to use it before - I suppose that you could always set another 2 profiles:
1 to countdown to 30 minutes which then sets a variable (say, "Timer") equal to 1 and has a context that tells it to run the profile every time "Timer" = 0; the other profile would have set "Timer" = 0 every time the Display turned on. You could then add a "Timer [matches 1]" context to your original profile, and that should work.

This seems like a rather roundabout way to do it, but that's what I can think of at this time. Let me know if you would like me to post up the instructions to do that though.

If anyone else has a better idea, let me know!
30th December 2010, 10:30 PM |#11  
Junior Member
Thanks Meter: 1
 
More
I think when using tasker (particularly with lots of profiles) It is important to keep things as simple and clean as possible. Otherwise if certain tasks start becoming too dependant on other tasks it will either reduce your ability to program new tasks or Things will start going pear shaped.

For Example. If I were to program the phone with Wifi-Near to Enter silent mode It will affect any other Tasks I have going with the Wifi, Either it being Turn wifi Off Or stop searching or Even If My network goes down. I think (if possible) it would be better to use a different more non varried method of location if you know what I mean. I think it would go for any other tasks you would want to program as well. Keep things simple and very direct, It will also help you too trace back and find problems if needed later down the track as well.
Post Reply Subscribe to Thread

Tags
automation, guide, tasker

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes