8

I used to work with this application: https://play.google.com/store/apps/details?id=com.fakegps.mock&hl=en And before this with this one: https://play.google.com/store/apps/details?id=com.incorporateapps.fakegps.fre&hl=en Am working on a LG G3 and a Nexus 5, but in the last couple of days, the fake location doesn't work as it should. It doesn't always modify my location and sets in where I want. Or many times, it sets my location where I want for a couple of seconds and then resets to my real location. I'm working on a travel app, and this made it very simple to simulate trips and locations. Is there any other fake location app that actually works how it should? Or is there any other way to set the location of my phone, while the app is running?

EDIT: YES! MOCK LOCATIONS is ON. Like i said: It DOES change my location, to the mock location I want, but it jumps back to my REAL location, after a couple of seconds. Depending, sometimes, it stays for minutes on the mock location, but then jumps for 1 second on my real location, and then goes back :) Now I know this, cause I log all the locations that I find, even more, draws the path, and I have lines that jump back to my Real location and then continue PICTURE: Pink = how it should be. Green = locations that I get and the path. As you can see, each a couple of locations that I get, it jumps back to my location https://www.dropbox.com/s/sszzrvhnwlq2bxr/Screenshot%202015-09-10%2015.47.20.png?dl=0

rosu alin
  • 5,674
  • 11
  • 69
  • 150
  • `then resets to my real location` may be you have registered for location updates and its updating because of a fix! – Muhammad Babar Sep 10 '15 at 10:26
  • I had the same code, and before Android 5.0, even if I was registered for location updates, it will update with the mock location I chose lat and long, but now, I set the mock locations, it's there, and in a couple of seconds it jumps back to my location – rosu alin Sep 10 '15 at 10:33
  • Make sure to enable High Accuracy, instead of Battery Saving for "Mode" in your device's Location settings area. – DiscDev Nov 06 '17 at 23:13

4 Answers4

13

If mocked location seems to jump to real one during simulation, try to turn off wifi based locations (Settings / Location / Mode --> Device only).

Ali
  • 1,102
  • 5
  • 21
  • 39
Ted
  • 1,481
  • 1
  • 17
  • 18
4

Make sure you have Allow Mock Location turned on in phone's Developer Options and try this app: https://play.google.com/store/apps/details?id=fr.dvilleneuve.lockito&hl=en

I'm using it when working on Geofencing and works great.

arsena
  • 1,935
  • 19
  • 36
  • Thanks, I will try it! And yes, I have mock locations allowed. Like I said, it does change my location, but it jumps back to my locations, It doesn't keep the mock location – rosu alin Sep 10 '15 at 10:32
  • I still get the same issue, Lockito works within its own app but when the App I am building tries for location it get the real locaton, not the spoofed location. Any other ideas? – SM3RKY Oct 08 '15 at 22:23
  • @SM3RKY on what device are you testing? mock locations don't work on some devices no matter what app you use. and just to be sure check if you have mock locations on in developer options. – arsena Oct 09 '15 at 07:29
  • Hey misho, Im using an LG G4, and a Samsung Galaxy S3. Neither seem to be able to mock locations for a consistent period and keep jumping between the current location and the fake location. While this is happening, when an App tries to get the location it fails and does not return either of the locations. – SM3RKY Oct 11 '15 at 20:14
  • 1
    @SM3RKY My Note 4 used to do exactly the same thing but I don't remember how I fixed it, I think I didn't do anything particular. Try testing on Android emulator. It definitely works on genymotion – arsena Oct 12 '15 at 07:34
  • 2
    In Android 6 there is no Allow Mock Locations option anymore; there is an option to choose the app which will fake the position instead. – Jago Jul 30 '16 at 15:44
3

I managed to fix this problem by disabling the "Fused Location" service on my phone. I used the Disable Service application which requires root privileges to run. After disabling the "Fused Location" service I stopped teleporting to my real location.

Kevin Cox
  • 3,080
  • 1
  • 32
  • 32
1

In Settings -> General -> Location -> Mode

I switched it from Battery Saving to High accuracy and then the mock location app started working.

Note, you also need to set your preferred Mock Location app in Developer Options, but even after doing that my app was showing my true location instead of the mocked location - now it's working like a champ!

DiscDev
  • 38,652
  • 20
  • 117
  • 133