Quisk and PulseAudio
This is a step towards connecting the Quisk output to Fldigi.
Quisk is already configured and working on your system.
You are running Ubuntu 10.4 (this probably works for newer versions too.)
You will need the pavucontrol application and it is not installed by default. To add it:
$ sudo apt-get install pavucontrol
You also need to have PulseAudio properly configured on your system. A good guide can be found at http://www.pulseaudio.org/wiki/PerfectSetup. The most important part is that you have a ~/.asoundrc file with these settings:
# If defaults.namehint.showall is set to off in alsa.conf, then this is
# necessary to make this pcm show up in the list returned by
# snd_device_name_hint or aplay -L
hint.description "Default Audio Device"
If you don't have that file, create it now.
First you need to make a copy of your quisk configuration file. We'll modify and use that copy so that your default configuration will continue to work as a fall-back.
The quisk configuration file is ~/.quisk_conf.py. Make a copy of it and then change a few lines as shown below:
$ cp .quisk_conf.py quisk_pulse_conf.py
Open quisk_pulse_conf.py in your favorite editor, find the name_of_sound_capt and name_of_sound_play lines and change them to look like this:
If the settings don't exist in your quisk_pulse_conf.py file, then add them as show above.
The last change to the configuration file is a change to the playback latency. You may not need this change but on my system it was necessary to keep the playback from stopping. I needed a 200ms delay rather than the default 150ms. Larger values also worked, so experiment to find what works for you. The playback latency should be set by adding (or changing) this line in quisk_pulse_config.py:
latency_millisecs = 200
Now start quisk using the modified configuration file. This example code assumes that your quisk installation directory is ~/quisk-3.5.8/, if you used a different directory, then change the first line appropriately.
$ cd ~/quisk-3.5.8/
$ python ./quisk -c ~/quisk_pulse_conf.py
Quisk should start up, but it is likely that it is not using the correct input and output channels. So we'll fix that next using the pavucontrol program installed during the preparation step above. Leave quisk running and startup pavucontrol.
Then navigate to the Recording tab and select your sound device. Note that quisk is not listed and we have to infer that the ALSA plug-in [python2.6] is actually the quisk capture input.
When selecting a device from the drop-down list, do not select a Monitor device. Here is what the list of devices on my system looks like. Yours is probably shorter (I have 4 sound cards connected).
You probably do not need to change the Playback device unless you have multiple cards installed on your system. Here is what the Playback setting looks like on my system:
That should do it. You should now be seeing signals in the quisk display and hear the decoded output on your speakers or headphones. If you only see signals in the quisk display and there is no audio output, exit quisk, increase the latency_millisecs setting and restart quisk.
You should only need to run pavucontrol and assign the Recording and Playback devices one time. The settings are non-volatile. However, if you have multiple sound cards you may have to make adjustments after each re-boot unless you have adjusted the boot time enumeration of the sound cards.
Why does output from quisk stop when using PulseAudio? Changing the latency_milliseconds setting seems like a cover-up or work-around for another problem.
What changes are necessary for TX?