0

Has anyone had success streaming music via a miniDSP usbstreamer b unit?

I'm attempting to cut out an extraneous digital->analogue conversion in my laptop-powered stereo system. The usbstreamer b unit would allow my stereo to do just a single digital to analogue conversion. Hopefully there is a way to make it compatible with Linux.

Ubuntu 16.04 recognises the unit and can be configured to send audio to it. But the usbstreamer does not appear to be generating a toslink signal, so I suspect Ubuntu is sending the wrong data to the usbstreamer.

I've set the firmware on the usbstreamer to toslink, using a windows box.

edit (July 1st 1016): I can get some sound to broadcast from my laptop. If I run the ALSA test wav files through aplay, they play. But I can't get any other sound to broadcast to the usbstreamer.

Does anyone know what this is a symptom of? aplay works, but no other system sounds get broadcast? In particular I would like to get to the point where I could get software like Rythmbox to play via the streamer. For example, in the "Sound Settings" dialogue (Ubuntu default) if I set output to USBStreamer, this results in none of the system sounds being sent to usbstreamer -- or at least, not in a way that the streamer can understand. Because they don't play.

Here is what I have done that has been successful:

aplay -l

**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: ALC269VC Analog [ALC269VC Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: USBStreamer [USBStreamer], device 0: USB Audio [USB Audio]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 7: HDMI 1 [HDMI 1]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 8: HDMI 2 [HDMI 2]
Subdevices: 1/1
Subdevice #0: subdevice #0

aplay -D plughw:1,0 /usr/share/sounds/alsa/Side_Left.wav

After some googling around it appears the usb-audio driver needs some setting up. ALSA sees the usbstreamer, but it looks like Ubuntu has no ready-made driver and ?perhaps? something can be cobbled-together with the usb-audio driver. It looks like I might have to set up an .asoundrc file. These pages seem particularly relevant:

https://help.ubuntu.com/community/UbuntuStudio/UsbAudioDevices

http://www.alsa-project.org/main/index.php/Matrix:Module-usb-audio

edit 2:

Finally, I'm playing music with mplayer, from my linux laptop to my speakers, via the usbstreamer and minidsp 4x10hd unit.

The key thing I did not understand is it's better not to use pulseaudio with high-end speakers. . . and the Linux community figured that out long ago. So they developed a distinct audio interface, called Jack.

I haven't figured out all the quirks yet, but the "Jack audio connection kit" has a nice GUI for setting up the audio interface. mplayer will stream straight to jack.

So all my music appears to play fine, now. Hmm, likely I'll have to rip all my music at a higher sample rate, now...

Once I have everything working smoothly I'll post something that is hopefully easier to follow, perhaps as an answer.

  • May be it would be simpler to use a hdmi to digital audio converter like this one: ebay.com/itm/… – laugeo Jul 1 '16 at 8:56
  • It's a little unclear if that does what I'm looking for. Do you know if this handles all the various (up to 192kHz) sample rates? I imagine it likely does, but they do not mention it. – Ryan Budney Jul 1 '16 at 16:45
0

The Jack Audio Connection kit does precisely what I'm looking for. The main issue I ran into is I was trying to solve my problem with Pulseaudio, but it appears jackd is the daemon of choice for hi-end audio, in Linux.

Jack-plumbing makes setting up persistent connections between applications and the audio system convenient, especially on linux boxes that do not have monitors. qjackctl is one of many ways you can do it if you want to use a GUI. I found the jack-plumbing file format a little obtuse, so I used qjackctl to help determine the file format.

For example,

(connect "MPlayer \[[0-9]+\]:out_0" "system:playback_9")
(connect "MPlayer \[[0-9]+\]:out_1" "system:playback_10")

is the contents of my .jack-plumbing file (at the top of my home directory) that sets up a persistent connection between mplayer and my audio system.

I grabbed these lines from the qjackctl "patchbay" file:

<!DOCTYPE patchbay>
<patchbay version="0.4.2" name="patchbay">
<output-sockets>
<socket exclusive="off" name="MPlayer \[[0-9]+\] 1" client="MPlayer \[[0-9]+\]" type="jack-audio">
<plug>out_0</plug>
<plug>out_1</plug>
</socket>
</output-sockets>
<input-sockets>
<socket exclusive="off" name="system 1" client="system" type="jack-audio">
<plug>playback_9</plug>
<plug>playback_10</plug>
</socket>
</input-sockets>
<slots/>
<cables>
<cable output="MPlayer \[[0-9]+\] 1" input="system 1" type="jack-audio"/>
</cables>
</patchbay>

A command such as

mplayer -ao jack blah.mp3

is enough to play the blah.mp3 file over the system.

edit:

An alternative solution is to create /etc/asound.conf and make it this:

pcm.usbSTR { type hw card USBStreamer device 0 } pcm.usbREMAP { type plug slave.pcm usbSTR ttable.0.8 1 ttable.1.9 1 } pcm.!default { type plug slave.pcm usbREMAP } ctl.!default { type plug slave.pcm usbREMAP }

This allows you to avoid Jack altogether, and pipe directly to ALSA.

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.