Upload
nitte5768
View
218
Download
0
Embed Size (px)
Citation preview
7/29/2019 Tasker Tutorial
1/4
This step-through will show you how to make application-specific settings, in this case
the brightness of the screen. Please make sure you've at least read the Overview in the Userguide
first. First we will create a new profile with an Application context and then add an action to it.
Startup Tasker by clicking it's icon. We're in the Profile List screen Press the Menu button on
your device and select Help: This Screen. That menu item is available on every screen. Have a
read to see what all the widgets do. OK, now your head is warmed up, let's get started. Make
sure you are in the App tab (we want to create a profile with an Application Context) and Press
the New button. You will be shown a list of applications to select. Pick any. Once you've
selected an app, Tasker returns to the Profile List, and then takes you to the Task Edit screen to
edit the new task associated with the application context you made. Press the + button in the
bottom left to add an action to this task. Tasks are divided into categories to make them easier to
find. Click Display and then select the action Screen Brightness. Now we're in the Action Edit
dialog. Some actions are more complicated than others and can have extra parameters to specify
how they act. The one we're using, Screen Brightness, needs to know how bright you want the
screen. Move the slider to the far right, then click Done Back at the Task Edit screen. Notice
how the action we just created has been added to the task. We could add other actions, and they
would all run when the application you selected is launched. We're finished editing our new
Task, Press Save. We're back at the Profile List, but this time you should see our brand new
profile. On the left are displayed the Contexts that make up the profile i.e. the conditions that
must be met for it to become active. On the right is the task that will run when it becomes active.
Time to see if it all works, but first we need to enable Tasker. Click the button labelled Off in
the bottom right If the button isn't lit up green, Tasker doesn't do anything when you leave.
Press Save to exit, then launch the application you configured. You should see the screen
brightness go up when the application starts, and go back to how it was when you leave it. If not,
make sure your normal brightness is not at the maximum already (look in the Settings
application). Maybe you're wondering why the brightness went back down when you didn't ask
it to ? If you click on the Task again, you'll see that the action 'Screen Brightness' has a particular
icon next to it. The icon signifies that the action is a special one called a Setting, and Tasker will
always restore Settings that were changed in the Enter task when a profile exits.
This step-through will show you how to change an existing profile and use profiles with more
than one context. The goal is to change the profile from the previous tutorial so that the
7/29/2019 Tasker Tutorial
2/4
brightness is only set at a particular time of day. Also, we want an alert when the brightness is
returned to normal. To get started, Long-Click on the icon for the profile you made in the
previous Step-Through. You see a list of options divided into Context actions, which affect the
action you just clicked on, and Profile which affect the whole profile (i.e. the contexts and tasks
as a whole). Click Add. Each profile can only have one of each type of context, so you are
shown a list of context types which does not include App. // Click Time// This is the Time Edit
dialog. The top dial is the time the context starts at. If it is deselected, the time starts at midnight.
The bottom dial is the time the context ends. If it is deselected, the context ends at the following
midnight. Set the top dial to 09:00 and the bottom dial to 19:00. Click Done. Notice how there
are now two contexts listed in the profile: Application and Time. Our task will only be executed
when both contexts become active. Nw we want to add an alert to make it more obvious when
the brightness is going back to normal (it's just an example). The task we made first with the
green arrow is an Enter task: it runs when the profile becomes active. We need to add an Exit
task which runs when the profile becomes inactive. Long-click on the existing task. Select Add
Exit Task. Now we're back at the Task Edit screen. Click + and add the action Alert/Vibrate.
Back at the Action Edit screen we've seen before. The action Vibrate makes the phone vibrate for
a specified number of milliseconds. Set the slider a little way to the right and click 'Done'. So,
back at the Profile List where we started. Click around the tabs and you'll see that our profile is
now visible in both the App and Time tabs, because it has App and Time contexts. When you
leave Tasker and launch the app you configured, you'll find that if the current time is between
09:00 and 19:00 when you enter the app, the brightness will go up, and when you leave it the
device will vibrate and the brightness will go down again. If it doesn't vibrate, it could be you
have vibration disabled on your phone. We're done, so Click 'Done'. and try it out!
In this tutorial we will build a menu of useful actions and display it by clicking on an icon on
the Android home screen. On the Android Home Screen, long-click, select *Widget*, then
select *Task*. You are now at the Widget Edit screen, which is basically a slightly modifiedversion of the Task Edit screen we've seen previously. It looks pretty bare at the moment. In the
previous tutorials, we've made tasks without naming them, because they were very simple and
we only wanted to use them in a single profile. This time, we're going to make a Task with a
name, which we can then re-use with a normal profile. Click New in the top right to make a new
Task. Enter any name you like. Now we have a new task. You'll seen an X icon in the bottom
7/29/2019 Tasker Tutorial
3/4
right of the screen. That signifies how the Task will be handled when it is processed. The tasks
we have seen so far have been Execute (hence the X) tasks: each action in the task is carried out
one-by-one. In a Menu task, the actions are presented as a list and the user selects one of them to
carry out. Click the X icon and select Menu. Great, the task is now a Menu task. Now we want
to assign an icon to the task so it's easier to differentiate in the Android home screen. The default
icon is a question-mark icon, which you can see in the bottom right. Click on the question-mark
icon to change it. It doesn't matter which type of icon you pick. Right, we've setup the task, now
we want to add a few actions by clicking on the + button in the bottom left a few times. The
Misc/Load App action is a useful one for a widget menu task, so add a couple of those. Click
Make Widget at the bottom of the screen. You're now returned to the Android home screen, and
you should be able to see the widget you just created. Clicking it should show the actions you
selected. Selected one of the actions runs that action only. Run Tasker and click the Tasks
button at the bottom of the screen. This screen allows you to change Tasks you have previously
created. Using the pulldown at the top you should be able to see the Widget task we just created.
You could assign that to a profile in order to show exactly the same menu as the widget press
produces. Warning: a widget's task is fixed once the widget is created. Changing the task on the
Tasks screen does not change the widget, you have to delete and recreate it.
In this step-through we will use events and action variables to keep a record of particular callers
in a file on the SD card. Events are one-time happenings. Click the Event tab and then the button
New Just like actions, events are sorted into categories. Select Phone and Phone Ringing Like
actions, some events take extra parameters. In the case of events, however, the parameters are
used to further narrow down which events to respond to. In this case, we're going to react when
someone calls from Germany. Enter +49* in the Caller Number field and press Done. That
matches any number starting with +49. The rules for matching are available in the help text on
the event edit screen. Now we've defined a context, Tasker takes us to the Task Edit screen to
decide what actions the event will trigger. Press + in the bottom left to add an action. Select Fileand then Write File The Action Edit screen. Click ? in the bottm right to see what this action
does. (you might have to scroll a bit). In the File field enter callers or similar and then click
Append We need to Append because we want to add the incoming number on the end of the file
each time. For the Text field, we want the number of the caller to be inserted. To do that, we
insert something called a Variable. Click on the Text field and then hit the Var button. You're
7/29/2019 Tasker Tutorial
4/4
shown a list of all the built-in variables. Select Last Call Time. Good, now have a look at the
Text field: it's got %CTIME written there. When the action executes, that will be replaced with
whatever time the last call took place. Note that you don't need to use the variable selector if you
don't want, you could just type out %CTIME yourself. Add a : at the end of the text and then
click Var again. This time select Last Call Number. So, when the action runs, it's going to put a
line like: 15:34: +49037499566 on the end of the file /sdcard/callers Click Done to return to the
Profile List. Click Save. and get someone from Germany to phone you (don't forget to say
Guten Tag).