Re: Disable Lock Screen on Home WiFi

6,688 views
Skip to first unread message

Brad Minion

unread,
Jan 8, 2013, 3:58:21 PM1/8/13
to tas...@googlegroups.com
You could do it in one profile if you want. Because I want the lock screen disabled when I'm at work, at home, in my car (connected to car bluetooth), etc., I choose to have several profiles.

A very simple profile is:

Event: Wifi connected
Entry Task: Security Settings clear password
Exit Task: Security Settings set PIN

My PIN unlock/lock profile would start with this instead of wifi connected.
Event: Variable %PACTIVE matches *x*/*y*/*z*

Where x, y and z are the profiles for my other conditions.



On Tue, Jan 8, 2013 at 12:59 PM, Scott Siegrist <sasan...@gmail.com> wrote:
Tasker newbie here. I have seen a couple threads herein discussing this, however, the tasks required are still unclear.

I wish to disable the Lock Screen functionality when connected to my home wifi; then, re-enable the Lock Screen upon disconnecting from the wifi.

Would I need to create two separate tasks for this process? Will I need to keep the initial task 'active'? What about ability to re-enable the Lock Screen upon leaving?

I have installed the 'Security Settings' plugin.

-Scott


Michael Yeager

unread,
Jan 8, 2013, 6:18:39 PM1/8/13
to tas...@googlegroups.com
Do you not need to disable Keyguard as well...

Michael Yeager

unread,
Jan 8, 2013, 6:22:31 PM1/8/13
to tas...@googlegroups.com

I guess not. Now if we could just store the PIN in a variable....

ScottS

unread,
Jan 9, 2013, 11:00:27 AM1/9/13
to tas...@googlegroups.com
Thanks @BradM. I'll give them a try, though I really only need to handle the keyguard.

ScottS

unread,
Jan 9, 2013, 11:01:26 AM1/9/13
to tas...@googlegroups.com
Thanks for the reply. Yeah, I'm just use the keyguard, so no need to set PIN/passwords.
Message has been deleted

ScottS

unread,
Jan 9, 2013, 11:52:17 AM1/9/13
to tas...@googlegroups.com
Diving into Tasker a bit, I was able to create a task to toggle the keyguard on/off. I then exported it into a functional App, and set it to run via my Profiles App (EasyProfiles).

It works at first, but then the keyguard comes back on soon thereafter. I guess I'm not understanding how Tasker interacts with Android, as when I run it to disable the keyguard, I notice the Android Setting for the Lock Screen is still enabled. What is causing the keyguard to automatically come back on?

In setting the Task, I did not enable it to run in the background, per the instructions. Security Settings is an OS Administrator.

Advise/recommendations?


Michael Yeager

unread,
Jan 9, 2013, 12:04:39 PM1/9/13
to tas...@googlegroups.com

Clear the PIN or password. I don't even have to disable the keyguard on my phone. Until I manipulated the PIN on my phone, I had ghe same problem. You'll need secure settings for this but you don't have to be rooted...

ScottS

unread,
Jan 9, 2013, 1:10:42 PM1/9/13
to tas...@googlegroups.com
@Michael, am I to presume then that I must use the PIN or Password option to access my Desktop, and not simply the 'Slide' option, in order for such a task to work in Tasker (when the task is not enabled)?

ScottS

unread,
Jan 9, 2013, 1:13:32 PM1/9/13
to tas...@googlegroups.com
@BradM, Pardon any ignorance, but I don't see wifi connected as an option under 'Event'.


On Tuesday, January 8, 2013 2:58:21 PM UTC-6, BradM wrote:

Michael Yeager

unread,
Jan 9, 2013, 1:26:30 PM1/9/13
to tas...@googlegroups.com

Scott, the WiFi Connected context is under status/net.

On my phone, the slide to unlock comes up all the time when I "wake up" my phone. The keyguard is the screen after that that asks for your pin/password. Clearing the password allows me to swipe the screen and go straight to my home screen or whatever app is open without having to put in my pin. Non secure is an understatement but only used in a few circumstances.

Brad Minion

unread,
Jan 9, 2013, 2:40:06 PM1/9/13
to tas...@googlegroups.com
On my Verizon GS3, when Secure Settings turns off the PIN lock, it appears to switch back to what ever I had when Secure Setting set the PIN lock.

