Welcome! Log In Create A New Profile

Advanced

[WM27] how to access flash drive in android 11

Posted by ccc2 
ccc2
[WM27] how to access flash drive in android 11
November 30, 2022 01:54PM
Hi,

My android app need to import and export file using usb flash drive. it work well until android 11 which non functions in wm work anymore.

i google around and found it is known issues
[issuetracker.google.com]

what should i do , any suggestion ?
Hi all,

my alternative solution is to ask the user to manual copy the file (using google files app) from or to the sd-card documents folder then the program can import and export.

i hope WM28 provide solution . since google files app can read and write to usb there must be away to do.
Re: [WM27] how to access flash drive in android 11
December 02, 2022 08:18AM
Hi CCC2

Hi have this in my code to manage it as-of Android 11
	//As of Android 11, fDataDir(), fExeDir(), fCacheDir, etc return
	// 		/data/user/0/com.company.appname/...
	//This folder is only accessible on a rooted device which is something that we don't 
	//want for our WMS solutions. In this case we create a generic accessible app folder
	IF SysNbExternalStorage() >= 1 THEN
		IF SysStatusExternalStorage(1) = sseAvailable THEN
			DATA_Path = SysDirExternalStorage(1,sseAppFile) + [fSep]
		END
	END

Cheers

Peter
Thanks but not working on un root device .

I do not have control on which devices will use or whether the device use can be root . I prefer for un root method




PeHoBe Wrote:
-------------------------------------------------------
> Hi CCC2
>
> Hi have this in my code to manage it as-of Android
> 11
>
> //As of Android 11, fDataDir(), fExeDir(),
> , fCacheDir, etc return
> // 		/data/user/0/com.company.appname/...
> //This folder is only accessible on a rooted
> d device which is something that we don't
> //want for our WMS solutions. In this case we
> e create a generic accessible app folder
> IF SysNbExternalStorage() >= 1 THEN
> IF SysStatusExternalStorage(1) = sseAvailable
> le THEN
> DATA_Path = SysDirExternalStorage(1,sseAppFile)
> le) + [fSep]
> END
> END
>
>
> Cheers
>
> Peter
Re: [WM27] how to access flash drive in android 11
December 04, 2022 03:41PM
ccc2 Wrote:
-------------------------------------------------------
> Thanks but not working on un root device .

I have this running on rooted Zebra devices with Android 11... So you must be doing something wrong I guess.

Cheers

Peter



Edited 1 time(s). Last edit at 12/04/2022 03:42PM by PeHoBe.
Re: [WM27] how to access flash drive in android 11
February 13, 2023 03:13PM
Hi Peter,

SysNbExternalStorage(), returns the number of "External Storages", not only SD Cards.
These could also be "pemanent memory partitions .." - so you must check them to see if they are "really SDCards"

[help.windev.com]

On devices I have checked (XIAOMI, HUAWEI) there are 2 external storages, but only one is a SDcard.
I will be doing, this week, some tests on a telpo m1 (v12 android) industrial device and see how things go and report back ...

Regards
Steven Sitas



Edited 1 time(s). Last edit at 02/13/2023 03:15PM by SteveSitas.
i try others apps but only google files working on non root device.
let hope wd28 has solution
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: