24
March
2023
Formation of a signal for VHF radio beacons in Pi4 mode
15:50

Formation of a signal for VHF radio beacons in Pi4 mode

24 March 2023 15:50

I received a message in the mail with the question of how to form a sound signal for a lighthouse in Pi4 mode.
In the article I talk about how to do it without the use of third -party hardware, only Linux with software capabilities.

Introduction

Radio beacons on the VHF are designed to track the signal passing, determining the conditions of the Tropo, in which, due to increased refraction of radio waves, long-range radio communications at VHF with high signal levels become possible. On ordinary days, the activity of amateur radio amateurs on VHF is low, but in the days of a strong path, it increases repeatedly, because The audibility of distant correspondents in analog regimes CW, SSB and digital species FT4, FT8, JT65A and others is dramatically improved. To detect an improvement in the spread of radio waves to VHF in time, beacons are used. It is constantly or most of the time current transmitters placed on frequencies intended for the v..

IARU in the region 1 allows narrow -lane bacins in the section 144.400 - 144.490 MHz according to VHF BandPlan, the Russian mesh of the frequencies of amateur service in the latest decision of the State Commission on Radio Frequences (GKRCH) Russia dated July 15, 2010 No. 10-07-01 Reference на частотный план диапазона R1: "при использовании радиочастот для любительской службы рекомендуется учитывать частотный план Международного союза радиолюбителей для района 1 в части, не противоречащей настоящему решению ГКРЧ". Полоса сигнала телеграфного маяка не должна превышать 500 Гц. Для широкополосных экспериментальных маяков исследований слабых сигналов предназначен участок 144,491 - 144,493 МГц, где разрешена полоса сигнала до 20 кГц.

The frequency of the RB1CA lighthouse in Priozersk is 144.420 MHz, the UA1ZFG lighthouse in Murmansk - 144.430 MHz.

Pi4 is an ideal digital modulation that corresponds to the IRU IRU for the VHR of the region 1 radio beacons in mixed mode "MGM - CW - Curvatory". The duration of the transmission is 1 minute (continuous transmission by almost without pauses - 100% working cycle 60 seconds), then the transmission is repeated.

In the article "Radio -beacon RB1CA in Priozersk" приведен опыт приёма маяка в программе PI4RX для Windows.

Search for information on the methods of signal formation brought me to the site OZ2M "Next Generation Beacons".

Resources for writing a program

What is Pi4 modulation?

Description of modulation is posted on the site OZ2M.

Pi4 - modulation with 4 tones (FSK). Two tones cannot sound at the same time.

ПарFSK models modulation depend on the coefficient K, which can take values 40, 80, 96 and 120. In fact, Pi4-RX recognizes only modulation with K = 40, and used it. Also, it is called "Pi4 modulation".

КажDoy frequency can be assigned to the 0, 1, 2 or 3. Duration of transmission of the signal formed by the machine (MGM - Machine Generated Mode) is approximately 24 seconds.

FSK-Code

At the reception, it is necessary to set the reception frequency with an accuracy of +- 50 Hz relative to carrier 800 Hz (preferably +- 12.5 Hz to narrow the frequency filter bandwidth stripes from 100 Hz to 50 or 25 Hz).

Четыре тона выровнены по сравнению с несущей 800 Гц на

  • Tone 0: -117,1875 Hz
  • Tone 1: 117,1875 Hz
  • Tone 2: 351.5625 Hz
  • Tone 3: 585,9375 Hz

The distance between the tones DELTAF = 12000/2400 * K, for the coefficient K = 40 is 234.375 Hz.
The duration of the symbol sound 2000/12000 = 0.166 seconds.

Name k DELTAF, Hz shift CW-FSK, Hz Strip, Hz
Pi4 40 234.375 250 709.125
Pi4-80 80 468.750 400 1412,250
Pi4-96 96 562,500 400 1693,500
Pi4-120 120 703,125 400 2115,375

Frequency tones Pi4 (K = 40) [/Mark]

Freq0 = 682.8125 Hz
FreQ1 = 917.1875 Hz
Freq2 = 1151.5625 Hz
Freq3 = 1385.9375 Hz

The frequency of the bearing = 800 Hz - for the exact settings for the signal (important!).

The first tone for dfcw = 800 Hz
The second tone for DFCW = 800-234.375 = 565.625 Hz (the frequency is not fundamental, because CW is not recognized in Pi-RX).

Lighthouse working cycle Pi4

