CN116346148A - Multi-mode automatic gain control method and system based on SoC - Google Patents

Multi-mode automatic gain control method and system based on SoC Download PDF

Info

Publication number
CN116346148A
CN116346148A CN202310243757.2A CN202310243757A CN116346148A CN 116346148 A CN116346148 A CN 116346148A CN 202310243757 A CN202310243757 A CN 202310243757A CN 116346148 A CN116346148 A CN 116346148A
Authority
CN
China
Prior art keywords
gain
value
signal
digital
agc
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310243757.2A
Other languages
Chinese (zh)
Inventor
石玉
焦子昂
吴旭兵
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
University of Electronic Science and Technology of China
Original Assignee
University of Electronic Science and Technology of China
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by University of Electronic Science and Technology of China filed Critical University of Electronic Science and Technology of China
Priority to CN202310243757.2A priority Critical patent/CN116346148A/en
Publication of CN116346148A publication Critical patent/CN116346148A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03GCONTROL OF AMPLIFICATION
    • H03G3/00Gain control in amplifiers or frequency changers
    • H03G3/20Automatic control
    • H03G3/30Automatic control in amplifiers having semiconductor devices
    • H03G3/3036Automatic control in amplifiers having semiconductor devices in high-frequency amplifiers or in frequency-changers
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M1/00Analogue/digital conversion; Digital/analogue conversion
    • H03M1/12Analogue/digital converters
    • H03M1/124Sampling or signal conditioning arrangements specially adapted for A/D converters
    • H03M1/1245Details of sampling arrangements or methods
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/06Receivers
    • H04B1/10Means associated with receiver for limiting or suppressing noise or interference
    • H04B1/1027Means associated with receiver for limiting or suppressing noise or interference assessing signal quality or detecting noise/interference for the received signal
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/06Receivers
    • H04B1/16Circuits
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Theoretical Computer Science (AREA)
  • Control Of Amplification And Gain Control (AREA)

Abstract

The invention belongs to the field of communication software radio, and particularly relates to a multimode automatic gain control system and method based on SoC. The invention takes the analog signal output by the program-controlled attenuator as the ADC input signal in the analog automatic gain control part, after the analog signal is converted into the digital signal by the ADC, the gain adjustment value of the analog automatic gain control module is obtained according to the digital signal output by the ADC, and then the gain input to the program-controlled attenuator is adjusted by using the gain adjustment value. In the digital AGC part, IQ signal is used as input signal, and the gain value is calculated according to the input signal, and the input signal is regulated by using the gain value. Compared with the prior art, the invention can control the gain of the short wave and ultrashort wave signals received by the antenna, so that the antenna reaches the target power. And the regulation and control precision is higher, and various application occasions and requirements are met.

Description