In other words, if I had the lock screen set to none, it returns to none when it turns off PIN lock. If I had it set to swipe, it returns to swipe.

Michael Yeager

unread,
Jan 9, 2013, 3:28:33 PM1/9/13
to tas...@googlegroups.com

What exactly are you referring to as "swipe"? Are you talking about the connect the dots pattern lock?

Brad Minion

unread,
Jan 9, 2013, 3:52:26 PM1/9/13
to tas...@googlegroups.com
On my VZ GS3 I can specify Swipe, Motion, Face unlock, Face and Voice, Pattern, PIN, Password or None for the screen lock. With "Swipe" all I have to do is swipe my finger across the screen to "unlock" it. 

Michael Yeager

unread,
Jan 9, 2013, 4:15:20 PM1/9/13
to tas...@googlegroups.com

Gotcha. Then "swipe" is the full time mode my phone wakes up in and it has no security. When I define the PIN code, after I swipe I get the actual unlock screen. PIN or password is all I use as the pattern lock is cheesy to me and face unlock often results in having to key in the PIN anyhow. I could probably turn it off somehow but haven't bothered. I actually use WidgetLocker with the same basic layout to display other info on my lock screen..

Brad Minion

unread,
Jan 9, 2013, 6:08:53 PM1/9/13
to tas...@googlegroups.com
I get one or the other, not both. So if I have PIN lock enabled that's what I see when I wake the phone. No swiping first then enter a PIN like you apparently have to do.

Michael Yeager

unread,
Jan 9, 2013, 6:32:50 PM1/9/13
to tas...@googlegroups.com

Gotcha. I don't know if I can disable the swipe screen but since I like it and use that page to display data using widgetlocker I haven't tried. That does clear up the confusion from the earlier posts.  :-)

Scott

unread,
Jan 10, 2013, 12:02:31 AM1/10/13
to tas...@googlegroups.com
Okay, I've attempted to write what I think is correct. However, it works for awhile, then the Lock Screen starts to appear again. I created an App to run this Task. I have the Secure Settings plugin installed and is an Admin.

Task settings:
Secure Settings/Keyguard Toggle
Secure Settings/Clear Password

I should note that I do not use the 'keyguard' (PIN/Password), I only use the 'slide' function to gain access to my Desktop. This seems to be correct, but for whatever reason, my OS is allowing the Lock Screen to bypass it after some period of time.

In trying write it as a Task within a Profile, as initially planned herein, I still cannot locate WiFi Connected. When I create a new 'Profile', under 'Event', I do not see it anywhere, and do not see 'status/net'. I've attached a screenshot of the Event categories I have available to me.
Wifo_connectef.png

RudeboyX

unread,
Jan 10, 2013, 5:13:40 AM1/10/13
to tas...@googlegroups.com
Not sure if iits causing your problem, but the most recent update of secure settings has ICS bugs which cause the lock screen functions to not work correctly. I have alerted the dev who advises he is aware of it and that it will be resolved in the next update.

I can't confirm this effects you as I only switch between patternlock and no lock/guard but it is highly possible the issue spans keyguard and PIN lock also.

RBX

RudeboyX

unread,
Jan 10, 2013, 5:16:59 AM1/10/13
to tas...@googlegroups.com
Look under STATE not EVENT.

RBX

Michael Yeager

unread,
Jan 10, 2013, 9:37:16 AM1/10/13
to tas...@googlegroups.com

Exactly, as stated before, it is a STATE condition not an EVENT. Event conditions are ones that occur for just a moment and then go away.

Scott

unread,
Jan 10, 2013, 9:45:50 AM1/10/13
to tas...@googlegroups.com
Thanks @RBX

Scott

unread,
Jan 10, 2013, 10:02:14 AM1/10/13
to tas...@googlegroups.com
@Michael, Pardon, though you initially stated 'status/net', not 'state/net' and since I'm new to Tasker, I had no idea what you were referring to...thank you regardless for your input.

Michael Yeager

unread,
Jan 10, 2013, 10:21:32 AM1/10/13
to tas...@googlegroups.com

No problem. I caught that the second time. I'm not familiar with your phone so I can't help much with your issue but if I may ask, what's the point of having the swipe screen at all with no security on the phone?

