Device, method and frequency source for controlling frequency source

By designing a digital fast closed-loop circuit and a high-speed controller in the millimeter-wave frequency source, the problem of too long amplitude switching time in the existing technology is solved, the fast amplitude control of the frequency source is realized, and the switching requirements of agile signals are met. High accuracy is maintained otherwise.

CN114629457BActive Publication Date: 2024-10-11BEIJING INST OF RADIO METROLOGY & MEASUREMENT
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111654042.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-30
Publication Date
2024-10-11
Estimated Expiration
2041-12-30

AI Technical Summary

Technical Problem

The amplitude switching time of the automatic level control method used by existing millimeter wave frequency sources is on the order of milliseconds, which cannot meet the fast switching requirements of agile signals on the order of 100ns.

Method used

A device for controlling frequency sources is designed, including electrically adjustable attenuators, couplers, detectors, SPDT switches, operational amplifiers, analog-to-digital converters, digital-to-analog converters and controllers, through digital fast closed-loop loops and high-speed controllers Calculate the attenuation multiple to achieve fast amplitude control.

Benefits of technology

The amplitude switching time of the frequency source is realized to be less than 100ns, which meets the fast switching requirements of agile signals. When there is no need to output agile signals, it switches to an analog loop to ensure higher amplitude control accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114629457B_ABST
    Figure CN114629457B_ABST
Patent Text Reader

Abstract

The embodiment of the present application relates to a device, method and frequency source for controlling a frequency source, the device comprising an electrically adjustable attenuator, a coupler, a detector, a first SPDT switch, a second SPDT switch, a third SPDT switch, a comparator, a first operational amplifier, a second operational amplifier, an analog-to-digital converter, a digital-to-analog converter, a controller and a temperature sensor; the controller is used to obtain a detection voltage of a detection signal through an analog-to-digital converter, obtain first compensation data according to the detection voltage, temperature data, a frequency control word and an amplitude control word, and control the digital-to-analog converter to generate a first compensation voltage signal; the first compensation voltage signal forms a first feedback signal, and the first feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator. The amplitude control circuit of the frequency source of the embodiment of the present application can switch to a theoretical value directly calculated by a high-speed controller to control the attenuation multiple when a jetway signal needs to be output, thereby reducing the time of using analog circuit integral feedback.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of electronic technology, and in particular, to a device, method and frequency source for controlling a frequency source. Background Art

[0002] Millimeter wave frequency sources are an important part of communication systems and radio technology, and are also the core of military electronic systems. With the increase in demand, there are increasingly higher requirements for millimeter wave frequency source output amplitude control capability, frequency stability, agile frequency capability, phase noise, and spurious indicators.

[0003] Among them, the amplitude switching time requirement of the agile signal is in the order of 100ns. However, at present, the amplitude switching time of the conventional analog ALC (Automatic Level Control) control method used by the millimeter wave frequency source is usually in the order of milliseconds, which cannot meet the requirement of the rapid switching amplitude of the agile signal. How to improve the amplitude switching speed of the millimeter wave frequency source so that the amplitude switching time meets the requirements of the agile signal is one of the technical problems in this field.

[0004] Therefore, the inventor provides a method for controlling a frequency source. By using this method to control the frequency source, the amplitude switching time of the frequency source can meet the requirements of an agile signal. Summary of the invention

[0005] 1. Technical issues to be resolved

[0006] The technical problem to be solved by the embodiments of the present application is that the ALC control method used in the frequency source in the prior art has a slow amplitude switching time and cannot meet the amplitude switching time requirement of the agile signal.

[0007] (II) Technical solution

[0008] To solve the above technical problems, according to one aspect of an embodiment of the present application, a device for controlling a frequency source is provided, comprising: an electrically adjustable attenuator, a coupler, a detector, a first SPDT switch, a second SPDT switch, a third SPDT switch, a comparator, a first operational amplifier, a second operational amplifier, an analog-to-digital converter, a digital-to-analog converter, a controller, and a temperature sensor;

[0009] The electrically adjustable attenuator is connected to the coupler, one end of the coupler is used to output the first output signal, the other end of the coupler is connected to the detector, the detector is connected to the fixed end of the first SPDT switch, a moving end of the first SPDT switch is connected to the analog-to-digital converter, the other moving end of the first SPDT switch is connected to the comparator, the analog-to-digital converter is connected to the controller, the comparator is connected to a moving end of the second SPDT switch, the other moving end of the second SPDT switch is connected to the second operational amplifier, the fixed end of the second SPDT switch is connected to the digital-to-analog converter, the digital-to-analog converter is connected to the controller, the comparator is connected to the first operational amplifier, the first operational amplifier is connected to a moving end of the third SPDT switch, the other moving end of the third SPDT switch is connected to the second operational amplifier, and the fixed end of the third SPDT switch is connected to the electrically adjustable attenuator; the temperature sensor is connected to the controller for acquiring temperature data;

[0010] When the fixed end of the first SPDT switch is connected to the analog-to-digital converter, the fixed end of the second SPDT switch is connected to the second operational amplifier, and the fixed end of the third SPDT switch is connected to the second operational amplifier, the input signal filtered by the switch passes through the electrically adjustable attenuator and the coupler, and the detection signal is output through the detector; the controller is used to obtain the detection voltage of the detection signal through the analog-to-digital converter, obtain the first compensation data according to the detection voltage, temperature data, frequency control word and amplitude control word, and control the digital-to-analog converter to generate the first compensation voltage signal according to the first compensation data; the first compensation voltage signal forms a first feedback signal through the second operational amplifier, and the first feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator, thereby adjusting the amplitude of the first output signal.

[0011] Furthermore, when the fixed end of the first SPDT switch is connected to the comparator, the fixed end of the second SPDT switch is connected to the comparator, and the fixed end of the third SPDT switch is connected to the first operational amplifier, the controller generates second compensation data according to the frequency control word, the amplitude control word, and the temperature data, and controls the digital-to-analog converter to generate a second compensation voltage signal according to the second compensation data. The second compensation voltage signal and the detection signal are input into the comparator, and the comparator obtains a comparison signal. The comparison signal forms a second feedback signal through the first operational amplifier, and the second feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator, thereby adjusting the amplitude of the first output signal.

[0012] Furthermore, one end of the coupler for outputting the first output signal is connected to a digitally controlled attenuator, and the digitally controlled attenuator is controlled by the controller; the first output signal forms a second output signal through the digitally controlled attenuator;

[0013] The controller is also used to control the attenuation multiple of the digital controlled attenuator according to the detection voltage, thereby adjusting the amplitude of the second output signal.

[0014] Further, the digitally controlled attenuator is connected to the third operational amplifier;

[0015] The second output signal is passed through a third operational amplifier to form a third output signal;

[0016] The controller is also used to control the gate voltage of the third operational amplifier.

[0017] Furthermore, the digitally controlled attenuator includes a plurality of units connected in series, each unit includes two fourth SPDT switches and a sub-attenuator with amplification attenuation, and the fourth SPDT switch is used to control whether a signal passing through the unit passes through the sub-attenuator.

[0018] According to another aspect of an embodiment of the present application, a method for controlling a frequency source is provided, which is applied to a controller and includes:

[0019] Control the fixed end of the first SPDT switch to be connected to the analog-to-digital converter, the fixed end of the second SPDT switch to be connected to the second operational amplifier, and the fixed end of the third SPDT switch to be connected to the second operational amplifier;

[0020] Obtain the detection voltage of the analog-to-digital converter;

[0021] Get the temperature data of the temperature sensor;

[0022] Obtain frequency control word and amplitude control word;

[0023] Acquire first compensation data according to the detection voltage, temperature data, frequency control word and amplitude control word;

