A circuit and device for controlling the advance of the falling edge of a square wave
Patent Information
- Application Number
- CN202211537732.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-02
- Publication Date
- 2026-09-25
- Estimated Expiration
- 2042-12-02
AI Technical Summary
[0002]许多驱动电路通过脉冲宽度调制(Pulse Width Modulation,PWM)信号进行控制,但是现有的技术方案为将方波的上升沿单独后移,或上升沿下降沿一起后移,而无法单独将下降沿前移
[0026]本申请所提供的控制方波下降沿前移的电路,包括:波形转换模块、基准电压模块、比较模块、第一运算模块、第二运算模块;波形转换模块的输入端用于接收PWM信号并将PWM信号由方波转换为三角波;基准电压转换模块的输入端与波形转换模块的输出端连接,用于输出小于三角波的峰值的基准电压;比较模块的正相输入端与波形转换模块的输出端连接,比较器的反相输入端与基准电压模块的输出端连接,用于根据三角波和基准电压输出第一方波;其中,第一方波的上升沿比PWM信号的上升沿后移,且第一方波的下降沿与PWM信号的下降沿相同;第一运算模块的输入端与比较模块的输出端连接,用于将第一方波反相形成第二方波;第二运算模块的第一输入端与第一运算模块的输出端连接,第二运算模块的第二输入端用于接收PWM信号,第二运算模块的输出端用于将第二方波与PWM信号作与运算,以便输出目标信号,其中,目标信号的上升沿与PWM信号的上升沿相同,且目标信号的下降沿比PWM信号的下降沿提前预设距离,预设距离与第一方波的脉冲宽度相同。可见,通过本申请提供的电路实现了单独将下降沿前移;另外,下降沿前移量与第一方波的脉冲宽度相同,而第一方波的脉冲宽度是根据三角波和基准电压确定的,故而,下降沿的前移量可通过调整基准电压来控制,以满足具体的设计需求。
Smart Images