Scott

unread,
Jan 10, 2013, 10:40:01 AM1/10/13
to tas...@googlegroups.com
If I have the Lock Screen disabled completely, the call screen is shown on any call coming in. If the Lock Screen is enabled, then it only shows who's calling and does not show the Desktop/call screen; this is good especially when the phone is in my pocket, as it won't accidentally answer the call. Additionally, it's just more convenient to have the Lock Screen off when at home.

This is simply my foray into Tasker. I'm sure I can find ways to save battery life, occupy my time while driving my wife and kid around shopping :-), etc.

Michael Yeager

unread,
Jan 10, 2013, 11:16:58 AM1/10/13
to tas...@googlegroups.com

Gotcha. My phone gives me the answer call screen regardless of phone locked. You'll find many things to do later. Wish I could help more with the current issue...

Scott

unread,
Jan 10, 2013, 10:06:13 PM1/10/13
to tas...@googlegroups.com
I discovered I couldn't have the Task on as a 'Toggle', I need to set it as Disabled. My problem is when leaving the home wifi, this setting alone does not re-enable the Keyguard. @Brad initially outlined 'Exit Task: Security Settings set PIN', though I'm not certain how to incorporate this. Do I need to create a separate profile for when leaving my Home wifi?

It seems I should be able to set two different states and associated Tasks within one profile. However, when I add another 'State' to the profile, I don't see an option to associate a Task with it directly.

Michael Yeager

unread,
Jan 10, 2013, 10:26:22 PM1/10/13
to tas...@googlegroups.com

Long press the entry task on your profile and when the menu pops up, select add exit task. Wording may be off but its close.

Scott

unread,
Jan 11, 2013, 9:10:24 AM1/11/13
to tas...@googlegroups.com
Ah, thank you.

Scott

unread,
Jan 11, 2013, 9:48:13 AM1/11/13
to tas...@googlegroups.com
I find the function frequently stops working, and invariably, I must stop the Profile and restart it. To me, this doesn't seem much of a convenience. In checking the Tasker log for this task, Tasker indicates my wifi network becomes Inactive often, therefore, disabling the Task. I'm certain this is not the case, because I have a strong signal all the time. I rarely have any device connectivity issues.

Anyone else have wifi network issues like this? Is there maybe some type of filter I can apply, etc?

How about this option...I use EasyProfiles for various profiles, i.e. Home, Car, etc. I would like for EasyProfiles to be a State within Tasker, however, it appears Tasker cannot do that. I see I can select an EasyProfiles Profile within a Task, but it cannot be set as a State to reference...do I have this correct?

Brad Minion

unread,
Jan 11, 2013, 10:14:17 AM1/11/13
to tas...@googlegroups.com
My WiFi profile will sometimes cycle as well. I have never been able to figure it out because I only notice it when it re-connects so I can never see what's going on when it disconnects. I also have the situation, mostly at home, where  I will go somewhere momentarily that is beyond the range of my WiFi  like take out the trash.

To keep my WiFi exit task from immediately executing each time I momentarily loose the signal, I added a 1 minute wait as the first task followed by an "IF variable %PACTIVE ~= *WifiProfileName*" then do the rest of the exit tasks. Or you might be able to do "IF variable %PACTIVE = *WifiProfileName*" then STOP. That way, if the WiFi profile re-activates during that 1 minute wait, it does not run the rest of my exit tasks.

Do you think something like that might help?

I also quit having profiles turn on and off WiFi. I found that if I just leave it on 24/7 I have fewer problems. Leaving WiFi on seems to have a minimal affect on my battery life, possibly because I'm connected to WiFi most of the time anyway. I leave GPS and Bluetooth on as well and I have no problem going all day without recharging so I don't mess with them either.

Scott

unread,
Jan 11, 2013, 11:03:24 AM1/11/13
to tas...@googlegroups.com
Thanks @Brad. Pardon for my Tasker 'learning curve' questions :-) ... Which Task do you place the If variable in? Does the If variable run before the task it's in, or is the If variable ran after the task?

Bob Findlay

unread,
Jan 11, 2013, 11:35:01 AM1/11/13
to tas...@googlegroups.com
I use "cell near" to detect if I'm at home and it works perfectly.

