Direwolf

Direwolf can be found at https://github.com/wb2osz/direwolf. This box is based on Direwolf 1.2.

Compiling Direwolf

Direwolf is surprisingly easy to compile: if you followed the instructions in Software, then it is a matter of cloning the Direwolf repository on your Beaglebone, then follow the standard instructions for Linux:

git clone https://www.github.com/wb2osz/direwolf
cd direwolf
git checkout 1.2
make
sudo make install
make install-conf

Configuring Direwolf

You should then install the configuration for Direwolf in /etc/direwolf/direwolf.conf . This file, along with all other configuration files is located in the github repository of the project. /etc/direwolf/direwolf.conf.

You will need to set the "MYCALL" variable to your actual call sign before launching Direwolf, of course!

Also depending on how you are connecting to your radio, you can/should update the PTT and DCD lines to reflect the GPIOs you are using.

Last: by default, direwolf.conf is configured to listen only. Configure the "PBEACON" and/or "OBEACON" lines to enable beaconing if you want to.

Configuring Direwolf logs

For a box that is running 24/7, you should make sure direwolf's log output is properly handled. This is done through the syslog and logrotate facilities:

This way, all direwolf log output will be directed to /var/log/direwolf.log and be automatically rotated every day.

Configuring sound for Direwolf duplex operations

Beaglebone Audio Cape

If you are using the Beaglebone audio cape, there seems to be a kind of bug somewhere, where the audio cape hangs when direwolf sends audio. The solution is to define a mixing device in /etc/asound.conf and let Direwolf use this instead of the raw device:

root@aprs:/home/debian# cat /etc/asound.conf
pcm.card0 {
    type hw
    card 0
# mmap_emulation true
}
pcm.dmix0 {
    type dmix
    ipc_key 34521
    slave {
        pcm "card0"
    }
}
pcm.dsnoop0 {
    type dsnoop
    ipc_key 34523
    slave {
        pcm "card0"
    }
}
pcm.asym0 {
    type asym
    playback.pcm "dmix0"
    capture.pcm "dsnoop0"
}
pcm.pasym0 {
    type plug
    slave.pcm "asym0"
}
# 'dsp0' is espected by OSS emulation etc.
pcm.dsp0 {
    type plug
    slave.pcm "asym0"
}
ctl.dsp0 {
    type hw
    card 0
}
pcm.!default {
    type plug
    slave.pcm "asym0"
}
ctl.!default {
    type hw
    card 0
}

Then Direwolf needs to be configured to use pasym0 for its ADEVICE.

USB Dongles

A lof ot audio cards have a 48kHz clock inside, which generates strong harmonics at 144MHz, not ideal for APRS which is at 144.39 in North America.

Moreover, lots of USB dongles have a lot of trouble with RPis and BBB's. One dongle family that stands out is the C-Media-based dongles which can be bought for about $10 or less on Amazon. Search for SD-CM-UAUD on Amazon for instance, that dongle works great and does not have 144MHz harmonics.

Automatically starting Direwolf

Then next step is to make sure Direwolf automatically starts when the box boots:

This script needs to be linked to runlevel 2:

cd /etc/rc2.d/
ln -s ../init.d/direwolf S001direwolf

so that Direwolf starts.

At this stage, you can reboot your Beaglebone to check that Direwolf does start properly:

ps aux | grep direwolf
tail -f /var/log/direwolf.log

... you can then move on to installing Polaric Server

(Optional) Enabling telemetry on Direwolf

The latest development version of Direwolf (1.3 series snapshots) supports sending packets that are generated by external processes using the "CBEACON" command. It ships with a set of perl scripts that use this capability for sending telemetry packets.

One small script that can be super useful is the following: if creates a /tmp/seq file that increments at each call and wraps at 100, so that online services like aprs.fi are happy with sequence numbers on telemetry reports:

debian@aprs:~/aprs-box$ cat ../bin/inc.sh 
#!/bin/sh
SEQ=`cat /tmp/seq`
SEQ=$(expr \( $SEQ + 1 \) % 100)
echo $SEQ | tee /tmp/seq