A motor PWM modulation circuit

By setting the slope ratio of the rising section and the falling section in the motor PWM modulation circuit, and re-counting when the motor Hall crosses zero, the problem of drive current waveform distortion caused by the back electromotive force of the brushless DC motor is solved, and the motor is realized Drive stability and noise reduction.

CN118523667BActive Publication Date: 2024-10-01禹创半导体(深圳)有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410965806.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-18
Publication Date
2024-10-01
Estimated Expiration
2044-07-18

AI Technical Summary

Technical Problem

During the operation of the brushless DC motor, the back electromotive force causes the drive current waveform to be distorted, causing noise and abnormal sound. It is difficult to effectively adjust the PWM modulation parameters according to the unevenness of the back electromotive force with the existing technology.

Method used

Design a motor PWM modulation circuit, divide the drive cycle into 32 slope periods through the proportional modulation circuit, set the slope ratio of the rising section and the falling section, and re-count when the motor Hall crosses zero through the period reset circuit. The modulation parameters of each slope period are calculated to reset synchronously, and finally the PWM output duty cycle is calculated by the duty cycle calculation circuit.

Benefits of technology

It realizes the adaptive adjustment of the back electromotive force in different cycle stages, improves the stability of the motor drive and reduces the noise, and ensures the uniform torque output by the motor.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118523667B_ABST
    Figure CN118523667B_ABST
Patent Text Reader

Abstract

This invention discloses a PWM modulation circuit for a motor with a drive cycle of 180 degrees. The circuit includes a proportional modulation circuit, a periodic reset circuit, and a duty cycle calculation circuit. The proportional modulation circuit divides the drive cycle into 32 equal slope periods. The first 16 slope periods and the last 16 slope periods are designated as the rising segment and falling segment, respectively, in chronological order. The ratio of the slope rate of the rising segment to the slope rate of the falling segment is set. The modulation parameters for each slope period are calculated and reset synchronously with the periodic reset circuit. The periodic reset circuit counts when the motor Hall sensor crosses zero and resets every 180 degrees. The duty cycle calculation circuit calculates the PWM output duty cycle for each slope period. This invention, by customizing the ratio of the slope rate of the rising segment to the slope rate of the falling segment, enables the PWM duty cycle to exhibit asymmetry in different cycle stages. This allows for adaptive and effective adjustments to the back electromotive force in different cycle stages, resulting in a more stable and less noisy overall motor drive.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of motor equipment control, and in particular to a motor PWM modulation circuit. Background Art

[0002] Brushless DC motors usually use PWM (Pulse width modulation) to modulate the duty cycle of the drive current to achieve drive control. On the one hand, since the motor back electromotive force is inevitably present when the motor is running, the motor back electromotive force will push the waveform of the drive current downward, causing the waveform of the drive current to be distorted, making it difficult to drive the motor to output uniform torque. This unevenness often manifests itself as noise and abnormal noise when the motor is running, so it is necessary to use PWM corresponding modulation to intensify the drive to offset this phenomenon; on the other hand, current technicians often manually set the PWM modulation parameters as a whole based on the current motor status, but since the back electromotive force is often uneven, which is reflected in the different degrees of depression of the back electromotive force on the rising and falling segments of the drive current waveform, it is difficult for people to make effective adjustments adaptively for different cycle stages. Summary of the invention

[0003] The present invention provides a motor PWM modulation circuit, wherein the driving cycle of the motor is 180 degrees, and the motor PWM modulation circuit comprises: a proportional modulation circuit, a cycle reset circuit and a duty cycle calculation circuit;

[0004] The proportional modulation circuit is used to divide the driving period into 32 slope periods;

[0005] In chronological order, the first 16 slope periods and the last 16 slope periods were recorded as the ascending segment and the descending segment, respectively;

[0006] Set the ratio of the slope of the rising section to the slope of the falling section;

[0007] Calculate the modulation parameters of each slope period and reset them synchronously with the period reset circuit;

[0008] The periodic reset circuit is used to count when the motor Hall passes through zero, and reset and re-count every 180 degrees;