The transmission repetition cycle - 1 minute starting with 00 seconds (time synchronization on the transmitter and receiver should be very accurate - better +-1 seconds.

Pi4Mod

Set of utilities for forming Pi4

File Description Entrance Exit
stage1.c The console application on the ANSI C language for the formation of a sequence of frequencies Pi4 - developed on the basis of the initial texts of the repository of programs with an open source code Github Guenael/TinyBeacon. It is used once. Callsign in the text Stage1.c Squeezed 146 digits
stage2.c The console application on the ANSI C language for encoding the call sign and locator in the frequency of the frequency of two -frequency CW manipulation (DFCW) - developed it independently. It is used once. Callsign, Locator in the text Stage2.c COUR COMS SECURITION OF CW
pi4-wav.sh Shell script of the author of PE1ITR for creating a WAV file with Pi4 modulations. To create sound (sinusoids), a utility is used sox. Exit programs Stage1.c and Stage2.c WAV file with PI4 modulation, for transmission
run.zsh Shell script for launch mpv имя_файла.WAV в начале каждой минуты. WAV-файл звук

The rule of writing the call sign in the first part of the message (MGM)

The length of the call sign should be 8 characters. After the call sign and “fractions”, you need to supplement the line to 8 characters with gaps at the end.
Table
By adding redundancy and the functions of the surveillance, these 8 characters during coding are converted into a pseudo -liable sequence from 146 characters. The duration of each symbol in the PI4 standard is selected 2000/12000 = 0.1666 seconds. The total duration of the MGM part of the message, in which, with the help of 4 tones, the call sign is transmitted - 24.32 seconds .

The rule of creating a message in the second part of the transmission of the lighthouse (CW)

The transmission of the call sign and locator at a speed of 12 WPM should be 12-20 seconds, for example, the RA1AHQ KO59CT message lasts 16.5 seconds. If the call sign is shorter, 4-digit, the length of the CW message decreases, and the length of the subsequent carrier CW increases automatically, which is provided in the Pi4-WAV.SH script.
Resolved characters - 0123456789ABCDEFHIJKLMNOPQRSTUVWXYZ /.
The restriction of the time of the second part of the transmission is due to the fact that the time should remain on the "mood" signal - carrier 800 Hz.

To improve the readability of the draft beacon in noise, you can use the CW transmission template " VV VV call signature ".

Carrier 800 Hz for configuration (third part of the program)

The SOX utility called with parameters from the PI4-WAV.SH script forms 800 Hz carrier (for configuration by "zero beats") at the transfer time remaining up to 60 seconds-60-24.3-16.5 = 19 seconds. The length of the last part of the bearing: 16-24 seconds, depending on the different duration of the CW part.

The rule of issuing the PI4 lighthouse messages on the air

Messages should be synchronized by time through the NTP protocol with maximum accuracy.
An acceptable is accuracy up to a second. The start of the transfer of messages is 00 seconds of every minute.

It is better to start the PI4 transfer for 58 or 59 seconds of every minute, because With the late beginning of the Pi4RX transmission, the signal does not decode.

The maximum deviations of the start time from 0 seconds: -2.5 ...+1.2 s.

The duration of the message is somewhat shorter a minute, for example, 58 or 59 seconds. Every minute the message is launched from the beginning. The transmitter in USB (or DIG) mode should work constantly, and the modulation is carried out using the WAV file, synchronized in time.
The transmitter frequency drift should not exceed +- 50 Hz ( 0.5 ppm = 72 Hz) at a frequency of 144.4 MHz.

Instructions (how to use a set of programs)

0) Set packages for compilation and the SOX program for sound synthesis - a sinusoid of a given frequency and phase.

sudo apt-get install build-essential sox

1) Correct the call sign in the original text of the Stage1.c file. The call sign along with the final spaces should occupy 8 characters strictly!
Compare the program and run it:

nano stage1.c
gcc stage1.c -o stage1
./stage1

2) Correct the text for the CW message of the second part of the lighthouse work, compile the program, start it:

nano stage2.c
gcc stage2.c -o stage2
./stage2

3) Edit pi4-wav.sh - write out sequences from paragraphs 1 and 2.

nano pi4-wav.sh

4) Launch a file that will form a WAV file for a lighthouse

bash pi4-wav.sh

4) Listen to the file in the same catalog: result.wav

5) We improve quality - we reduce clicks when changing the frequency of tones (FSK characters) - in Audacy we apply a low -frequency filter (remove the frequencies from 2 kHz and above) using the Equalizer effect.

sudo apt-get install audacity
audacity result.wav

To allocate - everything
Effects - graphic EQ

EQ

6) save the processed sound to the file result!.wav.

7) Preparation for the launch of the script - install zsh

sudo apt-get install zsh

8) Launch under Linux script run.zsh. From this, the PC will be transferred to the lighthouse.

9) Launch the program for Windows Pi4-RX. We look at the "waterfall" (for the test I connected the sound source of one PC under Linux with a cable with a receiver on another PC under Windows. In real conditions, the first PC should display the signal to the transmitter from the antenna lighthouse, and the second PC should be far from it at the reception).

10) When observing several transmission cycles, we clarify the time correction in the Run.zsh file (I have a constant -0.90 seconds) so that the reception has a minimum deviation of the start from ~~ beginning a minute of 0 seconds ~ ~ 59 seconds. For example, from -1.2 to +0.2 seconds depending on the cycle.
Progress4

Archive with the initial texts of programs:
*Pi4.zip


Data of the last change: 11.08.2025



Related publications