yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] comzone:
Oh.. Okay i will do all your suggestions.. And i will let you know later..

Yeap, i am using greenify, and auto hibernation is active. Does it interfere tasker's function?

Can i use both greenify and tasker with this thread files?

Hehehe show me the light :3 thanks
[Android Apps and Games] jdegreef:
Greenify is needed by this script and yes you can use both.

When you go to Task Edit Screen off (Data) do you see some german text on Action 2 ?

BTW, don't say thanks, click on the "Thanks" button situated at the bottom left of every post :D

Keep me posted.

---------- Post added at 08:20 PM ---------- Previous post was at 08:12 PM ----------

Siglost and Sigreturn are needed for this script to work.

You get the triangle because you didn't install "Secure Settings" that are needed by this (great) script.

You should also install Greenify.

Please go to OP and read it carefully, everything is explained there.

Now, if you just need to have data off when screen is off just create a simple script that achieves this.

If you use Android post 4.2;x you won't need Secure Settings as I understood from the OP.
[Android Apps and Games] comzone:
Hey sorry lol .. Ya i hit the button thanks now ;) hehehe

Ah thats nice i can also use greenify hehe

Yes i see the german text on the script, what should i do with that?

Btw its working now but not all.. The internet 3G doesnt turn off when the screen off.. When i check the RunLog.. It says that screen off (data) exerr.. I guess thats error :/
[Android Apps and Games] jdegreef:
Concerning the german text and depending on the language of your system (if it is german you have nothing to do) you have to recreate these actions (n° 2 in Screen Off (Data) and Screen Off (Wifi)

How :

Long press the action line to select it.

In menu choose Insert Action

Choose plugin then the equivalent of "Hibernate Now" in your language.

Then click the pencil (right of the creen) and select "All greenified apps"

Keep the defaults for the rest.

When finished, select the german line and cut it (there's no delete icon).

Done

I think this should solve the error you have.

Let me know.
[Android Apps and Games] comzone:
Heeeeyyyyyy .... I did it ! Wohooo, thanks, it's working now ;) :D :*
[Android Apps and Games] sohojmanush:
There is an app on the play that can do the thing.But its a bit pricey and I need tasker to geo fence my ringer settings,so why bother with two different apps where as one can do the both. All I need is a profile that ran every night at a predefined time,disables wifi and data if data usage is lower then threshold.Turns on data/wifi at specific interval,and turns it back to off till the time scheduled.And turns it back incase user is present.This profile is too complex..thnx though
[Android Apps and Games] allo_87:
I had already install secure settings when i posted. Numerous times I've gone back and uninstalled all the tasker profiles and tasks, imported them again and still nothing.

Tried uninstalling tasker after removing them and starting from scratch, still nothing. No matter what I do, siglost and sigreturn still show the error.

http://imgur.com/BfG0A8e

I'm on a Moto x if that makes a difference
[Android Apps and Games] ViliX64:
It seems like a great solution for battery drain. What are the scripts based on?
[Android Apps and Games] jdegreef:
I dont think you phone model is the problem.

Please post a screen shot of your entire task screen and of what you have when you click on SigLost and SigReturn tasks.

---------- Post added at 02:48 AM ---------- Previous post was at 02:45 AM ----------

Read OP.
[Android Apps and Games] allo_87:
http://imgur.com/Bfe5Fdb

http://imgur.com/At5SNvF

http://imgur.com/MuuA4bt
[Android Apps and Games] jdegreef:
Well, you did not import everything !

From the battery profile screen, delete the entire battery project and reimport Battery.prj.xml.

And now I'll go to sleep [emoji6]
[Android Apps and Games] allo_87:
I literally have no battery.prj.xml that tasker can see.

Root file explorer sees it on the projects folder but when I browse there with tasker (using import) it is empty.

Downloading files again gives the same result.
[Android Apps and Games] greyhd:
Make sure the projects are in the tasker folder which you can copy using root file explorer, then import the project using the tasker app.
[Android Apps and Games] allo_87:
It's in the tasker folder in a folder called projects. All the other things are in tasks i believe...
[Android Apps and Games] greyhd:
Did you extract them directly to the tasker folder? Make sure you extract only the project folder.
[Android Apps and Games] allo_87:
Extracted again, tasker still doesn't see it.
[Android Apps and Games] greyhd:
Do you have beginner mode unchecked? Can you take a screenshot of which folder you are extracting from the zip?
[Android Apps and Games] allo_87:
Beginner mode! Let me try this

---------- Post added at 09:50 AM ---------- Previous post was at 09:36 AM ----------

http://imgur.com/O0Z80wl

http://imgur.com/DBzFMM9

---------- Post added at 09:51 AM ---------- Previous post was at 09:50 AM ----------

http://imgur.com/PxZjTm9
[Android Apps and Games] greyhd:
What I notice is that you do not have a profiles folder.Try this, at the bottom of the tasker home screen, hold the + and a House icon should show up, press that and click on Import.
[Android Apps and Games] allo_87:
DING DING DING!!!!! Thank you SO much for helping :D
[Android Apps and Games] greyhd:
Glad you were able to import the profiles.
[Android Apps and Games] jdegreef:
Glad to read this [emoji2]

---------- Post added at 01:36 AM ---------- Previous post was at 01:31 AM ----------

Me too. [emoji2]

[MENTION=993470]allo_87[/MENTION] : now don't forget to install Greenify and modify the script as explained in my post above (#324).

And don't forget to press the "Thanks" button [emoji106]
[Android Apps and Games] allo_87:
Done and done. Thank you guys so much for the help!!

No errors, no German, just gotta greenify a couple apps and she's good to go :cool:
[Android Apps and Games] jdogzilla:
I've made a couple of modifications to the script to suite my requirements.

For one, I don't want data to connect on display on but on display unlocked. However, I realize the tasker is not able to detect display unlock half the time until I turned the priority up to high. Any other suggestions?
[Android Apps and Games] ShagoY:
With secure settings?

Envoyé de mon SM-T700 en utilisant Tapatalk
[Android Apps and Games] sohojmanush:
All credit goes to [MENTION=4872628]parthipanramesh[/MENTION]. I just modified the profiles and added specific time on the profiles and removed Night weekdays and Night weekend.And added a simple profile to turn on everything when the profile exits.Also inreased the autosync time interval due to high battery drain.Here is a link of the modified profiles xml files :D

https://www.dropbox.com/s/jaf9v0hnkj046h0/BatteryLite.prj.xml
[Android Apps and Games] jdogzilla:
Cool ... will try this out ... also is there a way to set display (data) to be on upon Display Unlock and not Display On? I tried it but then it didn't seem to have an option for exit task.
[Android Apps and Games] sohojmanush:
Data on when display on feature is up to OP... I couldnt find any settings that indicates display unlocking :(
[Android Apps and Games] jdegreef:
What's the point to have display on when phone is locked ?

Anyway, you have "display unlocked" in the display event category,
[Android Apps and Games] seking:
cell standby profile & wifi data traffic

This one is very good while travelling. While travelling the phone always searches for network resulting in tremendous battery drain. This will be a useful. Another one is wifi traffic. This I will modify to use to tell me when the net has become slow so that I could take action:). Some times we think that something is downloading but when we look it is stuck because net has become slow. Thanks alot
[Android Apps and Games] Superm@π:
I imported the profiles and tasks but I'm confused with what to do with the "projects" file. Could someone advise me what to do with it? Thanks!

.........also, how could I safely delete the WiFi auto on when screen on feature without affecting everything else?
[Android Apps and Games] granets:
It's stated in the OP what to do with the projects file. You copy it to the projects folder in tasker and then you long press on the home button at the bottom left and import it. But I have to say those profiles don't work right... I try to download something and as soon as I turn off my screen the wifi cuts off. Sometimes WiFi is disabled when screen is on?!?! I think there is something wrong with the tasks that are being run, But I'm still a noob. I'll try and check on them later to try and fix the problem.

Also another comment - As far as I can see, things are done rather dirty with those profiles. I'll try and improve and report back.
[Android Apps and Games] Superm@π:
That's awesome! Thanks!
[Android Apps and Games] jdegreef:
Just turn the task off.

---------- Post added at 02:29 AM ---------- Previous post was at 02:20 AM ----------

In screen off action hibernate is done before checking if wifi connection is active, that might be the problem.
[Android Apps and Games] Superm@π:
Can hibernate be simply moved down the list somewhere without screwing up the whole action? I'm terrified to screw with the process.
[Android Apps and Games] jdegreef:
What was the program you were using to download when wifi went off ?

Was it a program that was greenify-abled ? If yes, remove it from Greenify and see if it solve the problem.

Or

Long press on the action (nr 2, hibernate now) to select it and click on the power button icon (top left, second from right). This will disable the action. If it solve the problem you know hibernate is the problem and I would move it (cut>paste) inside the if loop (below action 13).
[Android Apps and Games] BNEV:
Hi, I love this profile, but I'm having a problem. I've installed this, and screen off(wifi) works fine, but not screen off(data). I lowered line 11to %DIFF_MOBILE<1, and it still doesn't keep the data on. Any ideas on how to fix this? Thanks
[Android Apps and Games] jdegreef:
You shouldn't move things unless you really know what you do or you'll break the script.

What do you mean by "it still doesn't keep the data on." ? When ? With screen off or on ?

Please give more information on what you try to achieve.
[Android Apps and Games] BNEV:
I have deleted things that deal with airplane mode and the German greenify. I like listening to Tunein Radio. When I’m at home connected to WIFI, it’s not a problem. However, when I am using data, my internet keeps turning off. The problem is in this script, I believe, or it’s where my phone stores the information for the data. Here’s the script I have running for Screen Off (Data).

1.	Run Shell(I’m not gonna type the whole command for each one as I didn’t change them from the original)

2.	Variable Set %CHECKA_MOBILE To 0 with If !Set

3.	Variable Convert

4.	Wait 30 seconds

5.	Run Shell

6.	Variabe Set %CHECKB_MOBILE To 0 with If !Set

7.	Variable Convert

8.	Wait 2 seconds

9.	Variable Set %DIFF_MOBILE To %CHECKB_MOBILE-%CHECKA_MOBILE Do Maths

10.	If %DIFF_MOBILE <15 Labeled Data

11.	Mobile Data Set Off If %SCREEN ~ off

12.	Stop Task Screen off(Data)

13.	Else

14.	Wait 2 minutes

15.	Goto Type Action Number Number 1

16.	End If

This looks the same as the screen off(wifi) task with the only differences being that it’s %CHECKA_WIFI and %CHECKB_WIFI instead of MOBILE. When I’m using wifi, it stays on. When I hit the play button for the WIFI script the IF %DIFF_WIFI<15 turns red. When I hit play for the Screen Off(Data) task, line 10 stays green. Even when I change 15 to 1 it stays green. However, when I change the 15 to 0, it turns it red. So, I believe that the problem is with the %CHECKA or %CHECKB or $DIFF lines(either line 2, 6, or 9), or the information is stored in a different location. I’m using Android version 4.2.1. Thanks for the help.
[Android Apps and Games] jdegreef:
I need to look at this and I'll be back after the weekend.
[Android Apps and Games] cornelito:
When screen goes off, it turns WIFI / DATA off but for some reason after i turn my screen on, WIFI or DATA will not switch back on ?

Why is that ?

Thx
[Android Apps and Games] jdegreef:
[MENTION=6000451]BNEV[/MENTION]

Sorry for the delay...

I've installed TuneIn Radio (great app btw) and I cannot reproduce your problem.

Could you try to generate a log file (here's how http://tasker.dinglisch.net/userguide/en/faqs/faq-how.html#x2) and post it here ?

---------- Post added at 07:48 PM ---------- Previous post was at 07:46 PM ----------

[MENTION=5004275]cornelito[/MENTION] : same remark, could you generate a log file ?
[Android Apps and Games] jdegreef:
I think I've found the problem.

Too late here today (01:21 am) il explain tomorrow.
[Android Apps and Games] jdegreef:
[MENTION=5004275]cornelito[/MENTION] and [MENTION=6000451]BNEV[/MENTION] are you still reading this thread ? I asked for log files and get nothing.

I think I found a solution for your problems but I need log files to confirm it.

II feel like you've abandoned this thread right after asking your question.
[Android Apps and Games] BNEV:
Yes, thanks. I've been extremely busy. I'll post them either late tonight or tomorrow. Thanks for the help.
[Android Apps and Games] jdegreef:
That's what I thought, the "cat sys/class/net/rmnet0/statistics/rx_bytes" gives an error.

Why ? Because your data device is not "rmnet0".

Here, in my Galaxy One Plus (trebon, gt-s7500).my data device is pdp0.

Replacing rmnet0 with pdp0 in the two cat shell command in Screen Off (Data) solved the problem.

It's now up to you to find what's your data device.

By doing a "ls /sys/class/net" from a terminal or ADB shell, first with data turned off and then with data turned on you should be able to find what device is added and correspond to your data device.

Replacing "rmnet0" with what you found, in the two cat command in Screen Off (Data) should solve your problem.

Not sure this is very clear, see it as an end of the week post :)
[Android Apps and Games] BNEV:
Thanks. I thought something like that might be the problem. Not ssure that I understand your solution, but I'll try and figure it out tomorrow. Thanks.
[Android Apps and Games] BNEV:
Thanks. I had no idea what you meant with the ls, but google helped interpret it, and I found it, and it now works! Thanks for the help!
[Android Apps and Games] jdegreef:
You're welcome.

(I don't now why but a got no email telling me you had quoted me...)
[Android Apps and Games] jim.j:
Hey, rmnet0 gives me 0 as result everytime even when I leave something for download. Using Nexus 7 LTE..

I have rmnet0 to 7, rev_rmnet0 to 8, rmnet_smuxO/usb0-4 along with lo. All of them have return 0 except lo. But the values in lo changes quite slowly to the amount that is being downloaded. Any help?
[Android Apps and Games] jdegreef:
What do you mean "I have rmnet0 to 7, rev_rmnet0 to 8" ?

lo is your loopback device. It has nothing to do with download from external site.

Do "ls /sys/class/net" from a terminal or ADB shell, first with data turned off and then with data turned on. You should be able to find what device is added and correspond to your data device.

That's the one used for data thus for downloading.

Replace the 2 "cat sys/class/net/[found device]/statistics/rx_bytes" where [found device] is the device you've found.
[Android Apps and Games] BigMacca:
Has anyone got the autosync profile working on 4.4?

I've imported all the tasks and the autosync profile (i'm assuming that i don't need the other profiles), replaced the German hibernation with the English one and altered the directory of statistic file to "sys/class/net/rmnet_USB0/statistics/rx_bytes".

However, the profile doesn't always seem to activate when the screen is off (nothing in the log) and when it does it's leaving my wifi disabled.....

:confused:
[Android Apps and Games] BigMacca:
Ok, it looks like you do need all the profiles in the v1.3 zip (I should have just read the opening post more carefully) - but one of the tasks references two tasks that aren't included in the v1.3 zip but I found them in the Cell_Standby_v1.0.zip.

So I think I've got everything working, let's see what happens......
[Android Apps and Games] MarcoKun:
I've got this to work today on my Galaxy Note N7000, although it seems that sometimes when I turn off my screen the WiFi does turn off but the data doesn't. Why would that be?

As far as I understand, when you turn on the screen and WiFi doesn't connect it turns it off and leaves data on. Would it be beneficial for the battery to turn data off whenever WiFi does connect?

Marco
[Android Apps and Games] grim_ripper:
I seem to be having trouble getting the profile to work. Have imported both 1.0 cell standby and 1.3 but am having issues. With cell standby, my phone enters airplane mode even with screen on so I deleted the project but left the contents, also disabled all three profiles in it. Seems to fix airplane mode but I can't get data or wifi to switch off when screen is off. Not sure of this is a Lollipop issue, but I have tried the ls cmd with data off and on, there's no difference in the list. Please advice (am not familiar on how to get the log file)
[Android Apps and Games] cipry189:
Unfortunately v1.3 does not work very well on Lollipop, but it's a good project for me to diagnose and learn what went wrong :) cheers
[Android Apps and Games] Uberharm:
Toggle Data 5.0

I found out that I had to replace "data on/off/toggle" by a plugin called Toggle Data 5.0

Now all my old scripts are working again. And if other stuff stopped working? what parts of it?
[Android Apps and Games] Antimon1:
Hi, for the last few days I've been struggling with the Tasker. I'm using it mainly for battery saving and I have managed to make the part of it work correctly. But I'm having issues with the night mode saving, it doesn't turn off data, I mean, it turns it off firstly, but during the night it turns it on sporadicaly. Everything else turns off, wifi and sync, just data keeps messing with my sanity. During the day, Tasker turns on data and sync every 30min for 2min and works like a charm. I have done everything by the book, installed secure settings, watched bunch of videos, read treads but I got lost among it all and I'm still not very familiar with the Tasker and if someone knows how and is willing to help me, it would be very nice if he/she could describe it by steps, for dummies like. I just need a small, simple night saving mode but it just does not want to cooperate with me. I'm running on 4.2.2., rooted, installed xposed installer, greenify etc. Thanks
[Android Apps and Games] Big Foot:
I can follow what you're saying to do in the terminal, but I just want to double check my set up, to make due I'd have the right data device for my phone (Oneplus One)

Below is the attachment of what I get from the command terminal.
[Android Apps and Games] lucky58:
+1
[Android Apps and Games] bluesfear:
I can make it so that when display is off, it will auto sync every 15 minutes, but then I don't know how to make it enable wifi (if wifi is connected) or data on top of the profiles from the first post...any help?
[Android Apps and Games] parthipanramesh:
Do you mean with "Auto Sync" the Google Synchronisation thing or just to check for new messages and stuff like that?
[Android Apps and Games] bluesfear:
yeah auto sync the google sync thing. The profile i made isn't working when screen is off (for obvious reason), i don't know how to make it so that it turns on wifi (if wifi connection is present) or data at an specific interval to turn on auto sync for like few minutes before turning auto sync off.
[Android Apps and Games] parthipanramesh:
How did you made your profile? Could you export the profiles and tasks? So that I can have a look at them to help you? :)
[Android Apps and Games] bluesfear:
i just added a new profile that does auto sync every hour on top of the profiles you made :P

so its not working probably lol, i am a noob
[Android Apps and Games] ruvort:
Re: Tasker solution: Screen off=wifi/data off if no traffic

I love this profile. Works flawlessly :) I was curious if a nighttime profile could be added? Example: Between 1am to 6am the phone is in airplane mode when the screen is off.

Huge Wallpaper Collection
[Android Apps and Games] parthipanramesh:
Create:

Task:

Name: Whatever-0

1. Perform task: Display (Wifi)

2. Wait 30 seconds

3. If: %CONNECTION !~1

4. Enable mobile data

5. End if

6. AutoSync → on

7. Wait 2 minutes

8. Perform task: Screen off (Data); if: %CONNECTION !~ 1

9. Perform task: Screen off (Wifi); if %CONNECTION ~ 1

Now add to the tasks Screen off (Data) and Screen off (Wifi) between Action 12 and 13:

12.5. AutoSync → off

Profile:

Name: Whatever

Context: State → Display off

Time → Repeat every xx minutes

Task: Whatever-0

Thanks for your positive feedback! :)

I'm working on it ;)
[Android Apps and Games] bluesfear:
thank you so much, do I disable any of the profiles that you made I imported?

EDIT: I tried it out, but it doesn't seem to turn autosync off once it's on?
[Android Apps and Games] rignfool:
Re: Tasker solution: Screen off=wifi/data off if no traffic

Missing...

Step 7a: Auto sync off
[Android Apps and Games] parthipanramesh:
I'll try it later on my device. Please be a little bit patient.

EDIT: Try the profiles/tasks which are attached to this post. ;)

Hope this will fix your issue!! :)
[Android Apps and Games] aspencer07:
parthipanramesh, thanks 100x!

This is so great I can't believe it, my gs3 lasts a full day away from a charger!!!

I have found that my wifi/data shuts off between songs on Pandora, which stops the music. (It seems Pandora doesn't constantly use data, only when it is loading a new song.)

The time in tasks 3.1.5 (and 3.2.5) of 30sec is time spent monitoring traffic right? If I increased that to 4-5 minutes would that give it enough time to see that a data connection is still active?

Sorry, I hate to ask you for advice in changing your own creation to fit my needs...
[Android Apps and Games] parthipanramesh:
First thanks for you positve feedback!! Yes you're right. Just increase the 30 seconds. It's ok to ask!!
[Android Apps and Games] ruvort:
Re: Tasker: Screen off=wifi/data off (no traffic)+Night Mode / Power Saver:Mobile Sta

I can't seem to get the airplane mode one to import....is there a way you can upload it as prf.xml and tsk.xml files?

EDIT: scratch that. I just needed to disable beginner mode. Looks good so far :)