[0009] The duty cycle calculation circuit is used to calculate the PWM output duty cycle of each slope period according to the modulation parameters of each slope period.

[0010] Optionally, in a first implementation of the first aspect of the present invention, the proportional modulation circuit includes: a clock register, a first selection register, a division register, a selection register unit and a reset register;

[0011] The clock register is used to automatically update the ramp period sequence number;

[0012] The first selection register is used to set the ratio of the rising segment to the falling segment;

[0013] The division register is used to divide the driving cycle into 32 equal parts;

[0014] The selection register unit is used to select the first calculation formula and the second calculation formula in the ascending section and the descending section respectively according to the current slope period number; the first calculation formula is the current slope period number plus one; the first calculation formula is 32 minus the current slope period number;

[0015] The reset register is used to reset the proportional modulation circuit and the periodic reset circuit synchronously.

[0016] Optionally, in a second implementation of the first aspect of the present invention, the proportional modulation circuit further includes: a first adder, a first multiplier, a first comparator, a second multiplier and a first subtractor;

[0017] The first adder is used to add one to the ramp period sequence number after each ramp period ends;

[0018] The first comparator is used to determine whether the current slope period is in the rising stage or the falling stage;

[0019] The first subtractor is used to make a difference between the slope period sequence number and the period reset circuit;

[0020] The clock register is connected to an input terminal of the first multiplier via the first adder;

[0021] The first selection register is connected to another input terminal of the first multiplier;

[0022] The output end of the first multiplier is connected to an input end of the second multiplier via the division register and the first comparator;

[0023] The selection register unit is connected to another input terminal of the second multiplier;

[0024] The selection register unit is also connected to the duty cycle calculation circuit;

[0025] An output terminal of the second multiplier is connected to the reset register, and the period reset circuit is connected to the reset register via the first subtractor.

[0026] Optionally, in a third implementation of the first aspect of the present invention, the selection register unit includes: a second selection register, a second comparator, a second adder, a second subtractor and a third selection register;

[0027] The second selection register is used to output the current slope period;

[0028] The second comparator is used to determine whether the current slope period is in the rising stage or the falling stage.

[0029] If the current slope period is in the rising stage, the third selection register selects the second adder to perform calculation according to the first calculation formula;

[0030] If the current slope period is in the descending stage, the third selection register selects the second subtractor to perform calculation according to the second calculation formula;

[0031] The second selection register is connected to the input end of the third selection register via the second comparator, the second adder and the second subtractor;

[0032] An output terminal of the third selection register is connected to the other input terminal of the second multiplier and the duty cycle calculation circuit.

[0033] Optionally, in a fourth implementation of the first aspect of the present invention, the period reset circuit includes: a pulse counter, a third comparator and a third adder;

[0034] The pulse counter is used to count the 180-degree drive cycle and reset when the motor Hall passes through zero;

[0035] The third comparator is used to compare whether the current value of the reset register is equal to the current count of the pulse counter. If they are equal, the current slope period number is increased by one through the third adder. If they are not equal, the current slope period number is reset to zero.

[0036] Optionally, in a fifth implementation of the first aspect of the present invention, the duty cycle calculation circuit includes: a third multiplier, a maximum duty cycle register, and a modulation duty cycle register;

[0037] The maximum duty cycle register is used to output the maximum PWM output duty cycle;

[0038] The selection register unit is connected to an input terminal of the third multiplier;

[0039] The maximum duty cycle register is connected to another input terminal of the third multiplier;

[0040] An output terminal of the third multiplier is connected to the modulation duty cycle register.

[0041] The technical solution provided by the present invention has the beneficial effect: a motor PWM modulation circuit provided by the present invention can customize the ratio of the slope of the rising segment to the slope of the falling segment, so that the PWM duty cycle has asymmetry in different cycle stages, and can adaptively make effective adjustments to the back electromotive force in different cycle stages, so that the overall drive of the motor is more stable and low-noise. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] Figure 1 A schematic diagram of the structure of an embodiment of a motor PWM modulation circuit in an embodiment of the present invention;

