Spectrum Lab Application: Beacon
Logger
By Wolfgang Buescher, DL4YHF
Last modified: October 12, 2001.
Note: some links only work if this file is located in the help directory
of Spectrum Lab.
If so, you can return here to the main index or look
at other sample applications .
Check for the latest release of Spectrum Lab somewhere at
www.qsl.net/dl4yhf
.
This application is used for propagation studies on shortwave. Radio amateurs
all over the world operate becons on certain frequencies (like 14.1 MHz).
These beacons periodically transmit a carrier and their identifier in Morse
code. Some of these beacons have a very low duty cycle but a precise interval,
for example 1 second carrier and 3 minute interval. This application takes
precise readings of the signal strength, and writes the result into a
text file which can be post-processed with a
spreadsheet program etc.
The settings for the two beacon-logging applications (presented below) can
be loaded from configuration files which are part of the installation package.
They are called "Beacon1.usr" and "Beacon2.usr". You can load them from Spectrum
Lab's file menu as explained here,
or add new entries to SL's quick settings menu as explained here. The latter
allows you to quickly switch between different settings.
A more recent beacon-logging example (from 2005) for the experimental MW
beacon DI2AG can be found in a separate
document (only in german language so far).
back to top
If the beacon you want to monitor has a very stable interval, try this (or
load the BEACON1.USR example into SpecLab from the "Quick Settings" menu):
-
Set the waterfall scroll interval to less than half the length of the beacon's
"key-down" interval
(under "Options..Display Settings"). For example, if the carrier is "on"
for 5 seconds, use a 1-second waterfall scroll interval.
-
Set the frequency resolution (FFT length and audio sample rate) to an appropriate
value. For shortwave observations, a frequency resolution of 1 Hertz is enough.
See "important note" below.
-
Set the "Write Interval" for the file export function to the beacons cycle
time, for example 30 seconds.
(in the "Text File Export" configuration dialog)
-
Use the "peak_a(f1,f2)"-function to
detect the amplitude of the carrier in a narrow frequency range. Allow a
few Hertz of 'drifting range' for the parameters f1 and f2. This numeric
expression must be entered in the export
definition table. The "peak_a" function will look at the spectrum which
has been recorded over a few seconds.
There is one problem with this approach: you must precisely start the export
function to catch the key-down phase. If your PC's clock or the beacon's
clock is drifting a bit, the "sample slot" will slowly move away from the
beacons key-down phase, no matter how precisely you measured the beacon's
cycle time.
-
Important Note:
-
To get an appropriate frequency resolution (not too high and not too low),
you must carefully select the FFT length and audio sample rate, for example:
FFT length = 8192 samples; no decimation; ADC sample rate = 11025
samples/second gives a resolution of about 1.4 Hz.
The FFT length and sample rate also set the time required to collect samples
for a "new" spectrum. In this example, it takes about 0.75 seconds to collect
samples for a completely new spectrum (without "overlap" or "sliding average").
Overlap would spoil the accuracy in this case. You can notice the overlap
effect by a "smeared" waterfall along the time axis, if the waterfall scrolls
much faster than the time required to collect samples for a "completely new"
spectrum).
back to top
To catch the carrier amplitude of a beacon with low duty cycle without the
need for precise timing, there is a different solution which will result
in a very clean exported file. Principle:
-
Measure the carrier's peak amplitude in a 1-second interval. Compare this
to the previously detected peak (which is saved in a variable). If the new
value is lower than the old, forget the new one.
-
Repeat this for 30 consecutive 1-second intervals. If the beacon transmits
a 2-second carrier every 28 seconds, we can be sure that we have the correct
peak value
-
Write the maximum peak value into the export file. After this, set the variable
for the peak value to a negative value. Start again with step one.
In Spectrum Lab, the steps described above can be performed simultaneously
for many different frequency ranges. The following interpreter commands must
be entered in the export configuration dialog to do the job (or load the
BEACON2.USR example into SpecLab from the "Quick Settings" menu) :
-
Turn the checkmark "Use Write Interval" on, and set the write interval
to 30 seconds
-
Define the expression for one column of the export file like this
(for example, column
2 of the export file = line
2 of the definition table):
max(peak_a(795,805),export.value[2])
(this expression detects the main peak between 795 and 805 Hz audio, compares
it to the old value from column 2, and returns the maximum
of both values which will be the "new" value for this colum. It you entered
this in column 3, you would have to use index [3] in
the expression).
-
In the edit field named "After writing a line to the export file, execute
these commands", enter this:
export.value[2]=-200
(this sets the exported value in the second export column to a new starting
value, as in the last step of the principle described above)
back to top