title: Controlling GPS operations using adb shell - turning on/seeing that GPS actually get a location
body: <p>Is there a way, using adb shell commands, to:</p>
  
  <ul>
  <li>Turn on GPS on the phone (and not to just toggle-on GPS, but to actually activate the sensor to retrieve location)</li>
  <li>Check to see if GPS sensor actually retrieves (correct) location</li>
  </ul>
  
  <p>I am writing a python script, passing adb shell commands through an internal app, and am having trouble checking to see if the GPS sensors check out on these phones. In a nutshell, I am testing the functionality of the GPS on the phones.</p>
  
  <p>Once I have a string variable with the GPS data, I am planning on using regex to parse it and actually find latitude/longitude coordinates. Right now I can turn on the GPS sensor but, for whatever reason, these phones (factory reset) do not connect to the satellite through this sensor. They can see their location if you connect them through WiFi or the mobile network, but when both are turned off GPS seems to go quiet. In order for the GPS to actually read something, the workaround we ended up using was to download a 3rd party GPS app. Only then could the phones connect and see their own location.</p>