I'm trying to make an MP3 player on top of the Linux kernel and busybox using the SDL and SMPEG libraries.

Does SDL work on top of the kernel or it needs PulseAudio?

I have just built a C program which plays mp3 files one by one from a directory. But when I put it on my ARM board nothing is happening, it justs hang in console, even plaympeg didn't work. But when I am using

plaympeg --novideo song.mp3

it shows

Couldn't init SDL audio: No available audio device

Can anyone guide me?


SDL doesn't need PulseAudio per se; however, it can use PA if it's available. It seems that SDL could run without X if a framebuffer is available.

You could begin from the examples at SDL's page to check whether it's a problem of your ARM board, and you probably will need to do other debugging on your audio player program (I would think it's a codec issue).

Since you're running on a Raspberry Pi, you might try this to see if you get audio working (I don't have my RPi here, so I can't test it).

  • can u tell me why plaympeg is not working?? – Shantanu Banerjee Dec 27 '12 at 17:34
  • I can't tell from the very little information you gave (what ARM board are you using? Which version of the Linux kernel? Which distro? etc...). More information (such as stack traces) would be needed. – Renan Dec 27 '12 at 17:44
  • linux 3.2.27 board raspberry pi, distro is my custom – Shantanu Banerjee Dec 27 '12 at 17:53
  • it shows Couldn't init SDL audio: No available audio device – Shantanu Banerjee Dec 27 '12 at 18:18
  • You say you're using a Raspberry Pi. Updated the answer with a link that may be relevant – Renan Dec 27 '12 at 18:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.