[0043] Figure 2 A schematic structural diagram of an embodiment of a selection register unit of a motor PWM modulation circuit in an embodiment of the present invention;

[0044] Figure 3 The structure schematic diagram of an embodiment of the periodic reset circuit of the motor PWM modulation circuit in the embodiment of the present invention is shown;

[0045] Figure 4 It is a structural schematic diagram of an embodiment of a duty cycle calculation circuit of a motor PWM modulation circuit in an embodiment of the present invention;

[0046] Figure 5 A circuit diagram of an embodiment of a proportional modulation circuit of a motor PWM modulation circuit in an embodiment of the present invention;

[0047] Figure 6 A schematic diagram of an embodiment of a period reset circuit of a motor PWM modulation circuit in an embodiment of the present invention;

[0048] Figure 7 The figure is a circuit diagram of an embodiment of a duty cycle calculation circuit of a motor PWM modulation circuit in an embodiment of the present invention.

[0049] Figure 8 Schematic diagram of waveform effect of duty cycle of motor PWM modulation circuit with respect to 180-degree driving cycle in an embodiment of the present invention.

[0050] In the figure, 100 is a clock register, 102 is a first selection register, 103 is a partition register, 104 is a selection register unit, and 105 is a reset register;

[0051] 106 - a first adder, 107 - a first multiplier, 108 - a first comparator, 109 - a second multiplier, 110 - a first subtractor;

[0052] 111 - a second selection register, 112 - a second comparator, 113 - a second adder, 114 - a second subtractor, 115 - a third selection register;

[0053] 116 - a pulse counter, 117 - a third comparator, 118 - a third adder;

[0054] 119 - a third multiplier, 120 - a maximum duty cycle register, 121 - a modulation duty cycle register. DETAILED DESCRIPTION

[0055] An embodiment of the present invention provides a motor PWM modulation circuit. The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" or "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0056] For ease of understanding, the specific process of the embodiment of the present invention is described below. Figures 1 to 4 , an embodiment of the motor PWM modulation circuit in the embodiment of the present invention, wherein the driving cycle of the motor is 180 degrees, comprises:

[0057] Proportional modulation circuit, period reset circuit and duty cycle calculation circuit;

[0058] The proportional modulation circuit is used to divide the driving period into 32 slope periods;

[0059] In chronological order, the first 16 slope periods and the last 16 slope periods were recorded as the ascending segment and the descending segment, respectively;

[0060] Set the ratio of the slope of the rising section to the slope of the falling section;

[0061] Calculate the modulation parameters of each slope period and reset them synchronously with the period reset circuit;

[0062] The periodic reset circuit is used to count when the motor Hall passes through zero, and reset and re-count every 180 degrees;

[0063] The duty cycle calculation circuit is used to calculate the PWM output duty cycle of each slope period according to the modulation parameters of each slope period.

[0064] Specifically, the proportional modulation circuit includes: a clock register, a first selection register, a division register, a selection register unit and a reset register;

[0065] The clock register is used to automatically update the ramp period sequence number;

[0066] The first selection register is used to set the ratio of the rising segment to the falling segment;

[0067] The division register is used to divide the driving cycle into 32 equal parts;

[0068] The selection register unit is used to select the first calculation formula and the second calculation formula in the ascending section and the descending section respectively according to the current slope period number; the first calculation formula is the current slope period number plus one; the first calculation formula is 32 minus the current slope period number;

[0069] The reset register is used to reset the proportional modulation circuit and the periodic reset circuit synchronously.

[0070] Specifically, the proportional modulation circuit further includes: a first adder, a first multiplier, a first comparator, a second multiplier and a first subtractor;

[0071] The first adder is used to add one to the ramp period sequence number after each ramp period ends;

[0072] The first comparator is used to determine whether the current slope period is in the rising stage or the falling stage;

[0073] The first subtractor is used to make a difference between the slope period sequence number and the period reset circuit;

[0074] The clock register is connected to an input terminal of the first multiplier via the first adder;

[0075] The first selection register is connected to another input terminal of the first multiplier;

