0

I want to add a ringtone sounds to my Andoid emulator, and have found instructions here: Add ringtones in android emulator

The problem is that when I look at the File Explorer tab in DDMS, with the (Nexus 4) emulator running, it is completely empty. Using the emulator I can see that I have a 2Gb SD card installed.

Any ideas for how I can access the SD card on the emulator and load a ringtone?

Community
  • 1
  • 1
Ian M
  • 567
  • 8
  • 33
  • ... try **selecting the device** in the LEFT PANE. – Phantômaxx Jun 03 '14 at 13:01
  • Thanks. How do I now make the file system writable (it's telling me it's read-only)?? – Ian M Jun 03 '14 at 13:33
  • See this question: http://stackoverflow.com/questions/2083709/android-emulator-sdcard-push-error-read-only-file-system – Phantômaxx Jun 03 '14 at 14:33
  • Thanks. I got it unlocked and have copied both an mp3 and an ogg file to /mnt/sdcard/ringtones, but when I go to settings/sound in the emulator and try to change the default ringtone or notification sound I don't see either of the files shown as options. In fact there are no options - just "None". I have restarted both Eclipse and the emulator. How can I make these files accessible as ringtones/notification tones? – Ian M Jun 03 '14 at 14:58
  • I don't know if you can. ringtones are normally stored in `/system/media/audio/ringtones/`, which requires **root access**. It can access files from the sd card, but won't search them, because it's not meant to use the ringing feature (while the notification might do). As an EXTREME tiral, try moving the files to `/mnt/sdcard/media/audio/ringtones/` same for `.../notifications/` and `.../alarms/` – Phantômaxx Jun 03 '14 at 15:25
  • I tried moving the files to /mnt/sdcard/media/audio/ringtones/ but they still weren't visible. The /system/media/audio folder only has 2 subfolders - ls and ui, so nowhere to put ringtones or notification sounds. – Ian M Jun 03 '14 at 16:05
  • What if you create the folders in `/system/media/audio`? can you? I think it requires **root privileges**. Maybe it doesn't even scan for media files on the sdcard, due to an **avd limitation**. Anyway, on the physical device, everything should work fine. – Phantômaxx Jun 03 '14 at 16:17
  • OK I managed to get write access, createds /system/media/audio due to the file system being read-only. – Ian M Jun 03 '14 at 16:36
  • If the (**/**) file system is read only you can do nothing: You can't root your emulator, I guess. – Phantômaxx Jun 03 '14 at 16:40
  • OK I managed to get write access to /system, created /system/media/audio and copied my mp3 to it. Then shutdown and restarted Eclipse and the Emulator....my mp3 now shows in Android as an option for a ringtone, but not for a notification. Any idea which folder it needs to be in to be recognised as a notification sound? – Ian M Jun 03 '14 at 16:42
  • `/system/media/audio/ringtones/` for ringtones and `/system/media/audio/notifications/` for notifications, as in your phone – Phantômaxx Jun 03 '14 at 16:45
  • Ok so I put the mp3 into /system/media/audio/notifications/ but it still doesn't get listed an as option for a notification sound. Does it need to be an OGG to be used as a notification sound? – Ian M Jun 03 '14 at 17:05
  • No, mp3 goes on the phone. But try - even if I'm always more convinced that you can't persuade the emulator... – Phantômaxx Jun 03 '14 at 17:08
  • I think maybe this is related to the Android 4.4.2 bug with notification tones? – Ian M Jun 04 '14 at 13:10
  • I'm not awar of `the Android 4.4.2 bug with notification tones`. If in doubt, try running another emulator. – Phantômaxx Jun 04 '14 at 13:15

0 Answers0