How can I play a sound using the dsp.AudioPlayer object in Ubuntu 12.04?

2 views (last 30 days)
I'm trying to play some data through the speakers in Ubuntu. I am able to use the "audioplayer" with the "play" commands successfully:
>>> p = audioplayer(data,48e3);
>>> play(p)
However, for some unknow reason, dsp.AudioPlayer object cannon find an audio device. Trying to run the following code results in an error:
>>> hAudio = dsp.AudioPlayer(48e3);
>>> step(hAudio, data);
Warning: Could not find the specified device (No audio output devices found (OSS)) in the list of devices. Switching to the Default device. Error using AudioPlayer/step Could not find the specified device (Default) in the list of devices.
I'm running Matlab 2012b. I'm able to run this code in a Windows machine with the same data without any issue (same Matlab version as well).
If I'm able to use the "audioplayer" and the "play" commands with no problems, why can't the dsp.AudioPlayer object find an audio device?
Any help is appreciated.
Thanks!

Answers (0)

Categories

Find more on Measurements and Spatial Audio in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!