[Sussex] USB Speakers
Steve Dobson
steve at dobbo.org
Thu Jul 21 10:21:54 UTC 2011
Hiya List
Last night I was traveling home after being out with some friends when I
popped into my local 24 hour Tesco store. To make a short story long
:-) I needed some milk. My Tesco store puts any special offer items
(they probably just want to unload) near the entrance and I always give
it a quick look just in case...
Last night they were offering some Logitech S-150 USB Digital Speakers
at £12.97. One of the "issues" I have is listening to music and
watching vidieos on my netbook is that the built speaks don't really
hack it volume wise, sound quality is acceptable - just.
I do have some headphone socket plug-in speakers but I have issues with
those too. While they will work without power the sound volume is no
better than the netbook built-ins. So to get any real volume I either
have to plug yet another transformer into the mains (and run yet another
power cable), or supply the speaks with batteries.
I've been using rechargeable batteries mostly, but I feel this is
wasteful if I forget to turn the speakers off. Also I run the risk that
the batteries will need recharging just when I want them the most -
Sod's Law I think. :-(
So the idea of USB speakers appealed to me big time, and at at £13 I
thought they were a steal. I like Logitech as a brand anyway, I've had
some good kit from them over the years. But I also remembered John
"Nugget" Davis's recent thread on the problems he is/was having [1] with
a new graphics device. My advice to him then was on the lines of "be
wary of just buying computer hardware without first checking that it is
supported." And here I was breaking my own advice.
So it wasn't without feelings of trepidation that I plugged my new
speakers into my netbook when I got home. Would they work out of the
box? Plugging them in showed me that Logitech really do think about the
usability of their products - the right speaker only has a little
"DIGITAL" label that is back light by an LED. Cool! I hate trying to
find tiny little L & R labels in poor lighting conditions. Here was a
very simple way of not only telling the right speaker from left, but
that power was getting to the units.
So I hit the on-speaker vol+ button to see what the hiss level was like.
My old speakers do hiss a bit if maxed out. Surprise number one: On
pressing one of the volume controls (vol+, vol-, and mute) the Gnome
volume popup appears on my netbook screen.
Remember that at this point I hadn't done anything other than plug the
speakers into a USB port on the computer, and here they work working
with the GUI system. It wasn't that long ago that you needed an
advanced degree of cleverness to get this sort of thing work at all.
So I powered up my music player (Rhythmbox) but no joy. The built in
speakers were still being used. :-(. Not a problem I thought, just a
matter of selecting the new sound device. So I fired up the Gnome ALSA
Controller and yes, sure enough a "USB AUDIO (Alsa mixer)" was listed
and when selected the PCM controls were at the bottom (zero) level. So
I maxed them out - still no joy.
So to the GoogleCave Batman. I search as I always do. Google suggested
playing with "asoundconf" but I could find no such command installed.
Nor could I find the command in any package. No, it's been replaced
with alsactrl and the old command was still at the top of Google's hit
list for my search words.
After a bit more searching I found the Debian WIKI ALSA page [2] which
linked to the ALSA FAQs [3] which suggested I needed to edit either
$HOME/.asoundrc or /etc/asound.conf. I went for the /etc file:
pcm.!default {
type hw
card 1
}
pcm.!ctl {
type hw
card 1
}
After this edit and a restart of Rhythmbox I got sound, loud sound.
More volume than I was conformable with, but not unbearably loud. The
speaks put out 0.5W per channel which is plenty for something that isn't
that far form my ears, but not too much.
But the Gnome volume controls were not working. Both the GUI and the
speaker volume controls had no effect. What I think is happening is the
the USB speaker buttons are just feeding button pressed events to the
OS, and it is only the sound system (ALSA) that controls the volume.
As I had just edited the conf file I thought that there may have been
some programs that initialized before I made the edit so just to be
absolutely sure I rebooted - a test I consider doing anyway when I
change config in /etc.
One reboot later still no joy. The desktop popup volume control is not
effecting the volume on USB AUDIO device. Neither do the buttons on the
speakers. Rhythmbox's audio control does thought. So it appears to me
that the desktop volume controller (which gets the button events from
the USB AUDIO device) don't control the selected device, but the first
one on the list. I think we can call that a bug!
I was going to say "Bummer" but then I thought: "Hang on." I'm sitting
here listen to music. I have my Android phone (Linux powered) plugged
into a USB port so Rhythmbox uses my phone's collection of music files
(mostly OGG format). Whether I download new music on the phone or on
the netbook the files all end up in the one place. When I rip a CD it
goes straight to the phone. I doubt I have the biggest music collection
on this list, but 2 days, 5 hours and 25 minutes of audio on my phone
does give me some variety.
And it is all so easy to manage!
At one time a fair amount of traffic on this maillist was on how to get
devices to work. Plugging anything new into Linux was an exercise in
advanced computer skills. Today all I needed to do was edit a config
file to tell the system which of the devices the OS could see I wanted
used. No downloading of code, or patches or re-compiling of the kernel
need at all! Just a little config editing.
Yes, I do feel that the config file is not the way to do this. USB is a
plug and un-plug devices bus, and config files are not the best way to
cope with such a bus. The system *needs* to configure itself
dynamically to changes in the device environment, and the sound system
doesn't.
But Xorg does! When I plug in my tablet I don't need to change a config
file to tell it there is a change in input device. The tablet just
works! When I plug in a monitor all I need to is config the multiple
screen setup. USB attach stroage devices work fine: disks, flash
drives, cameras, my phone....
Linux has come a long way since I joined SLUG.
Steve
[1] http://mailman.lug.org.uk/pipermail/sussex/2011-July/016682.html
[2] http://wiki.debian.org/ALSA
[3] http://alsa.opensrc.org/FAQ026
--
Steve "Dobbo" Dobson
More information about the Sussex
mailing list