I have this:
profile- if battery 45-0,
task - then power save on.
I want to add a exit task, which turns off battery save if mobile is plugged in. Can't i add this in the same profile? Can someone detail explain how to do this?
Add a second profile context, "not power any".
To do this, long press on the existing battery context. A pop up will appear, choose add, then state -> power -> power. Select "any" and check the box to invert. Save.
Now whenever your battery is less than 45, and the device is NOT charging, the entry task will run. If the battery level goes above 45 OR the device is charging with the device below 45, the exit task will run.
Just to make sure you know, when in the profile tab, long pressing the entry task (green right facing arrow), pops up a menu where you can add an exit task (red left facing arrow).
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Hi everyone,
I am using tasker a lot of time but I have a problem which I can't solve my own. I am using a nvidia shield with modded Android Tablet os (not lineage but droidmote one). But that's doesn't really matter. I would like to use Amazon video leanback app which isn't displayed in the normal app list but can only be started through settings->apps or with a shortcut on launcher which I use. Therefore Amazon video cannot be found in tasker profiles -> apps. I know that there are plugins for using shortcuts as a task. But I want to select it for a profile - when I quit Amazon video, a task shall be executed.
Do you have any hints for me?
When you add an app context to your profile, have you tried enabling "all" (bottom right of app screen)? Does the Amazon video app show up as an activity or service then?
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Yes, I have tested selecting all but it is not displayed there either
OK, so this thought will be less than optimal, but the shield is running of mains power not battery, right?
There is a variable %WIN, that on some devices, monitors the foreground app. You could monitor that variable for when it becomes the Amazon app, then trigger when it becomes something else.
If %WIN doesn't work on your device, then there is some code you could use to monitor the foreground app using raw dump.
Profile: Test WIN Variable
Event: Variable Set [
Variable: %WIN
Value: *
User Variables Only: Off
Enter: WIN
A1: Flash [
Text: Current WIN - %WIN
Long: Off
A2: Wait [
MS:0
Seconds:6
Minutes:0
Hours:0
Days:0
A3: Run Shell [
Command:su -c dumpsys window windows | grep -E 'mCurrentFocus'
Timeout (Seconds): 0
Use Root: Off
Store Output In: %rawDump
Store Errors In:
Store Result In:
A4: Popup [
Title: Current rawDump
Text: %rawDump
Background Image:
Layout: Popup
Timeout (Seconds): 119
Show Over Keyguard: Off
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
I have tried the win profile but always get another window id when I open the app. What can I do now?
For both the flash action and the pop-up? The flash action uses the app name, the pop-up should contain the package name.
If neither the %WIN variable nor the raw dump finds anything related to Amazon app, then I have no idea how you can identify that it's running.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Here is the output. I meant that the first number behind the brace is always different. The 2nd and 3rd row is identical
But how can i choose it now for profile - setting the value to com.amazon*** ?
The output for flash %win is "Prime Video". I can set that value in profiles but can only select a start task, no exit task which I like to use
How can I do this?
I think you make a profile to act as the exit task. Try setting a variable (e.g. %Prime = true) then having another profile context;
Profile: Test WIN Variable
Event: Variable Set [
Variable:%WIN
Value:*
User Variables Only: off ]
State: Variable Value [
%Prime ~ true ]
Make sure to clear the %Prime variable in that task.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Here is my task
Your suggested profile doesn't work with the task I attached.
Might you help me with an advice?
It's better to share your profile (or both in your case) when it's not working as expected. The exported description provides much more information than a screenshot.
Make sure it's named - not a default name assigned by tasker. To name the profile if it isn't already, long press on the name to highlight the profile and, at the top, tap the square with the A.
Then long press on the name to highlight the profile. Go to the 3-dot menu and select export -> Description to Clipboard.
Now you'll be able to paste it. Be aware, it easier to use pastebin and link to a post here. If you paste in a post here, the forum software will convert all semicolons with characters directly after to emoticons making it very hard to read.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
I have edited the profile like you mentioned in previous post
Profile: Amazon Video (9)
Event: Variable Set [ Variable:%WIN Valuerime Video User Variables Onlyff ]
State: Variable Value [ %Prime ~ true ]
Enter: 24Hz Aus (3)
A1: [X] Variable Clear [ Name:%Prime Pattern Matchingff Local Variables Onlyff ]
A2: Launch App [ App:TVHZ Data: Exclude From Recent Appsff Always Start New Copyff ]
A3: Run Shell [ Command:input tap 1260 260 Timeout (Seconds):0 Use Rootn Store Output In: Store Errors In: Store Result In: ]
A4: [X] Kill App [ App:Netflix Use Rootn ]
A5: Go Home [ Page:0 ]
What sets %Prime to true?
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Nothing so far. What would you suggest to do so?
greys11 said:
Nothing so far. What would you suggest to do so?
Click to expand...
Click to collapse
What I suggested in the first paragraph of the original post (below).
Create a profile whose only job is to recognize when the %WIN matches Prime Video and the associated task sets %Prime = true.
This acts as a mechanism to identify when you have launched the app.
Then, the 2nd profile monitors the %WIN variable for anything but Prime Video and runs the task you want after you exit Prime Video.
The point of the %Prime = true is so the 2nd profile runs only on exit from the video app and not every time the %WIN variable gets set as you go from app to app. You are creating a pseudo exit task.
ktmom said:
I think you make a profile to act as the exit task. Try setting a variable (e.g. %Prime = true) then having another profile context;
Profile: Test WIN Variable
Event: Variable Set [
Variable: %WIN
Value: *
User Variables Only: off ]
State: Variable Value [
%Prime ~ true ]
Make sure to clear the %Prime variable in that task.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Click to expand...
Click to collapse
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
I got it. Many thanks for your help
Is there any possibility in tasker to switch the refresh rate except using the detour over tvhz and input tap command?
Sorry I have no idea.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Do you know the tasker code (keyevent) to emulate the keypad navigation (exiting airmouse mode) ?
I haven't used that in a while Here is a link to a page with a list.
I tend to use the AutoInput root action, but there is also the built in Tasker DPad action.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Thanks for the list. But I can't find the code for the button on rc to switch from touchmode with cursor to keypad mode for leanback interaction. I recently opened a new thread for the issue
Hello friends,
I need your help, actually I want Tasker to automatically take call from specific numbers and wait 5 seconds then Dial 1 and hang up the call. (I will not even want to touch the mobile).
Can any body please guide or make script for me, I'm on Unrooted mobile? Thanks alot
Hi you can use autoinput to select 1.
Inviato dal mio FRD-L09 utilizzando Tapatalk
I don't know how to setup Tasker & Autoinput to take call and Dial 1.
I would be very thankful if some body can write steps here.
I'm on Oreo 8.0
Sent from my ZTE A2017U using Tapatalk
No one here to help ?
Sent from my ZTE A2017U using Tapatalk
There are tutorials galore for these basic functions. You might start with the Tasker Userguide and look for Event -> A-Z -> Phone Ringing.
In the task, you will need to use auto input and the device needs to be rooted. It's easier to use the AutoInput UI Query -> variable setup to grab the correct window for the call.
Using the UI Query action effectively creates a wait until the proper screen is loaded. Better than a wait action, using it allows for a possible variable wait.
Then use the AutoInput Action easy setup feature to grab the correct input to launch the dial pad.
Then an optional wait so the key press is accepted within the call (e.g. for a recorded message to finish)
Finally, a AutoInput Root action to dial the number you desire. One number per AutoInput Root action. You would need 4 AutoInput Root actions to dial a 4-digit PIN code for example.
<wait until main call screen launched>
A1: AutoInput UI Query [
Configuration: App
Package: com.google.android.dialer
Variables: dialer, keypad
Only
Visible: true
Only Clickable: true
Timeout (Seconds):20
<open dialpad from main call screen>
A2: AutoInput Action [
Configuration:
Type: Id
Value: com.google.android.dialer:id/incall_second_button
Action : Click
Timeout (Seconds): 20
<optional wait for proper time to dial>
A3: Wait [
MS: 0
Seconds: 5
Minutes: 0
Hours: 0
Days: 0
<dial the number 2 on dialpad - requires root>
A4: AutoInput Root [
Configurationress Key: 2
Timeout (Seconds):100
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
ktmom said:
There are tutorials galore for these basic functions. You might start with the Tasker Userguide and look for Event -> A-Z -> Phone Ringing.
In the task, you will need to use auto input and the device needs to be rooted. It's easier to use the AutoInput UI Query -> variable setup to grab the correct window for the call.
Using the UI Query action effectively creates a wait until the proper screen is loaded. Better than a wait action, using it allows for a possible variable wait.
Then use the AutoInput Action easy setup feature to grab the correct input to launch the dial pad.
Then an optional wait so the key press is accepted within the call (e.g. for a recorded message to finish)
Finally, a AutoInput Root action to dial the number you desire. One number per AutoInput Root action. You would need 4 AutoInput Root actions to dial a 4-digit PIN code for example.
A1: AutoInput UI Query [
Configuration: App
Package: com.google.android.dialer
Variables: dialer, keypad
Only
Visible: true
Only Clickable: true
Timeout (Seconds):20
A2: AutoInput Action [
Configuration:
Type: Id
Value: com.google.android.dialer:id/incall_second_button
Action : Click
Timeout (Seconds): 20
A3: Wait [
MS: 0
Seconds: 5
Minutes: 0
Hours: 0
Days: 0
A4: AutoInput Root [
Configurationress Key: 2
Timeout (Seconds):100
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Click to expand...
Click to collapse
Thanks alot for the detailed reply. Unfortunately my mobile is not Rooted, Is there a way for Unrooted mobile?
Thnx once again
Farman007 said:
Thanks alot for the detailed reply. Unfortunately my mobile is not Rooted, Is there a way for Unrooted mobile?
Thnx once again
Click to expand...
Click to collapse
Not that I'm aware of.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
ktmom said:
Not that I'm aware of.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Click to expand...
Click to collapse
Will have to try to root my device. Or may be any other friend comes with Unrooted solution.
Thnx man
Sent from my ZTE A2017U using Tapatalk
ktmom said:
There are tutorials galore for these basic functions. You might start with the Tasker Userguide and look for Event -> A-Z -> Phone Ringing.
In the task, you will need to use auto input and the device needs to be rooted. It's easier to use the AutoInput UI Query -> variable setup to grab the correct window for the call.
Using the UI Query action effectively creates a wait until the proper screen is loaded. Better than a wait action, using it allows for a possible variable wait.
Then use the AutoInput Action easy setup feature to grab the correct input to launch the dial pad.
Then an optional wait so the key press is accepted within the call (e.g. for a recorded message to finish)
Finally, a AutoInput Root action to dial the number you desire. One number per AutoInput Root action. You would need 4 AutoInput Root actions to dial a 4-digit PIN code for example.
<wait until main call screen launched>
A1: AutoInput UI Query [
Configuration: App
Package: com.google.android.dialer
Variables: dialer, keypad
Only
Visible: true
Only Clickable: true
Timeout (Seconds):20
<open dialpad from main call screen>
A2: AutoInput Action [
Configuration:
Type: Id
Value: com.google.android.dialer:id/incall_second_button
Action : Click
Timeout (Seconds): 20
<optional wait for proper time to dial>
A3: Wait [
MS: 0
Seconds: 5
Minutes: 0
Hours: 0
Days: 0
<dial the number 2 on dialpad - requires root>
A4: AutoInput Root [
Configurationress Key: 2
Timeout (Seconds):100
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
Click to expand...
Click to collapse
nice. this worked on access gate to property. The guest dials # plus unit number. Gate calls phone. Auto answers and press 9 and it opens the gate.
I have a wall tablet that cannot be rooted so the tasker screen idle function doesn't work.
I read that I can acheive the same thing with autoinputs but I can't figure out how to do it.
Generally, I'd have imperihome always running on the screen. I would like to launch daydream app using daydream launcher if I have not touch the screen for more than 1 minute. Can someone help me out? thanks
I think using create a profile that uses "UI Action" from AutoInput as a context will get you where you want. It should trigger anytime you touch the screen and the associated task contains a wait so if another touch occurs, the task will re-fire and start the wait again. The profile should be configured to abort the existing task for that to work. If the wait completes, then your daydream app can be launched.
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini
There is any way to set a task that will lunch yi home app and than will turn on the camera each time that im leaving home?
Sent from my SM-G950F using Tapatalk
Your choices include using swipe actions to emulate touches, or use intents from the Yi home app. To start learning about intents, Not Enough Tech's post
"find somebody that you think is undeserving of your compassion and give it to them" - Christian Picciolini