Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work well in 2G/3G #27

Open
jeremy447 opened this issue Dec 19, 2016 · 15 comments
Open

Doesn't work well in 2G/3G #27

jeremy447 opened this issue Dec 19, 2016 · 15 comments

Comments

@jeremy447
Copy link

Hello,

I don't know if it's UnifiedNlp or IchnaeaNlpBackend that doesn't work well but often my map apps can't find my location. I meant that doesn't work well with GPS disabled (disabled or in buildings). With GPS the location is found quickly. When GPS is not available UnifiedNLP should locate me, not accurately but I think in a range of 100m to 1km based on wifi and gsm, and that often not the case.

  • Sometimes the location is never found
  • Sometimes the location is quite imprecise (200+ km radius)
  • Sometimes the location is wrong, not updated, and correspond to the location where the last time I used the map apps

By the way I live in Bordeaux, France and there is plenty of wifi and 2G, 3G around. The thing is that at a given location sometimes that work, sometimes not.

Thanks !

@mar-v-in
Copy link
Member

In general, the data provided by this backend is straight from the Mozilla servers, but Mozilla's database is not always accurate.

Can you provide additional details:
Check logcat entries from ichnaea (if you have a unix device connected use adb logcat | grep -i Ichnaea) while using an app that actively requests your location (e.g. SatStat). If everything works right, you should see 4 entries repeated about every 5 seconds:

  1. something starting with "IchnaeaBackendService: request:", following a bunch of details that is exactly what is send to Mozilla to locate you.
  2. something starting with "IchnaeaBackendService: response:", following the response from Mozilla
  3. something starting with "IchnaeaBackendService: reporting:", which should contain the same data as above (possibly rounded)
  4. something starting with "NlpLocationBackendFuser: location=", which is the final data sent to the app to display it and contains meta information (other backends used, technical details on the provider)
  • If 2,3 and 4 show the same location details, the backend is correctly reporting what Mozilla is suggesting.
  • If the delay between the message repeating is far longer than 5 seconds, your modem or wifi chip might be slow in reporting data. To verify this, close SatStat if it is open (e.g. by swiping it away from the recent list) and open it again, and go straight to the cell/wifi info tab (third tab). If it takes a long time to show cells or wifi information, there is likely a problem with the drivers you use.
  • If there is few or no cell/wifi data, verify it is the same data as provided in SatStat. If it's not verify that you enabled the usage of cell/wifi data in backend settings (unifiednlp settings->configure location backends->gear icon next to mozilla)

If everything is fine above, it might be that there is just not enough data in the Mozilla database for your area. Try a) using another backend or b) using Mozilla Stumbler to contribute to the Mozilla database. You can also verify the location reported by Mozilla in Mozilla Stumbler by activating the corresponding option in Mozilla Stumbler settings.
Please also give some general details if the problem persists like device, used ROM, any possible relevant modifications/Xposed modules etc.

@jeremy447
Copy link
Author

I understand that Mozilla's database is not always accurate but I think it's not the problem because, for the same location, sometimes that work, sometimes that doesn't work and a few days ago I used Mozilla Stumbler to contribute to the Mozilla database (just my home location for now where I do the tests).

I don't know if that help but I already provided some logs on the other bug report microg/UnifiedNlp#105

Here is another one 2016-12-22-06-48-54.txt with osmand. Just before making the log I tried to see if I was located with wifi and that worked well. I didn't move, I disabled the wifi, started to record the log, I relaunched osmand and the location wasn't updated (still the wifi one) and every few seconds the location was lost in osmand.

My modem and wifi chip are fast when I open SatStat and go straight to the cell/wifi info tab. By the way my phone is a Motorola Razr i with CM11 without any modification.

Thank you mar-v-in for helping me !

@jeremy447
Copy link
Author

I made an other test with osmand, the location was not found and it seem that was the backend that crashed or hanged. I couldn't go into the IchnaeaNlpBackend settings (black screen) and when I switched to LocalGsmNlpBackend the location was found quickly in osmand.

Here is the log (it stop before I switched to LocalGsmNlpBackend I think)
2016-12-22-14-09-38.txt

So it seem that is the backend that crash or hang when the location is not found and maybe when the location is not updated.

@jeremy447
Copy link
Author

Well I don't know if it's the problem lies in the backend or in UnifiedNlp because it kind of happened too with LocalGsmNlpBackend when I was in Andernos, France yesterday. I tried 3 or 4 times to see if I was correctly located and that was not the case until maybe the 5th time. There was plenty of GSM antennas available and I didn't move at all when I was located.

Here is a log when that didn't worked with LocalGsmNlpBackend
2016-12-24-17-50-00.txt

@jeremy447
Copy link
Author

It seems that I'm not the only one #16

@jeremy447
Copy link
Author

I noticed that, at home when testing, the location work with wifi + 2G enabled but as soon as I disable the wifi the location doesn't work and I assure you that there is 2G, 3G coverage of my home area.

For the past month I used LocalGsmNlpBackend and it worked very well, except this one time in Andernos. I return to Andernos this sunday and it will try again to see if the problem happen again or not.

@jeremy447
Copy link
Author

For the past month I used LocalGsmNlpBackend and it worked very well, except this one time in Andernos. I return to Andernos this sunday and it will try again to see if the problem happen again or not.

LocalGsmNlpBackend worked perfectly. So it seem that the problems (sometimes the location is never found, sometimes the location is wrong, not updated, and correspond to the location where the last time I used the map apps) lies in IchnaeaNlpBackend.

@jeremy447
Copy link
Author

I think the problem is when I loss one of the previously way of locating me (Wifi or 2G/3G) that the problem occur.

@jeremy447
Copy link
Author

The problem doesn't seem to be when I lose one of the previously way of locating me but simply the 2G/3G one. If I use only wifi it works but if I use only 2G/3G it doesn't work well.

Here is a log where the location is found then lost after a few seconds :
2017-02-22-07-53-11.txt

@jeremy447
Copy link
Author

As I said there, if I use LocalGsmNlpBackend for 2G/3G and IchnaeaNlpBackend for wifi it work very well. @mar-v-in I hope you can take a look at it.

Thanks !

@jeremy447
Copy link
Author

@mar-v-in I really hope you can find some time to look at this :)
Thanks !

@jeremy447 jeremy447 changed the title Doesn't work well ? Doesn't work well in 2G/3G Apr 14, 2017
@jeremy447
Copy link
Author

Is it still developed ?

@jeremy447
Copy link
Author

@mar-v-in can you help please ?

@jeremy447
Copy link
Author

It seem that the problem had already been reported
#15

@jeremy447
Copy link
Author

Can it be the value et=?!? the problem (I replaced the lat and lng by xx.xx)

02-22 07:52:12.446 D/IchnaeaBackendService(26162): reporting: Location[ichnaea xx,xx,-xx,xx acc=1000 et=?!?]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants