HiFace and Linux
Posted by: Mr Underhill on 20 March 2013
To briefly recap:
A few years ago I did some experimentation using a laptop as a client;
I got some excellent results using the HiFace into an nDac;
To do so a used CMP2, and a VERY stripped down Windows OS, and so had NO networking.
Frankly, this was a pain and so I ended up buying an NS01, giving me two primary gains:
1. By routing the video from the NS01 into my TV I was able to REMOVE computing from my audio - hooray!! and
2. Ripping, whilst in no waybeing 'better', was a complete doddle.
And so my HiFace has sat in lonely isolation in my rack unused and unloved ....until today.
I had pretty much given up using Spotify, due to the five play rule for non-premium users, but yesterday I got an email saying this had been lifted. This gave me pause for thought, and it occurred to me that the long promised Linux driver for the HiFace might be available by now .....and it is.
I am curremtly using Ubuntu 11.10 and kernel 3.0.0-32-generic.
To get and compile the driver:
sudo apt-get install git
git clone git://github.com/panicking/snd-usb-asyncaudio.git
cd snd-usb-asyncaudio
make
ls
--you should see snd-usb-hiface.ko
snd-usb-hiface.ko is a module that needs to be loaded into the kernel. to make this automatic:
sudo gedit /etc/rc.local
-- now insert: insmod /usr/local/src/snd-usb-asyncaudio/snd-usb-hiface.ko
--Move the snd-usb-asyncaudio directory from your home directory to /usr/local/src/.
--Reboot your PC.
--Plug in your HiFace.
aplay -l
--You should see the the HiFace listed, in my case as Card1.
OK. You now have the module compiled and available, how do you get the audio from a program INTO the HiFace?
In my case Ubuntu loads PulseAudio. This is a piece of middle-ware that allows you to stream audio from programs to hardware interfaces. I therefore checked that the HiFace was available as a target, or a 'sink' in its terminology:
pacmd list-sinks
--It was and so I loaded a GUI to allow me to easily change the target hardware for an audio stream
sudo apt-get install pavucontrol
Voila!! Took my laptop downstairs, plugged it in and streamed to my hearts content. The result??
OK ....ish. Remember that I am using a NON-PREMIUM account, and so am not getting CD quality, and you can hear it. When a piece of music goes towards any climax it sounds highly compressed.
Now I am thinking of paying for premium!!
M