Quisk/Linux Setup Guide

General discussion and support for the Peaberry SDR V1.

Quisk/Linux Setup Guide

Postby hansvi » Mon May 06, 2013 10:07 pm

This document describes how to get a Peaberry V1 working with GNU/Linux and Quisk. I used Debian 7.0, but Ubuntu will be very similar if not identical. If you use another distribution, you may have to fiddle around a bit.

First test if the Peaberry is correctly detected by the system:
Code: Select all
hans@Aspire:~$ cat /proc/asound/cards
 0 [Intel          ]: HDA-Intel - HDA Intel
                      HDA Intel at 0xd4500000 irq 46
 1 [SDR            ]: USB-Audio - Peaberry SDR
                      AE9RB Peaberry SDR at usb-0000:00:1d.7-3.1, full speed

(From here on, all the commands are executed as root).

Here, we see that card 1 is the Peaberry. Now, we have to set the permissions for this device. Create a file /etc/udev/rules.d/99-peaberry.rules and enter the following rule:
Code: Select all
SUBSYSTEM=="usb", ATTR{idVendor}=="16c0", ATTR{idProduct}=="05dc", MODE="0660", GROUP="dialout"

this will allow read/write permissions to everybody in the group "dialout". Of course that implies you add the user to that group:
Code: Select all
usermod -a -G dialout hans

You can now reload the udev rules with this command:
Code: Select all
udevadm control --reload-rules

... or just reboot. Note that you would need to log out anyway to gain the "dialout" privileges.

Now we install the software dependencies:
Code: Select all
apt-get install python-wxgtk2.8 python2.7-dev fftw3-dev libasound2-dev portaudio19-dev make

and also download the latest version of quisk.

The following commands will compile the C part of quisk:
Code: Select all
root@aspire:~# cd /opt/
root@aspire:/opt# tar xvf /home/hans/Downloads/quisk-3.6.9.tar.gz
root@aspire:/opt# cd quisk-3.6.9
root@aspire:/opt/quisk-3.6.9# make

Then, make a launch script /usr/local/bin/quisk
Code: Select all
python /opt/quisk-3.6.9/quisk.py

and make it executable:

Code: Select all
root@aspire:/opt/quisk-3.6.9/softrock# chmod 755 /usr/local/bin/quisk

by this time, if you run quisk, it should start, but using your normal sound card.

In order to work with the peaberry, you'll need a hardware interface and a config file. These can be downloaded here:

(3.66 KiB) Downloaded 697 times

And need to be placed in the correct directories.

Code: Select all
root@aspire:~# cd /tmp
root@aspire:/tmp# tar xvf quisk-peaberry.tgz
root@aspire:/tmp# cd quisk-peaberry
root@aspire:/tmp/quisk-peaberry# cp hardware_peaberry.py /opt/quisk-3.6.9/softrock/
root@aspire:/tmp/quisk-peaberry# exit
hans@aspire:~$ cp /tmp/quisk-peaberry/quisk_conf.py ~/.quisk_conf.py

Notice the dot in the last line, the target filename is not the same as the source filename.

The hardware file is basically a modified hardware_usb.py to make it work with the peaberry. It also adds a small delay before turning off PTT on the keyer input, this helps greatly with CW keying.
Hans - ON8VQ
Posts: 70
Joined: Wed Apr 24, 2013 3:37 am

Re: Quisk/Linux Setup Guide

Postby CT1IQI » Fri May 10, 2013 5:47 pm

(Ubuntu 12.04)
The enumeration given to usb sound devices is not a fixed one, unless forced by user made prescriptions.
Without prescriptions the enumeration will just be on first come first serve basis. The Peaberry may come up under different card numbers.
It is important to force these card enumerations to be identical between boots and different usb sound device configurations when one uses
the alsa 'card number' format (e.g. hw:1.0) in Quisk's configuration, i.s.o. of unique card names.
This forced enumeration can be set in the //etc/modprobe.d/alsa-base.conf configuration file.

1) comment out the 'options snd-usb-audio index=-2' line
# Keep snd-usb-audio from beeing loaded as first soundcard
# options snd-usb-audio index=-2

2) add a section, here can example to be adapted to your needs:
# USB Magic
alias snd-card-0 snd-hda-intel
alias snd-card-1 snd-usb-audio
alias snd-card-2 snd-usb-audio
options snd-hda-intel index=0 enable=1
options snd-usb-audio index=1,2,3 vid=0x16c0,0x0c45,0x05e1 pid=0x05dc,0x60af,0x2010 enable=1,1,1

The two relevant drivers in this case (one driver can service multiple devices through multiple instances) get card(s) assigned through 'alias' statements
The 'options' lines assign one or more index numbers ( = card numbers) and in case of multiple devices allow to filter on usb vendor and prduct IDs (see lsusb).
Per ID the driver can be enabled or disabled for that device.
Note the peculiar notation of a list of vendor IDs and a list of product IDs, and an enable list, that are interpreted as triplets per identical position in the lists.
Reboot the system to have these card number assignments take effect. I noticed that once an enumeration has been made that given number will not be overruled and changed by this new definition.
Card numbers have to remain reserved from boot to be taken at the time the card appears.
This example shows the Intel motherboard audio (0), the Peaberry (1), and a usb headset (2).
Posts: 21
Joined: Fri Apr 19, 2013 6:15 pm

Return to Peaberry SDR V1

Who is online

Users browsing this forum: No registered users and 1 guest