yashsingh1/xdaforums huggingface dataset:
[Android Apps and Games] androcraze:
If I build a ROM that others can use, and I add "<item>org.microg.nlp</item>" under:

"<string-array name="config_locationProviderPackageNames" translatable="false">"

in:

frameworks/base/core/res/res/values/config.xml

it benefits users desiring to use UnifiedNlp with GApps.

Is there any negative effect to including the above in the ROM for users desiring to use MicroG and no GApps?

My gut is telling me "no", and it wouldn't make sense that it would adversely affect MicroG users, but I'd rather safe.

Thoughts?
[Android Apps and Games] rookey:
When I install "NetworkLocation.apk" from the 1st post in this thread, I get "App not installed. The package appears to be corrupt." The same happens for UnifiedNlp.apk. What can I do? During MicroG installation, I've installed quite a few apk's and there wasn't a problem with any of them.
[Android Apps and Games] Oswald Boelcke:
UnifiedNlp comes with microG Services Core i.e. no need to download and install the apk. Just ensure you using the most current version of microG Services Core (currently v0.2.4-81) from here.

Regarding the other "location"-apk's: I always download and install them from F-Droid. Currently using the following: LocalGsmNlpBackend, LocalWifiNlpBackend and NominatimNlpBackend. Some more details regarding my installation can be found in the OP and in port #8 of this thread. Myba it's helps?
[Android Apps and Games] Zeroblood:
Ya that part about location services is confusing. I took it as you have to s install both.
[Android Apps and Games] DIXES:
For Android 4.2.1, it seems that I need to install both of microG and LegacyNetworkLocation.apk, right?
[Android Apps and Games] sleepingelf:
Another flat earth apps :)
[Android Apps and Games] Mynacol:
No.

MicroG includes UnifiedNlp.

Either you use MicroG (signature spoofing required!)

Or you use UnifiedNlp (for your android version I think the legacy one is the right one)
[Android Apps and Games] DIXES:
If I just install Legacy version of UnifiedNlp, can I use Google Play Store? :confused:
[Android Apps and Games] Mynacol:
Unfortunately no. The Play Store needs all sorts of google services and for this you need MicroG! I would say read a bit on their website: microg.org and then try it.
[Android Apps and Games] piet8stevens:
A big thank you to n76. I am running UnifiedNlp with your backends, installed via Nanomod in Magisk. I have had a few instances where my location got stuck on yesterday's ending location. Rebooting the phone does not always solve the issue (I believe I had this when I had only activated Mozilla but am not sure).. I have therefore added more backends, including GSM Location Service and WiFi Location Service.

Unfortunately, GSM Location Service crashes regularly. I have set up a local database for Belgium, which I created on my phone.

I am running a 7.1.1 custom ROM (BlissROM) with backends downloaded from F-Droid.

One other thing: when creating the database, it crashes repeatedly, so it was a long process.

Finally, I live in a border area (Belgium, Netherlands, Germany). Any way to create a single database across multiple locations?
[Android Apps and Games] n76:
If can send/post the logs from the crashes during database creation it would be helpful. My experience has been that interruptions in connectivity are usually the issue.

Your database can contain as many countries as you wish (and have room on your phone). At present I have the United States (where I live) and Spain (where I will be traveling soon) loaded. Just select the countries you need. Unfortunately there is no way to select mobile towers within a radius of a location which might suit you needs better.

I am not sure about the current status of the Open Cell ID project and the may be issues using that as a source. I use Mozilla's data when building the database on my phone.
[Android Apps and Games] Oswald Boelcke:
I'm living in a border area (Germany, Netherlands, Belgium), too. Maybe my microG settings and my backend settings are interesting for you. Please find screenshots here.
[Android Apps and Games] piet8stevens:
Thank you for your quick reply. The backend no longer crashes today - I did not change anything, so not sure why.

The download of an additional database did stop (I did not see it crash) and I have the logcat (it says 'sending process COMPLETE' and then more to the end 'Stale or unreachable neighbors, ndm state:4' and as last line 'Network compressed POST connection error: java.net.ConnectException: Connection refused').. But the total logcat is 21MB. I have never uploaded a logcat. So

1) is it enough if I just select the last few lines?

2) how to upload/send to you?

