Last edited · 13 revisions  

 


Instructions

Based on notes provided by Basil - N7NIX and Corky - AF4PM

Mount your UDRC™ on a Raspberry Pi 2 or Pi 3

Note: Raspberry Pi 3 Addendum

ARMv6 Raspberry Pis are not supported. This includes the A/A+, Zero, Pi 1 B/B+, and Compute Module.

Make sure the pins are properly aligned and use the supplied standoffs to support the board above the HDMI port.

Universal Digital Radio Controller
Universal Digital Radio Controller

Install Compass Linux

See: https://nw-digital-radio.groups.io/g/compass/wiki/Installing-Compass-Linux-for-Raspberry-Pi

Basic Configuration

  1. From a terminal command line, verify that the UDRC™ is recognized by typing the command
    aplay -l	
    (that's a lowercase l) and observe that udrc is listed as a card. If you do not see it listed, power down and remount the UDRC™.
  2. To preset the pins and levels on the UDRC™ we provide a script. Execute the following:
    cd ~
    curl -L -s https://goo.gl/7rXUFJ > set-udrc-din6.sh
    chmod +x set-udrc-din6.sh
    sudo ~/set-udrc-din6.sh
  3. Optionally disable the internal sound chip by editing /boot/config.txt and commenting out this line (recommended unless you need it for something else):
    #dtparam=audio=on
  4. Reboot the Pi
    sudo reboot

Verify that Compass is seeing the UDRC

aplay –l

If you commented out the internal sound chip, as suggested above, only the UDRC will show, otherwise you will see a reply similar to:

card 0: ALSA [bcm2835 ALSA], device 0: bcm2835 ALSA [bcm2835 ALSA]
  Subdevices: 8/8
  Subdevice #0: subdevice #0
  Subdevice #1: subdevice #1
  Subdevice #2: subdevice #2
  Subdevice #3: subdevice #3
  Subdevice #4: subdevice #4
  Subdevice #5: subdevice #5
  Subdevice #6: subdevice #6
  Subdevice #7: subdevice #7
card 0: ALSA [bcm2835 ALSA], device 1: bcm2835 ALSA [bcm2835 IEC958/HDMI]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: udrc [udrc], device 0: Universal Digital Radio Controller tlv320aic32x4-hifi-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0

If using a Raspberry Pi 3

Lock the bus frequencies:by editing /boot/config.txt and adding the following line at the bottom:

force_turbo=1

    Save the file and reboot the Raspberry Pi.

    Configure the audio settings for the UDRC™/UDRC-II

    curl -L -s https://raw.githubusercontent.com/nwdigitalradio/udrc-tools/master/scripts/udrc-alsa-din6.sh | sudo sh

    Load libraries and header files to support the Fldigi install

    Load fast light toolkit and headers:
    sudo apt-get install libfltk1.3-dev  
    Load samplerate files and headers:
    sudo apt-get install libsamplerate0-dev
    Load PortAudio library and headers:
    sudo apt-get install portaudio19-dev  

    Source Code for Fldigi build

    Download the latest version of fldigi from SourceForge.(tar.gz version, version 3.23.15 at the time of writing, adapt if a newer version is listed)

    Unpack the tar file:
    tar -zxvsf fldigi-3.23.15.tar.gz  

    Build Fldigi

    Change to the fldigi-2.23.15 directory:
    cd fldigi-3.23.15  
    Build the object files and install:
    ./configure --with-portaudio  
    make  
    sudo make install

    Export the GPIO line for PTT

    (GPIO-12 for UDRC or GPIO-23 for UDRC-II on Din-6).
    Note: This script will need to be run whenever the pi is restarted

    For UDRC

    Create a script file (GPIO12.sh) to enable the export with the following contents:
    #!/bin/sh
    echo 12 > /sys/class/gpio/export
    echo out > /sys/class/gpio/gpio12/direction
    echo 0 > /sys/class/gpio/gpio12/value
    chown pi /sys/class/gpio/gpio12/value
    Set the file to be executable:
    sudo chmod u+x GPIO12.sh  
    Execute the script:  
    sudo ./GPIO12.sh

    For UDRC-II

    Create a script file (GPIO23.sh) to enable the export with the following contents:
    #!/bin/sh
    echo 23 > /sys/class/gpio/export
    echo out > /sys/class/gpio/gpio23/direction
    echo 0 > /sys/class/gpio/gpio23/value
    chown pi /sys/class/gpio/gpio23/value
    Set the file to be executable:
    sudo chmod u+x GPIO23.sh
    Execute the script:
    sudo ./GPIO23.sh

    Startup and set levels in fldigi

    Station Information

    On first run, fldigi will bring up the user setup page.
    Fill this page with your station information.

    Sound Card Setup

    Note: Make sure that UDRC is not selected as the primary sound card on the pi for the user session.
    i.e., if you select the speaker icon in the upper right corner of the display the check mark should not be on UDRC

    Within fldigi - Select Configure/Soundcard

    Select the Devices tab:
    • Select PortAudio and deselect all others
    • Select UDRC for both Capture and Playback
    [UDRC-II] Select the Right Channel tab
    • Check the reverse left/right channels
    Save the configuration

    Set up PTT

    Select the Configure/Rig Control
    Check the GPIO box and set the GPIO value to 12 (or 23 for UDRC-II)
    Make sure that the “use cat for PTT” box is not checked on the RigCAT tab.
    Save the configuration and close the configuration window
    Set the fldigi TX Attenuator to –6.0 (Lower right of fldigi window)
    Exit fldigi:

    Set output levels

    Set up radio
    Cable UDRC to radio (6-pin mini din or other)
    Radio set to low power
    Radio on dummy load for an antenna
    Radio set to monitor ALC

    Setup levels with alsamixer

    Make sure fldigi is not running and set initial UDRC output levels using alsamixer
    alsamixer  
    Press F6 and select the UDRC
    Using the arrow keys set
    • PCM to –26.5 db
    • Lo Drive to –6 db
    With alsamixer running open another terminal window and start fldigi.
    fldigi
    • Click the “Tune” button in the upper right corner of the window.
    • Radio should switch to transmit mode with little to no output power and no ALC indication.
    • Increase PCM until the ALC starts to indicate (on the IC-7000 this is about 2-3 bars of ALC on the digital display).
    Exit the alsamixer and save the settings
    Use ESC key to exit alsamixer
    sudo alsactl store
    Settings for IC-7000
    PCM: -22.5 db and LO Drive: -6 db which provides approximately 150 mv output for the UDRC.
    At this point deselect the tune button and the system is set for the proper SSB output level.