[0024] The digital-to-analog converter is controlled to generate a first compensation voltage signal according to the first compensation data, so as to adjust the attenuation multiple of the electrically adjustable attenuator by using the first compensation voltage signal, thereby adjusting the amplitude of the first output signal.

[0025] According to another aspect of an embodiment of the present application, a control frequency source is provided, comprising any one of the above-mentioned devices.

[0026] (III) Beneficial effects

[0027] The above technical solution of the embodiment of the present application has the following advantages:

[0028] The amplitude control circuit of the frequency source of the embodiment of the present application can switch to directly control the attenuation multiple by using the theoretical value calculated by the high-speed controller when it is necessary to output the Jetway signal, thereby reducing the time of using the analog circuit integral feedback. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] Figure 1 is a circuit schematic diagram of a device for controlling a frequency source according to an embodiment of the present application;

[0030] In the figure: 1. electrically adjustable attenuator; 2. coupler; 3. detector; 4. first SPDT switch; 5. second SPDT switch; 6. third SPDT switch; 7. comparator; 8. first operational amplifier; 9. second operational amplifier; 10. analog-to-digital converter; 11. digital-to-analog converter; 12. controller; 13. temperature sensor;.

[0031] Figure 2 is a schematic diagram of a digitally controlled attenuator including four units according to an embodiment of the present application;

[0032] Figure 3 It is a flow chart of a method for controlling a frequency source according to an embodiment of the present application. DETAILED DESCRIPTION

[0033] The specific implementation of the embodiments of the present application is further described in detail below in conjunction with the accompanying drawings and examples. The following examples are used to illustrate the embodiments of the present application, but are not used to limit the scope of the embodiments of the present application.

[0034] In the description of the embodiments of the present application, it should be understood that the terms "center", "longitudinal", "lateral", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc., indicating the orientation or positional relationship are based on the orientation or positional relationship shown in the drawings, which is only for the convenience of describing the embodiments of the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the embodiments of the present application. In addition, the terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance.

[0035] In the description of the embodiments of the present application, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal communication of two components. For ordinary technicians in this field, the specific meanings of the above terms in the embodiments of the present application can be understood according to specific circumstances.

[0036] Figure 1 is a circuit schematic diagram of a device for controlling a frequency source according to an embodiment of the present application, such as Figure 1 As shown, the device includes an electrically adjustable attenuator 1, a coupler 2, a detector 3, a first SPDT switch 4, a second SPDT switch 5, a third SPDT switch 6, a comparator 7, a first operational amplifier 8, a second operational amplifier 9, an analog-to-digital converter 10, a digital-to-analog converter 11, a controller 12, and a temperature sensor 13;

[0037] The electrically adjustable attenuator 1 is connected to the coupler 2, one end of the coupler 2 is used to output the first output signal, the other end of the coupler 2 is connected to the detector 3, the detector 3 is connected to the fixed end of the first SPDT switch 4, a moving end of the first SPDT switch 4 is connected to the analog-to-digital converter 10, the other moving end of the first SPDT switch 4 is connected to the comparator 7, the analog-to-digital converter 10 is connected to the controller 12, the comparator 7 is connected to a moving end of the second SPDT switch 5, the other moving end of the second SPDT switch 5 is connected to the second operational amplifier 9, the fixed end of the second SPDT switch 5 is connected to the digital-to-analog converter 11, the digital-to-analog converter 11 is connected to the controller 12, the comparator 7 is connected to the first operational amplifier 8, the first operational amplifier 8 is connected to a moving end of the third SPDT switch 6, the other moving end of the third SPDT switch 6 is connected to the second operational amplifier 9, and the fixed end of the third SPDT switch 6 is connected to the electrically adjustable attenuator 1; the temperature sensor 13 is connected to the controller 12, and is used to obtain temperature data;