the entry task is simply  password lock/PW off
and the exit is password lock/PW on

jabu...@gmail.com

unread,
Jan 11, 2013, 12:17:18 PM1/11/13
to tas...@googlegroups.com
does this work for the pattern lock too?

Scott

unread,
Jan 11, 2013, 12:19:23 PM1/11/13
to tas...@googlegroups.com
@Bob, thanks, and I may give that a try. Although, I'm located in an area that is surrounded by towers, however, not one of them is within close proximity...go figure.

TomL

unread,
Jan 11, 2013, 12:22:10 PM1/11/13
to tas...@googlegroups.com
Where WiFi is concerned, I wouldn't rule out the possibility that your connection dropped momentarily, even if you normally have a very strong signal.  

All it would take would be some nearby cordless phone, microwave oven or something to blast enough noise on the channel that the WiFi drops for a second.

Tom

Brad Minion

unread,
Jan 11, 2013, 12:52:01 PM1/11/13
to tas...@googlegroups.com

On Fri, Jan 11, 2013 at 10:03 AM, Scott <sasan...@gmail.com> wrote:
Thanks @Brad. Pardon for my Tasker 'learning curve' questions :-) ... Which Task do you place the If variable in? Does the If variable run before the task it's in, or is the If variable ran after the task?

Sorry if this isn't what you are asking for.

You can add the "IF" condition to each task/action or you can wrap an IF/END-IF around a set of tasks/actions.

At the bottom of most, if not all, actions you should find an "IF" with a check box. If you check that box, a dialog will open that will allow you to specify the variable IF condition.

If you have lots of actions and you don't want to add the IF condition to each one, you can add the "IF" action. You click the +, then "task", then "IF". Enter your condition, then hit the green check. Now any tasks you add  after this will only execute when the "IF" condition is true. You can end the set with an "End If". Here's what that might look like.

Profile: MortPlayer (46)

Priority: 5 CoolDown: 30
Application: MortPlayer Audio Books
State: Display State [ Is:On ]
State: Variable Value [ Name:%PACTIVE Op:Matches Value:*Connected* ]
Enter: Anon (47)
Abort Existing Task
A1: Wait [ MS:0 Seconds:30 Minutes:0 Hours:0 Days:0 ]
A2: If [ %PACTIVE ~ *MortPlayer* ]
A3: System Lock
A4: Wait [ MS:500 Seconds:0 Minutes:0 Hours:0 Days:0 ]
A5: System Lock
A6: End If 

I won't explain exactly what I'm trying to do here, but just understand that A3, A4 and A5 will not execute unless variable %PACTIVE is equal to "*MortPlayer*". The asterisks are required because %PACTIVE will contain all active profile names separated by a comma.

Scott

unread,
Jan 11, 2013, 2:59:28 PM1/11/13
to tas...@googlegroups.com
Thanks @Brad. Though I understand how to enable the If variables, I'm wondering if the If variables written within a Task are referenced before that Task is executed, or does the If variable indicate what's going to happen after that Task it's in has been executed?

In your example above, is A2 an If variable within the Wait Task? If yes, will the Wait Task not be executed until A2 has been referenced, or does A2 indicate what happens then with A3-A5, all after A2 has been executed, regardless?

Thanks. I just need to play around with the coding a bit.

Brad Minion

unread,
Jan 11, 2013, 3:39:56 PM1/11/13
to tas...@googlegroups.com
It is my understanding that when you specify the "IF" option on an action, the action does not execute unless the "IF" is true. So, the "IF" is checked first. If not true, the action is skipped.

The "IF" action or function, if you will let me call it that, on line A2 has nothing to do with the wait on A1. It's a separate action or function like any other and Tasker simply processes it after A1 is done. This type of "IF" "action" controls what happens after it and up to the EndIf or end if no EndIf is specified.

I find the best way to test stuff like this is to add "flash" actions.

If condition is true
  flash "true"
else
  flash "false"
end-if





Scott

unread,
Jan 11, 2013, 3:42:33 PM1/11/13
to tas...@googlegroups.com
Good recommendation, thanks.

Michael Yeager

unread,
Jan 11, 2013, 4:12:23 PM1/11/13
to tas...@googlegroups.com

