Page 6 of 7

Re: Navigation Apps Auto turn on/off GPS

Posted: 26 Feb 2019 04:13
by valdimar
For a long time I have been using a similar activity written by me and everything is ok except when during the navigation it will be necessary to temporarily close the navigation window, for example Google Maps when you need to enter something in the search engine, Automagica is activated and the location and access to the Internet are disconnected. How to achieve a delay of 10-20 seconds?

Re: Navigation Apps Auto turn on/off GPS

Posted: 26 Feb 2019 17:11
by Desmanto
I don't quite understand what you want to achieve. If you need delay, add sleep for 10-20 seconds, before proceeding to disconnect the location and internet.

Re: Navigation Apps Auto turn on/off GPS

Posted: 26 Feb 2019 23:57
by elektroinside
Unfortunately, none of these methods work anymore with Android v9, to toggle location services...

Re: Navigation Apps Auto turn on/off GPS

Posted: 27 Feb 2019 18:17
by Desmanto
Yes, the non root method seems not working anymore. I have to use Set GPS State on/off to achieve the location mode with high accuracy. Other method is to toggle the quick setting using Control UI, which have some UI distraction.

Re: Navigation Apps Auto turn on/off GPS

Posted: 28 Feb 2019 17:18
by pgrilo
Hi. Fortunately I think it is still possible to toggle location on and off without root on pie.
I was testing the premium version (trial) and after playing around a bit and realizing that it wouldn't work on samsung pie not rooted (while it does work on other automation app that I'm migrating from) I decided to read the contextual help. :) Followed the dev's indications and it worked perfectly!
Purchased premium version instantly!

So, to turn location on, instead of setting "location_providers_allowed" to "gps,network" in one step, do it in two steps: set it to "+gps" first and then to "+network". To turn it off set it to "-gps" and then "-network".
Please check if it works this way on your devices.

Re: Navigation Apps Auto turn on/off GPS

Posted: 28 Feb 2019 18:03
by Desmanto
@pgrilo : Wow, I didn't know that. :o Many thanks. It works, without root. I should take some time to reread the documentation again. :lol: Maybe there are a lot of other system setting also have the same behaviour. I should try them out then.

Re: Navigation Apps Auto turn on/off GPS

Posted: 28 Feb 2019 19:35
by elektroinside
Awesome! Thank you, works just fine here as well!

Re: Navigation Apps Auto turn on/off GPS

Posted: 01 Mar 2019 07:10
by tphg
Wow, a new discovery! Thanks, @pgrilo.
Does it mean now we have to add 2 actions in series: the first is for turning on GPS and another is for turning on network?

Re: Navigation Apps Auto turn on/off GPS

Posted: 01 Mar 2019 08:20
by anuraag
@Desmanto you might have forgot it as it was already discussed in page 2 :D http://automagic4android.com/forum/view ... =10#p18708

Re: Navigation Apps Auto turn on/off GPS

Posted: 01 Mar 2019 17:29
by Desmanto
@tphg : yes, two action in series, if you have location completely off before. I always turn on location with battery saving, so network value is there already. I only use -gps and +gps, only single action.

@anuraag: Hahaha, I already forgot that. :lol: Last time I test it at old phone, set the value at once, it still works. That's why I don't give it much thought. Didn't know that was the culprit after upgrade my phone.