[0076] The output end of the first multiplier is connected to an input end of the second multiplier via the division register and the first comparator;

[0077] The selection register unit is connected to another input terminal of the second multiplier;

[0078] The selection register unit is also connected to the duty cycle calculation circuit;

[0079] An output terminal of the second multiplier is connected to the reset register, and the period reset circuit is connected to the reset register via the first subtractor.

[0080] Specifically, the selection register unit includes: a second selection register, a second comparator, a second adder, a second subtractor and a third selection register;

[0081] The second selection register is used to output the current slope period;

[0082] The second comparator is used to determine whether the current slope period is in the rising stage or the falling stage.

[0083] If the current slope period is in the rising stage, the third selection register selects the second adder to perform calculation according to the first calculation formula;

[0084] If the current slope period is in the descending stage, the third selection register selects the second subtractor to perform calculation according to the second calculation formula;

[0085] The second selection register is connected to the input end of the third selection register via the second comparator, the second adder and the second subtractor;

[0086] An output terminal of the third selection register is connected to the other input terminal of the second multiplier and the duty cycle calculation circuit.

[0087] Specifically, the periodic reset circuit includes: a pulse counter, a third comparator and a third adder;

[0088] The pulse counter is used to count the 180-degree drive cycle and reset when the motor Hall passes through zero;

[0089] The third comparator is used to compare whether the current value of the reset register is equal to the current count of the pulse counter. If they are equal, the current slope period number is increased by one through the third adder. If they are not equal, the current slope period number is reset to zero.

[0090] Specifically, the duty cycle calculation circuit includes: a third multiplier, a maximum duty cycle register and a modulation duty cycle register;

[0091] The maximum duty cycle register is used to output the maximum PWM output duty cycle;

[0092] The selection register unit is connected to an input terminal of the third multiplier;

[0093] The maximum duty cycle register is connected to another input terminal of the third multiplier;

[0094] An output terminal of the third multiplier is connected to the modulation duty cycle register.

[0095] See also Figure 5 , Figure 5 A schematic diagram of an embodiment of a proportional modulation circuit of a motor PWM modulation circuit in an embodiment of the present invention;

[0096] Specifically, SSW is a clock register 100 composed of a D-type flip-flop (DFF), which is used to input the current ramp period number, SSW[4:0], [4:0] means: the bit width of the SSW bus. [4:0] represents a 5-bit bus, 4 represents the most significant bit, and 0 represents the least significant bit. SSW[4:0] can obtain values ​​ranging from 0 (5 bits 0) to 31 (5 bits 1).

[0097] SSWFSEL is a first selection register 102 composed of a D-type flip-flop (DFF), which is used to set the ratio of the slope of the rising segment to the slope of the falling segment. When SSWFSEL is 0, the slope of the rising segment is equal to the slope of the falling segment. When SSWFSEL is 1, the slope of the falling segment is equivalent to the slope of the rising segment divided by 1.25. When SSWFSEL is 2, the slope of the falling segment is equivalent to the slope of the rising segment divided by 1.5. When SSWFSEL is 3, the slope of the falling segment is equivalent to the slope of the rising segment divided by 2. By increasing the SSWCNT update time by 1.25 times, 1.5 times, and 2 times, the slope of the falling segment corresponds to the slope of the rising segment divided by 1.25, 1.5, and 2. SSWFSEL[1:0] is the bit width of the SSWFSEL bus, [1:0] indicates a 2-bit bus, 1 indicates the most significant bit, and 0 indicates the least significant bit. SSWFSEL[1:0] can take values ​​ranging from 0 (2 bits 0) to 3 (2 bits 1).

[0098] The MUX in the first selection register 102 represents a multiplexer that selects one from four inputs. The function is: when the signal input from the left is 3, the output input "8" is output. When the signal input from the left is 2, the output input "6" is output. When the signal input from the left is 1, the output input "5" is output. When the signal input from the left is 0, the output input "4" is output.

