Turn off WiFi and mobile data
Moderator: Martin
Turn off WiFi and mobile data
Hello, is there a possibility of wireless and mobile data, e.g. Turn off at 11:00 pm and turn back on at 6:00 am?
Re: Turn off WiFi and mobile data
Make two flows, where both have a Time trigger, one set at 6am and the other one at 11pm. Then after that use actions Set WiFi State and Set Mobile Datanetwork, on or off as you need it. Keep in mind the last one requires your phone to be rooted, so you can instead use Set System Setting where the setting is mobile_data1 and the value to turn on is 1, and or off is 0. To modify system setting of this type you need to grant Automagic a specific permission with your PC with adb (you can google how to install and set adb, and grant permission is described on the action help, which you can access by going to http://automagic4android.com/en/help/co ... em_setting
In base of what you said, I quickly made those flows I described to help you a bit.
In base of what you said, I quickly made those flows I described to help you a bit.
- Attachments
-
- exported_data_20190304_131607.xml
- (4.63 KiB) Downloaded 1509 times
Re: Turn off WiFi and mobile data
Wonderful, thank you.
Let's see if it works.
Let's see if it works.
Re: Turn off WiFi and mobile data
Has worked very well, - thanks.bininga59 wrote:Wonderful, thank you.
Let's see if it works.
Re: Turn off WiFi and mobile data
Thank you so much for posting. I have this working on a Galaxy Note 9. I want data to turn off when I'm at home because sometimes the kids turn data on and somehow the WiFi isn't connected so we use gobs of data.
I understand that without routing, you can use adb to give automagic permission to change the system settings. So I executed
adb shell pm grant ch.gridvision.ppam.androidautomagic android.permission.WRITE_SECURE_SETTINGS
No error messages, so I it worked.
The action looks like this:
<action type="set_system_setting">
<useDefaultName>true</useDefaultName>
<name>Set System Setting: Global mobile_data1 to 0</name>
<settingCategory>GLOBAL</settingCategory>
<settingName>mobile_data</settingName>
<value>0</value>
<verified>true</verified>
</action>
At first, maybe I misunderstood the example, I used <settingName>mobile_data1</settingName>. That didn't work for me, but without the 1 it works fine.
I understand that without routing, you can use adb to give automagic permission to change the system settings. So I executed
adb shell pm grant ch.gridvision.ppam.androidautomagic android.permission.WRITE_SECURE_SETTINGS
No error messages, so I it worked.
The action looks like this:
<action type="set_system_setting">
<useDefaultName>true</useDefaultName>
<name>Set System Setting: Global mobile_data1 to 0</name>
<settingCategory>GLOBAL</settingCategory>
<settingName>mobile_data</settingName>
<value>0</value>
<verified>true</verified>
</action>
At first, maybe I misunderstood the example, I used <settingName>mobile_data1</settingName>. That didn't work for me, but without the 1 it works fine.