Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've been using moc for a while on a laptop and it is great, but then I wanted to plug in USB radio as an output, rhythmbox and other players detected new output device, but moc has output hardcoded in ~/.moc/config, where is stated:

# Sound driver - OSS, ALSA, JACK, SNDIO (on OpenBSD) or null (only for
# debugging).
# You can enter more than one driver as a colon-separated list.  The first
# working driver will be used.
SoundDriver             = JACK:ALSA:OSS

# Jack output settings.
JackOutLeft             = "alsa_pcm:playback_1"
JackOutRight            = "alsa_pcm:playback_2"

# OSS output device.
OSSDevice               = /dev/dsp

# OSS Mixer device.
OSSMixerDevice          = /dev/mixer

# OSS Mixer channel: pcm or master.
OSSMixerChannel         = pcm

# Second OSS Mixer channel: pcm or master.
OSSMixerChannel2        = master

# ALSA mixer device.
AlsaMixer               = PCM

# Second ALSA mixer device.
AlsaMixer2              = Master

# ALSA output device.
AlsaDevice              = default

And I have no idea, what to change. Some tutorial on devices and some additional help is needed.

I suppose, I have to change something in alsa, but neither in moc nor in alsamixer, I do not know how to check, where is my usb device and what to change.

share|improve this question

I assume you are not using Jack audio server, but common Alsa:

Problem should probably be this line, which tells MOC to use default Alsa device (which is probably the internal sound card):

AlsaDevice              = default

Solution #1: Change your Alsa default device every time you insert your USB audio stuff. That is nicely mentioned at Alsa FAQ page: This can perhaps be scripted using udev (but that's another question I guess)

Solution #2: Create second config file for MOC with different setting of AlsaDevice variable and everytime you run MOC, setup which config to use with --config $FILE. But I am not sure how to set properly AlsaDevice setting in MOC

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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