[0099] SSWCNT is the second selection register 111 composed of the DFF soft switch counter. It is a counter that is cleared every 180 degrees (according to the edge of the Hall sensor signal). When PCNT=UDTMG is satisfied, 1 is added. The value of this counter divides 180 degrees into 33 parts to show the current position of the IC. SSWCNT[5:0], [5:0] is the bit width of the SSWCNT bus, [5:0] represents a 6-bit bus, 5 represents the most significant bit, and 0 represents the least significant bit. SSWCNT[5:0] can obtain values ​​ranging from 0 (6-bit 0) to 32 (5-bit clock register 10000). ;

[0100] SSWCNT<16 is a comparator (second comparator 112 / first comparator 108). If the value of SSWCNT is less than 16, it outputs 1, and if SSWCNT is 16 or more, it outputs 0. When (SSWCNT<16) is true, it indicates that the current process is the slope period of the rising segment, and when (SSWCNT<16) is false, it indicates that the current process is the slope period of the falling segment.

[0101] The third selection register 115 represents a multiplexer that can select one of the two inputs. Its function is: when the signal input from the left (or right) side is 1, the input at the upper left corner is output. When the signal input from the left (or right) side is 0, the input at the upper right corner is output;

[0102] PCNTLT is the locked value of the previous 180-degree cycle counter composed of DFF. This is the value obtained by counting 180 degrees with a 2MHz (500ns) pulse, generating a trapezoid with a period of 180 degrees to accommodate this count value; PCNTLT[17:0], [17:0] is the bit width of the PCNTLT bus, [17:0] represents an 18-bit bus, 17 represents the highest bit, and 0 represents the last bit. PCNTLT[17:0] can take values ​​ranging from 0 (18-bit 0) to 262,143 (18-bit 1).

[0103] “>>10” means shifting right by 10 bits, which is equivalent to dividing the input by the first selection register 102 .

[0104] UDTMG is a reset register 105 composed of DFF, which is used to calculate when to increase SSWCNT from PCNTLT. UDTMG is a register that stores the result of this calculation. This value only contains the integer part of the result of the calculation; UDTMG[17:0], [17:0] is the bit width of the UDTMG bus, [17:0] represents an 18-bit bus, 17 represents the highest bit, and 0 represents the last bit. UDTMG[17:0] can take values ​​in the range of 0 (18-bit 0) to 262,143 (18-bit 1).

[0105] See also Figure 5 , Figure 5 A schematic diagram of an embodiment of a proportional modulation circuit of a motor PWM modulation circuit in an embodiment of the present invention;

[0106] This embodiment takes SSWFSEL=3 as an example to illustrate the calculation process step by step:

[0107] from Figure 5 Starting from the upper left of the circuit,

[0108] The clock register 100 inputs the current slope period number (SSW), which is added by one by the first adder 106 (SSW+1);

[0109] The first selection register 102 selects SSWFSEL=3 and outputs 8; the first multiplier 107 calculates (SSW+1)×8=input;

[0110] Determine whether "input>128" is true, if true, output 1, if false, output 0;

[0111] ">>2" shifts right by 2 bits, i.e. divides by 4, and calculates (SSW+1)×8 / 4;

[0112] The division register 103 is a multiplexer for limiting (SSW+1)×8 / 4 to 32;

[0113] "MUX" determines whether SSWCNT<16 is true. If true, it outputs SSW+1. If false, it outputs (SSW+1)×8 / 4 and is limited to 32.

[0114] from Figure 5 In the upper right corner of the circuit,

[0115] In the selection register unit 104, the SSWCNT of the second selection register 111 outputs the current slope period, and the second comparator 112 determines whether "SSWCNT<16" is true. If true, it outputs 1 to the third selection register 115, and if weakly false, it outputs 0 to the third selection register 115;

[0116] The third selection register 115 selects the second adder 113 to calculate SSWCNT+1 according to receiving 1; and selects the second subtractor 114 to calculate 31-SSWCNT according to receiving 0, and outputs it to the second multiplier 109;

[0117] The second multiplier 109 first calculates (SSW+1)×(SSWCNT+1) if “SSWCNT<16” is true; and calculates (SSW+1)×(31-SSWCNT) if “SSWCNT<16” is false;

