Author Topic: Android 11+, changes  (Read 3996 times)

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Android 11+, changes
« on: November 26, 2021, 12:13:57 »
Hi guys,

there were not too many changes in the Android itself during last years, that affect Locus Map. The big one was of course battery optimizations  :o.

And now, tadá, we have another one as most of you know.

A11+ devices bring a limitation in access to the device file system. Task, which firstly was not looking so complicated, in the end, took more than a month of work for me and half of the Locus team.

I started this topic so I may answer and discuss any changes that the next update brings independently on the main app version topic(s).

----

Summary
- app can no longer access the root of the internal memory directly, only over very limited so-called "Scoped storage" access. This brings some limitations. Mainly fact that the neesd to move its main directory to the private storage (/android/data/...). Also no support for the custom "srtm" and "mapsVector" directory, no support for custom "geo tagged photos" directory, and no support for "external maps" defined over the app.

- app can't directly detect installed apps, so the content of the function panel may be limited

---

Michal is already writing a bigger blog post & manual for a better understanding of these changes and how to solve the most common use-cases.
You may watch the creation process of the main manual page in progress here.

Feel free to ask here, I'll gladly answer.

I'll also today finally publish the new Beta version where all these changes will be presented.
« Last Edit: November 26, 2021, 14:35:04 by Menion »
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 
The following users thanked this post: Andrew Heard, luce

Offline balloni55

  • Global Moderator
  • Professor of Locus
  • *****
  • Posts: 2974
  • Thanked: 171 times
    • View Profile
  • Device: Samsung XCover 4s Android 11
Re: Android 11+, changes
« Reply #1 on: November 26, 2021, 14:16:00 »
Hello menion,
thank you for your detailed explanation, although this will be devastating for many users.

A comment in the linked instructions is not always correct:

You have to move the maps to /Locus/Maps/ directory manually via the system file manager.

The file manager of my device "Samsung Xcover 4S" has no acces to Android/data ! :o
with e.g. "X-plore" or "Total Commander" i´m able to manage these folders
Locus PRO 3.56.5
Locus Map 4.5.7.3 GOLD
LMP User ID 3e620e7590
LM4 User ID e06d572d4
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: Android 11+, changes
« Reply #2 on: November 26, 2021, 14:32:15 »
Really no access? Surprising. I'll inform Michal about some inconsistencies, thanks.
Import of the map will be implemented directly over the app next weeks. I had no time to do it yet. The solution is similar to the import of GPX etc. just app copy map into the proper directory.

And devastating ... well, as I work on it last weeks, I've ended with the (my) opinion that it is not a problem at all. I do all the necessary tasks I did before on my device and no problem. Only that the directory is not directly in the root of the device memory so it takes a few more clicks to find it ...
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline balloni55

  • Global Moderator
  • Professor of Locus
  • *****
  • Posts: 2974
  • Thanked: 171 times
    • View Profile
  • Device: Samsung XCover 4s Android 11
Re: Android 11+, changes
« Reply #3 on: November 26, 2021, 14:42:10 »
regarding "devastating"  I mainly meant the memory consumption of the internal SD
Locus PRO 3.56.5
Locus Map 4.5.7.3 GOLD
LMP User ID 3e620e7590
LM4 User ID e06d572d4
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: Android 11+, changes
« Reply #4 on: November 26, 2021, 14:44:17 »
Ah understand.
You may put the whole directory on the SD card! If you use a faster SD card, I believe it will be fast enough. But it needs to be tested, I've not tried it to be true ...

- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline Michal

  • Locus team
  • Apprentice of Locus
  • *****
  • Posts: 130
  • Thanked: 12 times
    • View Profile
    • Asamm Software
Re: Android 11+, changes
« Reply #5 on: November 26, 2021, 15:05:30 »
To be honest, I would rather not rely on SD card with its "ability" to handle database fast random read/writing, its stability etc. Not long ago I lost all my data on an SD card due to its malfunction and the necessity of formatting.
PR/support & UXW & copy, Locus team, Asamm Software, Prague
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: Android 11+, changes
« Reply #6 on: November 26, 2021, 15:47:40 »
Hmm right. So maybe we should start recommend devices without SD card and bigger internal memory ...
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline michaelbechtold

  • Expert
  • Master of Locus
  • ****
  • Posts: 951
  • Thanked: 111 times
    • View Profile
Re: Android 11+, changes
« Reply #7 on: November 26, 2021, 17:37:57 »
I'm really shocked that none of the geo app providers joined forces and went up in arms to wake up Google.
The limitations are a disaster, as explained many times.

As far as I understand an existing Locus install (BEWARE OF UPDATES!) will continue to use full power of the existing app, right?
 

Offline michaelbechtold

  • Expert
  • Master of Locus
  • ****
  • Posts: 951
  • Thanked: 111 times
    • View Profile
Re: Android 11+, changes
« Reply #8 on: November 26, 2021, 17:40:35 »
Hmm right. So maybe we should start recommend devices without SD card and bigger internal memory ...

And this is a BAD joke, Menion. In fact not a joke at all.
 

Offline michaelbechtold

  • Expert
  • Master of Locus
  • ****
  • Posts: 951
  • Thanked: 111 times
    • View Profile
Re: Android 11+, changes
« Reply #9 on: November 26, 2021, 17:54:42 »
To be honest, I would rather not rely on SD card with its "ability" to handle database fast random read/writing, its stability etc. Not long ago I lost all my data on an SD card due to its malfunction and the necessity of formatting.

I appreciate your twofold warning, Michal!

Question to Menion:
I saw that many apps have a /Android/data folder on external SD, BUT their working directory in fact is on internal storage.
Are you able to access BOTH of them simultaneously? E.g. SRTM and large maps on external SD, while databases and other essential objects with high performance and reliability needs are kept on the internal /Android/data storage.
 
The following users thanked this post: freischneider

Offline arnor

  • More than Newbie
  • *
  • Posts: 12
    • View Profile
  • Device: Samsung Tab A
Re: Android 11+, changes
« Reply #10 on: November 26, 2021, 18:10:02 »
Just for my clarity:

Did I understand correctly that:
- both app and userdata may no longer be placed in the root directory.
- this means that userdata such as srtm and vector should no longer be in the root.
- this means that app and data must be in the private directory /android/data.
- that the app and data may be on the sd card, but only in the private directory.

Is it then possible to divide app and data over private directories in internal memory and SD card? For example the app with important data such as the database in the private folder in the internal memory and for example the srtm and vector folders in the private memory of the sdcard?

I personally like to have data (such as documents, books, photos, vector maps, etc.) together in such a way that a backup can easily be made and in my case all on the sd-card.

By the way, where could I find information about the devastating reasons behind this new setup in Android 11+. Maybe then I can understand. Years ago, I got rid of my Apple iPhone because I felt Apple was being too "protective" with regard to data I owned. Can I do what I want with it. I know; this is not the address where I should file my complaints. You can't do anything about it either. Fortunately, I know that you will do everything you can to keep things running smoothly. Thanks for that.
 

Offline arnor

  • More than Newbie
  • *
  • Posts: 12
    • View Profile
  • Device: Samsung Tab A
Re: Android 11+, changes
« Reply #11 on: November 26, 2021, 18:12:31 »
Sorry, I just saw that someone else has just beaten me to a similar question.
 

Offline Viajero Perdido

  • Apprentice of Locus
  • **
  • Posts: 209
  • Thanked: 44 times
    • View Profile
  • Device: Samsung Galaxy Tab S7+ (Android 11) and -S2 (Android 7), Blackview BV9900 Pro (Android 9).
Re: Android 11+, changes
« Reply #12 on: November 26, 2021, 18:35:27 »
"no longer"

What about Android 10, 9, 8, ...?

I had a bad dream a few weeks ago where the app (beta?) surprised me with a notice that something had changed (I never changed anything!), I experimented with the "new normal", didn't like it, then changed it back.  Did that really happen?  Do I have to care about this if I don't have Android 11?
« Last Edit: November 26, 2021, 18:48:30 by Viajero Perdido »
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: Android 11+, changes
« Reply #13 on: November 26, 2021, 19:28:21 »
@michaelbechtold
we discussed this earlier and I have to repeat myself. Changes introduced now for internal memory were introduced 7 years ago for SD cards. They (these changes) complicate life to me, to our team, to many users also, but they make sense. There is also no serious reason why Google should grant an exception to the Locus Map app, sorry to say this.

And yes, version 4.4.3 is the last with the "full" access to the internal memory.

App has access to the private directory in internal memory and the SD card as well, so yes, this is an alternative solution to discuss > placing some data to private dir on the SD card.

@arnor
"both app and userdata may no longer be placed in the root directory" - correct
"this means that userdata such as srtm and vector should no longer be in the root" - correct
"this means that app and data must be in the private directory /android/data" - correct
"that the app and data may be on the sd card, but only in the private directory" - correct

"Is it then possible to divide app and data over private directories in internal memory and SD card" - not yet. If there will be bigger interest, I may work on it and this is definitely a doable task.

You may find a lot about it on the internet. The fact is that Google is step by step going the same restrictive way as Apple. As I do not know apple devices, I have no idea how far it goes now ...

@Viajero Perdido
There should be no changes on Android 10. If anyone notices any, it is definitely not an intent, so let me know.
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline michaelbechtold

  • Expert
  • Master of Locus
  • ****
  • Posts: 951
  • Thanked: 111 times
    • View Profile
Re: Android 11+, changes
« Reply #14 on: November 26, 2021, 21:43:06 »
Menion, you never really convinced re. below points! So, pls. ask Google via your DEV account those questions:

- how to share a DATABASE of 1GB+ between two compatible apps (they have no right to play LM4 XOR LMP - not their business, it's user's choice)
- how to share double digit data files (non-media!) between apps (like SRTM data or large map files (vector and raster); apps from different developers.

Looking forward to their answer.