500 kHz beacon transmitter.
This beacon transmitter can frequently be heard on 503.700kHz around the southern UK. It generates a sequence of outputs in 3 different modes The RF electronics in the transmitter produces 6 Watts output but the antenna only radiates 2.5mW ERP. My motivation in building the beacon was to discover how to generate PSK31 with a microcontroller chip and to compare the efficiencies of the 3 different modes on the 600m band.
G0MRF 3 mode beacon. Sequence:
The beacon consists of 4 different modules connected together. Some have been detailed in other locations on this website or have been previously published.
1) The signal source.
- A direct digital synthesiser. - (A simple crystal oscillator would
be fine for a spot frequency)
2) The modulator / controller and low level linear amplifier. - Output power 750mW
3) A linear power amplifier. - A previous HF amplifier project using FETs was found to work down to 330kHz
4) A low pass filter LPF
Beacon in service Modulator / controller Low Pass Filter
In the next couple of weeks I'll try and get a circuit diagram here and write a description of the controller and how it generates PSK31.
In the meantime, if you hear the beacon, please let me know by e-mailing me at g0mrf @ aol.com
PSK modulator and 3 stage amplifier.
The source of RF, must be
capable of generating 800mV peak to peak into 50 Ohms. The RF source is
applied to a 6dB attenuator and then to a PSK modulator constructed from a
trifilar winding on a 15mm 3C85 ferrite. There are 7 turns of 3 windings of
0.5mm dia wire on the core. The first winding has the incoming RF at one end
with the other connected to ground. The other two windings have diodes
attached at one end. The other ends of these windings are connected together
to a pair of resistors across the 12V supply biasing the diodes to +6V.
The output ends of the diodes are connected together and fed with the modulating signal via a 680R resistor. The theory of generating the PSK is fairly simple. The input trifilar transformer generates in phase and 'antiphase' RF. If the DC voltage fed via the 680 ohm resistor is 6V, then the circuit is balanced and there is no RF output. If the voltage is increased towards 12V then the in phase signal is allowed through one of the diodes to the output amplifiers. This is a linear function. i.e. if the incoming voltage is 12V you have maximum signal and if the voltage is only 8V you have less RF passing through. Similarly if the voltage applied to the diodes via the resistor goes lower than 6 V, then the antiphase signal is allowed through. Again 5V will allow less output signal than say 3V. If the voltage falls to zero Volts, then the maximum amount of antiphase signal passes through the diode to the RF amplifier. More on the format of PSK31 later.
Incidentally, a quick test on the modulator during its testing revealed it has about 37dB of carrier rejection at 500kHz and it has acceptable performance from 50kHz to 10MHz.
Amplifier chain. The output of the modulator looks like the output of a half wave rectifier but varies in amplitude with the voltage applied to the diodes. As such, there is considerable distortion in the waveform. The first amplifier stage therefore has a tuned circuit in the collector which restores the missing part of the waveform. The transistor used is a BFY51 which works reasonably well at 500 kHz. Almost any similar transistor would work just as well. - There is nothing critical about any of this design.. This tuned amplifier uses tapped capacitors to provide an impedance match. This is followed by 2 transistors operating in class A. The first is a 2N3866 while the final amplifier is a MRF476 which was 'available'. Again almost any similar transistors would work. The output is about 750mW with good linearity while the saturated output power is about 1200mW. - But don't run PSK at that power unless you want a lot of complaints!
(assembly listing here in word)
For me, this was the most interesting part of the project. Learning how to program PIC chips (Peripheral Interface Controller) was a challenge and I was helped considerably by a book from the RSGB. I'm sure I have not produced the most efficient code for the controller, in fact I know I have not.. However, it does work and is fairly easy to understand. If you feel like improving the PIC code please do so. There are many areas that could be improved. - e.g. A varicode look up table would be great! (hint hint)
OK, so what does it do? essentially it does just 2 things. The first is that it holds 3 tables of data. One for the CW message, one for the QRS message and one for the PSK message. The only other function is to recall this data one bit at a time and send it to one of the chips output pins. Depending on the mode, the programme must hold the data on the pin for the correct period of time. Sounds simple, and if you want to have a look at the code used for the PIC chip I've listed it below. Each line starts with an instruction in 'assembly language' . after the instruction there is a semicolon. Any text after this is a description of what that line of code does. Have a look and see if you can see how it works. I may even be able to answer the odd simple question.
Question How do you produce a CW message?
Answer. We create the message in binary but store the message using hexadecimal to save space (0123456789ABCDEF)
In CW a dot is a
single unit of time. A dash is 3 units of time.
The space between dots and dashes in a morse character is a single unit of time
The space between characters in the same word is 3 units of time.
So if we write MRF we can convert that into dots and dashes then into a binary form.
dash dash space dot dash dot space dot dot dash dot space or in binary = 111011100010111010001010111010000000
Converting this binary into groups of 4 we get 1110 1110 0010 1110 1000 1010 1110 1000 0000
and converting into in Hex = EE 28 AE 80
Generating PSK31 is a little more complex. Just like morse encodes into dots and dashes, psk31 encodes numbers and letters into a pattern of zeros and ones. For example d is 101101. While the more commonly used letter e is 11. This code was developed by Peter Martinez G3PLX and is called 'Varicode'
Varicode has one rule. No varicode character contains two consecutive zeros. The reason is that 00 has been defined as the space between two characters.
Again, as an example, if I wanted to send de (an abbreviation for 'from') it would be sent in PSK31 as 1011010011.
OK, from the above we can go away, download a varicode table for all the keys on a keyboard and write any message we want in terms of zeros and ones. Then we need to take this long list and use it to control a transmitter. To store it on a chip we need to 'chop' up our long string into groups of four and then convert into Hex. - So now our de is 1011 0100 1100 or B4 C - notice I added 00 to the end to say that's the end of the letter e.
Modulating this onto a transmitter is achieved with a phase modulator. I've used a transformer and some diodes but you can use several other methods including double balanced mixers (the SBL1 from mini circuits works well) or logic gates - An Exclusive OR can be used.
There is one last complication. When we use our string of data for the characters de to control the transmitter, we can save some bandwidth with a very neat trick. Only the logic zeros in our string of data actually changes the phase. This means that in our string of data 1011010011 there are only 4 changes of phase. This makes PSK31 very bandwidth efficient.
Up to now I have
described Phase shift keying or more accurately BPSK (Bi Phase Shift
Keying) in that there are only 2 varieties of phase,. 0 degrees and 180
degrees. For the transmission to conform to PSK31 standards we need to send
it at the correct speed and that is 31 bits per second....well no, actually
the standard is 31.25 bits per second but even Peter Martinez realised a
mode called PSK31.25 wouldn't catch on !!
So the final requirement is to start sending a carrier then by using a simple timer make decisions every 32 milliseconds whether to change the phase or not.
For completeness lets examine our message of de 1011010011. This is 10 digits long so will take 320 milliseconds to transmit. Looking at the location of the zeros we can determine that there are phase changes at 64ms / 160 / 224 and 256ms. In the beacon, the timing and decisions on phase are made by the microcontroller which just slowly works its way through a very long list of zeros and ones.
G3HEJ M0BMU G3YMC G3UNT G3YXM G3XIZ Hartmut Wolff G3NYK G3XVL GM4SLV
G3WCB G8FZK M0FMT G4WGT G4DMA/M M1KTA OK2BVG EA1PX OH1LSQ G4ALD DD7PC
Stations shown in italics sent reports over new year 2007/8 while running 55mW. Best DX to date is OH1LSQ at 1834km on 1/1/08
Report from Hartmut Wolff at 763km
This report from JO52hp was
using 5mW ERP. If you look just after the 02.10am marker you can clearly
see the MRF in slow CW. Immediately after that you can see the sidebands
produced by the constant phase changes at +/- 15.625Hz followed by the wider
bandwidth of the PSK31 data.
After the PSK you can see the next trace with the bandwidth of about one third of the PSK31. This is simply the spectrum of the beacon when it's transmitting normal CW.
Click on the thumbnail to see the daytime reception of the beacon as received on the G3YXM grabber at apx 130km
|Click on the left thumbnail to see the daytime reception of the beacon as received on the G3YXM grabber.|