[0118] Then, when "SSWCNT<16" is true, the operation is (SSW+1) × (SSWCNT+1) × PCNTLT; when "SSWCNT<16" is false, the operation is (SSW+1) × (31-SSWCNT) × PCNTLT;

[0119] It can be understood that PCNTLT is equivalent to the initial slope multiplied by the adjustment coefficient.

[0120] Since the second Hall edge varies according to load fluctuations, it may not always be at the expected time (180°), so the length of the ramp period when falling can be calculated by subtracting it from the end of the cycle by the first subtractor 110 .

[0121] See also Figure 6 , Figure 6 A schematic diagram of an embodiment of a period reset circuit of a motor PWM modulation circuit in an embodiment of the present invention;

[0122] PCNT[17:0] is the bit width of the PCNT bus. [17:0] indicates an 18-bit bus, 17 indicates the most significant bit, and 0 indicates the last bit. PCNT[17:0] can take values ​​in the range of 0 (18-bit 0) to 262,143 (18-bit 1).

[0123] The third comparator 117 "==" is a comparator, which outputs a high pulse 1 when the two inputs are equal, and outputs a 0 when they are not equal.

[0124] The pulse counter 116 is a counter that increases the 2MHz (500ns) pulse. The counter consists of DFF and PCNT, which counts 180 degrees of electrical cycle. PCNTLT holds this count value at the edge signal of the 180-degree Hall cycle, and PCNT is cleared and reset at the edge of the Hall signal. Figure 6 In the process, the PCNT of the pulse counter 116 is compared with the UDTMG of the reset register 105 through the third comparator 117. If these values ​​are equal, the SSWCNT is increased by 1 through the third adder 118 and the next UDTMG calculation is started. The SSWCNT is also cleared and reset at the edge of the 180-degree Hall cycle signal.

[0125] See also Figure 7 , Figure 7 A schematic diagram of an embodiment of a duty cycle calculation circuit of a motor PWM modulation circuit in an embodiment of the present invention;

[0126] PWMDUTYMAX is the maximum duty cycle register 120. This register is the maximum PWM output duty cycle. The maximum duty cycle register 120 is composed of DFF. For example, assuming the maximum power is 500, it means that the output duty cycle is 100% of the clock register. If PWMDUTYMAX is 0, it means that the output duty cycle is 0%. This percentage value is preset by the system through register settings or PWM inputs.

[0127] PWMDUTYMAX[8:0] is the bit width of the PWMDUTYMAX bus. [8:0] represents a 9-bit bus, 8 represents the highest bit, and 0 represents the lowest bit. PWMDUTYMAX[8:0] can range from 0 (9-bit 0) to 511 (9-bit 1).