Multi-mode automatic gain control method and system based on SoC
Technical Field
The invention belongs to the field of communication software radio, and particularly relates to a multimode automatic gain control system and method based on SoC, which are applied to a digital receiver.
Background
In wireless communication, the wireless signals are attenuated differently in the space propagation process under the influence of factors such as transmission distance, weather environment, geography and the like, and the received signal strength is greatly changed. However, the radio frequency front end and the ADC in the radio device can only process signals with relatively small amplitude variation, and the received signals are too large, which can cause the input of the radio frequency front end circuit or the ADC to be blocked, and may even burn the circuit; too small a signal may result in insufficient resolution of post-digital signal processing and greatly reduced reception performance. In order to ensure that the wireless signal size is within the dynamic range that the receiving device can receive, the received signal amplitude must be adjusted in real time to reduce the influence of signal fluctuation on the system, so in a software radio platform, an automatic gain control circuit with a larger dynamic range is required to ensure that the radio frequency front end and the ADC are not excessive, and meanwhile, the capability of a post-digital processing module for small signal processing is improved.
In the digital intermediate frequency receiver, signals are received through an antenna, are input to a radio frequency module to convert the signals into intermediate frequency, then the intermediate frequency signals are converted into digital signals through an ADC (analog to digital converter), the digital signals are transmitted to a digital processing module to be processed, and finally the processed signals are output. In this configuration, two automatic gain modules are included, an analog AGC and a digital AGC, respectively. The analog AGC is a digital control AGC, and the analog AGC has the function of estimating the size of a signal according to the sampling value of the ADC, and sending gain data to a program-controlled attenuator in radio frequency through a radio frequency control unit, so that the signal is attenuated, and the intermediate frequency signal is ensured to be in the dynamic range of the ADC. The digital AGC is an all-digital AGC, and has the function of adjusting the IQ signal size output by the DDC to be in a constant range, so that the processing capacity of modules such as post-stage demodulation and the like on small signals is improved.
The traditional automatic gain system generally adopts a square law detection method and an approximation algorithm to calculate the amplitude of a signal, occupies a large resource, cannot meet the precision requirement, and only relates to two modes, namely an AGC automatic gain control mode and an MGC manual gain control mode, so that the regulation and control of the gain range in the AGC mode cannot be realized. With the rapid development of wireless communication technology, conventional AGC cannot meet the gradually increasing range and function requirements, and cannot set the automatic gain range of AGC according to the use requirements.
Disclosure of Invention
The invention aims at: a multimode automatic gain control system and method based on SoC are provided to solve the problems that the traditional automatic gain control system has high resource consumption, limited gain regulation range, incapability of setting the gain range according to the requirement of a user, and the like.
In order to achieve the above purpose, the invention adopts the following technical scheme:
a multimode automatic gain control method based on SoC, comprising the steps of:
step 1, converting an analog signal output by a program-controlled attenuator into a digital signal through an ADC (analog to digital converter), performing detection processing according to the digital signal output by the ADC to obtain a detection signal, calculating the detection signal to obtain an analog AGC gain adjustment value, and adjusting the gain input to the program-controlled attenuator according to the analog AGC gain adjustment value;
the gain adjustment value of the analog AGC is obtained by the steps of:
step 1.1, setting the time window width of saturation of a detection signal, the time window with too small a time window and the time window width of average power;
step 1.2, judging whether the detected signal is within the saturated time window width set in step 1.1, if yes, indicating that the ADC signal is saturated and overloaded at the moment, and reducing the gain by 8dB;
judging whether the detection signal is outside the time window which is set to be too small in the step 1.1, if so, indicating that the intermediate frequency signal is weak at the moment, and increasing the gain by 14dB;
judging the relation between the average power of the detection signal and the width of the time window set in the step 1.1: when the average power is larger than the threshold of-4 dB, the intermediate frequency signal energy is larger, and the gain of 2dB needs to be reduced; when the average power is below-8 dB, but its instantaneous amplitude is greater than-18 dB, the gain is increased by 2dB.
Step 2, taking the gain adjustment value of the analog AGC obtained in the step 1 as a gain compensation coefficient, and outputting the AD signal after gain compensation so as to obtain an input ADC signal actual value;
step 3: gain control for digital AGC gain
Step 3.1, the signal output in the step 2 is sent to a digital AGC, and the amplitude of the signal is calculated by adopting a cordic algorithm;
step 3.2, filtering the calculated amplitude result by adopting low-pass filtering to prove the stability of the signal;
step 3.3, calculating an error value between the filtered amplitude result and the target amplitude;
step 3.4, calculating an index value corresponding to the error value, and taking the index value as a gain value; setting a maximum value and a minimum value, limiting the gain value between the maximum value and the minimum value to obtain a final gain value, and adjusting the gain of the digital AGC according to the final gain value, thereby completing the gain control of the current signal.
Further, the low-pass filter adopted in the step 3.2 is an IIR filter adopting a first order.
Furthermore, the multi-mode automatic gain control method based on SoC further comprises the following steps of gain distribution of analog AGC and digital AGC before step 1:
a1, determining an actual demand gain adjustment range value of the digital AGC according to application demands and an ADC sampling inherent gain value;
a2, determining the actual gain adjustment range value of the analog AGC according to the starting control level value of the analog AGC and the actual required gain adjustment range value of the digital AGC determined in the step a1.
Furthermore, the multimode automatic gain control method based on SoC further comprises combining AGC automatic gain and MGC manual gain control to improve the accuracy of the gain output value; the specific operation is as follows:
a1.1, when the application requirement gain adjustment range value is larger than the digital AGC gain adjustment range value, the gain adjustment range of the digital AGC is required to be reduced, namely the maximum value of gain times is correspondingly reduced;
a1.2, when the AGC gain adjustment range is less than or equal to the radio frequency AGC adjustment range, the digital AGC keeps the gain multiple to be 1; the analog AGC range is reduced, the gain output port is increased by a gain value comparison module, and when the output gain value exceeds the AGC range at the moment, the allowable maximum gain value output is maintained.
A multimode automatic gain control system based on SoC comprises an analog automatic gain control module, a gain compensation module and a digital automatic gain control module;
the analog automatic gain control module comprises a program-controlled attenuator, an analog-to-digital converter ADC, a digital detection unit and a first gain control unit; the input end of the program-controlled attenuator is connected with the input end of the baseband signal and the gain control unit, and the output end of the program-controlled attenuator is connected with the input end of the analog-to-digital converter ADC; attenuating the baseband signal under control of the gain adjustment value; the output end of the analog-to-digital converter ADC is connected with a digital detection unit and is used for converting a received baseband analog signal into a digital signal; the output end of the digital detection unit is respectively connected with the input end of the gain compensation module and the input end of the gain control unit; generating a detection signal for the input digital signal; the gain control unit is used for receiving the detection signal, and calculating a gain adjustment value of the analog automatic gain control module according to the detection signal so as to control attenuation of the program controller;
the gain compensation module is used for compensating the detection signal provided by the digital detector;
the digital automatic gain control module comprises a second gain control unit, an amplitude detection unit and an error calculation unit; the second gain control unit consists of a gain adjustment unit and a gain calculation unit, wherein the input end of the gain adjustment unit is connected with the output ends of the gain compensation module and the gain calculation unit, and the output ends are respectively connected with the output end of the whole AGC system and the input end of the amplitude detection unit; the input end of the gain calculation unit is connected with the error calculation unit; the gain calculation unit is used for calculating a gain value according to the maximum value and the minimum value of the preset gain, and limiting the gain value between the maximum value and the minimum value range; the gain adjusting unit is used for adjusting the gain of the digital automatic gain control module according to the final gain value and then outputting the gain, so as to complete the gain control of the current signal; the output end of the amplitude detection unit is connected with the input end of the error calculation unit, and the amplitude detection unit calculates the amplitude of the output signal of the gain adjustment unit by adopting a cordic algorithm; the error calculation unit consists of a low-pass filter, a threshold comparison and an error processing unit which are sequentially connected in series, wherein the input end of the low-pass filter is used as the input end of the error calculation unit and is connected with the output end of the amplitude detection unit; the output end of the error processing unit is used as the output end of the error calculating unit and is connected with the gain calculating unit; the low-pass filtering unit is used for filtering the amplitude output by the amplitude detection unit; the threshold comparison unit is used for calculating an error value between the filtered amplitude and the target amplitude according to the target amplitude; the error processing unit is used for obtaining the index value corresponding to the error value and taking the index value as the gain value.
The invention provides a multimode automatic gain control based on SoC, which takes an analog signal output by a program-controlled attenuator as an ADC input signal in an analog automatic gain control module part, wherein the ADC converts the analog signal into a digital signal, obtains a gain adjustment value of the analog automatic gain control module according to the digital signal output by the ADC, and adjusts the gain input to the program-controlled attenuator according to the gain adjustment value of the analog automatic gain control module. In the adjustment process, the gain adjustment range is determined according to the time window width of saturation of the set detection signal, the too small time window and the time window width of average power, and the resource consumption in the calculation process is low. In the digital AGC part, the IQ signal output by the front stage module is used as an input signal, a required gain value is calculated according to the input signal, and the gain value is transmitted to the gain adjustment module to adjust the input signal. In the adjustment process, the gain value is limited according to the set maximum gain value and the set minimum gain value, the adjustment speed is determined according to the instruction sent by the upper computer of the user, and the resource consumption in the operation process is low and the accuracy is high.
After the technical scheme is adopted, the invention has the following beneficial effects:
the invention carries out gain control on the short wave and ultrashort wave signals received by the antenna, so that the target power is achieved. The analog AGC controls the input signal not to exceed the ADC range, the gain compensation module ensures the signal precision, the digital AGC increases the dynamic bit width of the signal, the AGC automatic gain and MGC manual gain control mode is adopted, the AGC gain adjustment range is controlled by manually setting parameters, the regulation precision is higher, and various application occasions and requirements are met.
Drawings
Fig. 1 is a block diagram of a digital intermediate frequency receiver system to which the present invention is applied;
fig. 2 is an analog AGC architecture of the present invention;
FIG. 3 is a gain adjustment schematic diagram of the present invention;
FIG. 4 is a gain compensator structure of the present invention;
fig. 5 is a digital AGC structure of the present invention;
FIG. 6 is a schematic diagram of the rotation process of the CORDIC algorithm of the present invention;
fig. 7 is a flow chart of analog automatic gain control according to the present invention.
Detailed Description
The invention will now be described in detail with reference to the drawings and examples.
The multimode automatic gain control method based on the SoC provided by the embodiment comprises the following steps:
a multimode automatic gain control method based on SoC, comprising the steps of:
step 1, taking an analog signal output by a program-controlled attenuator as an input signal of an ADC, converting the analog signal into a digital signal by the ADC, detecting the digital signal output by the ADC by a detection module, obtaining a gain adjustment value of an analog automatic gain control module according to the detection signal, and adjusting the gain input to the program-controlled attenuator according to the gain adjustment value of the analog automatic gain control module. As shown in fig. 3 and 7, gain adjustment is divided into three cases of coarse gain adjustment, fine gain adjustment and no adjustment, and three different time window widths are adopted to correspond to the three gain adjustment cases based on the control principle of automatic gain control "fast charge and slow discharge", and the specific operation steps are as follows:
step 1.1, setting the saturation time window width of a detection signal, an undersize time window and the average power time window width;
and step 1.2, judging whether the detected signal is within the saturation time window width set in the step 1.1, if so, indicating that the ADC signal is saturated and overloaded at the moment, and reducing the gain by 8dB. In this embodiment, the saturation time window width is set to 100us. In this time window, if the counted magnitude of 0dB and the number of sampling points of 32767 at 16 bits reaches a preset ratio, for example 1%, corresponding to the maximum output scale of the ADC, it is indicated that the ADC is saturated and overloaded at this time, and the gain needs to be reduced by 8dB.
Judging whether the detection signal is outside the small time window set in the step 1.1, if so, indicating that the intermediate frequency signal is weak at the moment, and increasing the gain by 14dB. In practice, the too small time window is set by the hold time instruction, the default value being preferably 20ms. If the time that the instantaneous amplitude of the signal is below-18 dB exceeds the time window, this indicates that the signal is weak at this time, and the gain needs to be increased by 14dB.
Judging the relation between the average power of the detection signal and the width of the time window set in the step 1.1: setting the width of the average power time window to be 2ms, and when the average power is larger than a threshold of-4 dB, indicating that the signal energy is larger at the moment, and reducing the gain of 2dB; when the average power is below-8 dB, but its instantaneous amplitude is greater than-18 dB, the gain is increased by 2dB. It should be noted that, in this process, if the instantaneous amplitude is lower than-18 dB, the timer is reset continuously.
And 2, taking the gain adjustment value of the analog automatic gain control module obtained in the step 1 as a gain compensation coefficient, and outputting the ADC signal after gain compensation so as to obtain the actual value of the input ADC signal. As shown in fig. 4, the compensation method of the present embodiment is to directly multiply the gain compensation coefficient with the ADC sampling value, and since the gain adjustment value outputted by the analog AGC is logarithmic, that is, in dB, the gain adjustment value needs to be converted into a value of g_db according to a conversion formula of power and bit width. The gain compensation coefficient K after conversion is expressed as:
Figure SMS_1
step 3: gain control for digital automatic gain control module gain
Step 3.1, the signal output from the step 2 is sent to a digital automatic gain control module to calculate the signal by adopting a cordic algorithmAmplitude values. The rotation process of the CORDIC algorithm is shown in fig. 6, assuming that the original coordinates (x i ,y i ) After rotation by an angle θ, a new coordinate (x n ,y n ) The new coordinates can be expressed as follows
Figure SMS_2
Figure SMS_3
When N→infinity, the rotation gain K becomes a fixed constant, which is about 0.6073. Therefore, the rotation gain needs to be compensated after N times of rotation, and for each rotation, CORDIC operation only comprises addition, subtraction and shift operation, so that the resource loss is reduced, and the method is easy to realize in hardware.
And 3.2, the actual signal received by the receiver generally fluctuates greatly due to environmental interference, and if the signal amplitude calculated by the amplitude detection module is directly sent to a post-processing module of the digital automatic gain control module, the gain calculated finally fluctuates. If the received signal is an amplitude modulated signal, such as an AM signal, an unstable gain acts directly on the input signal, degrading the signal, thereby rendering the entire system unusable. Therefore, the obtained amplitude signal is subjected to low-pass filtering, the low-frequency component of the amplitude signal is used as detection output, the resource consumption and the filtering delay of the FPGA or the DSP are comprehensively considered, and the first-order IIR filter is adopted to filter the calculated amplitude result so as to ensure the stability of the signal;
step 3.3, calculating an error value between the filtered amplitude result and the target amplitude;
step 3.4, adopting an exponential arithmetic unit to obtain an exponent value corresponding to the error value, and taking the exponent value as a gain value; and limiting the gain value between the maximum value and the minimum value according to the maximum value and the minimum value of the preset gain to obtain a final gain value so as to ensure that the gain value is positioned in a reasonable gain adjustment range. And then adjusting the gain of the digital automatic gain control module according to the final gain value, thereby completing the gain control of the current signal.
In practical application, as the input signal gradually increases from the sensitivity level, the analog automatic gain control module and the digital automatic gain control module are required to be controlled in a combined manner to ensure the constancy of the output signal. In order to achieve the best effect of the stability of the output signal, the embodiment distributes gains of the analog automatic gain control module and the digital automatic gain control module before performing gain control, and the gain distribution includes:
a1, determining an actual demand gain adjustment range value of a digital automatic gain control module according to application demands and an ADC sampling inherent gain value;
a2, determining the actual gain adjustment range value of the analog AGC according to the starting level value of the analog automatic gain control module and the actual required gain adjustment range value of the digital automatic gain control module determined in the step a1.
The maximum value of the required adjustment range of the whole automatic gain control module system of the embodiment is 127dB, and the inherent gain value of the adc sampling module is 55dB, so that the gain range of the digital automatic gain control module is 127dB-55 db=72 dB. If the receiver sensitivity to FM signals is required to be-120 dBm, the analog AGC has a start level of-120 dBm- (-72 dBm) = -48dBm. The control precision of the analog automatic gain control module is not high, coarse adjustment is realized, the amplitude of the analog intermediate frequency signal input to the ADC converter is ensured to be approximately stable, and the stability is finally realized through the digital automatic gain control module.
In addition, in order to meet the requirement of controllable gain range of the AGC automatic gain control mode, the embodiment improves the gain control mode which only adopts MGC manual gain control or AGC automatic gain control in the traditional digital receiver. The AGC automatic gain and MGC manual gain control mode is adopted, and the gain adjustment range of the AGC mode is controlled through manually setting parameters, so that the regulation and control precision is improved. For convenience of description, the specific operations are as follows:
a1.1, when the application requirement gain adjustment range value is larger than the gain adjustment range value of the digital automatic gain control module, the gain adjustment range of the digital automatic gain control module is required to be reduced, namely the maximum value of gain multiples is correspondingly reduced;
a1.2, when the application requirement gain adjustment range is less than or equal to the adjustment range of the radio frequency automatic gain control module, the digital automatic gain control module keeps the gain multiple to be 1; the range of the analog automatic gain control module is reduced, the gain output port is added with a gain value comparison module, and when the output gain value exceeds the application requirement gain adjustment range, the allowable maximum gain value output is maintained.
Assuming that the gain adjustment range is 127dB in the AGC mode, if the parameter 50dB is set in the "AGC automatic gain+mgc manual gain" mode, the adjustment range of the AGC is reduced to 127-50=77 dB.
Based on the above method, the embodiment also provides a multimode automatic gain control system based on SoC, which comprises an analog automatic gain control module, a gain compensation module and a digital automatic gain control module.
As shown in fig. 2, the analog automatic gain control module includes a programmable attenuator, an analog-to-digital converter ADC, a digital detection unit, and a first gain control unit; the input end of the program-controlled attenuator is connected with the baseband signal and the output end of the gain control unit, and the output end is connected with the input end of the analog-to-digital converter ADC; attenuating the baseband analog signal under control of the gain adjustment value; the output end of the analog-to-digital converter ADC is connected with a digital detection unit and is used for converting a received baseband analog signal into a digital signal; the output end of the digital detection unit is respectively connected with the input end of the gain compensation module and the input end of the gain control unit; generating a detection signal for the input digital signal; the gain control unit is used for receiving the detection signal and taking the detection signal as an input signal, and calculating a gain adjustment value of the analog automatic gain control module according to the input signal so as to control the attenuation of the program-controlled attenuator.
The traditional square law detection method firstly carries out square operation on an input intermediate frequency signal, and then uses a low-pass filter to filter out a high-frequency signal so as to obtain detection output. The method has simple working principle, can be used in both digital circuits and analog circuits, but needs a large amount of multiplier resources which are near the ADC with the highest data rate, and can use more FPGA or DSP resources to ensure the processing speed of the multiplier. In order to solve this problem, the digital detection unit of this embodiment selects the CIC detection method to perform wave building, uses the CIC filter to perform low-pass filtering, not only saves multiplier resources, but also does not need additional ROM resources to store filter coefficients because the filter tap coefficients are all 1. And the first gain control unit is arranged in the digital detector and is used for adjusting the gain according to the detection signal output by the digital detector. As shown in fig. 4, the gain compensation module is used for compensating the detection signal provided by the digital detector.
As shown in fig. 5, the digital automatic gain control module includes a second gain control unit, an amplitude detection unit, and an error calculation unit; the second gain control unit consists of a gain adjustment unit and a gain calculation unit, wherein the input end of the gain adjustment unit is connected with the output ends of the gain compensation module and the gain calculation unit, and the output ends are respectively connected with the output end of the whole automatic gain control system and the input end of the amplitude detection unit and are used for adjusting the gain of the digital automatic gain control module according to the final gain value and outputting the gain; the input end of the gain calculation unit is connected with the error calculation unit and is used for limiting the gain value according to a preset gain minimum value to obtain a final gain value; and a gain adjusting unit to complete gain control of the current signal. The output end of the amplitude detection unit is connected with the input end of the error calculation unit, the purpose of amplitude detection is to calculate the envelope amplitude of the input signal, and because the input signal is I, Q quadrature baseband signal, the envelope value of the signal needs to be calculated, which is called as amplitude hereinafter, and the cordic algorithm is adopted for calculation; the error calculation unit consists of a low-pass filter, a threshold comparison and an error processing unit which are sequentially connected in series, wherein the input end of the low-pass filter is used as the input end of the error calculation unit and is connected with the output end of the amplitude detection unit; the output end of the error processing unit is used as the output end of the error calculating unit and is connected with the gain calculating unit; the low-pass filtering unit is used for filtering the amplitude output by the amplitude detection unit; the threshold comparison unit is used for determining a required gain value according to the target amplitude and the low-pass filtered amplitude; the error processing unit is used for obtaining the index value corresponding to the error value and taking the index value as the gain value.
After the invention is added into the receiver, the specific implementation system block diagram of the receiver is shown in figure 1, in the digital intermediate frequency receiver, signals are received through an antenna, are input into a radio frequency module to convert the signals into intermediate frequency, then the intermediate frequency signals are converted into digital signals through an ADC (analog to digital converter), the digital signals are transmitted to a digital processing module to be processed, and finally the processed signals are output. In this configuration, two automatic gain modules are included, which are respectively an analog automatic gain control loop and a digital automatic gain control loop. In the analog automatic gain control part, the analog signal output by the program-controlled attenuator is used as an ADC input signal, the ADC converts the analog signal into a digital signal, a gain adjustment value of the analog automatic gain control module is obtained according to the digital signal output by the ADC, and the gain input to the program-controlled attenuator is adjusted according to the gain adjustment value of the analog automatic gain control module. In the digital AGC part, the IQ signal output by the front stage module is used as an input signal, a required gain value is calculated according to the input signal, and the gain value is transmitted to the gain adjustment module to adjust the input signal.

