Q: How can I tweak Settings/Location to switch on/off the GPS receiver directly, independent if an app asks for position data or not?

For enabling/disabling GPS, connman seems to have an interface:

 busctl call  net.connman /net/connman/technology/gps net.connman.Technology GetProperties
a{sv} 5 "Name" s "Gps" "Type" s "gps" "Powered" b true "Connected" b false "Tethering" b false
devel-su busctl call  net.connman /net/connman/technology/gps net.connman.Technology SetProperty sv "Powered" b false
 busctl call  net.connman /net/connman/technology/gps net.connman.Technology GetProperties
a{sv} 5 "Name" s "Gps" "Type" s "gps" "Powered" b false "Connected" b false "Tethering" b false

Haven’t tested whether that does anything though.

1 Like