|
|||||||||||||||||||
|
advertisement |
|
|
Practical Costas loop design Jan 1, 2002 12:00 PM By Jeff Feigin Designing a simple and inexpensive BPSK Costas loop carrier recovery circuit.
Binary phase shift keying (BPSK), in terms of noise immunity per unit bandwidth, is one of the most efficient binary data modulation techniques. Yet, communications systems designers often neglect this option because the design of a BPSK demodulator is not as mathematically simple or straightforward as frequency shift keying (FSK). The prospect of having to apply thorough engineering rigor to the design of a BPSK demodulator can be daunting. However, it is unlikely that any such circuit will perform as well as it could if it were implemented without fully understanding and parameterizing its behavior. Designing and implementing a Costas-loop carrier recovery circuit and demodulator can be done simply and inexpensively using only basic components. BPSK Background
Simple BPSK modulation is the process of shifting a carrier’s phase by 180° for one data symbol while not shifting it for the other — known as ‘antipodal’ phase shift modulation. The mathematical equation for this process is: (1) where DATAN is restricted to ±1 and N is advanced at a much lower rate than the frequency of the carrier (the cosine function). Shifting the phase of a carrier (a sinusoid) by 180° is the same mathematical process as reversing the magnitude of a carrier for one symbol and not the other. With identical results, the following amplitude modulation process can be substituted, interchangeably: Modulation theory
The modulation techniques in Equation 1 and Equation 2 are referred to as BPSK and double side-band, suppressed carrier-amplitude modulation (DSBSC-AM), respectively, and when the phase shift is restricted to 180° between opposing symbols, there is no difference. As with the DSBSC-AM, the resultant BPSK RF spectra are simply the baseband spectra mirrored by the carrier frequency (see Figures 1, 2). The upper sideband (the half of the BPSK spectra that exists above the carrier) is identical to that of the modulating signal, except shifted up to where the carrier frequency was the DC point in the spectra of the original signal. The lower sideband (similarly, the part of the modulated signal that exists below the carrier) contains identical information to the upper sideband, except its spectra is a mirror image of the carrier. A mathematically simple demodulation scheme multiplies the incoming RF signal by a coherent carrier (a carrier that is identical in frequency and phase to the carrier that originally modulated the BPSK signal). This is an application of the following trigonometric identity: (3) where the product of two cosine functions is the sum and the difference of the inner term of each. When two cosine functions representing periodic timedomain waveforms are multiplied together, the result is two new cosines; the sum of the two frequencies and the difference. Therefore, when the BPSK signal is multiplied by a cosine function identical to the one that modulated it, the original modulating data, plus the same BPSK signal at twice the carrier frequency, are produced. This is mathematically represented by: (4) Applying the trigonometric identity from Equation 3, the result becomes: (5) Now, considering that the cosine of zero is one, the result of this multiplication is the modulating signal plus the BPSK signal shifted to twice its original frequency: (6) A “brick wall” filter (an ideal lowpass filter) then isolates the demodulated data or “low side” product from the extraneous high-frequency or “highside” product: (7) Equivalently, the block diagram for this mathematical operation is depicted in Figure 3. On demodulation, the upper and lower sidebands, which are mirror images, will “fold” onto one another. The two sidebands of the modulating signal will coherently add while the random channel noise (in which the upper and lower sidebands are completely independent) will randomly add. The fact that the two identical modulation sidebands coherently add while the noise, which occupies the same bandwidth, adds according to a root mean squared (RMS) relationship means that the demodulated data will have an inherent signal-to-noise ratio (SNR) advantage, or “processing gain” of 3 dB above that of the BPSK signal. The narrower the bandwidth of the data filter, the less noise will appear at its output. Too narrow of a filter will limit demodulated data output levels. For optimum performance, the ratio between signal and noise should be maximized. According to Nyquist’s first criteria, so as not interfere with the data signal at the center of each symbol period (the instant where the symbol value is decided), a square-shaped “brick wall” filter should have a bandwidth of no less than half the symbol rate. Such a channel filter must have unity response between DC and a frequency equal to half the symbol rate. This is the ideal channel filter, because it removes the most noise possible without reducing the amplitude of the desired signal at its sampling instants. It will produce an output SNR that is 3dB greater than that of the BPSK signal. Note that Nyquist specifies alternate filters, vestigial spectrum filter shapes such as the raised-cosine, which will achieve the same goal. Demodulation theory
On demodulation, the upper and lower sidebands, which are mirror images, will “fold” onto one another. The two sidebands of the modulating signal will coherently add while the random channel noise (in which the upper and lower sidebands are completely independent) will randomly add. The fact that the two identical modulation sidebands coherently add while the noise, which occupies the same bandwidth, adds according to a root mean squared (RMS) relationship means that the demodulated data will have an inherent signal-to-noise ratio (SNR) advantage, or “processing gain” of 3 dB above that of the BPSK signal. The narrower the bandwidth of the data filter, the less noise will appear at its output. Too narrow of a filter will limit demodulated data output levels. For optimum performance, the ratio between signal and noise should be maximized. According to Nyquist’s first criteria, so as not interfere with the data signal at the center of each symbol period (the instant where the symbol value is decided), a square-shaped “brick wall” filter should have a bandwidth of no less than half the symbol rate. Such a channel filter must have unity response between DC and a frequency equal to half the symbol rate. This is the ideal channel filter, because it removes the most noise possible without reducing the amplitude of the desired signal at its sampling instants. It will produce an output SNR that is 3dB greater than that of the BPSK signal. Note that Nyquist specifies alternate filters, vestigial spectrum filter shapes such as the raised-cosine, which will achieve the same goal. Practical BPSK demodulation
The previous mathematical description explains the principle behind coherent BPSK demodulation. Such a structure is straightforward and lends itself well to understanding the concepts. However, it is difficult to implement this circuit because its performance is poor when non-ideal components are used. With some modification (see Figure 4), the demodulator circuit becomes much more practical. The requirements placed on the building blocks of the structure become far less demanding to achieve good performance. The more realizable BPSK demodulator is based on a practical mixer that is allowed to be imperfect. Such a mixer can be built using common semiconductor devices with small current requirements. Unlike an ideal multiplier, easily implementable mixers are subject to overloading and high-order non-linearities; undesired radio signals, which need not exist at even similar frequencies, can mix in a complicated manner to produce undesired interference that superimposes the desired demodulation product. The solution is to place a channel filter before the mixer to preclude as much off-channel energy from reaching the mixer as possible. The most common inexpensive channel filters are second- and third-order surface acoustic wave (SAW) and ceramic type. However, neither type exhibits ideal rectangular characteristics. Low-pass filter discussions
The low-pass filter, as with the ideal demodulator, is the data filter. Because the bandpass filter, ahead of the mixer, removes a great deal of unwanted noise, the low-pass filter requirements can be relaxed. While the perfect demodulator requires that the filter exhibit no intersymbol interference (a Nyquist filter), the practical design may use filters that trade cost, complexity, and size for some degree of SNR degradation. For the purpose of a simple implementation, a three-pole Butterworth is used as the bandpass filter and a single- pole RC is used as the low-pass data filter for this analysis. The singlepole low-pass filter has a far more gradual roll-off characteristic than ideal — about –20 dB per frequency decade. Therefore, it will not be possible to minimize intersymbol interference with allowing extra noise through; its –3 dB cutoff point must be defined such that it maximizes the SNR of the data signal. An optimization means that its bandwidth must be wide enough to minimize ISI, while narrow enough to minimize noise. For an alternating (1,0,1,0,1…) data pattern, a –3 dB cutoff frequency equal to half the symbol rate will maximize SNR for the singlepole RC low-pass. The total SNR degradation, shown by simulation, is about –1.2 dB for a worst-case alternating data pattern, but found to be about –0.6 dB in the case of a random data pattern. This amount of degradation is acceptable for simple designs, but better filters are recommended if one wishes to improve the SNR. Figure 5 is a comparison of the resultant demodulated BPSK data on ideal and practical demodulation. Ideal demodulation is that of Figure 3 where the “perfect filter” is implemented as a 10,001-tap raised cosine finite-impulse response (FIR) and the practical demodulator, from Figure 4, uses an infinite impulse response (IIR) threepole Butterworth as the channel filter and a one-pole IIR structure as the data filter. Although the ideal demodulator does not faithfully reproduce the original signal, it does reproduce the entire signal to reach its peak value at the data-sampling instant. This is the only critical point, according to Nyquist (this is an acausal implementation). However, the result obtained using the more practical structure requires more than one bit time to reach its maximum level. This is the ISI degradation parameter. More noise than ideal would have to be allowed through the demodulator if one were to attempt to solve this problem with non-ideal filters. Finally, the carrier must be recovered. Its frequency and phase needs to be exactly reproduced to optimally demodulate the BPSK signal. Unless there exists some connection or information path between the carrier that was used in modulation and the demodulator, a carrier recovery circuit is required for coherent demodulation. Carrier recovery
The two common methods for BPSK carrier recovery are: 1) squaring the BPSK signal then dividing by two and 2) the 180° Costas loop. The first technique relies on the fact that, because the BPSK modulation causes ±180° phase transitions, its second harmonic will be phase-modulated by an ambiguous ±360°. The second harmonic is an unmodulated carrier at twice the frequency. Dividing this second harmonic of the carrier by two will result in a theoretically phase-coherent carrier. The advantage of the squaring-thendivide circuit is that it is mathematically simple to analyze. However, in practice, controlling the phase offset will be somewhat complicated and layoutdependent; the recovered carrier takes a different path from the demodulator path, and this creates a time differential that will result in a phase error. Also, several filters are required, making it difficult to maintain proper phase over the range operating frequencies. While the first method is a feed-forward technique, the Costas loop relies on feedback concepts related to the PLL. The Costas loop offers an inherent ability to self-correct the phase (and frequency) of the recovered carrier and, in the end, its implementation is no more complicated than the first technique. Its main disadvantage is involvement of a loop settling time. Analyzing the Costas Loop
The mechanism of the Costas loop carrier recovery is to iterate its internally generated carrier – the VCO – into the correct phase and frequency based on the principle of coherency and orthogonality. The low-frequency product of a BPSK signal and its coherent carrier is the demodulated information, while the low-frequency component is completely canceled (there will be no low-frequency component at all) in the case of a BPSK signal multiplied by its orthogonal carrier (a carrier that is 90° out of phase with its coherent carrier). The coherent case has already been mathematically demonstrated in Equations 3 through 7. For the orthogonal case, the following trigonometric identity is presented: (8) representing the coherent BPSK carrier at a cosine function and its orthogonal carrier is a sine (or negative sine) function. The time-domain representation of this orthogonal multiplication is: (9) Applying the trigonometric identity from Equation 8, the result becomes: (10) Now, considering that the sine of zero is zero, the product of this multiplication is only a “high side” component and the BPSK signal shifted by 90° and to a frequency twice that of what it was. (11) Next, a low-pass filter removes the high-frequency component, and nothing remains: (12) The Costas loop is “locked” when it has adjusted its VCO phase and frequency (the initial conditions are random) until the ‘I’ signal is a maximum and the ‘Q’ signal is zero (in reality, the locked-loop ‘Q’ signal is close to zero, but not exactly zero). The third multiplier, the phase doubler, produces the product of the ‘I’ and ‘Q’ signals that sets the VCO input voltage. LPF3’s purpose is only to remove spurious components and LPF1/ LPF2 “high side” leakage — it is not meant to significantly contribute to the loop response and is often omitted in theoretical Costas loops block diagrams. LPF1 not only serves the purpose of a data filter, but in combination with LPF2 (these two should be equal to avoid imbalances that will prolong settling time), it comprises a pseudo-integrator (a low-pass filter is related to an integrator). This allows the circuit to behave in a somewhat similar fashion as a second-order PLL (see Figure 8). Carriers of interest
The carrier that is to become coherent when the loop settles is represented as a cosine function with some phase error. Therefore, the orthogonal carrier that leads the coherent carrier by 90° must be a negative sine function with the same phase error. Considering the incoming BPSK signal as a cosine with zero phase offset relative to time zero, a radial frequency of ωBPSK, (the radial frequency is 2π times the periodic frequency) and the Costas loop VCO frequency to be ωvco with a phase error relative to the BPSK carrier of φphase_error, the resultant product of the ‘I’ mixer is represented by: represented by: (13) For analysis purposes, because the modulating signal is binary data that reverses its magnitude, DATAN(t) is replaced by ±1 and the identity of Equation 3 is applied: (14) LPF1 removes the “high side” component and its output; the ‘I’ signal is represented as: (15) Similarly, the ‘Q’ mixer produces the following product: (16) Applying Equation 8, and again substituting DATAN(t) with ±1, the resultant ‘Q’ product is shown as: (17) LPF2 removes the “high side” component and its output; the ‘Q’ signal is represented as: (18) Then, multiplying these two LPF results together, the phase doubler produces: (19) Next, applying Equation 8: (20) Then simplifying the output of the phase doubler, the phase detector result becomes: (21) Further dissection
The phase detector result is then filtered by LPF3, which removes extraneous loop products before being applied to the VCO. Again, this filter is not meant to significantly contribute to the Costas loop locking response — its response should be far outside the closed-loop response. From the result of Equation 21, it can be determined that the loop will correct itself, both in terms of frequency and phase. And, by modifying Equation 21 to represent absolute phase difference (rather than phases that are relative to time zero), the phase detection response is found. It is important to remember that all three multipliers compose the phase detector response. The phase doubler multiplier is not, by itself, “the phase detector.” In the case where the input signals have a peak value of unity, the phase detection response is described by Equation 22. The phase detector gain vs. amplitude dependency is mentioned for mathematical completeness, but such effects need not be thoroughly quantified because realistic “multiplier” phase detectors will be amplitude invariant. Picking unity for the input and VCO amplitudes as the parameters for phase-detector gain serve the purpose of an example gain. The phase-detection response is described by: (22) This result is similar to that of a conventional multiplier-type phase detector whose output, based on a unity amplitude input, is: (23) Comparing these two results (see Figure 9), the Costas loop phase detection response is a sine function while the multiplier-type phase-detection response is a cosine function of the phase difference. The second-order PLL contains a low-pass filter that integrates (or pseudo-integrates, depending on the type of filter) the error signal from the phase detector. The PLL is locked when the phase detector result is zero (near zero when the loop filter is not a true integrator), hence producing a DC constant at the input of the VCO. The cosine response of the multiplier phase detector causes a lock when the phase error is 90° (because the cosine of 90° is zero). The Costas loop, considering LPF1 and LPF2, acts similarly to a secondorder loop (the combined effect of LPF1 and LPF2 adds a second pole to the loop response. The filtered ‘Q’ signal moves just slightly above or below zero and is multiplied by the filtered ‘I’ product). Its doubled-sine phase detection response allows two stable locking points: 180° phase error and zero degrees — both produce a redundant output that drives the VCO to the correct phase/frequency. Low-pass filters LPF1/LPF2 must pass the modulation (the direct result of filters that are too narrow is ISI) as: (24) where BM, the modulation bandwidth, is half the data rate.... Read the full article
|
|
||||||||||||||||||
| Back to Top |