I do see 2 databases, one for Belgium and one for the Netherlands, on my device, so maybe it succeeded.
[Android Apps and Games] n76:
I am not sure what you mean when you say you "see 2 databases, one for Belgium and one for the Netherlands". The database(s) should have names beginning with "lacells". There should be a lacells_gen.log file located at a location like /sdcard/Android/data/org.fitchfamily.android.gsmlocation/files on your phone. That would be a good place to start. If that does not have enough information, then the last bit of the logcat is the next place I'd look.
[Android Apps and Games] piet8stevens:
I did not write it correctly: I should have written that I have 2 countries selected. For now, it seems to work. Should the crashes return, I will try to get the logcat and somehow get it to you.
[Android Apps and Games] espionage724:
I'm using LocalGsmNlpBackend and LocalWifiNlpBackend currently. For the Wifi, I have it at default settings. For GSM, I've used https://github.com/sobrus/FastLacellsGenerator to generate a 370MB+ lacells.db file (using OpenCelliD and Mozilla for sourcing, and for MMC's 310, 311, 312, 313, and 316 (all the United States according to Wikipedia)), pushed it over to /storage/emulated/0/LocalGSMBackend/lacells.db.new, and then set the External database location in settings to /storage/emulated/0/LocalGSMBackend which then causes lacells.db.new to be renamed to lacells.db. For Sources, I have the 2nd option chosen (download chosen areas from lacells), and "Nothing chosen (will use all)" for Areas (I'm assuming this doesn't matter and it'll just use all the data available in the lacells.db?)

Is there anything else that should be done for this kind of set-up to be more optimal? Are both these backends ok to be using? Or should I perhaps switch over to another one like Mozilla? I'm looking for good accuracy primarily, and low battery usage, but I'm not entirely certain if using the backends locally would be better than using web-based ones like Mozilla's? On the other hand, I like the idea of my location data being primarily local. Also would either backend (Wifi and GPS) or UnifiedNlp itself need Doze/Battery Optimizations turned off at all? Right now I only have doze disabled for microG's Core Service.
[Android Apps and Games] BootloopedMillennials:
Can someone explain why I'm lacking that last check in the microg selftest regarding unifiednlp?

I have location set to high accuracy. Location backend is setup to GSM Location Service Local (Mozilla). Address Lookup Backend is setup to Nomination using OSM. I did reboot.
[Android Apps and Games] BootloopedMillennials:
I tried with another backend and even using both together. Backend was OpenBMap. Still didn't work.
[Android Apps and Games] n76:
Did you check that the backend(s) you tried had all the permissions they need to run?
[Android Apps and Games] BootloopedMillennials:
That could be the issue. Upon enabling the backend(s) in GmsCore settings I was prompted to grant them the location permissions. But that was all the permissions I granted them.
[Android Apps and Games] zeeBomb:
Can someone help me with my Wifi disconnecting every 10 or so minutes?
[Android Apps and Games] BootloopedMillennials:
So I did a whole new rom install to start fresh. Made sure everything was in the right place, installed correctly, all the permissions need. And still can't get that last microg selftest to pass. Weirdly apps like Osmand still get my location, within seconds. Officially stumped.
[Android Apps and Games] Tech 4 9:
Hello all. I have a Moto g4 plus that I think is GSM AND cdma but I'm on on Verizon which is cdma for sure so do I benefit at all from using the gsmlocationbackend? Anyone know of a cdma specific backend?..based on my searches they don't exist. Is there a benefit to running multiple wifi backends? Openbmap is crashing like crazy here lately. As I'm more interested in OFFline..I actually uninstalled Mozilla loc backend.

Here not to long ago I'm pretty sure I had mapfactor working without GPS...just with towers and wifi for navigation but now it DEMANDS gps or it won't even TRY to navigate. Any input as to best offline setup. Thanks again.

Sent from a xt1644-RezRmx
[Android Apps and Games] n76:
The Local GSM backend has code that might work with CDMA but since I don't have a CDMA phone account I can't test it. Nor, for that matter am I sure that OpenCell ID or Mozilla Location Services collect CDMA tower data as I've not specifically looked in their data for it. That said, all carriers are converging on LTE and it could be that a GSM/LTE based backend will work with Verizon LTE towers.

The Mozilla/Ichnaea backend has code in it that will use both cellular and WiFi data. And on the cellular side there is code it that is aware to some degree of CDMA cell towers. Of course it uses the Mozilla servers for its backend, so you might be able use it to test if Verizon LTE towers are in the Mozilla database.