[0038] When the fixed end of the first SPDT switch 4 is connected to the analog-to-digital converter 10, the fixed end of the second SPDT switch 5 is connected to the second operational amplifier 9, and the fixed end of the third SPDT switch 6 is connected to the second operational amplifier 9, the input signal filtered by the switch passes through the electrically adjustable attenuator 1 and the coupler 2, and the detection signal is output through the detector 3; the controller 12 is used to obtain the detection voltage of the detection signal through the analog-to-digital converter 10, obtain the first compensation data according to the detection voltage, temperature data, frequency control word and amplitude control word, and control the digital-to-analog converter 11 to generate a first compensation voltage signal according to the first compensation data; the first compensation voltage signal forms a first feedback signal through the second operational amplifier 9, and the first feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator 1, thereby adjusting the amplitude of the first output signal.

[0039] The application scenario of the embodiment of the present application is the amplitude control circuit of the frequency source. The amplitude control circuit controls the amplitude of the output signal by controlling the electrically adjustable attenuator 1. The ordinary analog automatic level control (ALC) generates a control signal of the attenuation multiple through a negative feedback circuit composed of analog components, which is slow and cannot meet the requirements of rapid amplitude switching of the agile signal. Therefore, the embodiment of the present application adds a digital fast closed-loop circuit to realize the frequency agility function, and realizes the switching of the analog ALC loop or the digital loop (that is, the controller 12 directly calculates the data required to adjust the attenuation multiple, and controls the attenuation multiple of the electrically adjustable attenuator 1 according to the data) through the SPDT switch.

[0040] Specifically, the controller 12 in the embodiment of the present application can be a FPGA (Field Programmable Gate Array), which uses a high-speed clock and has a fast data processing speed. In the digital loop, the FPGA uses a high-speed clock and can perform fast table lookup, comparison, calculation, correction and other data processing, so the calculation and response speed is fast, and the control time is less than 100ns.

[0041] In addition, since the amplifier is sensitive to temperature, a temperature sensor 13 is added to the system to collect the temperature, and compensation and correction are performed through the controller 12 to ensure the reliability of the system.

[0042] Specifically, the controller 12 generates compensation data according to the frequency control word, the amplitude control word, and the temperature data, and then calculates the data (i.e., the first compensation data) for controlling the attenuation multiple of the electronically controlled attenuator according to the compensation data and the detection voltage obtained by the detector 3. The controller 12 generates compensation data according to the frequency control word, the amplitude control word, and the temperature data by looking up a table. The controller 12 may store an experience data table containing the frequency control word, the amplitude control word, and the temperature data.

[0043] Specifically, the embodiment of the present application switches the negative feedback loop for generating the control signal of the attenuation multiple by controlling the first SPDT (Single Pole Double Throw) switch, the second SPDT switch 5 and the third SPDT switch 6. If it is necessary to process the agile signal, it is switched to generate the control signal of the attenuation multiple through the controller 12.

[0044] The input signal of the embodiment of the present application is input by the electrically adjustable attenuator 1, and the input signal can be a 40-67 GHz broadband agile vector signal obtained by passing through a switching bandpass filter.

[0045] The amplitude control circuit of the frequency source of the embodiment of the present application can switch to directly control the attenuation multiple using the theoretical value calculated by the high-speed controller 12 when the Jetway signal needs to be output, thereby reducing the time of using analog circuit integral feedback.

[0046] As a preferred embodiment, when the fixed end of the first SPDT switch 4 is connected to the comparator 7, the fixed end of the second SPDT switch 5 is connected to the comparator 7, and the fixed end of the third SPDT switch 6 is connected to the first operational amplifier 8, the controller 12 generates second compensation data according to the frequency control word, the amplitude control word, and the temperature data, and controls the digital-to-analog converter 11 to generate a second compensation voltage signal according to the second compensation data. The second compensation voltage signal and the detection signal are input into the comparator 7, and the comparator 7 obtains a comparison signal. The comparison signal forms a second feedback signal through the first operational amplifier 8, and the second feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator 1, thereby adjusting the amplitude of the first output signal.