[0128] The PWM DUTY of the modulation duty cycle register 121 is the final trapezoidal PWM output duty cycle (such as Figure 8 It is calculated by multiplying PWMDUTYMAX (maximum duty cycle register 120) by the value corresponding to each SSWCNT (select register unit 104) through the third multiplier 119.

[0129] PWM DUTY[8:0] is the bit width of the PWM DUTY bus. [8:0] indicates a 9-bit bus, 8 indicates the highest bit, and 0 indicates the last bit. PWMDUTY[8:0] can take values ​​in the range of 0 (9-bit 0) to 511 (9-bit 1).

[0130] ">>4" means right shift by 4 bits. That is, divide by 16;

[0131] The value corresponding to each SSWCNT output by the selection register unit 104 is: if (SSWCNT<16) is true, then (SSWCNT+1) is output, and if it is false, then (31- SSWCNT) is output, corresponding to the following table:

[0132]

[0133] The ratio of the ramp slope of the ascending segment to the ramp slope of the descending segment in the above table is 1. The unit ramp time of different stages can be adjusted according to the preset ratio of the ramp slope of the ascending segment to the ramp slope of the descending segment divided by the corresponding coefficient to achieve the asymmetry of the slope (such as Figure 8 as shown).

[0134] In the embodiment of the present invention, the beneficial effect is: by custom adjusting the ratio of the slope of the rising segment to the slope of the falling segment, the PWM duty cycle is made asymmetric in different cycle stages, and effective adjustments can be made adaptively for the back electromotive force in different cycle stages, making the overall drive of the motor more stable and low-noise.

[0135] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A motor PWM modulation circuit, wherein the driving cycle of the motor is 180 degrees, characterized in that: The motor PWM modulation circuit includes: a proportional modulation circuit, a cycle reset circuit and a duty cycle calculation circuit; the proportional modulation circuit includes: a clock register, a first selection register, a division register, a selection register unit and a reset register; the clock register is used to automatically update the slope period sequence number; the first selection register is used to set the ratio of the rising section and the falling section; the division register is used to divide the drive cycle into 32 equal parts; the selection register unit is used to select the first calculation formula and the second calculation formula in the rising section and the falling section respectively according to the current slope period number, wherein the first calculation formula refers to the current slope period number plus one, that is, SSWCNT+1, which is used for the slope period calculation of the rising section, and the duty cycle is linearly increased by adding 1 each time; the second calculation formula is 32 minus the current slope period number; the reset register is used to synchronize the proportional modulation circuit with the cycle reset circuit reset; the proportional modulation circuit also includes: the first An adder, a first multiplier, a first comparator, a second multiplier and a first subtractor; the first adder is used to add one to the slope period number after each slope period ends; the first comparator is used to determine whether the current slope period is in the rising section or the falling section; the first subtractor is used to make a difference between the slope period number and the period reset circuit; the clock register is connected to an input end of the first multiplier via the first adder; the first selection register is connected to the other input end of the first multiplier; the output end of the first multiplier is connected to an input end of the second multiplier via the division register and the first comparator; the selection register unit is connected to the other input end of the second multiplier; the selection register unit is also connected to the duty cycle calculation circuit; the output end of the second multiplier is connected to the reset register, and the period reset circuit is connected to the reset register via the first subtractor; The proportional modulation circuit is used to divide the driving period into 32 slope periods; In chronological order, the first 16 slope periods and the last 16 slope periods were recorded as the ascending segment and the descending segment, respectively; Set the ratio of the slope of the rising section to the slope of the falling section; Calculate the modulation parameters of each slope period and reset them synchronously with the period reset circuit; The periodic reset circuit is used to count when the motor Hall passes through zero, and reset and re-count every 180 degrees; The duty cycle calculation circuit is used to calculate the PWM output duty cycle of each slope period according to the modulation parameters of each slope period.

2. The motor PWM modulation circuit according to claim 1, characterized in that: The selection register unit includes: a second selection register, a second comparator, a second adder, a second subtractor and a third selection register; The second selection register is used to output the current slope period; The second comparator is used to determine whether the current slope period is in the rising stage or the falling stage. If the current slope period is in the rising stage, the third selection register selects the second adder to perform calculation according to the first calculation formula; If the current slope period is in the descending stage, the third selection register selects the second subtractor to perform calculation according to the second calculation formula; The second selection register is connected to the input end of the third selection register via the second comparator, the second adder and the second subtractor; An output terminal of the third selection register is connected to the other input terminal of the second multiplier and the duty cycle calculation circuit.

3. The motor PWM modulation circuit according to claim 2, characterized in that: The periodic reset circuit comprises: a pulse counter, a third comparator and a third adder; The pulse counter is used to count the 180-degree drive cycle and reset when the motor Hall passes through zero; The third comparator is used to compare whether the current value of the reset register is equal to the current count of the pulse counter. If they are equal, the current slope period number is increased by one through the third adder. If they are not equal, the current slope period number is reset to zero.

4. The motor PWM modulation circuit according to claim 3, characterized in that: The duty cycle calculation circuit includes: a third multiplier, a maximum duty cycle register and a modulation duty cycle register; The maximum duty cycle register is used to output the maximum PWM output duty cycle; The selection register unit is connected to an input terminal of the third multiplier; The maximum duty cycle register is connected to another input terminal of the third multiplier; An output terminal of the third multiplier is connected to the modulation duty cycle register.