Huge Wallpaper Collection
[Android Apps and Games] parthipanramesh:
How to import *.prj.xml files:

Unzip the *.prj.xml file in your Tasker/projects directory and then import it in Tasker by long-clicking the home icon or any of the other tabs. If you don't have the home tab, swipe down from the top in Tasker to show the tabs. (beginner mode must be disabled!)

EDIT: Ok. :)
[Android Apps and Games] bluesfear:
Do I keep the profiles from your OP active as well or disable them?
[Android Apps and Games] ruvort:
Re: Tasker: Screen off=wifi/data off (no traffic)+Night Mode / Reduce Cell-Standby

Do the tasker auto sync files incorporate both the auto sync and data off while screen off?

Huge Wallpaper Collection
[Android Apps and Games] parthipanramesh:
It doesn't matter. It's up to you. You can remove them if you don't need them.

Yes.
[Android Apps and Games] ruvort:
Re: Tasker: Screen off=wifi/data off (no traffic)+Night Mode / Reduce Cell-Standby

I figured but wanted to make sure. I submitted a link to this thread in one of the kernel optimization threads I frequent. Hopefully you don't mind :) It's full of people who are looking to get the most out of their phones and I think these profiles will truly benefit them. You definitely deserve these to be seen by a wider audience as well.

Huge Wallpaper Collection
[Android Apps and Games] parthipanramesh:
Ok thank you very much for your support, ruvort!!! :)