[0047] When there is no need to generate an agile signal, the frequency source of the embodiment of the present application switches to an analog loop with higher amplitude control accuracy, so that it is possible to output a signal with more accurate amplitude without outputting an agile signal.

[0048] As another preferred embodiment, one end of the coupler 2 for outputting the first output signal is connected to a digitally controlled attenuator, and the digitally controlled attenuator is controlled by a controller 12; the first output signal forms a second output signal through the digitally controlled attenuator; the controller 12 is also used to control the attenuation multiple of the digitally controlled attenuator according to the detection voltage, thereby adjusting the amplitude of the second output signal.

[0049] The digitally controlled attenuator added in the embodiment of the present application is used to further attenuate the output signal in the later stage, so as to meet the need of outputting a signal with a wider amplitude range.

[0050] As another preferred embodiment, as other optional real-time mode, the digitally controlled attenuator includes a plurality of units connected in series, each unit includes two fourth SPDT switches and a sub-attenuator with amplification attenuation, and the fourth SPDT switch is used to control whether the signal passing through the unit passes through the sub-attenuator.

[0051] Specifically, the fourth SPDT switch of the unit is connected to the sub-attenuator, that is, the unit is used to attenuate the attenuation multiple corresponding to the sub-attenuator. If it is not connected to the sub-attenuator, the unit is not used for attenuation.

[0052] Take the digital controlled attenuator including four units as an example. Figure 2 is a schematic diagram of a digitally controlled attenuator including four units according to an embodiment of the present application, Figure 2 The attenuators of the four units correspond to dynamic range 10dB and step 10dB, dynamic range 20dB and step 20dB, dynamic range 40dB and step 40dB, dynamic range 70dB and step 70dB. When combined with the electrically adjustable attenuator 1 with dynamic range 30dB and step 0.5dB, a dynamic range better than 100dB and step 0.5dB attenuation can be achieved.

[0053] As another optional real-time method, a digitally controlled attenuator is connected to the third operational amplifier;

[0054] The second output signal is passed through a third operational amplifier to form a third output signal;

[0055] The controller 12 is further configured to control the gate voltage of the third operational amplifier.

[0056] Specifically, the gate voltage is used as a window to determine whether the second output signal can pass through the circuit composed of the third operational amplifier. Therefore, the embodiment of the present application can generate a pulse signal through the gate voltage.

[0057] Figure 3 1 is a flow chart of a method for controlling a frequency source according to an embodiment of the present application. The method is applied to the controller 12 and includes the following steps S1 to S4:

[0058] Step S1, controlling the fixed end of the first SPDT switch 4 to be connected to the analog-to-digital converter 10, the fixed end of the second SPDT switch 5 to be connected to the second operational amplifier 9, and the fixed end of the third SPDT switch 6 to be connected to the second operational amplifier 9;

[0059] Step S1, obtaining the detection voltage of the analog-to-digital converter 10;

[0060] Step S2, obtaining temperature data from the temperature sensor 13;

[0061] Step S3, obtaining a frequency control word and an amplitude control word;

[0062] Step S4, obtaining first compensation data according to the detection voltage, temperature data, frequency control word and amplitude control word;

[0063] Step S5, controlling the digital-to-analog converter 11 to generate a first compensation voltage signal according to the first compensation data, so as to adjust the attenuation multiple of the electrically adjustable attenuator 1 by using the first compensation voltage signal, thereby adjusting the amplitude of the first output signal.

[0064] An embodiment of the present application provides a control frequency source, including any one of the devices described above.

[0065] It should be clear that the various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. For the embodiments of the method, the relevant parts can refer to the partial description of the device embodiment according to the writing situation. The embodiments of the present application are not limited to the specific steps and structures described above and shown in the figures. In addition, for the sake of simplicity, a detailed description of known method technologies is omitted here.

[0066] The above is only a preferred implementation of the embodiment of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the embodiment of the present application. These improvements and modifications should also be regarded as the protection scope of the embodiment of the present application.

Claims