If I recall correctly, the Apple back end is WiFi only. I guess I should go back and read the code again to be sure.

I normally run with data disabled (I am a cheapskate) and the one backend that I rely on is the local Wifi one. You need to have GPS enabled so it can collect its own WiFi database but it works pretty well at remembering places you've been and showing your location instantly and accurately enough that your navigation app can start computing a route before the GPS locks. Only issue I have is when I am in a very rural area and there are no WiFi APs around to compute a location. When that happens, I enable the local GSM backend (I am on a GSM/LTE provider). I update the phone's cell tower database about once per month or maybe once every other month, that keeps it current enough that on the rare times I use that backend it usually knows about the tower(s) my phone is detecting. Unfortunately the cell tower back end is not accurate enough to allow you to start your navigation, it does seem to help the GPS to lock faster by knowing an approximate location.

The different WiFi backends will report slightly different locations as the databases and algorithms behind them are slightly different. But in general I'd say you only need one WiFi backend. I use the local WiFi one as the others require a data connection. It also helps that I wrote it so it is tailored to my use. :)

I use OsmAnd and/or Maps.me for offline navigation. I usually recommend Maps.me as it is much easier to setup and run. OsmAnd supports turn lane guidance and a whole host of features geared to non-automotive use (elevation contours, hiking and bicycling profiles for routing, etc.) so I keep it on my phone too.

I hope the GPS on your Moto G4 Plus is better than the one on the Moto G4 Play. . . The GPS antenna connector on the Play version is problematic and the GPS sometimes has issues because of that.
[Android Apps and Games] Tech 4 9:
Thanks for such a great response. I've enjoyed playing with your wifi app(fitchfamily?..isn't the gsmloc app fitchfamily too?) I drive a lot and it's fun guessing which structures will trip the count..plus I appreciate ability to do local db. So I'll run your wifi, the gsmlocation and I'll keep Mozilla but like a backup..unticked but in case I might need online for some unforseen reason. Thanks again for the great response and app!

Sent from a xt1644-RezRmx
[Android Apps and Games] Hurkamurka:
Hello Guys!

Maybe you can help me out. I just switched on my phone to a new Marshmallow based ROM, called TugaPower (for OnePlus One). It supports signature spoofing out of the box. Till this time i used Nanomod to patch, or if it was a supported rom to install MicroG.

So i flashed the rom, than flashed nanomod. I gave permissions for play store and GSM Core Services (in Settings-->Apps-->Gear Icon-->App permissions-->Spoof package signature). Went to the MicroG settings to make a self check. Everythings checked, but 3 points:

1. "System supports location provider: Your system does not support this UnifiedNlp package. Either Install a matching package or a compatibility Xposd module."

2. "UnifiedNlp is registered in system: the system did not bind the unifiednlp service. etc..."

3. "UnifiedNlp do not have Location to test geocoder: Please verify your location Backend"

I tried it without nanomod, just using the FDroid repos for microg & unifiednlp too. Same results, the 3 unchecked boxes still remain unchecked.

Is there anything i could do to check these points? Of course i set Unified Settings in MicroG settings, gave all permissions what was asked and i did even reboot.

I tried to contact with the rom's developoer, but he couldn't give me any helpful advise, he hasn't used MicroG for a long time.

Thanks any help you can provide!
[Android Apps and Games] Oswald Boelcke:
Have you rebooted after the installations?
[Android Apps and Games] Hurkamurka:
---------- Post added at 09:31 PM ---------- Previous post was at 09:29 PM ----------

[/COLOR]

Yes, there was a reboot. The result was the same. Nanomod works fine on Marshmallow based Ressurection Remix for OPO, and on Marshmallow based Omni Rom for Galaxy Tab2. There are no problems with UnifiedNlp.
[Android Apps and Games] Hurkamurka:
On Nougat based TugaPower N50 UnifiedNlp works as it should be again.
[Android Apps and Games] Oswald Boelcke:
Weird, but at least I assume the issue wasn't unifiednlp related.
[Android Apps and Games] user822:
Hi,

I have a little and dumb question about the geocoding backend.

What is this used for, which kind of app needs this?

