Go Back   Android Forums > Android Discussion > Android Applications > Tasker

Get excited for the Samsung Galaxy S5! Find everything you need and discuss it in our Galaxy S5 Forum!

test: Reply
 
LinkBack Thread Tools
Old September 17th, 2012, 06:27 PM   #1 (permalink)
Junior Member
Thread Author (OP)
 
Join Date: Jan 2011
Posts: 29
 
Device(s):
Carrier: Not Provided

Thanks: 8
Thanked 2 Times in 2 Posts
Question Question about creating widgets with Tasker

Simple question, can I create widgets with Tasker to change settings? For example, say I create a widget called "Work", when I press that widget I want it to lower the volumes (ring and notification), disable vibrate (very important), turn off WiFi and haptic feedback. Then I want a widget called "Car" when I press it it will turn the screen brightness all the way up, turn on GPS, launch Waze, etc. Is this possible? My extensive Google search didn't give me a straight answer.

MaxPower1 is offline  
Reply With Quote
sponsored links
Old September 17th, 2012, 08:10 PM   #2 (permalink)
Senior Member
 
bberryhill0's Avatar
 
Join Date: Jan 2010
Location: Rhinelander, WI> Wayzata, MN>Sisters, OR
Posts: 2,335
 
Device(s): Q9c, Eris xtrROM 4.6.5, Droid Concepts 11, Incredible 2 EclipticSense
Carrier: Not Provided

Thanks: 776
Thanked 338 Times in 301 Posts
Default

Yup. Most of those are in Audio Settings. Start writing a task and see if you can find all the settings you want. Then you can create a widget that runs that task. After that you can figure out a context that runs the task automatically.
__________________
My Eris apps
bberryhill0 is online now  
Reply With Quote
Old September 18th, 2012, 01:01 AM   #3 (permalink)
ROM Developer
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

All tasker tasks are already widgets. Long press home screen > widgets > task

You may want to assign an icon though. In a task (via tasker) when editing, press the colour chart / swatch icon in the bottom right corner to choose.

You need to be clear what you want it to do. Instead of a context triggered task that will turn something on or off then revert as an exit task etc, you will most likely want to use toggle so the same widget turns on and off.

For example, audio task, you can set to turn audio on, off or toggle.

If you want it to toggle between 2 different volumes however, well this would be more tricky.

What you could do there is have the toggle change a variable and then have profiles triggered by the variable

tasker.wikidot.com/togglewidget
SUroot is offline  
Reply With Quote
The Following User Says Thank You to SUroot For This Useful Post:
D-U-R-X (September 18th, 2012)
Old September 18th, 2012, 12:22 PM   #4 (permalink)
Junior Member
Thread Author (OP)
 
Join Date: Jan 2011
Posts: 29
 
Device(s):
Carrier: Not Provided

Thanks: 8
Thanked 2 Times in 2 Posts
Default

Alright, I bought Tasker and started setting up profiles, so far everything is working like I need it to. I did run into problems with the phone vibrating when I got SMSs in a certain profile, I didn't want this to happen and couldn't figure out how to get it to work in Llama. It turned out to be Handcent overwriting the settings. I uninstalled that and installed GO SMS and now the phone doesn't vibrate when I get an SMS while the "Work" profile is enabled. (Vibrate can be too loud, especially when the phone's sitting on a hard surface)

I do plan on having several profiles set up so toggling them on and off shouldn't be necessary.
MaxPower1 is offline  
Reply With Quote
Old March 14th, 2013, 06:42 PM   #5 (permalink)
New Member
 
Join Date: Oct 2010
Posts: 9
 
Device(s):
Carrier: Not Provided

Thanks: 1
Thanked 1 Time in 1 Post
Default Used "Zoom" for my widgets

With native Tasker, I think you're limited to 1x1 widgets. For something more intricate, you can use Zoom.

Zoom was written by the same guy who developed Tasker. As such, it integrates thoroughly and easily with Tasker: you can run tasks by interacting with widget elements; tasks can modify the appearance and state of widget elements; widgets can monitor variable states and update themselves accordingly. It's pretty intuitive, and not difficult to use, once you get the hang of it.

I used Zoom to create this widget:

Attachment 50964

The buttons all call the same Tasker task when clicked, but each sends a unique parameter, corresponding to Loud, Normal, Quiet or Silent sound profiles. After the task sets the volume levels, it updates the widget speaker icon to reflect the new value, and updates the levels shown in the widget's static text area.

This widget was trivial to implement. By far, the most time consuming piece of it was to draw the speaker and buttons. (BTW, the buttons can be real buttons, rather than crude images, like I have them. In fact, I first implemented the widget with actual buttons, but I wanted to try out the hand drawn images. I liked the rustic look of the images, so I left them. )

As another example, I have a profile that monitors the time of day, to adjust both the sound profile and screen brightness at bedtime, and restores the settings in the morning. Sometimes however, I stay up later than normal. For this reason, I wanted a quick and easy way of overriding the profile behavior.

So, I created this widget:

Attachment 50965

This is very similar to the Silent Toggle widget on the Tasker wiki. When pressed, it simply toggles the value of a certain Tasker variable. I then added an additional state to the profile, requiring the variable to be in its "off" state, in addition to the time-of-day requirement. Finally, I modified my "Set Sound Profile" task to update the widget to the correct override state:

Attachment 50966

(BTW, to create the icons for this widget, I used an app from a different developer called Simple Text-Text Icon Creator)

Definitely check out Zoom if you want to create anything more than a 1x1 widget. It's a great add-on to Tasker that adds tremendously to its usefulness.
IAmHe is offline  
Reply With Quote
Reply


Go Back   Android Forums > Android Discussion > Android Applications > Tasker
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 03:48 AM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.