I need to download mp3 files to an sd card in Android Studio and then read them, firstly, how can i create an SD card for my emulator? Secondly, how can I add files to it? I\'m
I had the same problem. I needed a lot of space for saving images in the emulator. My solution was creating an image sdcard and attach it to emulator. I followed these steps:
1 ) Create an image of external sdcard:
~/Library/Android/sdk/tools/mksdcard -l mySdCard 20G path/mySdCard.img
2 ) Create an emulator with the external sdcard:
~/Libarary/Android/sdk/tools/bin/advmanager create avd -n EMULATOR_NAME -k “system-images;android-24;default;x86” -f -c path/mySdCard.img
3 ) I searched for the external storage path with adb shell because the path to push the files is not very intuitive.
My sdcard path is in storage/15F5-0C07/
4 ) Push the files into external storage path
~/Library/Android/sdk/platform-tools/adb push localPath /storage/15F5-0C07
I wrote all of the steps because I searched a lot for pushing the files into external storage and not into internal storage