LOPORA QRSS BEACON RECEPTION PROGRAM
WRITTEN IN PYTHON
KLIK HIER VOOR DE NEDERLANDSE VERSIEReception of very low QRSS beacon transmitters
QRSS beacons in the 100 Hz wide band in the 30 meter amateurband. Some signals are wider
due to the fading. That kind of effects are very good visible due to the narrow bandwidths!
The new version 03 of Lopora runs without problems on an overclocked Raspberry Pi.
A HDMI to VGA converter is used to connect an old VGA monitor.
And the screen of the audio input had to be grounded to suppress interferences.
The QRSS beacon reception program LOPORA with visible thunderstorm interference.
The screen does not scroll, but the cursor goes from left to right. Scrolling can
be implemented, it is a function in the PIL library of Python.
The FFT calculation
What an FFT window does, is visible on the picture here below. But for our purpose, the simple Cosine filter or Triangular filter is excellent! You can select the FFT windows by means of a button.
What an FFT window does, is visible here. On top a strong signal, at the bottom a 40 dB weaker dot-dot signal.
From left to right you can see the following FFT windows:
1. No window (also called rectangular window). Much noise around a strong signal, a good selectivity (1x) for the weak signal.
2. Cosine window. Much less noise around the strong signal, so a better dynamic range, somewhat less selectivity (1.24x).
3. Triangular window. comparable with the Cosine window, less selectivity (1.33x).
4. Nuttall window. Very good dynamic range, but less selectivity (2.02x) resulting in less sensitivity for the weak dot-dot signal.
5. Flattop window. Very good dynamic range, filter with flat top, but much less selectivity (3.77x). Usable for signals made wider by fading or frequency instability.
When a signal is between two FFT frequency points, it is attenuated. By means of Zero Padding, extra FFT frequency points will be added between the original points during the calculation, reducing the attenuation (also called Scalloping loss) so that it becomes negligible. An alternative is not to use Zero Padding, but a wider Nuttall of Flattop Window. The latter does have a flat top across a few FFT frequency points. But those windows do have a larger bandwidth. Zero Padding has to be configured in the configuration file.
Of course it is not possible to coincide a dot exactly with an array of FFT samples. That is why the FFT array is always re-used partially. With an FFT overlap of 2, 50% of the FFT array is deleted, 50% re-used and complemented with 50% of new samples. The FFT overlap does also influence how long it takes to fill the whole screen. I do use an FFT overlap of 2.9 to fill the whole screen in approximately 20 minutes. The minimum value for the FFT overlap is 2.0. The bigger the overlap, the more processing power is required. FFT overlap has to be configured in the configuration file.
ZL1EE, no stacking.
Stacking, 3x average.
Stacking, 3x peak.
YT1DL, no stacking.
Stacking, 3x average.
Stacking, 3x peak.
W4HBK, no stacking.
Stacking, 3x average.
Stacking, 3x peak.
Snapshot and FTP upload
By pressing the button "Snapshot", you can activate the function to save the received pictures. And also the FTP upload function. As it is possible to upload the received pictures to you website for use as a grabber. Others can see then what you do receive. You can program the FTP settings in the first lines of the software. If this data is missing, it will be asked for when you press the button "Snapshot" and do enable FTP uploading. In the ZIP file, you can also find an example of a HTML file for the grabber. If you want to know more about grabbers, google then for "QRSS grabber".
Together with the pictures, you can also upload a sound record file of 10 seconds from the receiver. In that way, you can hear if there is a thunderstorm or a strong signal that can disturb the reception. You have to make the variable WAVenabled = True. It can be found in the first lines of the program.
If the function FTP upload is enabled, also a configuration file with the name "lopold.cfg" is uploaded. You can edit it and rename it as "lopnew.cfg". During the next FTP upload, these new settings are taken by LOPORA. You have to set the variable Remote = True in the first lines of the program.
The trick is to configure the setting "10138467 Tuning frequency of the receiver in Hz" in the configuration file so
that the calibration signal is displayed exactly on 10140.000 kHz. The frequency standard is not completely stable!
PC speed and downsampling
Python is simple, but much slower than C. Fortunately, our modern PC's are fast enough for LOPORA. And as the source code is written in ASCII text, everything can be modified very easily. Great! If CPU speed is a problem can be checked by watching the Buffer(%) on the screen. If it goes above 100% and if long marker lines appear on the lower axis (stop and restart), then you PC is too slow.
Also the downsampling of the audio is a reason that much less CPU time is required. This downsampling does happen very fast in the operating system of your PC. But there is an other very important advantage of the downsampling. All frequencies above 50% of the sample rate will be suppressed by the downsampling! The downsampling does also work as an extra low pass filter and suppresses the interferences at higher audio frequencies. With a sample rate of 6000, all frequencies above 3000 Hz are suppressed. The usable frequency range goes then upto approximately 80% of this frequency or 2400 Hz. And this is a perfect match with the bandwidth of a normal SSB receiver. So do use a maximum sample rate for the audio stream of 6000, this acts like an extra interference suppressing low pass filter and does use much less CPU power!
QRSS reception is a very relaxing hobby!
WAVinput = 1 # DEFAULT 0 for Audio device input, 1 for WAV file channel 1 input, 2 for WAV file channel 2 input
When the variable AUTORUN = True, the program will start to run automatically. You can start it by placing a shortcut to the program in the start menue. For the auto run option, you have to initialize the next variables at the begin of the program:
AUTORUN = True # Default is False. True for Automatic Run.
FTPenabled = True # If True, upload snapshot. Can be modified with the Snapshot button.
FTPhost = "FTPhostname" # FTP host
FTPuser = "FTPusername" # FTP user
FTPdir = "FTPdirectory" # FTP remote directory
FTPpassword = "FTPpassword" # FTP password, if none ("") then the password will be asked
SNAPshotenabled = True # If True, save snapshot. Can be modified with the Snapshot button.
WAVenabled = True # A WAV audio snapshot is made and uploaded just after the FTP snapshot
Remote = True # Remote control by file lopnew.cfg enabled
AUDIOdevin = None # Audio device for input. None = Windows default. Can be modified with the Audio device button.
AUDIOdevout = None # Audio device for output. None = Windows default. Can be modified with the Audio device button.
It is a DISPLAY compression mode. See here below the effect of changing the DISPLAY compression.
No compression (DISPLAY = 0).
Very good for the two weak signals, but the strong signal is quite distorted.
Maximum compression (DISPLAY = 3).
The strong signal is not distorted anymore and the two weak signals are still visible.
SOFTWAREBefore you are using this program, you have to install Python. That is very simple. But read first something about Python by clicking the following link:
WHAT IS PYTHON AND HOW DO YOU INSTALL PYTHON
As the source code of Python is written in ASCII, it is very simple to modify the program to you own requirements. Think for example about the size of the screen, the colors etc.
Required Python version:
Download here the Python LOPORA QRSS beacon reception program by clicking the link here below:
BACK TO INDEX PA2OHH