Figure CN115833797B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of circuits, and in particular to a circuit and apparatus for controlling the forward shift of the falling edge of a square wave. Background Technology
[0002] Many drive circuits are controlled by pulse width modulation (PWM) signals, but existing technologies either shift the rising edge of the square wave backward individually or shift both the rising and falling edges backward, but cannot shift the falling edge forward individually. However, due to some control requirements or circuit reliability requirements, shifting the falling edge of the PWM signal forward would greatly improve design flexibility.
[0003] Therefore, how to shift the falling edge of a square wave forward independently is a technical problem that urgently needs to be solved by those in the field. Summary of the Invention
[0004] The purpose of this application is to provide a circuit and apparatus for controlling the forward shift of the falling edge of a square wave, for individually shifting the falling edge of a square wave forward.
[0005] To solve the above-mentioned technical problems, this application provides a circuit for controlling the forward shift of the falling edge of a square wave, comprising: a waveform conversion module, a reference voltage module, a comparison module, a first arithmetic module, and a second arithmetic module;
[0006] The input terminal of the waveform conversion module is used to receive the PWM signal and convert the PWM signal from a square wave to a triangular wave;
[0007] The input terminal of the reference voltage conversion module is connected to the output terminal of the waveform conversion module, and is used to output a reference voltage that is smaller than the peak value of the triangular wave;
[0008] The non-inverting input of the comparator module is connected to the output of the waveform conversion module, and the inverting input of the comparator is connected to the output of the reference voltage module, for outputting a first square wave according to the triangular wave and the reference voltage; wherein, the rising edge of the first square wave is delayed compared to the rising edge of the PWM signal, and the falling edge of the first square wave is the same as the falling edge of the PWM signal.
[0009] The input terminal of the first arithmetic module is connected to the output terminal of the comparison module, and is used to invert the first square wave to form a second square wave;
[0010] The first input terminal of the second arithmetic module is connected to the output terminal of the first arithmetic module. The second input terminal of the second arithmetic module is used to receive the PWM signal. The output terminal of the second arithmetic module is used to perform an AND operation between the second square wave and the PWM signal to output a target signal. The rising edge of the target signal is the same as the rising edge of the PWM signal, and the falling edge of the target signal precedes the falling edge of the PWM signal by a preset distance. The preset distance is the same as the pulse width of the first square wave.
[0011] Preferably, the waveform conversion module includes a first resistor and a first capacitor;
[0012] The first terminal of the first resistor is used to receive the PWM signal;
[0013] The first terminal of the first capacitor is connected to the second terminal of the first resistor and the non-inverting input terminal of the comparison module, respectively.
[0014] The second terminal of the first capacitor is grounded.
[0015] Preferably, the reference voltage module includes: a first diode, a second diode, a second resistor, a third resistor, and a second capacitor;
[0016] The positive terminal of the first diode and the negative terminal of the second diode are respectively connected to the non-inverting input terminal of the comparison module;
[0017] The cathode of the first diode is connected to the first terminal of the second resistor, and the anode of the second diode is connected to the first terminal of the third resistor;
[0018] The second terminal of the second resistor, the second terminal of the third resistor, and the inverting input terminal of the comparison module are all connected to the first terminal of the second capacitor;
[0019] The second terminal of the second capacitor is grounded.
[0020] Preferably, the comparison module is a comparator.
[0021] Preferably, the first arithmetic module is an inverter.
[0022] Preferably, the second operation module is an AND gate.
[0023] Preferably, it further includes: a filter circuit;
[0024] The filtering circuit is connected to the output terminal of the second arithmetic module and is used to filter the target signal and output the filtered target signal.
[0025] To solve the above-mentioned technical problems, this application also provides a device for controlling the forward shift of the falling edge of a square wave, including the circuit described above for controlling the forward shift of the falling edge of a square wave.
[0026] The circuit for controlling the forward shift of the falling edge of a square wave provided in this application includes: a waveform conversion module, a reference voltage module, a comparator module, a first arithmetic module, and a second arithmetic module; the input terminal of the waveform conversion module is used to receive a PWM signal and convert the PWM signal from a square wave to a triangular wave; the input terminal of the reference voltage conversion module is connected to the output terminal of the waveform conversion module and is used to output a reference voltage smaller than the peak value of the triangular wave; the non-inverting input terminal of the comparator module is connected to the output terminal of the waveform conversion module, and the inverting input terminal of the comparator is connected to the output terminal of the reference voltage module, and is used to output a first square wave according to the triangular wave and the reference voltage; wherein, the rising edge of the first square wave is faster than that of the PWM signal. The rising edge of the first square wave is shifted backward, and the falling edge of the first square wave is the same as the falling edge of the PWM signal. The input terminal of the first arithmetic module is connected to the output terminal of the comparator module, which is used to invert the first square wave to form a second square wave. The first input terminal of the second arithmetic module is connected to the output terminal of the first arithmetic module. The second input terminal of the second arithmetic module is used to receive the PWM signal, and the output terminal of the second arithmetic module is used to perform an AND operation between the second square wave and the PWM signal to output a target signal. The rising edge of the target signal is the same as the rising edge of the PWM signal, and the falling edge of the target signal is advanced by a preset distance compared to the falling edge of the PWM signal. The preset distance is the same as the pulse width of the first square wave. It can be seen that the circuit provided in this application realizes the individual forward shift of the falling edge. In addition, the amount of forward shift of the falling edge is the same as the pulse width of the first square wave, and the pulse width of the first square wave is determined based on the triangular wave and the reference voltage. Therefore, the amount of forward shift of the falling edge can be controlled by adjusting the reference voltage to meet specific design requirements.
[0027] In addition, this application also provides a device for controlling the forward shift of the falling edge of a square wave, which has corresponding technical features to the circuit for controlling the forward shift of the falling edge of a square wave mentioned above, and has the same effect. Attached Figure Description
[0028] To more clearly illustrate the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0029] Figure 1 A schematic diagram of a circuit for controlling the forward shift of the falling edge of a square wave, provided in an embodiment of this application;
[0030] Figure 2 A specific circuit diagram for controlling the forward shift of the falling edge of a square wave, provided for an embodiment of this application;
[0031] Figure 3 A waveform conversion diagram of a circuit for controlling the forward shift of the falling edge of a square wave, provided in an embodiment of this application;
[0032] Figure 4 This is a schematic diagram comparing a PWM square wave waveform with the output waveform of an AND gate, provided in an embodiment of this application. Detailed Implementation
[0033] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of this application.
[0034] The core of this application is to provide a circuit and device for controlling the forward shift of the falling edge of a square wave, used to individually shift the falling edge of a square wave forward.
[0035] In driving circuits, control is typically achieved using PWM signals. Current technologies can shift the rising edge of a square wave backward individually, or shift both the rising and falling edges backward together, but cannot shift the falling edge forward independently, significantly reducing the flexibility of circuit design. Therefore, this application provides a circuit that can shift the falling edge forward independently to meet circuit design requirements and improve design flexibility.
[0036] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments. Figure 1 A schematic diagram of a circuit for controlling the forward shift of the falling edge of a square wave, as provided in an embodiment of this application, is shown below. Figure 1 As shown, the circuit includes: waveform conversion module 1, reference voltage module 2, comparison module 3, first arithmetic module 4, and second arithmetic module 5;
[0037] The input terminal of waveform conversion module 1 is used to receive PWM signals and convert the PWM signals from square waves to triangular waves;
[0038] The input terminal of the reference voltage conversion module is connected to the output terminal of the waveform conversion module 1, and is used to output a reference voltage with a peak value smaller than that of the triangular wave.
[0039] The non-inverting input of the comparator module 3 is connected to the output of the waveform conversion module 1, and the inverting input of the comparator is connected to the output of the reference voltage module 2. It is used to output a first square wave according to the triangular wave and the reference voltage. The rising edge of the first square wave is delayed compared to the rising edge of the PWM signal, and the falling edge of the first square wave is the same as the falling edge of the PWM signal.
[0040] The input terminal of the first arithmetic module 4 is connected to the output terminal of the comparison module 3, and is used to invert the first square wave to form a second square wave;
[0041] The first input terminal of the second arithmetic module 5 is connected to the output terminal of the first arithmetic module 4. The second input terminal of the second arithmetic module 5 is used to receive the PWM signal. The output terminal of the second arithmetic module 5 is used to perform an AND operation between the second square wave and the PWM signal to output the target signal. The rising edge of the target signal is the same as the rising edge of the PWM signal, and the falling edge of the target signal is a preset distance earlier than the falling edge of the PWM signal. The preset distance is the same as the pulse width of the first square wave.
[0042] The specific structure of the waveform conversion module, reference voltage module, comparison module, first arithmetic module, and second arithmetic module is not limited, as long as the corresponding functions can be achieved.
[0043] The circuit for controlling the forward shift of the falling edge of a square wave provided in this embodiment includes: a waveform conversion module, a reference voltage module, a comparison module, a first arithmetic module, and a second arithmetic module. The input terminal of the waveform conversion module receives the PWM signal and converts it from a square wave to a triangular wave. The input terminal of the reference voltage conversion module is connected to the output terminal of the waveform conversion module and is used to output a reference voltage smaller than the peak value of the triangular wave. The non-inverting input terminal of the comparison module is connected to the output terminal of the waveform conversion module, and the inverting input terminal of the comparator is connected to the output terminal of the reference voltage module, used to output a first square wave based on the triangular wave and the reference voltage. The rising edge of the first square wave is faster than the PWM signal. The rising edge of the first square wave is shifted backward, and the falling edge of the first square wave is the same as the falling edge of the PWM signal. The input terminal of the first arithmetic module is connected to the output terminal of the comparator module to invert the first square wave to form a second square wave. The first input terminal of the second arithmetic module is connected to the output terminal of the first arithmetic module. The second input terminal of the second arithmetic module is used to receive the PWM signal, and the output terminal of the second arithmetic module is used to perform an AND operation between the second square wave and the PWM signal to output a target signal. The rising edge of the target signal is the same as the rising edge of the PWM signal, and the falling edge of the target signal is advanced by a preset distance compared to the falling edge of the PWM signal. The preset distance is the same as the pulse width of the first square wave. Therefore, the circuit provided in this embodiment achieves the independent forward shift of the falling edge. Furthermore, the forward shift of the falling edge is the same as the pulse width of the first square wave, and the pulse width of the first square wave is determined based on the triangular wave and the reference voltage. Therefore, the forward shift of the falling edge can be controlled by adjusting the reference voltage to meet specific design requirements.
[0044] Figure 2 A specific circuit diagram for controlling the forward shift of the falling edge of a square wave, as provided in the embodiments of this application, is as follows: Figure 2 As shown, the waveform conversion module includes a first resistor R1 and a first capacitor C1;
[0045] The first terminal of the first resistor R1 is used to receive the PWM signal;
[0046] The first terminal of the first capacitor C1 is connected to the second terminal of the first resistor R1 and the non-inverting input terminal of the comparator module, respectively.
[0047] The second terminal of the first capacitor C1 is grounded.
[0048] The reference voltage module includes: a first diode, a second diode D2, a second resistor R2, a third resistor R3, and a second capacitor C2;
[0049] The positive terminal of the first diode D1 and the negative terminal of the second diode D2 are connected to the non-inverting input terminal of the comparator module, respectively.
[0050] The cathode of the first diode D1 is connected to the first terminal of the second resistor R2, and the anode of the second diode D2 is connected to the first terminal of the third resistor R3.
[0051] The second terminal of the second resistor R2, the second terminal of the third resistor R3, and the inverting input terminal of the comparator module are all connected to the first terminal of the second capacitor C2;
[0052] The second terminal of the second capacitor C2 is grounded.
[0053] Among them, the comparison module is comparator U2, the first operation module is inverter U3, and the second operation module is AND gate U4.
[0054] Figure 2The input terminal of the comparator U2 takes the PWM square wave signal to be processed. This signal passes through the first resistor R1 and the first capacitor C1, outputting a pulsating, triangular-wave-like voltage from the upper end of the first capacitor C1, which is connected to the positive input terminal of the comparator U2. This triangular-wave-like voltage from the upper end of the first capacitor C1 passes through the series connection of the first diode D1 and the second resistor R2, the series-parallel connection of the second diode D2 and the third resistor R3, and then through the series connection of the second capacitor C2. The resulting relatively stable voltage, slightly lower than the highest voltage of the first capacitor C1, is then connected to the negative input terminal of the comparator U2. Finally, the output terminal of the comparator U2 outputs a slightly narrower square wave pulse, which is connected to the positive input terminal of the comparator U2. The inverter U3 outputs an inverted waveform, which is then connected to one of the inputs of AND gate U4. The other input of AND gate U4 is connected to the input terminal. After these two signals are ANDed, the voltage waveform at the output pin of AND gate U4 achieves the function of individually shifting the falling edge of the input square wave forward. The output waveform is the voltage waveform with the falling edge of the input square wave shifted forward. The degree of forward shift can be achieved by changing the specific values of the second resistor R2, the third resistor R3, and the second capacitor C2, as well as by selecting different diode voltage drops for the first diode D1 and the second diode D2. The lower the voltage across the second capacitor C2, the greater the degree of forward shift.
[0055] To better understand the process of the falling edge moving forward, Figure 3 A waveform conversion diagram of a circuit for controlling the forward shift of the falling edge of a square wave, as provided in an embodiment of this application, is shown below. Figure 3 As shown in the waveform diagrams, the solid lines represent the waveforms, the horizontal axis represents time, and the vertical axis represents the output voltage of each module. The first waveform is the output voltage of the waveform conversion module; the second waveform is the output voltage of the comparator; the third waveform is the output voltage of the inverter; the fourth waveform is the input voltage; and the fifth waveform is the output voltage of the AND gate. The shaded area in the fifth waveform represents the falling edge shift. Comparing the fourth and fifth waveforms, it can be seen that the falling edge is shifted forward independently. It should be noted that... Figure 2 The reference voltage circuit composed of the first diode D1, the second diode D2, the second resistor R2, the third resistor R3, and the second capacitor C2, regardless of the specific form of the circuit, is considered to be within the scope of protection of this patent as long as the maximum value of the output voltage of the first capacitor C1 is appropriately reduced to obtain a relatively stable voltage that is slightly lower than the highest value of the output voltage of the first capacitor C1. Figure 4 This is a schematic diagram comparing a PWM square wave waveform with the output waveform of an AND gate, provided in an embodiment of this application. Figure 4 The shaded area represents the amount of waveform forward shift.
[0056] The specific circuit for controlling the forward shift of the falling edge of the square wave provided in this embodiment is relatively simple, easy to implement, and low in cost because resistors, capacitors, diodes, comparators, and AND gates are all common circuit components.
[0057] In practice, in order to reduce interference from noise and other factors on the target signal, a preferred implementation is that the circuit controlling the forward shift of the falling edge of the square wave further includes a filter circuit.
[0058] The filtering circuit is connected to the output of the second arithmetic module and is used to filter the target signal and output the filtered target signal.
[0059] The specific structure of the filter circuit is not limited and can be determined based on the actual situation; for example, it can be an LC filter circuit. Through the filter circuit, noise interference with the target signal can be minimized, thereby improving the quality of the target signal.
[0060] The above describes a circuit for controlling the forward shift of the falling edge of a square wave. This embodiment also provides a device for controlling the forward shift of the falling edge of a square wave, including the circuit described above for controlling the forward shift of the falling edge of a square wave.
[0061] The device for controlling the falling edge of a square wave to advance provided in this embodiment has corresponding technical features to the circuit for controlling the falling edge of a square wave to advance described above. The embodiment of the circuit for controlling the falling edge of a square wave to advance has been described in detail above, and the embodiment of the device for controlling the falling edge of a square wave to advance will not be described again here.
[0062] The device for controlling the forward shift of the falling edge of a square wave provided in this embodiment includes: a waveform conversion module, a reference voltage module, a comparison module, a first arithmetic module, and a second arithmetic module; the input terminal of the waveform conversion module is used to receive a PWM signal and convert the PWM signal from a square wave to a triangular wave; the input terminal of the reference voltage conversion module is connected to the output terminal of the waveform conversion module and is used to output a reference voltage smaller than the peak value of the triangular wave; the non-inverting input terminal of the comparison module is connected to the output terminal of the waveform conversion module, and the inverting input terminal of the comparator is connected to the output terminal of the reference voltage module, and is used to output a first square wave according to the triangular wave and the reference voltage; wherein, the rising edge of the first square wave is faster than the PWM signal. The rising edge of the first square wave is shifted backward, and the falling edge of the first square wave is the same as the falling edge of the PWM signal. The input terminal of the first arithmetic module is connected to the output terminal of the comparator module, which is used to invert the first square wave to form a second square wave. The first input terminal of the second arithmetic module is connected to the output terminal of the first arithmetic module. The second input terminal of the second arithmetic module is used to receive the PWM signal, and the output terminal of the second arithmetic module is used to perform an AND operation between the second square wave and the PWM signal to output a target signal. The rising edge of the target signal is the same as the rising edge of the PWM signal, and the falling edge of the target signal is advanced by a preset distance compared to the falling edge of the PWM signal. The preset distance is the same as the pulse width of the first square wave. It can be seen that the device provided in this embodiment realizes the individual forward shift of the falling edge. In addition, the amount of forward shift of the falling edge is the same as the pulse width of the first square wave, and the pulse width of the first square wave is determined based on the triangular wave and the reference voltage. Therefore, the amount of forward shift of the falling edge can be controlled by adjusting the reference voltage to meet specific design requirements.
[0063] The circuit for controlling the forward shift of the falling edge of a square wave, provided in this application, has been described in detail above. The various embodiments in the specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section. It should be noted that those skilled in the art can make several improvements and modifications to this application without departing from the principles of this application, and these improvements and modifications also fall within the protection scope of the claims of this application.
[0064] It should also be noted that, in this specification, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
Claims
1. A circuit for controlling the falling edge of a square wave to advance, characterized in that, include: Waveform conversion module, reference voltage module, comparison module, first arithmetic module, second arithmetic module; The input terminal of the waveform conversion module is used to receive the PWM signal and convert the PWM signal from a square wave to a triangular wave; The input terminal of the reference voltage module is connected to the output terminal of the waveform conversion module, and is used to output a reference voltage that is smaller than the peak value of the triangular wave. The non-inverting input of the comparison module is connected to the output of the waveform conversion module, and the inverting input of the comparison module is connected to the output of the reference voltage module, for outputting a first square wave according to the triangular wave and the reference voltage; wherein, the rising edge of the first square wave is delayed compared to the rising edge of the PWM signal, and the falling edge of the first square wave is the same as the falling edge of the PWM signal. The input terminal of the first arithmetic module is connected to the output terminal of the comparison module, and is used to invert the first square wave to form a second square wave; The first input terminal of the second arithmetic module is connected to the output terminal of the first arithmetic module. The second input terminal of the second arithmetic module is used to receive the PWM signal. The output terminal of the second arithmetic module is used to perform an AND operation between the second square wave and the PWM signal to output a target signal. The rising edge of the target signal is the same as the rising edge of the PWM signal, and the falling edge of the target signal precedes the falling edge of the PWM signal by a preset distance. The preset distance is the same as the pulse width of the first square wave.
2. The circuit for controlling the forward shift of the falling edge of a square wave according to claim 1, characterized in that, The waveform conversion module includes a first resistor and a first capacitor; The first terminal of the first resistor is used to receive the PWM signal; The first terminal of the first capacitor is connected to the second terminal of the first resistor and the non-inverting input terminal of the comparison module, respectively. The second terminal of the first capacitor is grounded.
3. The circuit for controlling the forward shift of the falling edge of a square wave according to claim 1, characterized in that, The reference voltage module includes: a first diode, a second diode, a second resistor, a third resistor, and a second capacitor; The positive terminal of the first diode and the negative terminal of the second diode are respectively connected to the non-inverting input terminal of the comparison module; The cathode of the first diode is connected to the first terminal of the second resistor, and the anode of the second diode is connected to the first terminal of the third resistor; The second terminal of the second resistor, the second terminal of the third resistor, and the inverting input terminal of the comparison module are all connected to the first terminal of the second capacitor; The second terminal of the second capacitor is grounded.
4. The circuit for controlling the forward shift of the falling edge of a square wave according to claim 1, characterized in that, The comparison module is a comparator.
5. The circuit for controlling the falling edge of a square wave to advance according to claim 1, characterized in that, The first arithmetic module is an inverter.
6. The circuit for controlling the forward shift of the falling edge of a square wave according to claim 1, characterized in that, The second operation module is an AND gate.
7. The circuit for controlling the forward shift of the falling edge of a square wave according to any one of claims 1 to 6, characterized in that, Also includes: Filtering circuit; The filtering circuit is connected to the output terminal of the second arithmetic module and is used to filter the target signal and output the filtered target signal.
8. A device for controlling the forward shift of the falling edge of a square wave, characterized in that, The circuit includes the control circuit for advancing the falling edge of the square wave as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Frequency jittering circuit and low-frequency triangle wave generator
CN101562442A
Circuit and device for controlling forward movement of falling edge of PWM signal
CN113162590A