Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to add an SD card to genymotion?

Tags:

genymotion

In genymotion settings->storage there is only the internal storage, no SD card.

Is there a way to have a SD card also?

like image 273
telebog Avatar asked Aug 01 '14 22:08

telebog


People also ask

How do I enable drag and drop in Genymotion?

You need to open Oracle VM Virtual Box that was installed with GenyMotion (or manually). Select the emulator and go to "configuration -> Advanced" and check "enable drag and drop" or something like that. Relaunch the emulator and drag n drop should be available ! Enjoy !

Why is my Genymotion not working?

Reboot the PC (Windows) On Windows, a reboot is usually enough to fix the problem after Genymotion Desktop first run.

How do I access Genymotion files?

Your folder is available in the mnt/shared folder, accessible by default in Android's File Manager.


1 Answers

There's already some emulation of SD card (external) storage in Genymotion that might work for you, depending on what you're trying to do. Although Settings->Storage doesn't show it separately as External Storage like you might expect, Genymotion does emulate external storage. The size of files stored there will be reflected in the totals shown under Internal Storage by Settings-Storage.

Running in Genymotion, an app using Environment.getExternalStorageDirectory().getPath() or .getAbsolutePath() will get back /storage/emulated/<userId>, where userId=0 if the app is running as Owner, and 10, 11, 12, etc. if the app is running as another user or restricted/managed profile. The Android framework actually maps this for you to /mnt/shell/emulated/<userId>, which is why you won't find /storage/emulated/<userId> if you use a shell to poke around.

The paths /sdcard and /mnt/sdcard are symlinks to /storage/emulated/legacy, which is basically the Owner's storage. Don't use these in your apps, since they might not exist everywhere and/or your app might not have access to them if not running as Owner. They are just there to support legacy hardcoded apps.

Not being sure what you're trying to do, it's probably also worth mentioning that Genymotion now supports VirtualBox shared folders which will appear under /mnt/shared inside your VM. Check their Google+ post for instructions.

like image 74
Paul Ratazzi Avatar answered Oct 17 '22 01:10

Paul Ratazzi