Thanks
[Android Apps and Games] n76:
Apps that are location aware may use this. On my phone I have a weather widget that uses it for two purposes: First to take your current position returned by your location backends and look up a city name. Second, if you are setting up a widget display for someplace other than where you are at, to look up the lat/lon based on the location name you give it.
[Android Apps and Games] travarilo:
I installed nougat Citrus-CAF that has been applied signature spoofing and unifiednlp patch from official microg page..

But, when I did self check on microg settings, unifiednlp can't be registered in system while almost all of the bos were checked..

I rebooted my device many times but still no luck..

I flashed unofficial microg installer and got the same, unifiednlp still can't be registered in system..

Is there any patches to make it work?

Thank you..
[Android Apps and Games] rnd83:
Did you switch locations off and on again? Also, it has to be on while rebooting. If your room supports AppOps you should check the permissions.

And check that signature spoofing is actually enabled.
[Android Apps and Games] Adurnas:
I've been trying out lineageOS with microG, and I've been having trouble making the oBike app (oBike version 2.5.3) work without gapps. With gapps it requests location access, locates your position on the map and lets you interact with the buttons on the screen. With microg, it doesn't request location access, and everything remains blocked (as if I hadn't given location permissions if I had gapps) despite having given the app all permissions from android settings. I've installed mozilla and apple nlp backends, and other apps (such as google maps) work with location.

I've tried capturing a log of when oBike is opened, there seems to be an exception generated when the app starts (line 145 on the attached file).

If needed, I can try gathering more logs if this one isn't enough.

Thanks for your time.

Edit: I forgot to add, I'm running LineageOS 14.2 on Oneplus x (onyx).
[Android Apps and Games] starbright_:
Hello,

I excuse not to have read all the 30 pages. But I am confused. There is a lot of talking about microG. Although this is a great thing - maybe some (like me) just wants to use unifiedNlp. As far as I read first post - spoofing and microG is not needed for that.

Nevertheless I am puzzled about this 3 apps from [MENTION=3999488]MaR-V-iN[/MENTION]:

NetworkLocation.apk - LegacyNetworkLocation.apk - UnifiedNlp.apk

Only one of the app (according to description - old UnifiedNlp.apk ?) is in FDROID. This is the one I tried in my LOS14.1. But I don't get it registered (Selfcheck). Reboot and on/off of GPS (with support of WLAN/CellIDs) I did.

Maybe someone can give me a hint?
[Android Apps and Games] Ultramanoid:
I'm using version 1.6.8, without MicroG or anything else, in Lineage 14.1, with the Apple backend.

Same as in your case, it does not show as registered in the self-check, but it works.
[Android Apps and Games] starbright_:
Mh, which version of UnifiedNLP do you use - one of the apk linked in original post? I have tried that one in FDroid (which seems to has some reference to microG). This is probably the one you used, it has 1.6.8 version - right?

And with a second try (after deinstallation) I tried the NetworkLocation.apk linked here.

This has far less settings. One for Location Backends (I use the one with offline database that I could download), the other for AdressLookup. But this this one does nothing after pushing to it. ?!?

How do you know it works for you?
[Android Apps and Games] Ultramanoid:
To be honest I don't remember if I got it from GitHub or F-Droid. That's why I gave you the version, 1.6.8.

The Japanese EEW alarm system for quakes tracks my location fine with it, it is basically the only thing I use location for. Occasionally I will use the Google Maps site on Firefox and there it works too.

Edit : I don't use GApps or any other software that provides location, without this I wouldn't have any functioning location service at all.
[Android Apps and Games] starbright_:
Just have seen, the 1.6.8 exists a (nogapps) - which I used and (gapps) version.
[Android Apps and Games] Ultramanoid:
I use the no GApps version.
[Android Apps and Games] starbright_:
I am now back to this version. Again, no check for "unifiedNlp is registered in system".

And what does mean "Network based location enabled" - it is checked.

(It is pure LOS14.1 + addsu) + very few apps (FDroid...)

