Change any Android Setting from anywhere with AutoApps 2018-06-21

Learn how to use the new Custom Settings action in Tasker to change settings from anywhere

  1. joaomgcd
    This will allow you to change any Android system setting from anywhere you can send an AutoApps command from! This means that you can change them from your PC (with Join), your watch (AutoWear), Notifications (AutoNotification), etc.

    Take a look how I can change my screen's brightness with Join from my PC for example:


    Download and import the attached profile and then send a command with the following structure from any AutoApp
    Code (Text):
    setting=:=type=:=example_name=:=example_value
    where type can be either
    • global
    • secure
    • system
    and example_name and example_value are the name and value of the setting respectively.

    As an example use the

    Code (Text):
    setting=:=system=:=screen_brightness=:=20
    command to change your screen's brightness to 20, or change the 20 at the end to any value you want.

    You can also follow the tutorial below to understand how it all works.

    STEP 1 - CREATE PROFILE TO CHANGE ANY SETTING


    • In Tasker create a new profile with the AutoApps condition
    • Set the Command Filter to setting=:=
    • Set the variable names to type,name,value
    • Accept and create the task
    • Add a Flash action that shows the type, name and value just to confirm that they are being set correctly
    • Back out of Tasker to save


    STEP 2 - CHECK IF IT'S WORKING


    Send an AutoApps command from anywhere. In this example I used Join, but you can use any app that uses the AutoApps Command Sytem.
    Check that the toast shows up correctly.


    STEP 3 - ADD AN IF FOR EACH SETTING TYPE


    • Add an If action and set the condition to %type matches system
    • Add an Else action and set the If condition inside it to %type matches secure
    • Add an Else action and set the If condition inside it to %type matches global


    STEP 4 - USING THE CUSTOM SETTING ACTION


    • Add a Custom Setting action inside the first If
    • Set type to System, Name to %name and Value to %value
    (i) This will use the variables gotten from the AutoApps command and use them in the action to change the setting with the given name and value
    • Copy->paste the Custom Setting action into the other Ifs and change the type to Secure and Global in each one
    • Back out of Tasker to save


    STEP 5 - FIND SETTING AND TEST IT


    (i) We're now just going to find a setting to test this setup with. If you know a setting you want to change you can skip this and test it right away.

    • Add a new Task in Tasker and name it Find Setting
    • Add a Custom Setting action
    • Use the functionality to find a setting automatically
    • Change your screen brightness
    • Check that the setting is a System setting with the name screen_brightness and a value like 195 (depending on what you set the brightness to)
    • Send an AutoApp command like setting=:=system=:=screen_brightness=:=20 and it should turn down your screen's brightness to 20!


    That's it! Now it's super easy to change any setting from anywhere! :cool: