CN117459034A - PWM modulation method and PWM modulation apparatus - Google Patents
PWM modulation method and PWM modulation apparatus Download PDFInfo
- Publication number
- CN117459034A CN117459034A CN202311173080.6A CN202311173080A CN117459034A CN 117459034 A CN117459034 A CN 117459034A CN 202311173080 A CN202311173080 A CN 202311173080A CN 117459034 A CN117459034 A CN 117459034A
- Authority
- CN
- China
- Prior art keywords
- count value
- current
- preset
- target
- value
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 71
- 230000001960 triggered effect Effects 0.000 claims abstract description 17
- 230000000630 rising effect Effects 0.000 claims description 39
- 230000015654 memory Effects 0.000 claims description 17
- 230000003247 decreasing effect Effects 0.000 claims description 16
- 230000002085 persistent effect Effects 0.000 claims description 3
- 238000012545 processing Methods 0.000 claims description 3
- 230000006403 short-term memory Effects 0.000 claims description 2
- 230000005856 abnormality Effects 0.000 abstract description 15
- 230000002159 abnormal effect Effects 0.000 description 13
- 230000008859 change Effects 0.000 description 11
- 238000010586 diagram Methods 0.000 description 11
- 230000000737 periodic effect Effects 0.000 description 4
- 238000006243 chemical reaction Methods 0.000 description 3
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 230000008569 process Effects 0.000 description 3
- 230000008901 benefit Effects 0.000 description 2
- 238000004891 communication Methods 0.000 description 2
- 238000004590 computer program Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 238000002474 experimental method Methods 0.000 description 2
- 230000002035 prolonged effect Effects 0.000 description 2
- 238000012360 testing method Methods 0.000 description 2
- 230000007704 transition Effects 0.000 description 2
- HEZMWWAKWCSUCB-PHDIDXHHSA-N (3R,4R)-3,4-dihydroxycyclohexa-1,5-diene-1-carboxylic acid Chemical compound O[C@@H]1C=CC(C(O)=O)=C[C@H]1O HEZMWWAKWCSUCB-PHDIDXHHSA-N 0.000 description 1
- 230000001934 delay Effects 0.000 description 1
- 230000003111 delayed effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 230000035772 mutation Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000002441 reversible effect Effects 0.000 description 1
- 230000001052 transient effect Effects 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H03—ELECTRONIC CIRCUITRY
- H03K—PULSE TECHNIQUE
- H03K7/00—Modulating pulses with a continuously-variable modulating signal
- H03K7/08—Duration or width modulation ; Duty cycle modulation
Landscapes
- Inverter Devices (AREA)
Abstract
The embodiment of the application discloses a PWM modulation method and PWM modulation equipment, which are used for PWM modulation under the condition of reducing the possibility of abnormality of PWM modulated signals. The method comprises the following steps: if the condition that the target parameter is assigned to the target parameter value is triggered, determining whether the current count value is in a preset non-assignable area corresponding to the current mode, wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode, if the current count value is in the preset non-assignable area, taking the count value obtained by extending the preset count time period of the current count value as a target assignment point, wherein the target assignment point is outside the preset non-assignable area, assigning the target parameter to the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and generating a new PWM signal based on the target parameter value of the target parameter.
Description
Technical Field
The embodiment of the application relates to the field of PWM (pulse width modulation), in particular to a PWM modulation method and PWM modulation equipment.
Background
With the development of PWM modulation techniques, there is a need in many fields to use PWM modulation devices for fast frequency-changing or duty-cycle operation. For example, the PWM modulation apparatus may control the operation of turning on and off the circuit switching device by adjusting the frequency and the duty ratio.
In the existing PWM modulation method, if a condition of assigning a target parameter to a target parameter value is triggered, assignment may be performed at a fixed certain time point other than a preset loading point to assign a target parameter of a register to a target parameter value, then the target parameter value of the target parameter is obtained from the register at the preset loading point, and a new PWM signal is generated based on the target parameter value of the target parameter.
However, this method only implements the assignment operation, and does not consider that there may be an unreasonable situation at the time point of the assignment, so that the probability of missing the zero crossing point of the carrier in the current period is high, and the probability of generating an abnormal waveform in the PWM modulated signal is high.
Disclosure of Invention
The embodiment of the application provides a PWM modulation method and PWM modulation equipment, which are used for PWM modulation under the condition of reducing the possibility of abnormality of PWM modulated signals.
In a first aspect, an embodiment of the present application provides a PWM modulation method, including:
if the condition of assigning the target parameter to the target parameter value is triggered, determining whether the current count value is in a preset non-assignable area corresponding to the current mode; wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode;
If the current count value is in the preset non-assignable area, the count value obtained by extending the current count value by a preset count time is used as a target assignment point; wherein the target assignment point is outside the preset non-assignable region;
and assigning the target parameter to the target parameter value at the target assignment point so as to obtain the target parameter value of the target parameter at the preset loading point, and generating a new PWM signal based on the target parameter value of the target parameter.
Optionally, before the counting value obtained by extending the current counting value by a preset counting time is used as the target assignment point, the method further includes:
predicting a first counting time length required for executing the step of determining whether the current counting value is in a preset non-assignable area corresponding to the current mode;
predicting a second count duration to be consumed for executing the step of assigning the target parameter to the target parameter value at the target assignment point;
and determining the preset counting time length based on the first counting time length and the second counting time length.
Optionally, before the determining the preset count duration based on the first count duration and the second count duration, the method further includes:
Determining an adjustment count duration;
the determining the preset count duration based on the first count duration and the second count duration includes:
and determining the preset counting time based on the first counting time, the second counting time and the adjustment counting time.
Optionally, the preset non-assignable area is a count value within a preset count duration range of the preset loading point; the current mode comprises a current loading mode and a current carrier mode; and the current carrier mode is an increasing/decreasing mode; the preset loading point is a zero crossing point of a carrier wave;
before determining whether the current count value is in the preset non-assignable area corresponding to the current mode, the method further comprises:
if the current loading mode is a shadow mode, regarding a count value range from a target count value of the falling edge to the zero crossing point as the preset non-assignable area aiming at each falling edge of the carrier wave; wherein, the shadow mode representation is loaded at the preset loading point; and the difference value of the count value between the target count value corresponding to the falling edge and the zero crossing point is the preset count duration.
Optionally, if the current count value is in the preset non-assignable area, the method includes:
and if the current count value is the count value of the falling edge of the carrier wave and the current count value is contained in the count value range corresponding to the preset non-assignable area, determining that the current count value is in the preset non-assignable area corresponding to the current mode.
Optionally, the preset non-assignable area is a count value within a preset count duration range of the preset loading point; the current mode comprises a current loading mode and a current carrier mode; and the current carrier mode is an increasing/decreasing mode;
before determining whether the current count value is in the preset non-assignable area corresponding to the current mode, the method further comprises:
if the current loading mode is an immediate mode, determining that a preset loading point corresponding to the current mode is a target loading point corresponding to the immediate mode; the immediate mode representation takes the current assignment point as the target loading point, and loads immediately at the target loading point; the current assignment point is any count value;
regarding the rising edge of a carrier wave, taking the range of a count value from a first count value of the rising edge to the target loading point as a preset non-assignable area of the rising edge; the difference value of the count value between the first count value corresponding to the rising edge and the target loading point is the preset count duration;
Regarding the falling edge of the carrier wave, taking the range from the second count value of the falling edge to the count value between the target loading point as a preset non-assignable area of the falling edge; and the difference value of the count value between the second count value corresponding to the falling edge and the target loading point is the preset count duration.
Optionally, if the current count value is in the preset non-assignable area, at least one of the following cases is included:
if the current count value is the count value of the rising edge of the carrier wave and the current count value is contained in the count value range corresponding to the preset non-assignable area of the rising edge, determining that the current count value is in the preset non-assignable area;
and if the current count value is the count value of the falling edge of the carrier and the current count value is contained in the count value range corresponding to the preset non-assignable region of the falling edge, determining that the current count value is in the preset non-assignable region.
Optionally, after determining whether the current count value is in the preset non-assignable area corresponding to the current mode, before the target assignment point assigns the target parameter to the target parameter value, the method further includes:
And if the current count value is not in the preset non-assignable area, taking the current count value as the target assignment point.
In a second aspect, embodiments of the present application provide a PWM modulation apparatus, including:
the determining unit is used for determining whether the current count value is in a preset non-assignable area corresponding to the current mode if the condition of assigning the target parameter to the target parameter value is triggered; wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode;
the determining unit is further configured to, if the current count value is in the preset non-assignable area, set a count value obtained by extending the preset count time period from the current count value as a target assignment point; wherein the target assignment point is outside the preset non-assignable region;
and the assignment unit is used for assigning the target parameter to the target parameter value at the target assignment point so as to obtain the target parameter value of the target parameter at the preset loading point and generating a new PWM signal based on the target parameter value of the target parameter.
In a third aspect, embodiments of the present application provide a PWM modulation apparatus, including:
The CPU, the memory, the input/output interface and the power supply;
the memory is a short-term memory or a persistent memory;
the central processor is configured to communicate with the memory and execute the instruction operations in the memory to perform the aforementioned PWM modulation method.
In a fourth aspect, embodiments of the present application provide a computer program product comprising instructions which, when run on a computer, cause the computer to perform the aforementioned PWM modulation method.
From the above technical solutions, the embodiments of the present application have the following advantages: if the condition that the target parameter is assigned to the target parameter value is triggered, determining whether the current count value is in a preset non-assignable area corresponding to the current mode, wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode, if the current count value is in the preset non-assignable area, taking the count value obtained by extending the preset count time period of the current count value as a target assignment point, wherein the target assignment point is outside the preset non-assignable area, assigning the target parameter to the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and generating a new PWM signal based on the target parameter value of the target parameter. By judging whether the PWM modulation signal is in the preset non-assignable area or not to determine a more reasonable assignment point to bypass the loading point, the probability of missing the carrier zero crossing point of the current period is smaller, and the probability of abnormality of the PWM modulation signal is lower.
Drawings
Fig. 1 is a schematic flow chart of a PWM modulation method disclosed in an embodiment of the present application;
fig. 2 is a schematic diagram of a preset non-assignable area corresponding to a current carrier mode being an increasing or decreasing mode and a current loading mode being a shadow mode according to an embodiment of the present application;
fig. 3 is a schematic diagram of a preset non-assignable region corresponding to a current carrier mode being an increasing or decreasing mode and a current loading mode being an immediate mode according to an embodiment of the present application;
FIG. 4 is a schematic diagram of various waveforms for configuring a corresponding comparison value to be changed prior to a period value according to an embodiment of the present disclosure;
FIG. 5 is a schematic diagram of an abnormal situation of a comparison value when assigning a loading point according to an embodiment of the present application;
fig. 6 is a schematic structural diagram of a PWM modulation apparatus according to an embodiment of the present disclosure;
fig. 7 is a schematic structural diagram of another PWM modulation apparatus disclosed in an embodiment of the present application;
fig. 8 is a schematic structural diagram of still another PWM modulation apparatus according to an embodiment of the present application.
Detailed Description
The embodiment of the application provides a PWM modulation method and PWM modulation equipment, which are used for PWM modulation under the condition of reducing the possibility of abnormality of PWM modulated signals.
Referring to fig. 1, fig. 1 is a flowchart of a PWM modulation method disclosed in an embodiment of the present application, where the method includes:
101. if the condition of assigning the target parameter to the target parameter value is triggered, determining whether the current count value is in a preset non-assignable area corresponding to the current mode; the preset non-assignable area is a count value near a preset loading point corresponding to the current mode.
In this embodiment, when PWM modulation is performed, if a condition for assigning a target parameter to a target parameter value is triggered, it is determined whether the current count value is in a preset non-assignable area corresponding to the current mode; the preset non-assignable area is a count value near a preset loading point corresponding to the current mode.
102. If the current count value is in the preset non-assignable area, the count value obtained by extending the current count value by a preset count time is used as a target assignment point; wherein the target assignment point is outside the preset non-assignable region.
After determining whether the current count value is in the preset non-assignable area corresponding to the current mode, if the current count value is in the preset non-assignable area, the count value obtained by extending the preset count time length of the current count value is taken as a target assignment point; wherein the target assignment point is outside the preset non-assignable region.
The preset counting time length can be determined before the counting value obtained by extending the current counting value by the preset counting time length is used as the target assignment point. The method for determining the preset counting time length may be that first a first counting time length required for executing the step of determining whether the current counting value is in the preset non-assignable area corresponding to the current mode is predicted, then a second counting time length required for executing the step of assigning the target parameter to the target parameter value at the target assignment point is predicted, and finally the preset counting time length is determined based on the first counting time length and the second counting time length. It will be appreciated that other methods of determining the preset count duration may be reasonable in addition to those described above, and are not limited in this regard.
103. And assigning the target parameter to the target parameter value at the target assignment point so as to obtain the target parameter value of the target parameter at the preset loading point, and generating a new PWM signal based on the target parameter value of the target parameter.
After the current count value is taken as the target assignment point after the preset count time is prolonged, the target parameter can be assigned as the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and a new PWM signal is generated based on the target parameter value of the target parameter.
In this embodiment of the present invention, if a condition for assigning a target parameter to a target parameter value is triggered, it may be determined whether the current count value is in a preset non-assignable area corresponding to the current mode, where the preset non-assignable area is a count value near a preset loading point corresponding to the current mode, if the current count value is in the preset non-assignable area, the count value obtained by extending the current count value by a preset count period is used as a target assignment point, where the target assignment point is outside the preset non-assignable area, and the target parameter is assigned to the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and a new PWM signal is generated based on the target parameter value of the target parameter. By judging whether the PWM modulation signal is in the preset non-assignable area or not to determine a more reasonable assignment point to bypass the loading point, the probability of missing the carrier zero crossing point of the current period is smaller, and the probability of abnormality of the PWM modulation signal is lower.
In this embodiment of the present application, before the count value obtained by extending the current count value by the preset count duration is used as the target assignment point, the preset count duration may be determined. There are various methods for determining the preset count duration, and one of the methods is described below based on the PWM modulation method shown in fig. 1.
In this embodiment, when PWM modulation is performed, it may be determined whether a condition for assigning a target parameter to a target parameter value is triggered, and if the condition for assigning the target parameter to the target parameter value is triggered, it is determined whether the current count value is in a preset non-assignable area corresponding to the current mode; the preset non-assignable area is a count value near a preset loading point corresponding to the current mode.
Specifically, the target parameter may include a period parameter and/or a comparison value parameter, the method of triggering the condition for assigning the target parameter to the target parameter value may be based on an instruction trigger, and the instruction may characterize assigning the period parameter of the instrumented register to the target period value and/or assigning the comparison value parameter of the comparison register to the target comparison value. It should be understood that the modulation of the PWM signal (i.e. the modulation of the duty cycle) may be determined by loading a register for storing a target period value corresponding to the period parameter, determining the period of the PWM signal, and determining the high/low level time of the PWM signal, i.e. determining the size of the duty cycle, and determining a specific duty cycle by comparing the register for storing a target comparison value corresponding to the comparison value parameter. It will be appreciated that the target parameter may be any other reasonable parameter, and is not limited in this regard, and the method of triggering the condition for assigning the target parameter to the target parameter value may be any other reasonable method, and is not limited in this regard.
Wherein, before determining whether the current count value is in the preset non-assignable area corresponding to the current mode, the preset non-assignable areas corresponding to various modes can be determined.
The method for determining the preset non-assignable area corresponding to each mode may be that if the current loading mode is a shadow mode (shadow register mode), for each falling edge of the carrier, a count value range from a target count value of the falling edge to a zero crossing point is used as the preset non-assignable area, wherein the shadow mode represents loading at the preset loading point; the difference value of the count value between the target count value corresponding to the falling edge and the zero crossing point is a preset count duration, the preset non-assignable area is a count value in a preset count duration range of a preset loading point, the current mode comprises a current loading mode and a current carrier mode, the current carrier mode is an increasing and decreasing mode, and the preset loading point is the zero crossing point of the carrier. In other embodiments, the preset loading point is a period value of the carrier, and at this time, the non-assignable area is located on a rising edge of the carrier, and a count value range between a target count value of the rising edge and the period value is used as the preset non-assignable area.
And if the current count value is the count value of the falling edge of the carrier wave and the current count value is included in the count value range corresponding to the preset non-assignable area, determining that the current count value is in the preset non-assignable area corresponding to the current mode.
Specifically, referring to fig. 2, fig. 2 is a schematic diagram of a preset non-assignable area corresponding to a current carrier mode being an increasing or decreasing mode and a current loading mode being a shadow mode, as shown in fig. 2, where fig. 2 includes a carrier, a time axis, and a period, and a non-assignable area of a CMP value, where the non-assignable area of the period and the CMP value is a count value area corresponding to a gray area in the time axis in fig. 2, and a length corresponding to the non-assignable area may be a preset count duration. For example, the preset count duration is 25, the preset loading point is a zero crossing point of the carrier, the target parameter may be a cycle parameter and a comparison value parameter, the preset loading point of the cycle parameter and the comparison value parameter may be configured as the zero crossing point, when the current count value is 23, it may be determined whether the current count value 23 is a count value of a falling edge of the carrier, if yes, it may be determined that the current count value 23 is included in a count value range (25, 0) corresponding to a preset non-assignable area, that is, a count value 25 to a count value 0, and it may be determined that the current count value is in a preset non-assignable area corresponding to the current mode.
The determining of the preset non-assignable areas corresponding to the various modes may be that if the current loading mode is an immediate mode (immediate register mode), determining that a preset loading point corresponding to the current mode is a target loading point corresponding to the immediate mode, where the immediate mode characterizes that the current assignment point is taken as the target loading point, loading is performed immediately at the target loading point, and the current assignment point is any count value. Aiming at the rising edge of the carrier wave, taking the range of the count value from the first count value of the rising edge to the target loading point as a preset non-assignable area of the rising edge; the difference value of the count value between the first count value corresponding to the rising edge and the target loading point is a preset count duration; aiming at the falling edge of the carrier wave, taking the range from the second count value of the falling edge to the count value between the target loading point as a preset non-assignable area of the falling edge; the difference value of the count value between the second count value corresponding to the falling edge and the target loading point is a preset count duration, wherein the preset non-assignable area is a count value in a preset count duration range of the preset loading point, the current mode comprises a current loading mode and a current carrier mode, and the current carrier mode is an increasing and decreasing mode.
And wherein if the current count value is within the preset non-assignable region, determining that the current count value is within the preset non-assignable region if the current count value is a count value of a rising edge of the carrier and the current count value is included in a count value range corresponding to the preset non-assignable region of the rising edge; if the current count value is the count value of the falling edge of the carrier and the current count value is contained in the count value range corresponding to the preset non-assignable area of the falling edge, determining that the current count value is in the preset non-assignable area.
Specifically, referring to fig. 3, fig. 3 is a schematic diagram of a preset non-assignable area corresponding to a current carrier mode being an increasing/decreasing mode and a current loading mode being an immediate mode, as shown in fig. 3, where fig. 3 includes a carrier, a time axis, and a period, and a non-assignable area of a CMP value, where the non-assignable area of the period and the CMP value is a count value area corresponding to a gray area in the time axis in fig. 3, and a length corresponding to the non-assignable area may be a preset count duration. For example, if the preset count duration is 25 and the target loading point corresponding to the immediate mode is 70, it may be determined that the preset non-assignable region corresponding to the immediate mode is a rising edge (45, 70) of the carrier, and if the current count value is 50, it may be determined that the current count value 50 is a count value of a falling edge or a count value of a rising edge of the carrier, if the current count value is 50, it may be determined that the current count value 50 is included in a count value range corresponding to the preset non-assignable region, that is, a count value 45 to a count value 70, it may be determined that the current count value is within the preset non-assignable region corresponding to the current mode, if the current count value is a count value of a falling edge, it may be determined that the current count value 50 is not included in a count value range corresponding to the preset non-assignable region, that is, a count value 95 to 70, and if the current count value is not included in the preset non-assignable region corresponding to the current mode.
It should be noted that, for the immediate loading mode, the non-assignable area corresponding to each target loading point (the current assignment point) may be predetermined, and specifically, as the target loading point moves, the non-assignable area may also change along with the movement.
It is to be understood that the current carrier mode may be an increasing mode, a decreasing mode, or the like, besides the increasing or decreasing mode, and is not limited herein.
The method for determining the preset non-assignable areas corresponding to the various modes may further include that, for the current carrier mode being an increasing mode, if the current loading mode is an immediate mode, determining that a preset loading point corresponding to the current mode is a target loading point corresponding to the immediate mode, wherein the immediate mode represents that the current assignment point is used as the target loading point, loading is performed immediately at the target loading point, and then, for a rising edge of the carrier, a range from a first count value of the rising edge to a count value between the target loading point is used as the preset non-assignable area of the rising edge; the difference value of the count value between the first count value corresponding to the rising edge and the target loading point is a preset count duration.
The method for determining the preset non-assignable areas corresponding to the various modes may further include that, for the current carrier mode being a subtraction mode, if the current loading mode is an immediate mode, determining that a preset loading point corresponding to the current mode is a target loading point corresponding to the immediate mode, wherein the immediate mode represents that the current assignment point is used as the target loading point, loading is performed immediately at the target loading point, and then, for a falling edge of the carrier, a range from a second count value of the falling edge to a count value between the target loading points is used as the preset non-assignable area of the falling edge; the difference value of the count value between the second count value corresponding to the falling edge and the target loading point is a preset count duration.
The method for determining the preset non-assignable areas corresponding to the various modes may further include that, for a current carrier mode being a subtraction mode, if the current loading mode is a shadow mode, for each falling edge of the carrier, a count value range from a target count value of the falling edge to a zero crossing point is used as the preset non-assignable area; wherein, the shadow mode representation is loaded at a preset loading point; and the difference value of the count value between the target count value corresponding to the falling edge and the zero crossing point is a preset count duration.
It will be appreciated that, in addition to the above-described method for determining the preset non-assignable areas corresponding to the various modes, other reasonable methods for determining the preset non-assignable areas corresponding to the various modes may be used, which is not limited herein.
After determining whether the current count value is in a preset non-assignable area corresponding to the current mode, determining whether the current count value is in the preset non-assignable area, and if the current count value is in the preset non-assignable area, taking the count value obtained by extending the preset count time period of the current count value as a target assignment point; wherein the target assignment point is outside the preset non-assignable region.
The preset counting time length can be determined before the counting value obtained by extending the current counting value by the preset counting time length is used as the target assignment point. The method for determining the preset counting time length may be that first a first counting time length required for executing the step of determining whether the current counting value is in the preset non-assignable area corresponding to the current mode is predicted, then a second counting time length required for executing the step of assigning the target parameter to the target parameter value at the target assignment point is predicted, and finally the preset counting time length is determined based on the first counting time length and the second counting time length.
Wherein the adjustment count duration may be determined before the preset count duration is determined based on the first count duration and the second count duration. The method for determining the preset count time based on the first count time and the second count time may be that the preset count time is determined based on the first count time, the second count time and the adjustment count time.
Specifically, the PWM modulation needs to be adjusted by combining the actual PWM period, the execution time of the delay statement, the period, and the assignment time of the comparison value, that is, the delay time should be greater than (period & duty ratio assignment execution time+delay judgment execution time). In practical application, the assignment execution time of the period and the comparison value (duty ratio) can be calculated first to be T1, the judgment execution time of the delay to be entered is T2, the delay time T > (t1+t2), for example, t=25 > (t1+t2) =12+5, the allowance of 8 clock periods is reserved, wherein the delay time is a preset counting time length, the period & duty ratio assignment execution time is a second counting time length, the judgment execution time of the delay is a first counting time length, and the allowance of the reserved clock period is an adjustment counting time length.
After the current count value is taken as the target assignment point after the preset count time is prolonged, the target parameter can be assigned as the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and a new PWM signal is generated based on the target parameter value of the target parameter.
After determining whether the current count value is in the preset non-assignable area corresponding to the current mode, before the target assignment point assigns the target parameter to the target parameter value, if the current count value is not in the preset non-assignable area, the current count value may be used as the target assignment point.
Specifically, referring to fig. 2, for example, the preset count duration is 25, the preset loading point is the zero crossing point of the carrier, if the current count value is 50, it may be determined whether the current count value 50 is the count value of the falling edge of the carrier, if so, it may be determined that the current count value 50 is not included in the count value range (count value 25 to count value 0) corresponding to the preset non-assignable area, and if so, it may be determined that the current count value is not included in the preset non-assignable area corresponding to the current mode.
It should be noted that, for the scheme that the current loading mode of the embodiment of the present application is the shadow mode, the loading point of the period is generally a zero crossing point, and the loading point of the comparison value is generally a zero crossing point and/or a period value, and for PWM driving control of DCDC, whether the PWM duty cycle is adjusted or not, the PWM period and the comparison value need to be synchronously changed when the driving period is changed, so that the period and the comparison value can be configured to be loaded at the zero crossing point. Specifically, the method for determining the preset loading point as the zero crossing point of the carrier wave may be determined by performing deduction through experiments, and the deduction process based on the experiments is explained below.
For example, for a 5G outdoor integrated direct current power supply project, a TMS320F28069 chip can be adopted as a control system in the 5G outdoor integrated direct current power supply project. When the PWM is configured in shadow mode (shadow register mode), the PWM period loading defaults to loading at carrier zero-crossings and is not modifiable, please refer specifically to the description in the TMS320F28069 chip manual.
For configuration one: the comparison value is loaded at the carrier zero crossing and period.
The PWM carrier mode is configured into an increasing and decreasing mode, the loading mode is configured into a shadow register mode, and in order to ensure that the comparison value can be updated quickly, the PWM comparison value updating mode is updated when the carrier counts to the zero crossing period value. The PWM driving is subjected to frequency mutation test, and the following problems occur in the actual test process:
(1) When the PWM frequency is ramped from 200KHz to 60KHz:
the PWM frequency is ramped from 200KHz to 60KHz (duty cycle fixed 45%), with the waveform of PWMA configured with rising edge going high and falling edge going low; the waveform of PWMB is configured such that the rising edge goes low and the falling edge goes high (PWMB, hereinafter). From this waveform, it is clear that both PWMA and PWMB have a high/low level which does not coincide with the frequency before and after switching at the time of the sudden drop in frequency. Specifically, if the comparison value corresponding to the 60KHz and 45% duty ratio is greater than the carrier period of 200KHz, and the PWM loads the comparison value at the period value at this time, the comparison value update point corresponding to the carrier falling edge with the period of 200KHz is missed, so that the PWM drive needs to wait until the next period is adjusted to the carrier falling edge with the period of 60KHz, and the PWM drive can be updated normally.
(2) PWM frequency was ramped from 60KHz to 200KHz:
the PWM frequency is ramped from 60KHz to 200KHz (duty cycle fixed 45%), with PWMA configured with rising edge high and falling edge low; PWMB is configured with rising edge out low level and falling edge out high level. From this waveform, it is clear that both PWMA and PWMB have a high/low level which does not coincide with the frequency before and after switching at the time of frequency burst. Specifically, the carrier period with the comparison value smaller than 60KHz corresponding to the duty ratio of 200KHz and 45% is triggered by the abnormal driving caused by the frequency sudden increase, which is the loading moment of the comparison value at the carrier period by the PWM, and if the PWM driving frequency is raised and the comparison value is updated and loaded in advance of the period, abnormal waveforms will occur.
The reason analysis is carried out on the problems which occur in sequence in the experimental process corresponding to the PWM frequency changing from 200KHz to 60KHz and the PWM frequency changing from 60KHz to 200KHz: specifically, referring to fig. 4, fig. 4 is a schematic diagram of various operating mode waveforms in which a comparison value changes before a period value, and fig. 4 shows that a corresponding comparison value is configured according to an embodiment of the present application, where the waveform is shown in fig. 4:
(1) When the frequency is unchanged and the duty ratio is increased or decreased, the first waveform after the comparison value is loaded is a transition waveform before and after the change, and the actual duty ratio of the waveform is 0.5 (duty ratio before the change+duty ratio after the change). The transition waveform is normal when the fixed frequency becomes the duty cycle in this configuration.
(2) For PWM ports with a carrier rising edge going high and a carrier falling edge going low (i.e., the corresponding PWM drive in fig. 4), if the drive duty cycle is not 0, it must be high when loaded at the cycle; similarly, if the driving duty is not 0, the PWM port of the carrier with the rising edge going low and the falling edge going high is necessarily low when loaded at the cycle.
(3) The comparison value is configured to be loaded in a carrier period and a zero crossing point, and the configuration faces an application scene requiring a PWM period to be changed, and the comparison value of PWM is required to be synchronously adjusted according to the period no matter whether the duty ratio is changed or not, so that the period and the comparison value are required to be updated and loaded. When the comparison value is loaded before the period, that is, the comparison value is loaded at the carrier period and the period is loaded at the zero crossing point of the next carrier, no matter the PWM driving is at the high level or at the low level, the situation that the actual duty ratio is inconsistent with the change trend of the theoretical duty ratio is necessarily caused.
After the reason analysis is carried out, the configuration is carried out in the carrier period and the zero crossing point, and the PWM comparison value can be ensured to be updated rapidly, but the configuration is not suitable for the working condition that the period and the comparison value need to be carried repeatedly and simultaneously. If the application working condition has low requirement on the change precision of the PWM duty ratio, the situation that the comparison value is larger than the current carrier period and the actual driving has larger phase difference with the ideal driving can be avoided by limiting the measure of loading the change difference value before and after the PWM frequency; or PWMA is loaded at the carrier zero crossing point and PWMB is loaded at the carrier periodic point, so that the PWMA and PWMB can be ensured to load the period at the low level moment, the consistency of the PWMA and the period loading can be ensured, but the comparison value loading of the PWMB is staggered from the period loading point for the next time, and a driving signal longer than ideal high level time can appear when the frequency is suddenly reduced and the comparison value loading is later than the period loading.
In conclusion, the situation that the actual duty ratio is inconsistent with the theoretical duty ratio change trend cannot be fundamentally solved by the measures. Therefore, after balancing the comparison value and advancing the benefit and disadvantage of periodic loading, the configuration of the comparison value update points of PWMA and PWMB can be selected and adjusted to be consistent with the periodic loading point, that is, loading of the periodic and comparison values is uniformly performed at the carrier zero crossing point.
It is worth mentioning that after the loading of the period and the comparison value is uniformly carried out at the zero crossing point of the carrier wave, the situation of PWM modulation abnormal waveform still occurs. In particular, please refer to the following description of configuration two.
For configuration two: the comparison value is loaded only at the carrier zero crossing point.
When the PWM count mode is configured as an up-down mode, it is explicitly indicated in the TMS320x2806x manual that in some cases, loading of the PWM CMPA/CMPB comparison value may be delayed for a period of time, and thus, assigning a value of 0 at the carrier zero crossing point or a value of carrier period at the carrier period may occur, where the comparison value fails to be loaded at this loading point.
For the second configuration, that is, the working condition of loading the cycle and the CMP value (comparison value) at the carrier zero crossing point is taken as an example, when tbctr=0, that is, when the carrier counts to the zero crossing point, the assignment of 0 to the CMP value may cause loading abnormality (when tbctr=tbprt (cycle value) is applied, the assignment of TBPRT to the CMP value may also cause loading abnormality), and referring to fig. 5, fig. 5 is a schematic diagram showing an abnormality of the comparison value at the loading point assignment in the embodiment of the present application, for example, the assignment of 0 to the CMP value at the carrier zero crossing point, where the CMP value can be loaded normally and completed, but the DSP may miss the judgment of the rising edge to go high/low level, thereby causing driving abnormality for one cycle. When the trigger driving is abnormal, the driving which should be fast high/low level is continuously output with the reverse level which is more than or equal to one period. It will be appreciated that in practical applications, the effect of such abnormal driving is much worse than with hysteresis control. Therefore, to adopt this configuration and the driving needs to be configured to be fully on/fully off, and therefore, it is necessary to solve the problem of carrier zero crossing driving abnormality.
It should be noted that, the existing solutions for solving the driving abnormality of the carrier zero crossing point may be two kinds, in which the first is to adjust the C phase of the three-phase PWM to the carrier period point for loading, and the PWM duty ratio cannot reach the period value through amplitude limiting, so that the driving abnormality will not occur. The second is to configure the three-phase PWM to be in-phase, and the shadow register update time and the software update value time can be ensured not to be overlapped forever under the configuration of the interrupt and the PWM driving strong hook. For the scheme of the embodiment of the present application, zero crossing points may be avoided when the period and the comparison value are assigned, so as to solve the problem of abnormal driving of the carrier zero crossing points, for example, for the scheme of the embodiment of the present application in which the current loading mode is the shadow mode, please continue to refer to fig. 2, as can be known from fig. 2, the logic of bypassing the zero crossing points/period values is added on the basis of the configuration two, and when the PWM period and the comparison value are assigned, it may be determined whether the carrier count value of the TBCTR is close to the carrier zero crossing points/period value. If the count is close to the zero-crossing point/period value, the PWM period and the comparison value cannot be assigned at the moment, the system actively delays for a period of time, and assignment is carried out after the zero-crossing point/period value is bypassed.
Compared with the existing scheme for solving the carrier zero crossing driving abnormality, the scheme with the shadow mode as the current loading mode in the embodiment of the application can solve the abnormal waveform generated when the frequency or the duty ratio is suddenly changed due to different loading moments of the PWM by changing the PWM configuration aiming at the driving configuration working conditions of repeated frequency conversion, duty ratio change and frequent overlapping of the control moment and the loading moment; by additionally bypassing the loading point assignment scheme, the situation that abnormal waveforms are generated when loading points are assigned to the loading values and the comparison values are not assigned to the loading values, which are reminded in the manual, can be effectively avoided, and the effect that abnormal driving does not occur even if the PWM duty ratio is assigned to the full duty ratio or 0 can be achieved. It can be understood that the existing scheme for solving the driving abnormality of the zero crossing point of the carrier can only carry out assignment at a fixed certain time point of the non-zero crossing point, so that the probability of missing the zero crossing point of the carrier in the current period is larger, but the probability of missing the zero crossing point of the carrier in the current period is smaller by judging whether the current period is in a preset non-assignable area to determine a more reasonable assignment point.
It will be appreciated that in addition to the method of determining the preset count duration described above; in addition to the method of determining the preset count duration based on the first count duration and the second count duration described above; in addition to the method of determining a preset non-assignable region corresponding to the current mode described above; in addition to the method of determining that the current count value is within the preset non-assignable region described above; other reasonable methods are also possible, and are not limited in this regard.
In this embodiment, if a condition of assigning the target parameter to the target parameter value is triggered, it may be determined whether the current count value is in a preset non-assignable area corresponding to the current mode, where the preset non-assignable area is a count value near a preset loading point corresponding to the current mode, if the current count value is in the preset non-assignable area, the count value obtained by extending the preset count duration from the current count value is taken as the target assignment point, where the target assignment point is outside the preset non-assignable area, and the target parameter is assigned to the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and a new PWM signal is generated based on the target parameter value of the target parameter. The method can determine whether more reasonable assignment points are located in a preset non-assignment area to bypass the loading points, the probability of missing the carrier zero crossing points of the current period is small, and the situation that abnormal waveforms occur in PWM driving during large dynamic frequency conversion and duty ratio change can be effectively avoided by changing PWM configuration and bypass the loading point assignment scheme aiming at driving configuration working conditions of repeated frequency conversion and duty ratio change. And secondly, the first counting time length required by executing the step of determining whether the current counting value is in the preset non-assignable area corresponding to the current mode can be predicted, the second counting time length required by executing the step of assigning the target parameter to the target parameter value at the target assignment point can be predicted, and the preset counting time length is determined based on the first counting time length and the second counting time length, so that the rationality of determining the preset counting time length is improved, the probability of missing the carrier zero crossing point of the current period is reduced, and the possibility of generating abnormal waveforms of PWM (pulse-width modulation) signals is improved. Finally, the adjustment counting time length can be determined, and the preset counting time length is determined based on the first counting time length, the second counting time length and the adjustment counting time length, so that the accuracy of determining the preset counting time length is improved.
The PWM modulation method in the embodiment of the present application is described above, and the PWM modulation apparatus in the embodiment of the present application is described below, referring to fig. 6, one embodiment of the PWM modulation apparatus in the embodiment of the present application includes:
a determining unit 601, configured to determine whether the current count value is in a preset non-assignable area corresponding to the current mode if a condition that the target parameter is assigned to the target parameter value is triggered; wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode;
the determining unit 601 is further configured to, if the current count value is in the preset non-assignable area, set a count value obtained by extending the current count value by a preset count duration as a target assignment point; wherein the target assignment point is outside the preset non-assignable region;
and an assigning unit 602, configured to assign the target parameter to the target parameter value at the target assigning point, so that the target parameter value of the target parameter is obtained at the preset loading point, and generate a new PWM signal based on the target parameter value of the target parameter.
In this embodiment of the present invention, if a condition for assigning a target parameter to a target parameter value is triggered, it may be determined whether the current count value is in a preset non-assignable area corresponding to the current mode, where the preset non-assignable area is a count value near a preset loading point corresponding to the current mode, if the current count value is in the preset non-assignable area, the count value obtained by extending the current count value by a preset count period is used as a target assignment point, where the target assignment point is outside the preset non-assignable area, and the target parameter is assigned to the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and a new PWM signal is generated based on the target parameter value of the target parameter. By judging whether the PWM modulation signal is in the preset non-assignable area or not to determine a more reasonable assignment point to bypass the loading point, the probability of missing the carrier zero crossing point of the current period is smaller, and the probability of abnormality of the PWM modulation signal is lower.
Referring to fig. 7, another embodiment of the PWM modulation apparatus in the embodiment of the present application includes:
a determining unit 701, configured to determine whether the current count value is in a preset non-assignable area corresponding to the current mode if a condition that the target parameter is assigned to the target parameter value is triggered; wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode;
the determining unit 701 is further configured to, if the current count value is in the preset non-assignable area, set a count value obtained by extending the current count value by a preset count duration as a target assignment point; wherein the target assignment point is outside the preset non-assignable region;
and an assignment unit 702, configured to assign the target parameter to the target parameter value at the target assignment point, so that the target parameter value of the target parameter is obtained at the preset loading point, and generate a new PWM signal based on the target parameter value of the target parameter.
The PWM modulation apparatus further includes:
a prediction unit 703, configured to predict a first count duration that is required to be consumed for executing the step of determining whether the current count value is in the preset non-assignable area corresponding to the current mode;
The prediction unit 703 is further configured to predict a second count duration that is required to be consumed for performing the step of assigning the target parameter to the target parameter value at the target assignment point;
the determining unit 701 is further configured to determine the preset count duration based on the first count duration and the second count duration.
The determining unit 701 is further configured to determine an adjustment count duration;
the determining unit 701 is specifically configured to determine the preset count duration based on the first count duration, the second count duration, and the adjusted count duration.
The determining unit 701 is further configured to determine, for each falling edge of the carrier, a range of a count value between a target count value of the falling edge and the zero crossing point as the preset non-assignable area if the current loading mode is a shadow mode; wherein, the shadow mode representation is loaded at the preset loading point; and the difference value of the count value between the target count value corresponding to the falling edge and the zero crossing point is the preset count duration; the preset non-assignable area is a count value in a preset count duration range of the preset loading point; the current mode comprises a current loading mode and a current carrier mode; and the current carrier mode is an increasing/decreasing mode; the preset loading point is the zero crossing point of the carrier wave.
The determining unit 701 is specifically configured to determine that the current count value is in a preset non-assignable area corresponding to the current mode if the current count value is a count value of a falling edge of the carrier and the current count value is included in a count value range corresponding to the preset non-assignable area.
The determining unit 701 is further configured to determine that, if the current loading mode is an immediate mode, a preset loading point corresponding to the current mode is a target loading point corresponding to the immediate mode; the immediate mode representation takes the current assignment point as the target loading point, and loads immediately at the target loading point; the current assignment point is any count value;
the determining unit 701 is further configured to determine, for a rising edge of a carrier, a range of count values from a first count value of the rising edge to the target loading point as a preset non-assignable area of the rising edge; the difference value of the count value between the first count value corresponding to the rising edge and the target loading point is the preset count duration;
the determining unit 701 is further configured to determine, for a falling edge of the carrier, a range of count values from a second count value of the falling edge to the target loading point as a preset non-assignable area of the falling edge; the difference value of the count value between the second count value corresponding to the falling edge and the target loading point is the preset count duration; the preset non-assignable area is a count value in a preset count duration range of the preset loading point; the current mode comprises a current loading mode and a current carrier mode; and the current carrier mode is an increasing or decreasing mode.
The determining unit 701 is specifically configured to determine that the current count value is in a preset non-assignable area if the current count value is a count value of a rising edge of the carrier and the current count value is included in a count value range corresponding to the preset non-assignable area of the rising edge; and if the current count value is the count value of the falling edge of the carrier and the current count value is contained in the count value range corresponding to the preset non-assignable region of the falling edge, determining that the current count value is in the preset non-assignable region.
The determining unit 701 is further configured to take the current count value as the target assignment point if the current count value is not in the preset non-assignable area.
In this embodiment, each unit in the PWM modulation apparatus performs the operation of the PWM modulation apparatus in the embodiment shown in fig. 1, which is not described herein.
Referring now to fig. 8, yet another embodiment of a PWM modulation apparatus 800 according to an embodiment of the present application includes:
a central processing unit 801, a memory 804, an input/output interface 803, and a power supply 802;
memory 804 is a transient memory or persistent memory;
The central processor 801 is configured to communicate with the memory 804 and to execute the instructions in the memory 804 to perform the method of the embodiment shown in fig. 1 described above.
Embodiments of the present application also provide a computer-readable storage medium comprising instructions that, when executed on a computer, cause the computer to perform the method of the embodiment shown in fig. 1 described above.
Embodiments of the present application also provide a computer program product comprising instructions which, when executed on a computer, cause the computer to perform the method of the embodiment shown in fig. 1 described above.
It should be understood that, although the steps in the flowcharts related to the embodiments described above are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described systems, apparatuses and units may refer to corresponding procedures in the foregoing method embodiments, which are not repeated herein.
In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods may be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of the units is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be embodied in essence or a part contributing to the prior art or all or part of the technical solution in the form of a software product stored in a storage medium, including several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a read-only memory (ROM), a random access memory (RAM, random access memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Claims (10)
1. A PWM modulation method, comprising:
if the condition of assigning the target parameter to the target parameter value is triggered, determining whether the current count value is in a preset non-assignable area corresponding to the current mode; wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode;
if the current count value is in the preset non-assignable area, the count value obtained by extending the current count value by a preset count time is used as a target assignment point; wherein the target assignment point is outside the preset non-assignable region;
and assigning the target parameter to the target parameter value at the target assignment point so as to obtain the target parameter value of the target parameter at the preset loading point, and generating a new PWM signal based on the target parameter value of the target parameter.
2. The method according to claim 1, wherein before the step of taking the count value obtained by extending the current count value by a preset count duration as the target assigned point, the method further comprises:
predicting a first counting time length required for executing the step of determining whether the current counting value is in a preset non-assignable area corresponding to the current mode;
Predicting a second count duration to be consumed for executing the step of assigning the target parameter to the target parameter value at the target assignment point;
and determining the preset counting time length based on the first counting time length and the second counting time length.
3. The method of claim 2, wherein prior to determining the preset count duration based on the first count duration and the second count duration, the method further comprises:
determining an adjustment count duration;
the determining the preset count duration based on the first count duration and the second count duration includes:
and determining the preset counting time based on the first counting time, the second counting time and the adjustment counting time.
4. The method of claim 1, wherein the predetermined non-assignable region is a count value of a predetermined count duration range at the predetermined loading point; the current mode comprises a current loading mode and a current carrier mode; and the current carrier mode is an increasing/decreasing mode; the preset loading point is a zero crossing point of a carrier wave;
before determining whether the current count value is in the preset non-assignable area corresponding to the current mode, the method further comprises:
If the current loading mode is a shadow mode, regarding a count value range from a target count value of the falling edge to the zero crossing point as the preset non-assignable area aiming at each falling edge of the carrier wave; wherein, the shadow mode representation is loaded at the preset loading point; and the difference value of the count value between the target count value corresponding to the falling edge and the zero crossing point is the preset count duration.
5. The method of claim 4, wherein if the current count value is within the preset non-assignable region, comprising:
and if the current count value is the count value of the falling edge of the carrier wave and the current count value is contained in the count value range corresponding to the preset non-assignable area, determining that the current count value is in the preset non-assignable area corresponding to the current mode.
6. The method of claim 1, wherein the predetermined non-assignable region is a count value of a predetermined count duration range at the predetermined loading point; the current mode comprises a current loading mode and a current carrier mode; and the current carrier mode is an increasing/decreasing mode;
Before determining whether the current count value is in the preset non-assignable area corresponding to the current mode, the method further comprises:
if the current loading mode is an immediate mode, determining that a preset loading point corresponding to the current mode is a target loading point corresponding to the immediate mode; the immediate mode representation takes the current assignment point as the target loading point, and loads immediately at the target loading point; the current assignment point is any count value;
regarding the rising edge of a carrier wave, taking the range of a count value from a first count value of the rising edge to the target loading point as a preset non-assignable area of the rising edge; the difference value of the count value between the first count value corresponding to the rising edge and the target loading point is the preset count duration;
regarding the falling edge of the carrier wave, taking the range from the second count value of the falling edge to the count value between the target loading point as a preset non-assignable area of the falling edge; and the difference value of the count value between the second count value corresponding to the falling edge and the target loading point is the preset count duration.
7. The method of claim 6, wherein if the current count value is within the preset non-assignable region, comprising at least one of:
if the current count value is the count value of the rising edge of the carrier wave and the current count value is contained in the count value range corresponding to the preset non-assignable area of the rising edge, determining that the current count value is in the preset non-assignable area;
and if the current count value is the count value of the falling edge of the carrier and the current count value is contained in the count value range corresponding to the preset non-assignable region of the falling edge, determining that the current count value is in the preset non-assignable region.
8. The method according to claim 1, wherein after determining whether the current count value is within a preset non-assignable region corresponding to the current mode, the method further comprises, before the target assignment point assigns the target parameter to the target parameter value:
and if the current count value is not in the preset non-assignable area, taking the current count value as the target assignment point.
9. A PWM modulation apparatus, comprising:
the determining unit is used for determining whether the current count value is in a preset non-assignable area corresponding to the current mode if the condition of assigning the target parameter to the target parameter value is triggered; wherein the preset non-assignable area is a count value near a preset loading point corresponding to the current mode;
the determining unit is further configured to, if the current count value is in the preset non-assignable area, set a count value obtained by extending the preset count time period from the current count value as a target assignment point; wherein the target assignment point is outside the preset non-assignable region;
and the assignment unit is used for assigning the target parameter to the target parameter value at the target assignment point so as to obtain the target parameter value of the target parameter at the preset loading point and generating a new PWM signal based on the target parameter value of the target parameter.
10. A PWM modulation apparatus, comprising:
a central processing unit and a memory;
the memory is a short-term memory or a persistent memory;
the central processor is configured to communicate with the memory and to execute instruction operations in the memory to perform the method of any of claims 1 to 8.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311173080.6A CN117459034A (en) | 2023-09-12 | 2023-09-12 | PWM modulation method and PWM modulation apparatus |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311173080.6A CN117459034A (en) | 2023-09-12 | 2023-09-12 | PWM modulation method and PWM modulation apparatus |
Publications (1)
Publication Number | Publication Date |
---|---|
CN117459034A true CN117459034A (en) | 2024-01-26 |
Family
ID=89589929
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311173080.6A Pending CN117459034A (en) | 2023-09-12 | 2023-09-12 | PWM modulation method and PWM modulation apparatus |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117459034A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN118074486A (en) * | 2024-04-18 | 2024-05-24 | 如果新能源科技(江苏)股份有限公司 | Power converter, control method thereof and power supply system |
-
2023
- 2023-09-12 CN CN202311173080.6A patent/CN117459034A/en active Pending
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN118074486A (en) * | 2024-04-18 | 2024-05-24 | 如果新能源科技(江苏)股份有限公司 | Power converter, control method thereof and power supply system |
CN118074486B (en) * | 2024-04-18 | 2024-06-25 | 如果新能源科技(江苏)股份有限公司 | Power converter, control method thereof and power supply system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101741238B (en) | Current balancing circuit and method | |
CN205212743U (en) | AC motor control system | |
US9461544B2 (en) | Enhanced phase control circuit and method for a multiphase power converter | |
US10103632B2 (en) | Enhanced phase control circuit and method for a multiphase power converter | |
CN104242651A (en) | Advanced phase number control for multiphase converters | |
US9496791B2 (en) | Multiphase buck converter with dynamic phase firing | |
US20100017636A1 (en) | Power supply system | |
CN117459034A (en) | PWM modulation method and PWM modulation apparatus | |
US10969808B2 (en) | On-time timer circuit with external clock for switching converter control | |
JP2016525269A (en) | High frequency heater, power supply control method thereof, and power supply control apparatus | |
Fei et al. | State-trajectory control of LLC converter implemented by microcontroller | |
CN114221642B (en) | PWM wave generation and duty ratio control method, device, timer and equipment | |
JP2003333839A (en) | Power control method and power control device | |
JP2022041912A (en) | Multi-phase switched-mode power supply | |
US9923467B2 (en) | Multiphase converting controller | |
EP3062432A1 (en) | Direct current power source and method of operation thereof | |
US7786714B2 (en) | Voltage converter apparatus and method therefor | |
JP6344500B1 (en) | Matrix converter and constant determination method for AC motor | |
EP4075655A1 (en) | Polyphase power-supply device | |
EP3576277B1 (en) | Method for controlling a psfb converter and psfb converter | |
CN113131736A (en) | PFM controller for multilevel converter using flying capacitor voltage monitor | |
CN115528896A (en) | Control method and structure of interleaved parallel topology and AC/DC power supply | |
WO2019226169A1 (en) | Optimization of switching losses in buck-boost converters | |
US11043891B1 (en) | Controller for an AC/DC or a DC/AC multi-phase power converter | |
Gasparri et al. | Variable off-Time Peak Current Mode Control (VoT-PCMC) as method for average current regulation in Buck Converter Drivers |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |