Accessing a file on Android SD card
-
- Posts: 25
- Joined: Tue 05 Nov 2019, 18:07
Re: Accessing a file on Android SD card
Thanks, Richard. Glad I'm not the only one with this issue... The ultimate destination for this app is on a hand-held device that is used in a laboratory. The app that runs on that device, takes a reading and then stores the data on the SD card in the Export directory. This tells me that that app can create and write files on the SD card, so maybe (hopefully) my app will be able to as well (when it gets installed). Unfortunately, I don't have access to that instrument for developing my app, just a tablet... I'll figure out a work-around... Thanks!
Re: Accessing a file on Android SD card
More Googling suggests that this may provide the explanation. It says that "More recent versions of Android rely more on a file's purpose than its location for determining an app's ability to access that file". It implies that you should be able to store files in app-specific or shared regions of external storage but not elsewhere. More details can be found at the article and pages linked from it.
Hopefully, but the implication at the linked article is that it can depend on the targetted version of Android, and that may differ between that app and BBC BASIC.so maybe (hopefully) my app will be able to as well (when it gets installed).
-
- Posts: 1
- Joined: Thu 16 Mar 2023, 23:57
Re: Accessing a file on Android SD card
Hey Everyone,
Has anyone been successful in making an Ext SD Card usable in between apps...? And all the customary techniques I'm aware of and programmes (FX) that have previously worked don't.
Both the OS's built-in settings and the secret Developer Options to force write access are ineffective.
At this point, I'm wondering why Xiaomi even bothered to incorporate an SD Card slot because it is currently redundant and meaningless.
It's slow as hell and doesn't always work, so I have to copy it from the internal memory to the computer before copying it back from the computer to the external memory. It's a brand-new SanDisk MicroSD that I bought from a major retailer. So it's not like it's some dubious eBay purchase.https://techemirate.com/fildo-for-pc-windows-mac/
Has anyone been successful in making an Ext SD Card usable in between apps...? And all the customary techniques I'm aware of and programmes (FX) that have previously worked don't.
Both the OS's built-in settings and the secret Developer Options to force write access are ineffective.
At this point, I'm wondering why Xiaomi even bothered to incorporate an SD Card slot because it is currently redundant and meaningless.
It's slow as hell and doesn't always work, so I have to copy it from the internal memory to the computer before copying it back from the computer to the external memory. It's a brand-new SanDisk MicroSD that I bought from a major retailer. So it's not like it's some dubious eBay purchase.https://techemirate.com/fildo-for-pc-windows-mac/
Re: Accessing a file on Android SD card
There's not a lot I can add to your own experiences. For reference:davidalex01 wrote: ↑Fri 17 Mar 2023, 00:10 Has anyone been successful in making an Ext SD Card usable in between apps...? And all the customary techniques I'm aware of and programmes (FX) that have previously worked don't.
- The only 'externally accessible' storage which is guaranteed to be writable is the application's own files directory, which is exposed as @usr$ in BBC BASIC. This typically isn't on an SD card (although it might be), but is accessible remotely, e.g. via a USB connection, so is suitable for transferring files either from or to a PC, for example.
- BBC BASIC requests the following storage permissions:
Code: Select all
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:maxSdkVersion="22" /> <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" android:maxSdkVersion="32" /> <uses-permission android:name="android.permission.READ_MEDIA_IMAGES" /> <uses-permission android:name="android.permission.READ_MEDIA_VIDEO" /> <uses-permission android:name="android.permission.READ_MEDIA_AUDIO" />
- BBC BASIC specifies the target SDK version as 31:
Code: Select all
targetSdkVersion 31
- I have seen suggestions (but not an authoritative reference) that recent versions of Android won't grant full permissions to side-loaded apps (that is, apps installed other than from the Google Play Store). Therefore I would recommend that you install BBC BASIC from there.