The if statement is executed as the task runs. In other words, your exit task would trigger and if you had a wait as the first line with one minute as the time duration, you could follow it with a STOP (if %PACTIVE matches the name of the profile that the exit task belongs to) and it would abort the exit task if the profile was active again.

Scott

unread,
Jan 11, 2013, 5:51:51 PM1/11/13
to tas...@googlegroups.com
Lock Screen keeps reengaging. This happens even though my Profile remains Active, I still have the 'Keyguard is Disabled' notification,and no indication in the log that it went Inactive.

Something in the OS is overriding the Task, most specifically, Secure Settings. My phone is rooted and Secure Settings is an Admin.

Thoughts?

BTW, my Profile/Task includes 'Clear Password'

Michael Yeager

unread,
Jan 11, 2013, 6:58:16 PM1/11/13
to tas...@googlegroups.com

What if you disable it in the OS and then enable it with Tasker? You may have already tried this and it may not make a difference but it's worth a shot.

Scott

unread,
Jan 12, 2013, 2:52:49 AM1/12/13
to tas...@googlegroups.com
That doesn't work. There must be something in this version of my OS (Jelly Bean 4.1.1) that doesn't allow another App full control of the lock screen.

Is there any debugging apps that could show me activity of my OS and what is causing it to reengage the lock screen? Or, is there a way to give Secure Settings a higher priority?

Michael Yeager

unread,
Jan 21, 2013, 9:41:34 AM1/21/13
to tas...@googlegroups.com

If your using the secure settings action to clear the PIN and its still asking for a PIN, the only thing I can think is that your company's security policy won't allow a blank pin.

ScottS

unread,
Apr 29, 2013, 5:02:52 PM4/29/13
to tas...@googlegroups.com
Thanks @Yin, though the profiles you outlined don't work for me. It's an issue many are experiencing...the keyguard self-activates.

For me, I really only use the keyguard on/off; I seldom actually engage the PIN/Password. In order for my phone to display the keyguard, I must set my Settings/Security/Screen Lock to at least 'Slide', regardless of what Tasker Profile I setup. With this setting, then I experience the aforementioned issue of the keyguard re-appearing after it's been disabled, via any Tasker profile outlined herein.

The only thing that has worked for me, with the help of GermainZ's getevents macro script, is setting the 'Screen Lock' in Settings, as outlined here:


On Sunday, April 28, 2013 2:21:46 AM UTC-5, Yan Lin wrote:
I did have trouble disabling screenguard (mine is simple swiping display) when I was in home connected wifi.
After googling around, I found this http://tasker.wikidot.com/disable-keyguard-when-at-home
Altering some of the task and trigger, I finally did it.

outofthisworld

unread,
Feb 12, 2014, 6:08:49 AM2/12/14
to tas...@googlegroups.com, sasan...@gmail.com
So after using this Tasker profile for one day, I have the SLIDE TO LOCK ONLY (TURN OFF/ON WHEN CONNECTED TO HOME WIFI) working on Tasker. No other methods I tried have worked for a long period of time.

Disclaimer - This is not for those using pattern/pin/password/face or none. Tested on Nexus 5, 4.4.2, rooted, stock rom, franco kernel f32. All Apps mentioned up to date (no betas) as at Feb 2014.

Things you will need:

1) Settings -> Security -> Screen Lock -> Set to Slide
2) Tasker
3) Secure Settings (free version from Play Store is enough to do this)
4) Follow Secure Settings installation to give full root access and install Busybox etc..

Here goes:

Add New Profile (+), State (Net, Wifi Connected, select you SSID or SSIDs)
Add New Task
Add 1. Action (Plugin, Secure Settings, Configuration, PATTERN LOCK DISABLED)
Add 2. Action (Plugin, Secure Settings, Configuration, SCREEN & KEYBOARD LIGHTS ON 5 SECONDS)
Add 3. Action (Plugin, Secure Settings, Configuration, KEYGUARD DISABLED Background without notification is fine)
Go back to Profile, long press on the Green Arrow next to the first Task you added, and select Add Exit Task
Exit Task
Add 1. Action (Plugin, Secure Settings, Configuration, KEYGUARD ENABLED)

IMPORTANT: Turn off WiFi, and Turn on again to activate the Tasker profile
Reply all
Reply to author
Forward
0 new messages