[mono-android] detect SD Card path?
Jonathan Pryor
jonp at xamarin.com
Thu Jun 7 20:30:24 UTC 2012
What is this i don't even...
So... The android.os.Environment API is designed with _one_ external storage directory in mind. Samsung has decided that it'll have _two_ (or more?!), and is returning the internal one in preference to the external one. That appears to be the short of it.
What do you do? I have no idea. I would suggest going to the Samsung developer portal and asking them how your Java app is supposed to use the Environment API to e.g. access Music files when Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_MUSIC) returns the internal directory and not the external one. (If you contact their forums, I'd suggest using Java terminology; no sense complicating matters with C#/Mono for Android unless it's actually relevant, and in this case I doubt that Mono for Android is relevant.)
Really, what they _should_ have done was union-mount the two filesystems into one mount point. At least then you could read both internal and external storage without going crazy. (Writing would be...problematic -- which would you write to, internal or external? -- but at least reading would be sane.)
- Jon
On Jun 7, 2012, at 2:48 PM, moelski wrote:
> Hi Jon,
>
> ok let´s make thing even more crazy ...
> My wife has a brand new Samsung Galaxy S3. And I took a look at the device
> ...
> There you have 2 folders in /mnt
> /mnt/sdcard >> taht is the internal flash storage
> /mnt/sdextcard >> that is the inserted sd card
>
> So this is again a new "solution" ...
>
> But what can I do now (and I think there are a lot of people with the same
> problem ...)?
> It´s hard for a normal user to find the correct mounting points in order to
> use the sd crad storage
>
> Dominik
>
> --
> View this message in context: http://mono-for-android.1047100.n5.nabble.com/detect-SD-Card-path-tp5710218p5710239.html
> Sent from the Mono for Android mailing list archive at Nabble.com.
> _______________________________________________
> Monodroid mailing list
> Monodroid at lists.ximian.com
>
> UNSUBSCRIBE INFORMATION:
> http://lists.ximian.com/mailman/listinfo/monodroid
More information about the Monodroid
mailing list