I need to detect GPS status through adb shell
. I have tried dumpsys location
command but the output of this command is not changed when the GPS is enabled/disabled.
I need to detect GPS status through adb shell
. I have tried dumpsys location
command but the output of this command is not changed when the GPS is enabled/disabled.
You can use this command:
adb shell settings get secure location_providers_allowed
Possible outcomes:
gps,wifi,network
or gps,network
-- High accuracy mode wifi,network
or network
only -- Battery saving modegps
-- Device onlyQ & A