Claims (5)

1. The multimode automatic gain control method based on the SoC is characterized by comprising the following steps of:
step 1, converting an analog signal output by a program-controlled attenuator into a digital signal through an ADC (analog to digital converter), performing detection processing according to the digital signal output by the ADC to obtain a detection signal, calculating the detection signal to obtain an analog AGC gain adjustment value, and adjusting the gain input to the program-controlled attenuator according to the analog AGC gain adjustment value;
the gain adjustment value of the analog AGC is obtained by the steps of:
step 1.1, setting the time window width of saturation of a detection signal, the time window with too small a time window and the time window width of average power;
step 1.2, judging whether the detected signal is within the saturated time window width set in step 1.1, if yes, indicating that the ADC signal is saturated and overloaded at the moment, and reducing the gain by 8dB;
judging whether the detection signal is outside the time window which is set to be too small in the step 1.1, if so, indicating that the intermediate frequency signal is weak at the moment, and increasing the gain by 14dB;
judging the relation between the average power of the detection signal and the width of the time window set in the step 1.1: when the average power is larger than the threshold of-4 dB, the intermediate frequency signal energy is larger, and the gain of 2dB needs to be reduced; when the average power is lower than-8 dB, but the instantaneous amplitude is larger than-18 dB, the gain is increased by 2dB;
step 2, taking the analog AGC gain adjustment value obtained in the step 1 as a gain compensation coefficient, and outputting an AD signal after gain compensation so as to obtain an input ADC signal actual value;
step 3: gain control for digital AGC gain
Step 3.1, the signal output in the step 2 is sent to a digital AGC, and the amplitude of the signal is calculated by adopting a cordic algorithm;
step 3.2, filtering the calculated amplitude result by adopting low-pass filtering to prove the stability of the signal;
step 3.3, calculating an error value between the filtered amplitude result and the target amplitude;
step 3.4, calculating an index value corresponding to the error value, and taking the index value as a gain value; setting a maximum value and a minimum value, limiting the gain value between the maximum value and the minimum value to obtain a final gain value, and adjusting the gain of the digital AGC according to the final gain value, thereby completing the gain control of the current signal.
2. The SoC-based multimode automatic gain control method of claim 1, wherein: the low-pass filter adopted in the step 3.2 is a first-order IIR filter.
3. The SoC-based multimode automatic gain control method of claim 1, wherein: the multi-mode automatic gain control method based on SoC also comprises the following specific operation steps of gain distribution of analog AGC and digital AGC before step 1:
a1, determining an actual demand gain adjustment range value of the digital AGC according to application demands and an ADC sampling inherent gain value;
a2, determining the actual gain adjustment range value of the analog AGC according to the starting control level value of the analog AGC and the actual required gain adjustment range value of the digital AGC determined in the step a1.
4. A multi-mode automatic gain control method based on SoC according to claim 3, characterized in that: the multi-mode automatic gain control method based on the SoC further comprises the step of combining AGC automatic gain with MGC manual gain control to improve the accuracy of a gain output value; the specific operation is as follows:
a1.1, when the application requirement gain adjustment range value is larger than the digital AGC gain adjustment range value, the gain adjustment range of the digital AGC is required to be reduced, namely the maximum value of gain times is correspondingly reduced;
a1.2, when the AGC gain adjustment range is less than or equal to the radio frequency AGC adjustment range, the digital AGC keeps the gain multiple to be 1; the analog AGC range is reduced, the gain output port is increased by a gain value comparison module, and when the output gain value exceeds the AGC range at the moment, the allowable maximum gain value output is maintained.
5. The utility model provides a multimode automatic gain control system based on SoC, includes analog automatic gain control module, gain compensation module and digital automatic gain control module, its characterized in that:
the analog automatic gain control module comprises a program-controlled attenuator, an analog-to-digital converter ADC, a digital detection unit and a first gain control unit; the input end of the program-controlled attenuator is connected with the input end of the baseband signal and the gain control unit, and the output end of the program-controlled attenuator is connected with the input end of the analog-to-digital converter ADC; attenuating the baseband signal under control of the gain adjustment value; the output end of the analog-to-digital converter ADC is connected with a digital detection unit and is used for converting a received baseband analog signal into a digital signal; the output end of the digital detection unit is respectively connected with the input end of the gain compensation module and the input end of the gain control unit; generating a detection signal for the input digital signal; the gain control unit is used for receiving the detection signal, and calculating a gain adjustment value of the analog automatic gain control module according to the detection signal so as to control attenuation of the program controller;
the gain compensation module is used for compensating the detection signal provided by the digital detector;
the digital automatic gain control module comprises a second gain control unit, an amplitude detection unit and an error calculation unit; the second gain control unit consists of a gain adjustment unit and a gain calculation unit, wherein the input end of the gain adjustment unit is connected with the output ends of the gain compensation module and the gain calculation unit, and the output ends are respectively connected with the output end of the whole AGC system and the input end of the amplitude detection unit; the input end of the gain calculation unit is connected with the error calculation unit; the gain calculation unit is used for calculating a gain value according to the maximum value and the minimum value of the preset gain, and limiting the gain value between the maximum value and the minimum value range; the gain adjusting unit is used for adjusting the gain of the digital automatic gain control module according to the final gain value and then outputting the gain, so as to complete the gain control of the current signal; the output end of the amplitude detection unit is connected with the input end of the error calculation unit, and the amplitude detection unit calculates the amplitude of the output signal of the gain adjustment unit by adopting a cordic algorithm; the error calculation unit consists of a low-pass filter, a threshold comparison and an error processing unit which are sequentially connected in series, wherein the input end of the low-pass filter is used as the input end of the error calculation unit and is connected with the output end of the amplitude detection unit; the output end of the error processing unit is used as the output end of the error calculating unit and is connected with the gain calculating unit; the low-pass filtering unit is used for filtering the amplitude output by the amplitude detection unit; the threshold comparison unit is used for calculating an error value between the filtered amplitude and the target amplitude according to the target amplitude; the error processing unit is used for obtaining the index value corresponding to the error value and taking the index value as the gain value.
CN202310243757.2A 2023-03-14 2023-03-14 Multi-mode automatic gain control method and system based on SoC Pending CN116346148A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310243757.2A CN116346148A (en) 2023-03-14 2023-03-14 Multi-mode automatic gain control method and system based on SoC

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310243757.2A CN116346148A (en) 2023-03-14 2023-03-14 Multi-mode automatic gain control method and system based on SoC

Publications (1)

Publication Number Publication Date
CN116346148A true CN116346148A (en) 2023-06-27

Family

ID=86876815

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310243757.2A Pending CN116346148A (en) 2023-03-14 2023-03-14 Multi-mode automatic gain control method and system based on SoC

Country Status (1)

Country Link
CN (1) CN116346148A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116805882A (en) * 2023-08-24 2023-09-26 成都零点科技有限公司 Processing method for signal amplitude exceeding AD range of receiver

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116805882A (en) * 2023-08-24 2023-09-26 成都零点科技有限公司 Processing method for signal amplitude exceeding AD range of receiver
CN116805882B (en) * 2023-08-24 2023-11-17 成都零点科技有限公司 Processing method for signal amplitude exceeding AD range of receiver

Similar Documents

Publication Publication Date Title
JP3183078B2 (en) Control signal generation circuit, automatic gain control circuit using the same, receiver using the same, and communication system using the same
JP5554769B2 (en) Automatic filter control
EP2810370B1 (en) Method and apparatus to independently control front end gain and baseband gain
EP2086269B1 (en) A transmit power controller
EP1129522B1 (en) Method and apparatus for automatic gain control
CN110365302B (en) Automatic gain control method and device for communication system
CN107086859A (en) Digital resources obtainment circuit for wireless communication receiver
JP4163531B2 (en) Automatic gain controller
CN114204949B (en) Large dynamic quick digital AGC control method
CN116346148A (en) Multi-mode automatic gain control method and system based on SoC
CN107147368B (en) Gain adjusting method and device for gain amplifier
Zhang et al. Digital automatic gain control design with large dynamic range in wireless communication receivers
US8676140B2 (en) Efficient scheme for automatic gain control in communication systems
CN101741402A (en) Wireless receiver applicable to ultra-large dynamic range under wireless communication system
CN101588196B (en) Device and method for gain control
CN100440741C (en) Automatic gain control device and method for mobile communication terminal
US8787435B2 (en) Narrow band interference determined by second and fourth order norms
US7805121B2 (en) Radio signal receiver and gain control method thereof
CN104247276A (en) Apparatus and method for matching antenna impedance in wireless communication system
CN1293492A (en) Radio MF receiver with integrated base-band digital MF AGC
KR101159851B1 (en) Automatic gain control device
CN104539253B (en) Three-level automatic gain control equipment and its control method
JP4460678B2 (en) Frequency analyzer
CN113219241A (en) Power detection method and device and treatment equipment
KR20130004994A (en) Automatic gain controller using oversampling and method thereof

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination