Tasker/TasGear samples

Search This thread

edwardsc005

Member
Sep 20, 2011
40
19
Here is another method for sending multiple variables to the gear without root or the use of run shell commands. In my previous example I've showed you how to send variables individually one at a time without erasing other variables in your gear set up. But what if you want to send a lot of variables at once? Run shell command still seems like the best way in this situation vs. sending many different sent intents in a row (even though you could with the previous example). Here is a second method I use, which I also use in conjunction with my first method...
Let's say you have 8 variables that you want to update on the gear at the same time:
%CURRENTTEMP
%TEMPHIGH
%TEMPLOW
%WEATHERCONDITION
%SUNRISETIME
%SUNSETTIME
%WINDSPEED
%WINDDIRECTION

On the PHONE:
Set them all to one variable seperated by @'s, then sent intent that variable to the gear like so:

VARIABLE SET
%WEATHER
to %CURRENTTEMP@%TEMPHIGH@%TEMPLOW@%WEATHERCONDITION@%SUNRISETIME@%SUNSETTIME@%WINDSPEED@%WINDDIRECTION

SEND INTENT
com.orbonis.gear.tasker.MESSAGE_GEAR
EXTRA:
PHONE_WEATHER: %WEATHER

On the GEAR:
Receive the intent and set local variable to a global variable. Then variable split it with splitter "@". You now have an array with 8 values that can be accessed individually.

VARIABLE SET
%P_WEATHER
To
%phone_weather
IF
%phone_weather SET

VARIABLE SPLIT
%P_WEATHER
Splitter: @
Delete Base
IF
%phone_weather SET

You now have:
%P_WEATHER1 = %CURRENTTEMP
%P_WEATHER2 = %TEMPHIGH
%P_WEATHER3 = %TEMPLOW
%P_WEATHER4 = %WEATHERCONDITION
%P_WEATHER5 = %SUNRISETIME
%P_WEATHER6 = %SUNSETTIME
%P_WEATHER7 = %WINDSPEED
%P_WEATHER8 = %WINDDIRECTION

Any of these array values can be used normally as a regular variable in a zooper configuration or whatever you wish to do with them.
 

edwardsc005

Member
Sep 20, 2011
40
19
Full weather replacement for Gear

Here is my current weather replacement set up for the gear.
On the PHONE:

PROFILE 1 (pull weather data every hour)
Add Event>Date/Time>Repeat:every 1 Hour(s)
--->Task "Get Weather"
+
PROFILE 2 (pull weather data on sunrise/sunset times)
Add Event>State>Variables>Variable Value (Conditions: %DAY = %TIME (OR) %DARK = %TIME)
--->Task "Get Weather"

TASK "Get Weather" (Prompt for the Zip Code if one isn't set. Turn on internet if it's not on already and wait a few seconds to establish connection to avoid HTTP Get error...If internet is not working (poor signal) then skip to end of task. Otherwise get data, break it down, store it to a variable and send it to the gear, then turn off internet if it was off to begin with)

1. Show Scene>Name 'Get ZIP'>Display As 'Dialog, Dim Behind Heavy'>Show Exit Button>Continue Task Immediately 'unchecked'>IF %ZIPCODE Isn't Set
2. Test Net>Connection Type>Store Result In '%TEST'
3. Mobile Data>Set On IF %TEST eq none
4. Wait>5 seconds IF %TEST eq none
5. HTTP Get>Server:port 'xml.weather.yahoo.com/forecastrss?p=%ZIPCODE>Continue Task after error checked
6. Goto>Action Number 23 IF %err = 1
7. Variable Split>Name '%HTTPD'>Splitter 'chill='>Delete Base
8. Variable Split>Name '%HTTPD2'>Spliter '"'>Delete Base
9. Perform Task>Name '12HourTime'>Priority '%priority+1'
10. Variable Set>Name '%UPDATED' to 'Updated %12HRTIME'
11. Variable Section>Name '%HTTPD215' From 1 Length 5>Store Result In '%DAY'
12. Variable Section>Name '%HTTPD217' From 1 Length 5>Store Result In '%DARK'
13. Variable Split>Name '%DARK'>Splitter ':'>Delete Base
14. Variable Add>Name '%DARK1'>Value 12
15. Variable Join>Name '%DARK'>Joiner '.'>Delete Parts
16. Variable Split>Name '%DAY'>Splitter ':'>Delete Base
17. Variable Join>Name '%DAY'>Joiner '.'>Delete Parts
18. Variable Set>Name '%SUN' to 'Sunrise: %HTTPD215' IF %TIME < %DAY (OR) %TIME > %DARK (OR) %TIME = %DARK
19. Variable Set>Name '%SUN' to 'Sunset: %HTTPD217' IF %TIME = %DAY (OR) %TIME > %DAY (AND+) %TIME < %DARK
20. Variable Set>Name '%WEATHER' to '%HTTPD21@HTTPD23@HTTPD25@%SUN@%UPDATED@HTTPD219@HTTPD223@HTTPD237@HTTPD239@HTTPD241@HTTPD249@HTTPD251@HTTPD253@HTTPD261@HTTPD263@HTTPD265@HTTPD273@HTTPD275@HTTPD277@HTTPD285@HTTPD287@HTTPD289@HTTPD221@HTTPD243@HTTPD255@HTTPD267@HTTPD279@HTTPD291
21. Array Clear>Name '%HTTPD2'
22. Send Intent>Action 'com.orbonis.gear.tasker.MESSAGE_GEAR'>Extra 'PHONE_WEATHER:%WEATHER'
23. Mobile Data>Set Off IF %TEST eq none

TASK "12HourTime" (Converts the default Tasker time into something a little more readable since nobody uses military time...I was in the military and I don't even use it lol. Also tacks on the current date)
1. Variable Split>Name '%TIME'>Splitter '.'
2. Variable Set>Name '%TIME2' to 'PM'>Append Checked>IF %TIME1 > 11
3. Variable Set>Name '%TIME2' to 'AM'>Append Checked>IF %TIME1 < 12
4. Variable Section>Name '%TIME1' From 2 Length 1>IF %TIME1 < 10
5. Variable Subtract>Name '%TIME1' Value 12>IF %TIME1 >12
6. Variable Set>Name '%12HRTIME' to '%DATE, %TIME1:%TIME2'

SCENE "Get ZIP:378x364" (Prompt for Zip Code...if you want to bring up this prompt at any time just create a new task that calls for it and link that task to a zooper module shortcut or homescreen tasker shortcut)
Element Add>Text>Geometry (77,9)(226x99)>Text 'Zipcode'>Text Size 16
Element Add>Text Edit>MAIN TAB:Geometry (77,132)(226x99), Text Size 18>BACKGROUND TAB: Border Width 5>TEXT CHANGED TAB: 1. Variable Set>Name '%ZIPCODE' to '%new_val'
Element Add>Button>MAIN TAB:Geometry (101,256)(176x107), Label 'SET', Label Size '16'>TAP TAB: 1. Destroy Scene 'Get ZIP', 2. Flash Text 'Zipcode set to: %new_val'


On the GEAR
Include this as part of your Intent Recieved Profile Task (whatever you have called it). I'm assuming you already have a profile set up for receive intent (aka "Battery Example")
TASK 'Whatever'(Mine is 'Phone Updates')
1. IF %phone_weather SET
2. Variable Set>Name '%P_WEATHER' to '%phone_weather'
3. Perform Task>Name 'Weather Update'
4. END IF

TASK 'Weather Update'
1: Variable Split>Name '%P_WEATHER'>Splitter '@'>Delete Base
2: Zooper Widget Pro Variable [ Configuration:realfeal = %P_WEATHER1
3: Zooper Widget Pro Variable [ Configuration:winddir = %P_WEATHER2
4: Zooper Widget Pro Variable [ Configuration:windspeed = %P_WEATHER3
5: Zooper Widget Pro Variable [ Configuration:sun = %P_WEATHER4
6: Zooper Widget Pro Variable [ Configuration:updated = %P_WEATHER5
7: Zooper Widget Pro Variable [ Configuration:ccondition = %P_WEATHER6
8: Zooper Widget Pro Variable [ Configuration:ctemp = %P_WEATHER7
9: Zooper Widget Pro Variable [ Configuration:cdaylow = %P_WEATHER8
10: Zooper Widget Pro Variable [ Configuration:cdayhigh = %P_WEATHER9
11: Zooper Widget Pro Variable [ Configuration:cdcondition = %P_WEATHER10
12: Zooper Widget Pro Variable [ Configuration:tomlow = %P_WEATHER11
13: Zooper Widget Pro Variable [ Configuration:tomhigh = %P_WEATHER12
14: Zooper Widget Pro Variable [ Configuration:tomcondition = %P_WEATHER13
15: Zooper Widget Pro Variable [ Configuration:twodlow = %P_WEATHER14
16: Zooper Widget Pro Variable [ Configuration:twodhigh = %P_WEATHER15
17: Zooper Widget Pro Variable [ Configuration:twodcond = %P_WEATHER16
18: Zooper Widget Pro Variable [ Configuration:threedlow = %P_WEATHER17
19: Zooper Widget Pro Variable [ Configuration:threedhigh = %P_WEATHER18
20: Zooper Widget Pro Variable [ Configuration:threedcond = %P_WEATHER19
21: Zooper Widget Pro Variable [ Configuration:fourdlow = %P_WEATHER20
22: Zooper Widget Pro Variable [ Configuration:fourdhigh = %P_WEATHER21
23: Zooper Widget Pro Variable [ Configuration:fourdcond = %P_WEATHER22
24: Zooper Widget Pro Variable [ Configuration:ctoday = %P_WEATHER23
25: Zooper Widget Pro Variable [ Configuration:today = %P_WEATHER24
26: Zooper Widget Pro Variable [ Configuration:tomorrow = %P_WEATHER25
27: Zooper Widget Pro Variable [ Configuration:twoday = %P_WEATHER26
28: Zooper Widget Pro Variable [ Configuration:threeday = %P_WEATHER27
29: Zooper Widget Pro Variable [ Configuration:fourday = %P_WEATHER28

These values should be pretty easy to decipher. Actions 25 through 29 are the yahoo weather codes. In order to get them to match up with zooper widget I had to make a new Bitmap Icon Set which I've attatched to this post. You can unzip it and replace the Icons in the folder with your own if you wish. Also change the name of them in the config file, then zip the folder and config file back together and place it in the ZooperWidget/IconSets folder on the SD Card. When setting up your zooper widget you add a new module>select Bitmap Icon Set>change the Iconset to 'ZW Tasker Weather Icons', and change the Iconset Mode to either: Current Weather, Today's Weather, Tomorrow's Weather, 2 Days Weather, 3 Days Weather, or 4 Days Weather. I've already edited the default config file to select the correct Icon based on the Yahoo weather codes from Tasker Zooper Configs 24 through 29 so all the hard work is done for you :) I suggest setting the Module On Tap for the 'Current Weather' Icon to a Popup Widgets shortcut (you need the app for that on your gear), and in the Popup Widget setup link that to another zooper widget showing the 5 day forecast like you see in my example pics attatched to the post. I had trouble getting popup widgets to work at first on the gear...you have to select in the options to use the Legacy widget picker or it won't work. I'll leave setting up the zooper widget layout up to you...
 

Attachments

  • Screenshot_2015-03-01-00-23-35.png
    Screenshot_2015-03-01-00-23-35.png
    79.1 KB · Views: 136
  • Screenshot_2015-03-01-13-30-32.png
    Screenshot_2015-03-01-13-30-32.png
    55 KB · Views: 137
Last edited:

edwardsc005

Member
Sep 20, 2011
40
19
SMS

I rarely use the Gear S Voice to send texts either because of loud environments or fear of looking stupid or because it just sometimes can't understand me. So for people who like to type stuff out on the watch I made this set up...and I'm sure you can incorporate auto-voice into it if you want. But regardless it is still good for better sms notifications. It will popup the entire message instead of a fraction of it. Plus it looks better. I've added all the bells and whistles you would expect and then some. To get the full functionality you will need root and sqlite3 installed on your phone. If you don't have root on the phone then you will not be able to retrieve contact book info or sms logs, but you will still be able to receive popup notifications and either reply directly to them or type in phone numbers from memory...just be sure to not include any of the shell commands that need root and the actions that rely on them. But seriously... Root your phone. It takes 5min. If you are worried about tripping a silly knox warranty then I'm shaking my head at you. :/
PHONE----------------------->
Profile: Received text any *,*-----> Task: SMS Send

TASK: SMS Send
*A1: Perform Task [ Name:12HourTime ]
A2: Variable Set [ Name:%SMS To:%12HRTIME|%SMSRN|%SMSRF|%SMSRB ]
A3: Send Intent [ Action:com.orbonis.gear.tasker.MESSAGE_GEAR Extra:pHONE_SMS: %SMS ]
*NOTES*-12hourTime is the same task from my weather set up a few posts back.

TASK: Gear Updates (Intent Received Task).
A1: If [ %gear_number Set ]
A2: Variable Split [ Name:%gear_number Splitter:| ]
A3: If [ %gear_number3 Set ]
A4: For [ Variable:%spam Items:1:%gear_number4 ]
A5: Send SMS [ Number:%gear_number2 Message:%gear_number3 ]
A6: End For
A7: Wait [ Seconds:3 ]
A8: End If
*A9: Variable Set [ Name:%newline To: ]
A10: Run Shell [ Command:sqlite3 /data/data/com.android.providers.contacts/databases/contacts2.db "SELECT display_name FROM raw_contacts, phone_lookup WHERE raw_contacts._id = phone_lookup.raw_contact_id AND normalized_number LIKE '%%gear_number2' LIMIT 1;" Use Root:eek:n Store Output In:%name Continue Task After Error:eek:n ]
A11: Variable Set [ Name:%name To:%gear_number2 ] If [ %name !Set ]
A12: Run Shell [ Command:sqlite3 /data/data/com.android.providers.telephony/databases/mmssms.db "SELECT CASE WHEN type= '2' THEN 'YOUR NAME ' ELSE '%name ' END, strftime('%Y-%m-%d ¥%w (%H:%M)', date/1000, 'unixepoch', 'localtime') AS date, '%newline', body, '%newline' FROM sms WHERE address LIKE '%%gear_number2' ORDER BY date DESC;" Use Root:eek:n Store Output In:%logs Continue Task After Error:eek:n ]
A13: Variable Search Replace [ Variable:%logs Search:¥1 Replace Matches:Mon ]
A14: Variable Search Replace [ Variable:%logs Search:¥2 Replace Matches:Tue ]
A15: Variable Search Replace [ Variable:%logs Search:¥3 Replace Matches:Wen ]
A16: Variable Search Replace [ Variable:%logs Search:¥4 Replace Matches:Thur ]
A17: Variable Search Replace [ Variable:%logs Search:¥5 Replace Matches:Fri ]
A18: Variable Search Replace [ Variable:%logs Search:¥6 Replace Matches:Sat ]
A19: Variable Search Replace [ Variable:%logs Search:¥0 Replace Matches: Sun ]
A20: Send Intent [ Action:com.orbonis.gear.tasker.MESSAGE_GEAR Extra:pHONE_LOGS: %logs ]
A21: End If
A22: If [ %gear_contacts Set ]
A23: Variable Set [Name:%newline To: ]
A24: Run Shell [ Command:sqlite3 /data/data/com.android.providers.contacts/databases/contacts2.db "SELECT display_name, normalized_number FROM raw_contacts, phone_lookup WHERE raw_contacts._id = phone_lookup.raw_contact_id AND normalized_number NOT LIKE '+%' ORDER BY display_name;" Use Root:eek:n Store Output In:%contacts Continue Task After Error:eek:n ]
A25: Variable Split [Name: %contacts Splitter: %newline]
A26: Variable Join [Name: %contacts Joiner:,]
A27: Send Intent [ Action:com.orbonis.gear.tasker.MESSAGE_GEAR Extra:pHONE_CONTACTS: %contacts ]
A28: End If
*NOTES: the variable set for "%newline" is simply hitting return once.
 

Attachments

  • Screenshot_2015-03-15-21-49-55.png
    Screenshot_2015-03-15-21-49-55.png
    40.5 KB · Views: 118
  • Screenshot_2015-03-15-22-04-16.png
    Screenshot_2015-03-15-22-04-16.png
    30.3 KB · Views: 120
  • Screenshot_2015-03-15-21-52-06.png
    Screenshot_2015-03-15-21-52-06.png
    38 KB · Views: 120
  • SMSTasks_Scenes.zip
    10.1 KB · Views: 6
Last edited:
  • Like
Reactions: Brendo

edwardsc005

Member
Sep 20, 2011
40
19
GEAR------------------------>

TASK: Phone Updates (Intent Received Task)
A1: If [ %phone_sms Set ]
A2: Variable Set [ Name:%P_SMS To:%phone_sms ]
A3: Destroy Scene [ Name:SMS Popup ]
A4: Perform Task [ Name:SMS]
A5: End If
A6: Variable Set [ Name:%P_CONTACTS To:%phone_contacts ] If [%phone_contacts Set]
A7: Element Text [ Scene Name:Compose SMS Element:Logs Position:Replace Existing Text:%phone_logs ] If [ %phone_logs Set ]

TASK: SMS
A1: Variable Set [ Name:%INDEX To:1 ]
A2: Vibrate Pattern [ Pattern:0,500,80,200,80,200,80,200 ]
A3: Array Push [ Name:%P_SMS Position:1 Value:%P_SMS ]
*A4: Zooper Widget Pro Variable [ Configuration:#Tcounter# = %P_SMS(#) ]
A5: Variable Set [ Name:%SCENE To:%P_SMS1 ]
A6: Variable Split [ Name:%SCENE Splitter:| Delete Base:eek:n ]
A7: Test Scene [ Name:Compose SMS Test:Status Store Result In:%temp ]
A8: If [ %temp neq visible ]
*A9: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%SCENE3.jpg]
A10: Test File [ Type:Size Data:Tasker/Pics/%SCENE3.jpg Store Result In:%test Continue Task After Error:eek:n ]
*A11: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png] If [ %err = 1 ]
A12: Show Scene [ Name:SMS Popup Display As:Dialog, Dim Behind Heavy Horizontal Position:100 Vertical Position:100 Animation:System Show Exit Button:eek:ff Continue Task Immediately:eek:n ] If [ %POPUP eq Popup On ]
A13: End If
A14: If [ %temp eq visible & %SCENE3 ~ %NUMBER ]
*A15: Variable Set [ Name:%number To:|%NUMBER| ]
A16: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_NUMBER: %number ]
A17: End If
A18: If [ %TEXT eq Speech On ]
A19: Shut Up
A20: Media Volume [ Level:25 Display:eek:ff Sound:eek:ff ]
*A21: Music Play [ File:Tasker/Pics/beep.mp3]
A22: Say [ Text:%SCENE2 says.. %SCENE4 Engine:Voice:default Continue Task Immediately:eek:n ]
A23: End If
*NOTES*
A4 sets your new message count to a zooper variable
A9 sets your contacts pic (create a folder in tasker named pics and fill it with contact pics..rename each of them with the contacts phone number. Example= 2223334444.jpg, also choose a default pic for any received numbers not in your phone book (default.png in my set up)
A15 it is necessary to send phone numbers inside brackets as a send intent or else they will get converted to scientific notation and might come out wrong on the phone side.
A21 you can use a tasker beep action or do like I did and find a more pleasant sounding ding.mp3 to use through a play file command. (starts off a text to speech when turned on)

TASK: SMS Scene
A1: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%SCENE3.jpg ]
A2: Test File [ Type:Size Data:Tasker/Pics/%SCENE3.jpg Store Result In:%test Continue Task After Error:eek:n ]
A3: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png ] If [ %err = 1 ]
A4: Show Scene [ Name:SMS Popup Display As:Dialog, Dim Behind Heavy Horizontal Position:100 Vertical Position:100 Animation:System Show Exit Button:eek:ff Continue Task Immediately:eek:n ]
A5: Variable Set [ Name:%contacts To:1]
A6: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_CONTACTS: %contacts]
*NOTES* - Link this task to a widget in order to access sms to view or create new texts. In my set up this task is linked to a module on tap action for a zooper widget bitmap and the new text count (#Tcounter#) is aligned over top of that in SRC mode.

That's it for tasks...now on to the SCENES...

---------- Post added at 11:04 AM ---------- Previous post was at 10:53 AM ----------

SCENE: SMS Popup 320x320

Element: SMS Body/Text 85,110 235x140, Text: %SCENE4 Vertical Fit Mode: Allow Scrolling

Element: Contact Image 5,110 75x100 %CONTACTPHOTO

Element: NEXT/Button 200,0 120x50
A1: If [ %P_SMS(#) != 0 ]
A2: Variable Add [ Name:%INDEX Value:1]
A3: Variable Set [ Name:%INDEX To:1] If [ %INDEX > %P_SMS(#) ]
A4: Variable Set [ Name:%SCENE To:%P_SMS(%INDEX)]
A5: Variable Split [ Name:%SCENE Splitter:| Delete Base:eek:n ]
A6: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%SCENE3.jpg]
A7: Test File [ Type:Size Data:Tasker/Pics/%SCENE3.jpg Store Result In:%test Continue Task After Error:eek:n ]
A8: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png] If [ %err = 1 ]
A9: Shut Up
A10: Say [ Text:%SCENE2 says.. %SCENE4 Engine:Voice:default Continue Task Immediately:eek:n ] If [ %TEXT eq Speech On ]
A11: End If

Element: PREVIOUS/Button 0,0 120x50
A1: If [ %P_SMS(#) != 0 ]
A2: Variable Subtract [ Name:%INDEX Value:1]
A3: Variable Set [ Name:%INDEX To:%P_SMS(#)] If [ %INDEX = 0 ]
A4: Variable Set [ Name:%SCENE To:%P_SMS(%INDEX)]
A5: Variable Split [ Name:%SCENE Splitter:| Delete Base:eek:n ]
A6: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%SCENE3.jpg]
A7: Test File [ Type:Size Data:Tasker/Pics/%SCENE3.jpg Store Result In:%test Continue Task After Error:eek:n ]
A8: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png] If [ %err = 1 ]
A9: Shut Up
A10: Say [ Text:%SCENE2 says.. %SCENE4 Engine:Voice:default Continue Task Immediately:eek:n ] If [ %TEXT eq Speech On ]
A11: End If

Element: From/Text 0,42 210x70 Text: %SCENE1(newline)From: %SCENE2(newline)%SCENE3:

Element: Text Count/Text 120,0 80x45 Text: %INDEX/%P_SMS(#)

Element: Clear/Button 93,250 110x50 Label: Clear
A1: If [ %P_SMS(#) eq 1 ]
A2: Array Clear [ Name:%P_SMS ]
A3: Zooper Widget Pro Variable [ Configuration:#Tcounter# = ' '(empty space here) ]
A4: Variable Set [ Name:%SCENE To:' |N/A|N/A| '] (empty space on both sides)
A5: Variable Split [ Name:%SCENE Splitter:| Delete Base:eek:n ]
A6: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png]
A7: Variable Set [ Name:%SMS To:0 ]
A8: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_SMS: %SMS]
A9: Else If [ %SCENE2 neq N/A ]
A10: Array Pop [ Variable:%P_SMS Position:%INDEX To Var: ]
A11: Variable Subtract [ Name:%INDEX Value:1 ] If [ %INDEX > %P_SMS(#) ]
A12: Array Process [ Variable:%P_SMS Type:Squash ]
A13: Zooper Widget Pro Variable [ Configuration:#Tcounter# = %P_SMS(#)]
A14: Variable Set [ Name:%SCENE To:%P_SMS(%INDEX)]
A15: Variable Split [ Name:%SCENE Splitter:| Delete Base:eek:n ]
A16: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%SCENE3.jpg]
A17: Test File [ Type:Size Data:Tasker/Pics/%SCENE3.jpg Store Result In:%test Continue Task After Error:eek:n ]
A18: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png] If [ %err = 1 ]
A19: End If

Element: Clear All/Button 210,250 110x50 Label: Clear All
A1: Array Clear [ Name:%P_SMS ]
A2: Zooper Widget Pro Variable [ Configuration:#Tcounter# =' '] (empty space)
A3: Variable Set [ Name:%SCENE To:' |N/A|N/A| '] (empty space both sides)
A4: Variable Split [ Name:%SCENE Splitter:| Delete Base:eek:n ]
A5: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png]
A6: Variable Set [ %INDEX To: 1]

Element: Notify/Button 0,250 85x50 Label: %POPUP
A1: If [ %POPUP eq Popup On ]
A2: Variable Set [ Name:%POPUP To:popup Off]
A3: Else
A4: Variable Set [ Name:%POPUP To:popup On]
A5: End If

Element: Compose/Button 210,50 105x60 Label: Compose
A1: Hide Scene [ Name:SMS Popup]
A2: Destroy Scene [ Name:Compose SMS]
A3: Variable Set [ Name:%SPAM To:1] If [ %SPAM !Set ]
A4: Variable Clear [ Name:%BODY]
A5: Variable Clear [ Name:%NUMBER]
A6: Variable Set [ Name:%NUMBER To:%SCENE3] If [ %SCENE3 neq N/A ]
A7: Variable Set [ Name:%number To:|%NUMBER|]
A8: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_NUMBER: %number]
A9: Show Scene [ Name:Compose SMS Display As:Dialog, Dim Behind Heavy Horizontal Position:100 Vertical Position:100 Animation:System Show Exit Button:eek:ff Continue Task Immediately:eek:n ]
A10: Element Visibility [ Scene Name:Compose SMS Element Match:Contacts Set:False]
A11: Element Visibility [ Scene Name:Compose SMS Element Match:Contact Set:True]
A12: Element Text [ Scene Name:Compose SMS Element:Contact Position:Replace Existing Text:%NUMBER ] If [ %NUMBER Set ]
A13: Element Value [ Scene Name:Compose SMS Element:Contacts Value:1 ]

Element: Text to Speech/Button 0,205 85x50 Label: %TEXT
A1: Shut Up
A2: If [ %TEXT eq Speech Off ]
A3: Media Volume [ Level:25 Display:eek:ff Sound:eek:ff ]
A4: Variable Set [ Name:%TEXT To:Speech On]
A5: Say [ Text:%SCENE2 says.. %SCENE4 Engine:Voice:default:default Stream:3 Pitch:5 Speed:5 Continue Task Immediately:eek:n ] If [ %P_SMS(#) != 0 ]
A6: Else
A7: Variable Set [ Name:%TEXT To:Speech Off]
A8: End If

SCENE: Compose SMS*P:320x320

Element: ContactImage/Image 4,1 60x80 Image: %CONTACTPHOTO

Element: Contacts/Spinner 66,1 176x76 Variable %P_CONTACTS
A1: Element Text [ Scene Name:Compose SMS2 Element:Logs Position:Replace Existing Text: ]
A2: Variable Split [ Name:%tap_label Splitter:| Delete Base:eek:ff ]
A3: Variable Set [ Name:%NUMBER To:%tap_label2]
A4: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%NUMBER.jpg]
A5: Test File [ Type:Size Data:Tasker/Pics/%NUMBER.jpg Store Result In:%test Continue Task After Error:eek:n ]
A6: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png] If [ %err = 1 ]
A7: Variable Set [ Name:%number To:|%NUMBER|]
A8: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_NUMBER: %number]

Element: Show/Button 240,0 80x80 Icon: book
A1: Element Text [ Scene Name:Compose SMS2 Element:Logs Position:Replace Existing Text: ]
A2: Test Element [ Scene Name:Compose SMS2 Element:Contacts Test:Element Visibility Store Result In:%element Continue Task After Error:eek:n ]
A3: If [ %element eq false ]
A4: Element Visibility [ Scene Name:Compose SMS2 Element Match:Contacts Set:True]
A5: Element Visibility [ Scene Name:Compose SMS2 Element Match:Contact Set:False]
A6: Test Element [ Scene Name:Compose SMS2 Element:Contacts Test:Value Store Result In:%temp Continue Task After Error:eek:n ]
A7: Variable Split [ Name:%temp Splitter:| Delete Base:eek:ff ]
A8: Variable Set [ Name:%NUMBER To:%temp2]
A9: Else
A10: Element Visibility [ Scene Name:Compose SMS2 Element Match:Contact Set:True]
A11: Element Visibility [ Scene Name:Compose SMS2 Element Match:Contacts Set:False]
A12: Test Element [ Scene Name:Compose SMS2 Element:Contact Test:Value Store Result In:%NUMBER Continue Task After Error:eek:n ]
A13: End If
A14: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%NUMBER.jpg]
A15: Test File [ Type:Size Data:Tasker/Pics/%NUMBER.jpg Store Result In:%test Continue Task After Error:eek:n ]
A16: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png] If [ %err = 1 ]
A17: Variable Set [ Name:%number To:|%NUMBER|]
A18: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_NUMBER: %number]

Element: Contact/TextEdit 66,1 176x76 Phone Number Max Characters: 10
A1: Variable Set [ Name:%NUMBER To:%new_val ]
A2: If [ %NUMBER > 999999999 ]
A3: Element Text [ Scene Name:Compose SMS2 Element:Logs Position:Replace Existing Text: ]
A4: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/%NUMBER.jpg]
A5: Test File [ Type:Size Data:Tasker/Pics/%NUMBER.jpg Store Result In:%test Continue Task After Error:eek:n ]
A6: Variable Set [ Name:%CONTACTPHOTO To:file:///sdcard/Tasker/Pics/default.png] If [ %err = 1 ]
A7: Variable Set [ Name:%number To:|%NUMBER|]
A8: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_NUMBER: %number]
A9: End If

Element: Reply Text/TextEdit 5,212 310x40
A1: Variable Set [ Name:%BODY To:%new_val ]

Element: Send/Button 120,250 195x50 L:0,0 0x0 Label: Send
A1: Stop If [ %BODY !Set ]
A2: Variable Set [ Name:%number To:|%NUMBER|%BODY|%SPAM|]
A3: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_NUMBER: %number]
A4: Element Text [ Scene Name:Compose SMS2 Element:Reply Text Position:Replace Existing Text: ]
A5: Variable Clear [ Name:%BODY]

Element: Logs/Text 5,83 310x130

Element: Spam/Button 5,250 110x50 Label: Text Bomber
CLICK
A1: Variable Query [ Title:Spam # of times Variable:%SPAM Default:%SPAM]
LONGCLICK
A2: Flash [ Text:Spam reset ]
A3: Vibrate Pattern [ Pattern:0,100,50,100 ]
A4: Variable Set [ Name:%SPAM To:1]
 
Last edited:

edwardsc005

Member
Sep 20, 2011
40
19
I realized the other day looking through the root of my Gear that it has the exact same contacts2.db that is on the Phone...so you can modify this setup to pull contact names and numbers from the Gear with the same Sqlite3 shell command used in the intent recieved portion of Tasker on the Phone. This will save a little battery not having to broadcast two ways to extract what is already on the Gear to begin with.

I like database querys so much that I've found a way to make a facebook app for the Gear using tasker. It doesn't require BT internet tethering and having the actual facebook app installed on the Gear. You just need to set up Push notifications in Facebook to send to email...then set up whatever email you have to sync with the standard Email app (same one that sends email notifications through Gear Manager). Then you can extract database info from that. I have Gmail..but trying to extract directly from the Gmail app only gives you short one line previews. The standard Email app gives you the full messages regardless of length. Since you can make posts and reply directly by email, it won't be hard to put together a fully functional facebook app. I'll post more about this later if anyone is interested...this thread seems kinda dead unfortunately lol.
 
Last edited:

Santaclauswitz

Senior Member
Jan 2, 2014
109
20
I realized the other day looking through the root of my Gear that it has the exact same contacts2.db that is on the Phone...so you can modify this setup to pull contact names and numbers from the Gear with the same Sqlite3 shell command used in the intent recieved portion of Tasker on the Phone. This will save a little battery not having to broadcast two ways to extract what is already on the Gear to begin with.

I like database querys so much that I've found a way to make a facebook app for the Gear using tasker. It doesn't require BT internet tethering and having the actual facebook app installed on the Gear. You just need to set up Push notifications in Facebook to send to email...then set up whatever email you have to sync with the standard Email app (same one that sends email notifications through Gear Manager). Then you can extract database info from that. I have Gmail..but trying to extract directly from the Gmail app only gives you short one line previews. The standard Email app gives you the full messages regardless of length. Since you can make posts and reply directly by email, it won't be hard to put together a fully functional facebook app. I'll post more about this later if anyone is interested...this thread seems kinda dead unfortunately lol.

Dude I'm still very interested in your posts! Keep up the good work! Sorry I've not been around and active, had to reflash the Rom to fix some problems I was having and then I've been away.
 

edwardsc005

Member
Sep 20, 2011
40
19
I'm still looking for a better way to pull facebook notifications from the phone. The problem is that the email push notifications are not instantaneous and I'll get them an hour after the actual posts were made.

Sent from my SM-N900P using XDA Premium 4 mobile app
 

edwardsc005

Member
Sep 20, 2011
40
19
Here is my set up for controlling music on the phone from the gear. There is nothing wrong with the default gear app but this set up offers a lot more. It can be modified to control any music player app on the phone but I have it customized to control Poweramp in particular (best android music app by far in my opinion)...giving options to change shuffle and repeat as well as pick out the eq preset you want, and also show the current track info and the option to delete it from a long press. This is all accomplished from a free tasker app plugin on the Play Store called "Actionbox". There is also a paid app called "AutoShare" that I'm sure would work also.
Something else unique with this set up is that I've added a file browser, so that you can browse through the internal and external SD cards and play files directly from there as well as having the option to longpress and delete them.

On the main screen:
-Long press Play to bring up eq preset selection or Swipe Play to refresh track info if for some reason you lose sync with the phone.
-Tap track info to open file browser or Long press to delete current track
-Long press Shuffle or Repeat to reset to off
-Long Press Volume Up or Volume Down to automatically jump to 15 or 0.

In file Browser:
(Browser always opens up to the folder containing the current playing track, you can then explore internal/external SD from there)
-Tap "..." to select parent directory (I've restricted this browser from going into Root folders...there is nothing to play in there and you wouldn't want to delete anything anyways :/ )
-Tap a folder to open it, tap a file to play it, long press a file to delete it (deleting entire folders does not work in this browser)
-any commas in your file names will throw off the file browser because the way it works is to seperate file paths by a comma...so a song with a comma in it will get split in half and either half will return an error if selected.


ON THE PHONE:

PROFILE: Track
Event: Variable Set [ Variable:%MTRACK Value:* ]
Enter Task: Track Changed
A1: Variable Clear [ Name:%POWERAMP]
A2: Action Box [ Configuration:[PowerAMP]
Current Track Info, |, %POWERAMP]]
A3: Wait Until [ Seconds:1] If [ %POWERAMP Set ]
A4: Send Intent [ Action:com.orbonis.gear.tasker.MESSAGE_GEAR Extra:pHONE_POWERAMP: %POWERAMP]


TASK: Poweramp
A1: If [ %G_MUSIC = 21 ]
A2: Variable Split [ Name:%POWERAMP Splitter:| Delete Base: Off]
A3: Delete File [ File:%POWERAMP1]
A4: Array Clear [ Name:%POWERAMP ]
A5: Variable Set [ Name:%G_MUSIC To:19]
A6: End If
A7: Media Control [ Cmd:previous Simulate Media Button:eek:n ] If [ %G_MUSIC = 18 ]
A8: Media Control [ Cmd:Next Simulate Media Button:eek:n ] If [ %G_MUSIC = 19 ]
A9: Media Volume [ Level:%G_MUSIC ] If [ %G_MUSIC < 16 ]
A10: Media Control [ Cmd:play [Simulated Only] Simulate Media Button:eek:n ] If [ %G_MUSIC = 16 ]
A11: Media Control [ Cmd:pause Simulate Media Button:eek:n ] If [ %G_MUSIC = 17 ]
A12: Stop If [ %G_MUSIC < 30 ]
A13: If [ %G_MUSIC > 30 & %G_MUSIC < 40 ]
A14: Action Box [ Configuration:[PowerAMP]
Shuffle OFF ] If [ %G_MUSIC = 31 ]
A15: Action Box [ Configuration:[PowerAMP]
Shuffle All ] If [ %G_MUSIC = 32 ]
A16: Action Box [ Configuration:[PowerAMP]
Shuffle Songs ] If [ %G_MUSIC = 33 ]
A17: Action Box [ Configuration:[PowerAMP]
Shuffle Categories ] If [ %G_MUSIC = 34 ]
A18: Action Box [ Configuration:[PowerAMP]
Shuffle Songs & Categories ] If [ %G_MUSIC = 35 ]
A19: Action Box [ Configuration:[PowerAMP]
Repeat OFF ] If [ %G_MUSIC = 36 ]
A20: Action Box [ Configuration:[PowerAMP]
Repeat List ] If [ %G_MUSIC = 37 ]
A21: Action Box [ Configuration:[PowerAMP]
Repeat Advance List ] If [ %G_MUSIC = 38 ]
A22: Action Box [ Configuration:[PowerAMP]
Repeat Songs ] If [ %G_MUSIC = 39 ]
A23: End If
A24: If [ %G_MUSIC > 40 & %G_MUSIC < 56 ]
A25: Action Box [ Configuration:[PowerAMP]
EQ Preset, Bass Extreme ] If [ %G_MUSIC = 41 ]
A26: Action Box [ Configuration:[PowerAMP]
EQ Preset, Bass Treble ] If [ %G_MUSIC = 42 ]
A27: Action Box [ Configuration:[PowerAMP]
EQ Preset, Treble ] If [ %G_MUSIC = 43 ]
A28: Action Box [ Configuration:[PowerAMP]
EQ Preset, Flat ] If [ %G_MUSIC = 44 ]
A29: Action Box [ Configuration:[PowerAMP]
EQ Preset, Classical ] If [ %G_MUSIC = 45 ]
A30: Action Box [ Configuration:[PowerAMP]
EQ Preset, Dance ] If [ %G_MUSIC = 46 ]
A31: Action Box [ Configuration:[PowerAMP]
EQ Preset, Rock ] If [ %G_MUSIC = 47 ]
A32: Action Box [ Configuration:[PowerAMP]
EQ Preset, Techno ] If [ %G_MUSIC = 48 ]
A33: Action Box [ Configuration:[PowerAMP]
EQ Preset, Phone Speaker ] If [ %G_MUSIC = 49 ]
A34: Action Box [ Configuration:[PowerAMP]
EQ Preset, Live ] If [ %G_MUSIC = 50 ]
A35: Action Box [ Configuration:[PowerAMP]
EQ Preset, Middle ] If [ %G_MUSIC = 51 ]
A36: Action Box [ Configuration:[PowerAMP]
EQ Preset, Pop ] If [ %G_MUSIC = 52 ]
A37: Action Box [ Configuration:[PowerAMP]
EQ Preset, Soft ] If [ %G_MUSIC = 53 ]
A38: Action Box [ Configuration:[PowerAMP]
EQ Preset, Soft Treble ] If [ %G_MUSIC = 54 ]
A39: Action Box [ Configuration:[PowerAMP]
EQ Preset, Soft Bass ] If [ %G_MUSIC = 55 ]
A40: End If

TASK: Gear Updates (Intent Received)
A1: If [ %gear_music Set ]
A2: Variable Set [ Name:%G_MUSIC To:%gear_music]
A3: Perform Task [ Name: Track Changed] IF [%G_MUSIC = 20]
A4: Perform Task [ Name:poweramp]
A5: End If
A6: If [ %gear_delete Set ]
A7: Delete File [ File:%gear_delete]
A8: Variable Split [ Name:%gear_delete Splitter:/ Delete Base:eek:n ]
A9: Array Pop [ Variable:%gear_delete Position:99 To Var: ]
A10: Variable Join [ Name:%gear_delete Joiner:/ Delete Parts:eek:n ]
A11: Variable Set [ Name:%gear_dir To:%gear_delete ]
A12: End If
A13: If [ %gear_dir Set ]
A14: Variable Set [ Name:%G_DIR To:/%gear_dir]
A15: List Files [ Dir:%G_DIR Match: Use Root:eek:ff Variable:%dir Continue Task After Error:eek:n ]
A16: If [ %err = 1 ]
A17: Action Box [ Configuration:[PowerAMP]
Play File, %G_DIR Continue Task After Error: On ]
A18: Stop
A19: End If
A20: Variable Split [ Name:%G_DIR Splitter:/ Delete Base:eek:n ]
A21: Array Pop [ Variable:%G_DIR Position:99 To Var:%folder ]
A22: Variable Join [ Name:%G_DIR Joiner:/ Delete Parts:eek:n ]
A23: Variable Set [ Name:%dirlist To:...,%dir()|/%G_DIR|%folder ]
A24: Send Intent [ Action:com.orbonis.gear.tasker.MESSAGE_GEAR Extra:pHONE_DIRLIST: %dirlist]
A25: End If

ON THE GEAR:

TASK: Poweramp
A1: Vibrate Pattern [ Pattern:0,100 ]
A2: Variable Set [ Name:%PLAY To:file:///sdcard/Tasker/poweramp/play.png ] If [ %PLAY !Set ]
A3: Variable Set [ Name:%EQPRESET To:Bass,Bass_Extreme,Bass&Treble,Classical,Dance,Flat,Phone_Speaker,Rock,Techno,Treble,Live,Middle,Soft_Bass,Soft,Pop ] If [ %EQPRESET !Set ]
A4: Variable Set [ Name:%SHUFFLE To:31 ] If [ %SHUFFLE !Set ]
A5: Variable Set [ Name:%REPEAT To:36 ] If [ %REPEAT !Set ]
A6: Variable Set [ Name:%VOL To:11 ]
A7: Variable Set [ Name:%music To:20]
A8: Variable Set [ Name:%P_POWERAMP To:Loading...]
A9: Show Scene [ Name:poweramp Display As:Dialog, Dim Behind Heavy Show Exit Button:eek:ff Continue Task Immediately:eek:n ]
A10: Element Visibility [ Scene Name:poweramp Element Match:Track Set:True ]
A11: Element Visibility [ Scene Name:poweramp Element Match:presets Set:False ]
A12: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music ]

TASK: Phone Updates (intent received)
A1: Variable Set [ Name:%P_POWERAMP To:%phone_poweramp] If [ %phone_poweramp Set ]
A2: If [ %phone_dirlist Set ]
A3: Variable Set [ Name:%P_DIRLIST To:%phone_dirlist]
A4: Variable Split [ Name:%P_DIRLIST Splitter:| Delete Base:eek:n ]
A5: Variable Set [ Name:%P_DIRLIST2 To:/%P_DIRLIST3] If [ %P_DIRLIST2 eq /%G_DIR ]
A6: Variable Search Replace [ Variable:%P_DIRLIST1 Search:%P_DIRLIST2/%P_DIRLIST3 Replace Matches:eek:n Replace With:(leave blank)]
A7: Variable Search Replace [ Variable:%P_DIRLIST1 Search:/%P_DIRLIST3 Replace Matches:eek:n Replace With:(leave blank) ] If [ %P_DIRLIST2 eq /%P_DIRLIST3 ]
A8: End If

GEAR SCENES

Scene: Poweramp
Element: Play_Pause/Image
Content: Image: %PLAY
Events:
CLICK:
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: If [ %PLAY eq file:///sdcard/Tasker/poweramp/play.png ]
A3: Variable Set [ Name:%music To:16]
A4: Variable Set [ Name:%PLAY To:file:///sdcard/Tasker/poweramp/pause.png]
A5: Else
A6: Variable Set [ Name:%music To:17]
A7: Variable Set [ Name:%PLAY To:file:///sdcard/Tasker/poweramp/play.png]
A8: End If
A9: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]
LONGCLICK:
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: Element Visibility [ Scene Name:poweramp Element Match:Track Set:Toggle]
A3: Element Visibility [ Scene Name:poweramp Element Match:presets Set:Toggle]
STROKE (Any Direction, Length 40):
A1: Vibrate Pattern [ Pattern:0,40 ]
A2: Variable Set [ Name:%music To:20]
A3: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]
A4: Variable Set [ Name:%P_POWERAMP To:Loading...]

Element: Previous/Image
Image: file:///sdcard/Tasker/poweramp/previous.png
Events:
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: Variable Set [ Name:%music To:18 ]
A3: Variable Set [ Name:%P_POWERAMP To:Loading...]
A4: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music ]

Element: Next/Image
Image: file:///sdcard/Tasker/poweramp/next.png
Events:
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: Variable Set [ Name:%music To:19 ]
A3: Variable Set [ Name:%P_POWERAMP To:Loading...]
A4: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music ]


Element: Volup/Image
Image: file:///sdcard/Tasker/poweramp/volup.jpg
CLICK:
A1: If [ %VOL != 15 ]
A2: Variable Add [ Name:%VOL Value:1]
A3: Variable Set [ Name:%music To:%VOL]
A4: Vibrate Pattern [ Pattern:0,50 ]
A5: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]
A6: End If
A7: Variable Set [ Name:%hold To:%PLAY]
A8: Variable Set [ Name:%PLAY To:file:///sdcard/Tasker/poweramp/%VOL.jpg]
A9: Wait [ MS:400 ]
A10: Variable Set [ Name:%PLAY To:%hold]
LONGCLICK:
A1: Variable Set [ Name:%VOL To:15]
A2: Variable Set [ Name:%music To:15]
A3: Vibrate Pattern [ Pattern:0,100,200,100 ]
A4: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]
A5: Variable Set [ Name:%hold To:%PLAY]
A6: Variable Set [ Name:%PLAY To:file:///sdcard/Tasker/poweramp/%VOL.jpg]
A7: Wait [ MS:500 Seconds:0 Minutes:0 Hours:0 Days:0 ]
A8: Variable Set [ Name:%PLAY To:%hold]

Element: Voldown/Image
Image: file:///sdcard/Tasker/poweramp/voldown.jpg
CLICK:
A1: If [ %VOL != 0 ]
A2: Variable Subtract [ Name:%VOL Value:1]
A3: Variable Set [ Name:%music To:%VOL]
A4: Vibrate Pattern [ Pattern:0,50 ]
A5: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]
A6: End If
A7: Variable Set [ Name:%hold To:%PLAY]
A8: Variable Set [ Name:%PLAY To:file:///sdcard/Tasker/poweramp/%VOL.jpg]
A9: Wait [ MS:400]
A10: Variable Set [ Name:%PLAY To:%hold]
LONGCLICK:
A1: Variable Set [ Name:%VOL To:0]
A2: Variable Set [ Name:%music To:0]
A3: Vibrate Pattern [ Pattern:0,100,200,100 ]
A4: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]
A5: Variable Set [ Name:%hold To:%PLAY]
A6: Variable Set [ Name:%PLAY To:file:///sdcard/Tasker/poweramp/%VOL.jpg]
A7: Wait [ MS:500]
A8: Variable Set [ Name:%PLAY To:%hold ]

Element: Repeat/Image
Image: file:///sdcard/Tasker/poweramp/%REPEAT.png
CLICK:
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: Variable Add [ Name:%REPEAT Value:1 ]
A3: Variable Set [ Name:%REPEAT To:36 Do ] If [ %REPEAT = 40 ]
A4: Variable Set [ Name:%music To:%REPEAT]
A5: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music ]
LONGCLICK:
A6: Vibrate Pattern [ Pattern:0,100,200,100 ]
A7: Variable Set [ Name:%REPEAT To:36 ]
A8: Variable Set [ Name:%music To:36 ]
A9: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]

Element: Shuffle/Image
Image: file:///sdcard/Tasker/poweramp/%SHUFFLE.png
CLICK:
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: Variable Add [ Name:%SHUFFLE Value:1]
A3: Variable Set [ Name:%SHUFFLE To:31] If [ %SHUFFLE = 36 ]
A4: Variable Set [ Name:%music To:%SHUFFLE ]
A5: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music ]
LONGCLICK:
A6: Vibrate Pattern [ Pattern:0,100,200,100 ]
A7: Variable Set [ Name:%SHUFFLE To:31]
A8: Variable Set [ Name:%music To:31]
A9: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]

Element: Track/Text
Text: %P_POWERAMP
CLICK:
A1: Variable Set [ Name:%P_POWERAMP To:/storage/extSdCard/Audio/Music/ ] If [ %P_POWERAMP !Set | %P_POWERAMP eq Loading... ]
A2: Vibrate Pattern [ Pattern:0,50 ]
A3: Variable Split [ Name:%P_POWERAMP Splitter:| Delete Base:eek:ff ]
A4: Variable Set [ Name:%dir To:%P_POWERAMP1]
A5: Variable Split [ Name:%dir Splitter:/ Delete Base:eek:n ]
A6: Array Pop [ Variable:%dir Position:99]
A7: Variable Join [ Name:%dir Joiner:/ Delete Parts:eek:n ]
A8: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra: GEAR DIR:%dir]
A9: Show Scene [ Name:FileBrowser Display As:Dialog, Dim Behind Heavy Show Exit Button:eek:ff Continue Task Immediately:eek:n ]
A10: Array Clear [ Name:%P_POWERAMP ]
LONGCLICK:
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: Menu [ Title:Delete File? Background Image: Layout:IconAndTextMenu Timeout (Seconds):30 Show Over Keyguard:eek:n Items:(2) ]
1.Cancel (default-checked)= Destroy Scene Menu
2.Delete = Variable Set %music to 21
A3: Stop If [ %music != 21 ]
A4: Vibrate Pattern [ Pattern:0,100,50,100 ]
A5: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music ]
A6: Variable Set [ Name:%P_POWERAMP To:Loading...]

Element: Presets/Menu
Source: Variable: %EQPRESET
A1: Vibrate Pattern [ Pattern:0,50 ]
A2: Variable Set [ Name:%music To:%tap_index+40 ]
A3: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_MUSIC: %music]
A4: Element Visibility [ Scene Name:poweramp Element Match:presets Set:False ]
A5: Element Visibility [ Scene Name:poweramp Element Match:Track Set:True ]


Scene: FileBrowser
Element: FileBrowser/Menu
Source: Variable: %P_DIRLIST1
Selection Mode: None
Events:
CLICK:
A1: Vibrate Pattern [ Pattern:0,40 ]
A2: Variable Set [ Name:%dir To:%P_DIRLIST2] If [ %tap_index = 1 ]
A3: Variable Set [ Name:%dir To:%P_DIRLIST2/%P_DIRLIST3%tap_label] If [ %tap_index != 1 ]
A4: Variable Set [ Name:%dir To:/%P_DIRLIST3%tap_label] If [ %tap_index != 1 & %P_DIRLIST2 eq /%P_DIRLIST3 ]
A5: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_DIR: %dir]
LONGCLICK:
A1: Vibrate Pattern [ Pattern:0,40 ]
A2: Variable Set[Name:%temp To:%P_DIRLIST2/%P_DIRLIST3%tap_label]
A3: Menu [ Title:Delete File? Background Image: Layout:IconAndTextMenu Timeout (Seconds):31 Show Over Keyguard:eek:n Items:(2) ]
1. Cancel (default-checked) = Destroy Scene Menu
2. Delete = Variable Set %delete to %temp
A4: Stop If [ %delete !~ %temp ]
A5: Vibrate Pattern [ Pattern:0,100,50,100 ]
A6: Send Intent [ Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST Extra:GEAR_DELETE: %delete]

Element: Header/Text
Text: %P_DIRLIST2/%P_DIRLIST3
 

Attachments

  • Screenshot_2015-04-02-11-37-27.png
    Screenshot_2015-04-02-11-37-27.png
    45 KB · Views: 162
  • Screenshot_2015-04-02-11-37-40.png
    Screenshot_2015-04-02-11-37-40.png
    19.1 KB · Views: 160
  • Screenshot_2015-04-02-11-37-54.png
    Screenshot_2015-04-02-11-37-54.png
    26.8 KB · Views: 160
  • tmp_17063-PwrampScenesTasks1660578650.zip
    119.2 KB · Views: 17
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 6
    Post your ideas and thoughts for others

    Required apps:
    TasGear: http://xdaforums.com/showthread.php?t=2707248
    Tasker (PAID): https://play.google.com/store/apps/details?id=net.dinglisch.android.taskerm

    NOTE: Tasker is a very complex, yet rewarding app. I'd suggest reading up on tutorials (a few links in post 2) and playing around with profiles/tasks/variables before attempting examples below
    6
    A simple example is Gear Battery displayed on Phone
    I use ZooperWidget (there is a FREE version available too)
    Make sure you've enabled external access in Tasker preferences

    Widget.jpg

    Phone:
    - Add new Profile
    - Event -> System -> Intent Received
    Action:com.orbonis.gear.tasker.MESSAGE_RECEIVED
    - Add new Task
    P_Task.png
    A1) Variable Set
    %G_BATT to %gear_batt
    A2) Plugin, Zooper, configuration
    Z_Var.png
    ZW Variable g_battery
    ZW Text %G_BATT
    Save

    Watch:
    - Add new Profile
    - Event -> Display -> Display On
    - Add new Task
    - Misc -> Send Intent
    Action:com.orbonis.gear.tasker.consumer.MESSAGE_HOST
    Extra: GEAR_BATT:%BATT

    (Note: there is not meant to be a space between o and s of HOST)
    (Note: some users found that inserting a space between the : and % of the extra helps)

    Widget:
    Z.png
    Layout -> Rich Text
    Edit text manually
    #Tg_battery#

    Eg.
    Gear Battery: #Tg_battery#%
    This displays:
    Gear Battery: 54%
    5
    So, I've not tested this, but in theory, phone battery on gear should look like this:

    Phone:
    - Add new Profile
    - Event -> Display -> Display On
    - Add new Task
    - Misc -> Send Intent
    Action: com.orbonis.gear.tasker.MESSAGE_GEAR
    Extra: PHONE_BATT:%BATT


    Watch:
    - Add new Profile
    - Event -> System -> Intent Received
    Action: com.orbonis.gear.tasker.consumer.MESSAGE_RECEIVED
    - Add new Task
    A1) Variable Set
    %P_BATT to %phone_batt
    A2) Plugin, Zooper, configuration
    ZW Variable p_battery
    ZW Text %P_BATT
    Save

    Widget:
    Layout -> Rich Text
    Edit text manually
    #Tp_battery#

    This is how it works:
    %BATT = 98%
    PHONE_BATT = %BATT
    %P_BATT = %phone_batt
    p_battery = %P_BATT


    EDIT: I've tested this and to make it work, you need to select the VAR section of tasker on watch and enter a value into %P_BATT. For some reason a tasker variable will only be set into this variable if there is previous data to overwrite (looks to be Tasker issue). You may also have to exit all the way out of tasker after setting up task on watch
    5
    I have few that I use that are pretty basic but if you are interested I'll post how I did it.

    - Turn my pc on or off from my gear.
    - Silence my phone - sends me a notification letting me know if the phone is in fact in silent mode.
    - Phone battery - my gear speaks my phone battery level. I downloaded the hd British male voice so it sounds like jarvis. He says "my reserves are at 'blank'% sir" also if my battery is above 90% he'll say "very good sir" and if it's below 30% he'll say "I could do with a little more juice sir"
    - Take a picture with my phones front camera.
    - Then for a prank I can hide my phone and then have it play fart sounds controlled remotely from my gear. It makes for a good laugh. I've scared my wife with it a bunch.

    Sent from my SPH-L900 using XDA Premium 4 mobile app