I uses Firefox and Openstreetmap to try to locate myself. I agreed that it can have access to location, but nothing happened :(
[Android Apps and Games] Ultramanoid:
Maybe wait a bit or reboot. Network-based is using the wireless or cellular signal to triangulate the location of the device. It's good, but not as precise as GPS.

EDIT : I forgot ! In recent Android versions, only system applications have location access. I placed the apk in /system/app to make it work.
[Android Apps and Games] androcraze:
I have a flashable version in this post under "Add-on Downloads":

https://xdaforums.com/showpost.php?p=69052354&postcount=1

EDIT: It's the GApps version.

---------- Post added at 12:32 ---------- Previous post was at 12:22 ----------

Here's a UnifiedNlp NoGApps version:

http://www.mediafire.com/file/n9mabklrzubrol2/UnifiedNlp-NoGApps-1.6.8-flashable.zip
[Android Apps and Games] starbright_:
What is the source of it and what is the difference to the one in the first post? At least with this I get the box for integration checked.

The "Network based location enabled" I couldn't uncheck. I would like to have a rough location only based on offline data. Thats why I configured the according backend and downloaded the database.

Nevertheless, I don't get any position with it. Frankly speaking, I give it up for now. I don't get it work.

Just from reading it, it sounds far more easy.
[Android Apps and Games] androcraze:
I pulled the version from F-Droid, renamed it, and put it into a flashable zip. Nothing more.

The issue is what [MENTION=4004386]Ultramanoid[/MENTION] alluded to: to get things working properly, the APK needs to reside in /system, not /data.

The two backends that seem to work well for me are the Mozilla and the Apple.
[Android Apps and Games] starbright_:
Can it be, that it the Frontend doesn't work with the Backend I have chosen: LocalGsmNlpBackend ? It is not at the list in initial post.

This is because I want to use an offline cell based database.
[Android Apps and Games] Ultramanoid:
You could try with the Mozilla or Apple backends temporarily and see if they work for you. If they do then you'll know the problem is only with LocalGsmNlpBackend.
[Android Apps and Games] ale5000:
There are all three versions on F-Droid:

UnifiedNlp (no GAPPS)

UnifiedNlp (no GAPPS) (legacy)

UnifiedNlp (GAPPS)

The differences are explained here.
[Android Apps and Games] n76:
In the local GSM backend have you selected the areas you wish to have data for and downloaded the data from either OpenCellID or Mozilla?
[Android Apps and Games] starbright_:
That makes me the initial post and FDroid matching :)

UnifiedNlp (no GAPPS) = NetworkLocation.apk !

[MENTION=6204913]n76[/MENTION]:

Yes I downloaded a database for my country (don't remember whether Mozilla or OpenCellID) - at least it takes some time.

[MENTION=4004386]Ultramanoid[/MENTION]:

Maybe I start another trial next. Do you know: can these other backends operate offline (with downloaded database) too?
[Android Apps and Games] Oswald Boelcke:
Please refer to attached screenshots. Got my backends from F-Droid. Really decently working. Very acceptable postioning with GPS, WiFi and mobile data disabled just by using my offline cell based database (last updated about a month ago).
[Android Apps and Games] starbright_:
Looks good so far. I can see you use the complete microG - not just unifiedNlp.

I'll give it another try next.
[Android Apps and Games] Ultramanoid:
I'm sorry, I haven't used the offline options, the Apple backend works very well for me online ( mostly LTE, I tested Mozilla too ) and so I haven't used anything else. I don't use the rest of MicroG either.
[Android Apps and Games] Oswald Boelcke:
My second location backend is the WiFi backend that provides excellent location in "savings" as soon as it has once correlated a GPS position with a known WiFi network e.g. at home. Here is my complete "microG curriculum vitae". Maybe it contains some usable hints?
[Android Apps and Games] n76:
For what it is worth, I have just released "Déjá Vu", a new back end plug-in for microG/UnifiedNlp to GitHub.

This new backend uses multiple RF types (mobile/cellular and WLAN/WiFi) to estimate the location of your phone. While the concept is similar to my previous wifi_backend, implementation details are different.

For the last month or so, I've been using this new backend as a replacement for both my older Local-GSM-Backend and my older wifi_backend.

I will continue to support the two older location backends when bugs are reported or if pull requests are received. However my personal focus is now on Déjá Vu and it is much more likely to get upgrades and improvements.
[Android Apps and Games] starbright_:
I installed microG core, which should include the unifiedNlp.

I can check the status, and all seems to be ok. Just the unifiedNlp is NOT bind into system.

So why and what can I do?

Currently I download the database for a RadiocellsUNLProviderBackend.
[Android Apps and Games] n76:
On newer systems microG needs to be installed in /system/priv-apps/ for the location provider to register and work. Did you do that?