1. A device for controlling a frequency source, characterized in that: include: An electrically adjustable attenuator (1), a coupler (2), a detector (3), a first SPDT switch (4), a second SPDT switch (5), a third SPDT switch (6), a comparator (7), a first operational amplifier (8), a second operational amplifier (9), an analog-to-digital converter (10), a digital-to-analog converter (11), a controller (12), and a temperature sensor (13); The electrically adjustable attenuator (1) is connected to the coupler (2), one end of the coupler (2) is used to output a first output signal, the other end of the coupler (2) is connected to the detector (3), the detector (3) is connected to the fixed end of the first SPDT switch (4), a moving end of the first SPDT switch (4) is connected to the analog-to-digital converter (10), the other moving end of the first SPDT switch (4) is connected to the comparator (7), the analog-to-digital converter (10) is connected to the controller (12), the comparator (7) is connected to a moving end of the second SPDT switch (5), the other moving end of the second SPDT switch (5) is connected to the comparator (7), the analog-to-digital converter (10) is connected to the controller (12), the comparator (7) is connected to a moving end of the second SPDT switch (5), and the other moving end of the second SPDT switch (5) is connected to the comparator (7). The fixed end of the second SPDT switch (5) is connected to the second operational amplifier (9), the fixed end of the second SPDT switch (5) is connected to the digital-to-analog converter (11), the digital-to-analog converter (11) is connected to the controller (12), the comparator (7) is connected to the first operational amplifier (8), the first operational amplifier (8) is connected to a moving end of the third SPDT switch (6), the other moving end of the third SPDT switch (6) is connected to the second operational amplifier (9), and the fixed end of the third SPDT switch (6) is connected to the electrically adjustable attenuator (1); the temperature sensor (13) is connected to the controller (12) for acquiring temperature data; When the fixed end of the first SPDT switch (4) is connected to the analog-to-digital converter (10), the fixed end of the second SPDT switch (5) is connected to the second operational amplifier (9), and the fixed end of the third SPDT switch (6) is connected to the second operational amplifier (9), the input signal filtered by the switches passes through the electrically adjustable attenuator (1) and the coupler (2), and outputs a detection signal through the detector (3); the controller (12) is used to obtain a detection voltage of the detection signal through the analog-to-digital converter (10), obtain first compensation data according to the detection voltage, the temperature data, the frequency control word and the amplitude control word, and control the digital-to-analog converter (11) to generate a first compensation voltage signal according to the first compensation data; the first compensation voltage signal forms a first feedback signal through the second operational amplifier (9), and the first feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator (1), thereby adjusting the amplitude of the first output signal.

2. The device according to claim 1, characterized in that When the fixed end of the first SPDT switch (4) is connected to the comparator (7), the fixed end of the second SPDT switch (5) is connected to the comparator (7), and the fixed end of the third SPDT switch (6) is connected to the first operational amplifier (8), the controller (12) generates second compensation data according to the frequency control word, the amplitude control word, and the temperature data, and controls the digital-to-analog converter (11) to generate a second compensation voltage signal according to the second compensation data. The second compensation voltage signal and the detection signal are input into the comparator (7), and the comparator (7) obtains a comparison signal. The comparison signal forms a second feedback signal through the first operational amplifier (8), and the second feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator (1), thereby adjusting the amplitude of the first output signal.

3. The device according to claim 1, characterized in that One end of the coupler (2) for outputting the first output signal is connected to a digitally controlled attenuator, and the digitally controlled attenuator is controlled by the controller (12); the first output signal is converted into a second output signal through the digitally controlled attenuator; The controller (12) is also used to control the attenuation multiple of the digital controlled attenuator according to the detection voltage, thereby adjusting the amplitude of the second output signal.

4. The device according to claim 3, characterized in that The digitally controlled attenuator is connected to the third operational amplifier; The second output signal forms a third output signal through the third operational amplifier; The controller (12) is also used to control the gate voltage of the third operational amplifier.

5. The device according to claim 4, characterized in that The digitally controlled attenuator includes a plurality of units connected in series, each of which includes two fourth SPDT switches, an operational amplifier with amplification gain, and a sub-attenuator with amplification attenuation, and the fourth SPDT switch is used to control whether the signal passing through the unit passes through the sub-attenuator.

6. A method for controlling a frequency source, applied to a controller (12), characterized in that: The method is implemented using a device for controlling a frequency source, The device comprises: an electrically adjustable attenuator (1), a coupler (2), a detector (3), a first SPDT switch (4), a second SPDT switch (5), a third SPDT switch (6), a comparator (7), a first operational amplifier (8), a second operational amplifier (9), an analog-to-digital converter (10), a digital-to-analog converter (11), a controller (12), and a temperature sensor (13); The electrically adjustable attenuator (1) is connected to the coupler (2), one end of the coupler (2) is used to output a first output signal, the other end of the coupler (2) is connected to the detector (3), the detector (3) is connected to the fixed end of the first SPDT switch (4), a moving end of the first SPDT switch (4) is connected to the analog-to-digital converter (10), the other moving end of the first SPDT switch (4) is connected to the comparator (7), the analog-to-digital converter (10) is connected to the controller (12), the comparator (7) is connected to a moving end of the second SPDT switch (5), the other moving end of the second SPDT switch (5) is connected to the comparator (7), the analog-to-digital converter (10) is connected to the controller (12), the comparator (7) is connected to a moving end of the second SPDT switch (5), and the other moving end of the second SPDT switch (5) is connected to the comparator (7). The fixed end of the second SPDT switch (5) is connected to the second operational amplifier (9), the fixed end of the second SPDT switch (5) is connected to the digital-to-analog converter (11), the digital-to-analog converter (11) is connected to the controller (12), the comparator (7) is connected to the first operational amplifier (8), the first operational amplifier (8) is connected to a moving end of the third SPDT switch (6), the other moving end of the third SPDT switch (6) is connected to the second operational amplifier (9), and the fixed end of the third SPDT switch (6) is connected to the electrically adjustable attenuator (1); the temperature sensor (13) is connected to the controller (12) for acquiring temperature data; The fixed end of the first SPDT switch (4) is connected to the analog-to-digital converter (10), the fixed end of the second SPDT switch (5) is connected to the second operational amplifier (9), and the fixed end of the third SPDT switch (6) is connected to the second operational amplifier (9), the input signal after switch filtering passes through the electrically adjustable attenuator (1) and the coupler (2), and outputs a detection signal through the detector (3); the controller (12) is used to obtain the detection voltage of the detection signal through the analog-to-digital converter (10), obtain first compensation data according to the detection voltage, the temperature data, the frequency control word and the amplitude control word, and control the digital-to-analog converter (11) to generate a first compensation voltage signal according to the first compensation data; the first compensation voltage signal forms a first feedback signal through the second operational amplifier (9), and the first feedback signal is used to adjust the attenuation multiple of the electrically adjustable attenuator (1), thereby adjusting the amplitude of the first output signal; The method comprises: Controlling the fixed end of the first SPDT switch (4) to be connected to the analog-to-digital converter (10), the fixed end of the second SPDT switch (5) to be connected to the second operational amplifier (9), and the fixed end of the third SPDT switch (6) to be connected to the second operational amplifier (9); Obtaining a detection voltage of an analog-to-digital converter (10); Acquiring temperature data from a temperature sensor (13); Obtain frequency control word and amplitude control word; Acquire first compensation data according to the detection voltage, the temperature data, the frequency control word and the amplitude control word; The digital-to-analog converter (11) is controlled to generate a first compensation voltage signal according to the first compensation data, so as to adjust the attenuation multiple of the electrically adjustable attenuator (1) using the first compensation voltage signal, thereby adjusting the amplitude of the first output signal.

7. A control frequency source, characterized in that: The invention comprises the device according to any one of claims 1 to 5.