Hum filtering

You're almost certainly going to need to remove interference from the mains power distribution, which appears on all VLF receivers (even those in remote places like Antarctica). This takes the form of a strong 50 or 60Hz fundamental, plus odd harmonics running up to 5 or 6 kHz or more. Fortunately this is very easy to do with an automatic notch filter.

Run the command

vtfilter -a th=5 @timed:1 @filtered           # Stereo card
vtfilter -a th=5 @timed:1,2,3,4,5 @filtered   # Octo card

We're selecting here just the channels in @timed that contain signal and leaving behind the PPS channel which we don't need to process any further.

You now have a buffer @filtered which contains one or five channels of signal with mains hum removed. By default, vtfilter removes harmonics up to 6kHz. If you need to go further up than that, say, 8kHz, set a 'ul=' parameter, eg

vtfilter -a th=5,ul=8000 ...

to specify the upper limit for the auto notching. If you do need to use that option, it probably means your receiver is overloading and clipping the 50/60Hz signal somewhere, perhaps in the front-end or maybe in the isolating transformers which are not very linear at 50/60 Hz. Normally the default 6kHz upper limit is plenty.

Once you're happy with the vtfilter settings, add the start-up and shut-down commands to /root/radio, for example

#!/bin/bash

killall -q vtcard
killall -q vttime
killall -q vtfilter

if [ "$1" = start -o "$1" = restart ]
then

   sleep 2 # Delay needed when using Octo, the driver is slow to initialise

   vtcard -B -d hw:0,0 -r96000 -b32 -c2 -g-1 -L /run/vtcard.log -v @raw
   vtwait -t @raw

   vttime -B -m pulse+ -c2 -L /tmp/vttime.log -v @raw @timed
   vtwait -t @timed
   
   vtfilter -B -a th=5 @timed:1 @filtered
   vtwait -t @filtered
   
fi

As usual, a -B option puts vtfilter into background and we don't need a log file for this program. Stop your vtfilter in the shell and restart the radio system with the by now familiar command

systemctl restart radio.service

Running

vtstat @filtered

should show one or five channels, according to which sound interface you're using.


Back to Timing Up to Index   Next to Listen