Download DSP-Based Implementation of a Digital Radio Demodulator on the
Transcript
3.1. Automatic Gain Control is decreased by a small amount. On the other hand, if it is lower then the gain factor is increased. Note the word slightly in the last sentence. This is because, in order to avoid the gain factor to be oscillating over and over again, we define a range of values for which no change of the gain factor is performed. Typically, this range is around [0.9 ∗ P owerRef erence, 1.1 ∗ P owerRef erence] . With all this at hand, we can write the pseudo-code for the AGC: while true do AvgP wr = 0; gain = 1; pwrRef = −12dB; tav = 1/213 ; for i = 0 to W indowSize do current IQ − Sample = current IQ − Sample ∗ gain; AvgP wr = tav ∗ IQpwr + (1 − tav) ∗ AvgP wr; if (AvgP wr < 0.9 ∗ P wrRef ) then gain = 1.1 ∗ gain; end if if (AvgP wr > 1.1 ∗ P wrRef ) then gain = 0.9 ∗ gain; end if end for end while As an example of the workings of the last algorithm, in picture 3.2 we show an example of a real DAB signal received at NXP Offices in Leuven. It turned out that the power of the incoming signal was not very good to be subsequently processed. Nevertheless, as can be seen the AGC performs well its task and amplifies the signal to a amplitude such that it can be processed with all the available resolution in the CoolFlux architecture (24 bits). For a better understanding of the AGC block we show in picture 3.3 the average signal power of the last signal (in blue) in superposition with the gain factor (in red). Presumably the power of the input signal is increased (maybe due to multipath propagation) at around point 12 in the x-axis. Consequently, the gain factor is immediately decreased to maintain the power of input signal at safe levels. As an observation, an excess in power does not 75