Compressor motor current sampling method and sampling system based on hardware compensation
By adopting an adaptive current sampling method based on hardware parameters, the problems of insufficient sampling window and current imbalance of compressor motor under high modulation depth conditions are solved, realizing high-precision current sampling and improving system stability. It is applicable to permanent magnet synchronous motor compressor drive systems with different controller platforms and topologies.
Patent Information
- Application Number
- CN202610373554.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-03-25
- Publication Date
- 2026-06-19
AI Technical Summary
Existing compressor motor current sampling schemes fail to effectively consider hardware characteristics, resulting in problems such as insufficient sampling window, current distortion, three-phase imbalance, large current reconstruction error, and increased motor noise under high modulation depth conditions.
The current sampling method based on hardware parameter adaptation constructs a mathematical model of the current sampling window by collecting circuit hardware parameters, automatically determines the minimum sampling time and compensation amount, corrects the duty cycle of the three-phase PWM, ensures dynamic matching between the sampling window and the hardware, and realizes periodic symmetrical sampling of the three-phase current.
It improves sampling accuracy, enhances three-phase current balance, strengthens system stability, reduces noise and vibration, optimizes energy efficiency, reduces development costs, and improves the control performance and operational reliability of the compressor permanent magnet synchronous motor drive system.
Smart Images

Figure CN122238852A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of compressor technology, and in particular to a compressor motor current sampling method and sampling system based on hardware compensation. Background Technology
[0002] Permanent magnet synchronous motors are widely used in compressors, electric joints, and robot servo systems. Vector control algorithms require high-precision, highly synchronized phase current sampling to ensure accurate flux linkage orientation and stable electromagnetic torque output. Under high modulation depth conditions, the duty cycle of the upper arm of the inverter bridge increases, while the conduction time of the lower arm shortens, resulting in a smaller current sampling window. If the sampling window does not reach the minimum settling time required by the sampling conditioning circuit and analog-to-digital conversion interface, current distortion, current imbalance, and even control instability and increased compressor noise will occur.
[0003] Existing current sampling compensation schemes are generally based on a "fixed threshold" or use software logic to determine the pulse width modulation duty cycle, and then perform single-phase compensation or reconstruction. However, the compensation amount of these schemes is entirely set by software, without considering the actual dynamic capability of the conditioning circuit, resulting in a mismatch between the compensation amount and the circuit hardware. For example, the hardware structure, including operational amplifiers, resistors, capacitors, ADCs (analog-to-digital converters), drivers, and power transistors, all affect the current sampling window. Among them, the output slew rate and saturation characteristics of the operational amplifier determine the signal settling time; the resistors and capacitors in the feedback network determine the amplification bandwidth and phase margin; the input impedance and sample-and-hold capacitance of the ADC determine the signal settling time; and the dead time of the driver and the delay of the power transistor affect the usable length of the sampling window.
[0004] The aforementioned hardware characteristics are not included in the compensation calculation in traditional solutions, so the threshold set by the software often does not match the hardware capabilities. Under high modulation ratio conditions, existing compensation methods may encounter problems such as insufficient sampling window, current distortion, three-phase imbalance, large current reconstruction error, increased motor noise, and instability in some operating ranges.
[0005] Therefore, the present invention requires an adaptive sampling compensation scheme based on hardware parameters, which can automatically determine the minimum sampling time and compensation amount according to the real-time characteristics of the hardware. Summary of the Invention
[0006] This invention provides a compressor motor current sampling method and system based on hardware compensation. The system can automatically determine the minimum sampling time and compensation amount according to the real-time characteristics of the hardware, so that the sampling window always meets the dynamic requirements of the hardware. Without reducing the PWM (pulse width modulation) frequency or changing the control cycle, it still ensures high-precision sampling and three-phase current balance. It can maintain the periodic symmetry and current balance of current sampling under high modulation depth and complex operating conditions, thereby improving the efficiency and reliability of the compressor variable frequency drive system, and further improving the operational stability and efficiency of the entire servo system or compressor system.
[0007] This invention provides a hardware-compensated method for sampling the current of a compressor permanent magnet synchronous motor, comprising the following steps:
[0008] S1: Various hardware parameters of the acquisition circuit;
[0009] S2: Determine the maximum allowable duty cycle of the phase voltage based on the aforementioned hardware parameters. and duty cycle offset ;
[0010] S3: In each PWM control cycle, calculate the three-phase PWM duty cycle, and synchronously correct the three-phase PWM duty cycle based on the duty cycle bias to ensure that the corrected three-phase PWM duty cycle meets the sampling window requirements.
[0011] Optionally, step S3 includes the following steps:
[0012] Step S3-1: Determine the duty cycle of the three-phase PWM Is it less than the maximum allowable duty cycle? And count the number of phases N that meet the condition; if N is less than or equal to 1, then execute step S3-2;
[0013] S3-2: PWM duty cycle for each phase In the process, the PWM duty cycle is sorted by numerical value and the middle value is selected as the target duty cycle. The target duty cycle value is then assigned to the maximum allowable duty cycle. ;
[0014] PWM duty cycle Corrected to and according to Generate drive signals, where
[0015] .
[0016] Optionally, in step S3-1, if N=2, then step S3-3 is executed;
[0017] S3-3: Perform current sampling on the two phases that meet the above conditions to obtain the two-phase current sampling values. and Reconstruct the current of another phase ;
[0018]
[0019] Current and Together, they serve as the three-phase current feedback signal input to the vector controller, and are adjusted according to the three-phase duty cycle. Generate driving signals.
[0020] Optionally, in step S3-1, if N=3, then step S3-4 is executed;
[0021] S3-4: Sample the three-phase currents to obtain the sampled three-phase current values. The three-phase current is then used as a current feedback signal and input to the vector controller, according to... Generate driving signals.
[0022] Optionally, the hardware parameters collected in step S1 include: operational amplifier response speed, feedback network bandwidth, analog-to-digital converter sample-and-hold parameters, driver dead time, and power switch delay.
[0023] Optionally, the duty cycle offset is calculated in step S2 through the following steps. ;
[0024] Calculate the minimum sampling time based on the hardware parameters. ;
[0025] By small sampling time Calculate duty cycle offset , ;
[0026] in This represents the PWM cycle time.
[0027] Optionally, the minimum sampling time Calculate using the following steps;
[0028] Calculate the operational amplifier settling time based on the hardware parameters. Feedback network establishment time Analog-to-digital converter setup time Drive dead time and safety margin time Power switching delay time ;
[0029] .
[0030] Optionally, the operational amplifier settling time Based on the gain-bandwidth product, input step change amplitude, and output slew rate of the operational amplifier, this method is used to characterize the time required for the output of the operational amplifier to reach a steady state after the input changes.
[0031] And / or, ,in The feedback resistor of the feedback network. The feedback capacitor is used for the feedback network.
[0032] And / or, ,in The sample-and-hold capacitor for the analog-to-digital converter. This is the input impedance of the analog-to-digital converter;
[0033] And / or, the The sum of the dead time configuration for the upper and lower bridge arms of the driver and the additional safety margin;
[0034] And / or, ,in This refers to the turn-on delay time of the power device. This is the turn-off delay time of the power device.
[0035] Optionally, in step S2 .
[0036] The present invention also provides a compressor motor current sampling system based on hardware compensation, comprising:
[0037] The hardware parameter acquisition module is used to collect various hardware parameters of the circuit.
[0038] The calculation module is used to determine the maximum allowable duty cycle of the phase voltage based on the hardware parameters. and duty cycle offset ;
[0039] The sampling module is used to collect data for each PWM control cycle and calculate the three-phase PWM duty cycle.
[0040] The compensation module synchronously corrects the duty cycle of the three-phase PWM based on the duty cycle offset, so that the corrected three-phase PWM duty cycle meets the sampling window requirements.
[0041] The aforementioned sampling method incorporates various dynamic hardware parameters of the circuit into the current sampling process, constructing a mathematical model of the current sampling window based on the actual dynamic capabilities of the hardware. Compared to existing methods that rely on manual experience to set fixed sampling thresholds or fixed sampling windows, this method automatically determines the minimum sampleable time, the maximum allowable duty cycle, and a uniform duty cycle bias for compensating the three-phase PWM duty cycle based on the actual hardware response characteristics of the circuit. This ensures that the sampling window always matches the setup time of the current conditioning link, fundamentally avoiding problems such as insufficient sampling window, current measurement deviation, and three-phase imbalance caused by inaccurate empirical settings. The compensation amount of this method has higher accuracy and applicability.
[0042] The above sampling method, by ensuring that the sampling window matches the dynamic hardware setup process and achieving periodic symmetrical sampling of the three-phase current, can effectively reduce harmonic components in the stator current, alleviate the torque ripple and electromagnetic noise they cause, and improve the stability, vibration, and acoustic performance of the compressor motor. During long-term operation or wide-range variable frequency operation of the permanent magnet synchronous motor, the compensation strategy of the above sampling method can maintain good current balance and current regulation quality, making the dynamic response of the drive system smoother and improving overall operating performance.
[0043] The aforementioned sampling method automatically derives the sampling window threshold and compensation amount based on hardware parameters, without relying on manual experience for debugging. This significantly reduces the parameter tuning complexity and development time of the control algorithm, improving product consistency and manufacturability. The sampling method can be implemented in software without altering existing hardware structures and modulation strategies, making it easy to port and apply. It is adaptable to different controller platforms, power levels, and permanent magnet synchronous motor compressor drive systems with different topologies, demonstrating good versatility and scalability.
[0044] Regarding the sampling strategy, this application intelligently classifies sampling conditions based on the real-time calculated three-phase PWM duty cycle. Direct sampling can be performed when all three phases meet the sampling conditions. When only one phase's duty cycle exceeds the limit, it automatically switches to a "two-phase sampling combined with Kirchhoff's current law reconstruction" method. Under conditions where two or more phases exceed the limit, synchronous correction is performed on the three-phase PWM duty cycle based on the aforementioned duty cycle bias, ensuring that the corrected PWM waveform maintains zero-vector time period symmetry and meets the minimum sampling window requirement. This adaptive sampling compensation mechanism can stably provide accurate three-phase current feedback under complex conditions such as different modulation depths, high back voltage, high bus voltage fluctuations, and high-speed operation, significantly reducing errors caused by sampling point offset and improving the reliability and continuity of current sampling.
[0045] In summary, the above sampling method offers significant advantages in terms of improved sampling accuracy, enhanced three-phase current balance, improved system stability, noise and vibration control, optimized energy efficiency, and reduced development costs. It helps address issues such as insufficient sampling window, current distortion, three-phase imbalance, large current reconstruction error, increased motor noise, and instability in certain operating ranges. Furthermore, it effectively improves the control performance and operational reliability of the compressor's permanent magnet synchronous motor drive system. Attached Figure Description
[0046] Figure 1 This is a flowchart of a hardware-compensated compressor permanent magnet synchronous motor current sampling method according to an embodiment of the present invention;
[0047] Figure 2 This is a flowchart illustrating a compensation strategy according to an embodiment of the present invention;
[0048] Figure 3 This is a schematic diagram illustrating the relationship between the modulation waveform and the sampling window according to an embodiment of the present invention;
[0049] Figure 4 This is a system overall structure block diagram according to an embodiment of the present invention;
[0050] Figure 5 This is a block diagram of the system adaptive compensation structure according to an embodiment of the present invention. Detailed Implementation
[0051] The following detailed description, in conjunction with the accompanying drawings and specific embodiments, provides a further detailed explanation of the hardware-compensated compressor motor current sampling method and sampling system proposed in this invention. The advantages and features of this invention will become clearer from the following description. It should be noted that the accompanying drawings are all in a very simplified form and use non-precise proportions, and are only used to facilitate and clarify the illustration of the embodiments of this invention.
[0052] In this invention, "outer diameter" and "inner diameter" refer to the diameter of a circular structure, while for a non-circular structure, the inner diameter refers to the diameter of its inscribed circle and the outer diameter refers to the diameter of its circumscribed circle. "Axial direction" refers to the direction of the central axis of a cylindrical rod, while for a non-cylindrical rod, the axial direction refers to the length direction of the rod.
[0053] As used in this invention, the singular forms “a,” “an,” and “the” include plural objects; the term “or” is generally used to mean “and / or”; the term “a number” is generally used to mean “at least one”; and the term “at least two” is generally used to mean “two or more”. Furthermore, the terms “first,” “second,” and “third” are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined with “first,” “second,” or “third” may explicitly or implicitly include one or at least two of that feature. Additionally, as used in this invention, “installed,” “connected,” “joined,” and “set” on one element by another should be interpreted broadly, generally indicating only a connection, coupling, mating, or transmission relationship between the two elements, which can be direct or indirect through an intermediate element. They should not be construed as indicating or implying a spatial positional relationship between the two elements, i.e., one element can be located inside, outside, above, below, or to one side of another element, unless otherwise explicitly stated. For those skilled in the art, the specific meaning of the above terms in this invention can be understood according to the specific circumstances. Furthermore, directional terms such as above, below, up, down, upward, downward, left, right, etc., are used relative to exemplary embodiments as shown in the figures, with upward or up direction pointing towards the top of the corresponding figure, and downward or down direction pointing towards the bottom of the corresponding figure.
[0054] This embodiment provides a hardware-compensated method for sampling the current of a compressor permanent magnet synchronous motor.
[0055] Combination Figure 1 As shown, the compensation method includes the following steps:
[0056] S1: Acquire various hardware parameters of the motor control circuit; specifically, the hardware parameters of the acquisition module can be acquired through the hardware parameter acquisition module to obtain the operational amplifier response speed (e.g., output slew rate, gain-bandwidth product, and input step change amplitude), feedback network bandwidth (e.g., feedback resistor and feedback capacitor parameters), analog-to-digital converter sample-and-hold parameters (e.g., sample-and-hold capacitor and input impedance), driver dead time (e.g., upper and lower bridge arm dead time configuration time and safety margin time), and power switch delay (e.g., power switch device turn-on delay time and turn-off delay time), and other hardware characteristic parameters.
[0057] S2: Determine the maximum allowable duty cycle of the phase voltage based on hardware parameters. and duty cycle offset Specifically, a mathematical model of the current sampling window based on the hardware dynamic characteristics can be constructed using the calculation module based on the hardware parameters, and the maximum allowable duty cycle can be calculated based on this mathematical model. and duty cycle offset .
[0058] S3: The sampling module samples the voltages in each PWM control cycle and calculates the three-phase PWM duty cycle based on the d-axis and q-axis voltage commands or space voltage vectors obtained from vector control calculations. These duty cycles are denoted as the first phase duty cycle. Second phase duty cycle and the third duty cycle The duty cycle of the three-phase PWM is synchronously corrected based on the duty cycle bias to ensure that the corrected duty cycle meets the sampling window requirements. Finally, a drive signal is generated based on the corrected duty cycle.
[0059] The aforementioned sampling method incorporates various dynamic hardware parameters of the circuit (operational amplifier response speed, feedback network bandwidth, analog-to-digital converter sample-and-hold parameters, driver dead time and safety margin, and power device switching delay, etc.) into the current sampling process, constructing a mathematical model of the current sampling window based on the actual dynamic capabilities of the hardware. Compared with existing methods that rely on manual experience to set fixed sampling thresholds or fixed sampling windows, this method can automatically determine the minimum sampleable time, maximum allowable duty cycle, and a uniform duty cycle bias for compensating the three-phase PWM duty cycle based on the actual hardware response characteristics of the circuit. This ensures that the sampling window always matches the setup time of the current conditioning link, fundamentally avoiding problems such as insufficient sampling window, current measurement deviation, and three-phase imbalance caused by inaccurate empirical settings. The compensation amount of this method has higher accuracy and applicability.
[0060] The above sampling method, by ensuring that the sampling window matches the dynamic hardware setup process and achieving periodic symmetrical sampling of the three-phase current, can effectively reduce harmonic components in the stator current, alleviate the torque ripple and electromagnetic noise they cause, and improve the stability, vibration, and acoustic performance of the compressor motor. During long-term operation or wide-range variable frequency operation of the permanent magnet synchronous motor, the compensation strategy of the above sampling method can maintain good current balance and current regulation quality, making the dynamic response of the drive system smoother and improving overall operating performance.
[0061] Furthermore, the aforementioned sampling method automatically derives the sampling window threshold and compensation amount based on hardware parameters, without relying on manual experience for debugging. This significantly reduces the parameter tuning complexity and development time of the control algorithm, improving product consistency and manufacturability. The sampling method can be implemented in software without requiring changes to existing hardware structures and modulation strategies, making it easy to port and apply. It is adaptable to different controller platforms, power levels, and permanent magnet synchronous motor compressor drive systems with different topologies, demonstrating good versatility and scalability.
[0062] In summary, the above sampling method offers significant advantages in terms of improved sampling accuracy, enhanced three-phase current balance, improved system stability, noise and vibration control, optimized energy efficiency, and reduced development costs. It helps address issues such as insufficient sampling window, current distortion, three-phase imbalance, large current reconstruction error, increased motor noise, and instability in certain operating ranges. Furthermore, it effectively improves the control performance and operational reliability of the compressor's permanent magnet synchronous motor drive system.
[0063] For further information, please refer to... Figure 2 As shown, the strategy for synchronously correcting the three-phase PWM duty cycle in step S3 is as follows: within each PWM control cycle, the three-phase PWM duty cycle is calculated according to the voltage command, and it is determined whether the duty cycle of each phase is less than the maximum allowable duty cycle. The system classifies operating conditions according to the number of phases that meet the condition and executes corresponding correction strategies based on the classification. After correction, the corrected voltage control signal is output, maintaining periodic symmetry, ensuring current balance, and achieving stable system operation. The sampling results are feature-calculated and compared with reference values. Then, the compensation bias is adaptively updated based on the deviation, achieving continuous compensation under dynamic hardware conditions.
[0064] Specifically, step S3 includes the following steps:
[0065] Step S3-1: Determine the duty cycle of the three-phase PWM Is it less than the maximum allowable duty cycle? And count the number of phases N that satisfy this condition;
[0066] Based on N, the operating conditions can be divided into three categories: all three phases meet the sampling window conditions (N=3); only one phase exceeds the duty cycle limit (N=2); and two or more phases exceed the duty cycle limit (N ≤ 1). Different strategies are executed based on different operating conditions.
[0067] If N is less than or equal to 1, it means that the PWM duty cycle of two or all three phases exceeds the maximum allowable duty cycle. At this point, it is necessary to synchronously correct the duty cycle of the three-phase PWM, so step S3-2 is executed;
[0068] If N=2, it means that the PWM duty cycle of one phase exceeds the maximum allowable duty cycle. The non-over-limit currents of the two phases are sampled and the over-limit currents are reconstructed using Kirchhoff's current law. At this time, step S3-3 is executed.
[0069] If N=3, it means that all three phases meet the duty cycle condition, and it is determined that all three phases PWM are in the allowable sampling range. At this time, no compensation or reconstruction is required, and direct sampling of the three phase current is performed, then step S3-4 is executed.
[0070] S3-2: PWM duty cycle for each phase In the process, the PWM duty cycle is sorted by numerical value and the middle value is selected as the target duty cycle. The target duty cycle value is then assigned to the maximum allowable duty cycle. For example, when If it becomes smaller in this way, then the one in the middle is considered. As the target duty cycle, update the maximum allowed duty cycle. , .
[0071] PWM duty cycle Corrected to and according to Generate drive signals, where
[0072]
[0073] Corrected three-phase duty cycle This ensures that the compensated sampling window time is not less than the minimum sampling time. This strategy aims to meet sampling window requirements and maintain a constant line voltage space vector and symmetrical PWM period under three-phase common-mode bias. It is designed to handle demanding conditions such as high modulation depth and high back voltage.
[0074] Then the obtained three-phase duty cycle The three-phase current is directly sampled according to steps S3-4 below to obtain the sampled three-phase current values as current feedback signals, and then the three-phase duty cycle is adjusted accordingly. Six PWM drive signals are generated and output to the compressor's permanent magnet synchronous motor.
[0075] In the actual correction process, you can refer to Figure 3 As shown. Figure 3 The upper middle figure shows the three-phase voltage and three-phase switch status before correction, and the lower figure shows the three-phase voltage and three-phase switch status after correction based on the upper figure.
[0076] Figure 3 The upper and middle diagrams correspond to the duty cycles of three-phase PWM. The corresponding voltages are respectively , as well as Maximum allowable duty cycle The corresponding voltage is The corresponding minimum sampling time at this time for The region below the intersection with the voltage curve.
[0077] Figure 3 The lower half of the diagram shows the correction of the duty cycle for the three-phase PWM. First, update... ,but = '. The corresponding minimum sampling time at this time for The region below the intersection with the voltage curve. And update. for When the switch state changes in the low-voltage region, both ends of the horizontal axis of the low-voltage region change. This increases the sampling area, ensuring that in the next sampling period, the sampling time of at least two phases is greater than or equal to the minimum sampling time. To meet the sampling window requirements.
[0078] S3-3: Perform current sampling on the two phases (not exceeding the limit) that meet the above conditions to obtain the current sampling values of the two phases. and At this point, instead of sampling the current of the other phase (the over-limit phase), a reconstruction strategy is applied to that phase. Based on the constraint that the sum of the three-phase currents is zero, the current of the other phase is reconstructed according to Kirchhoff's current law. Through current The current that replaces the current in another phase (the over-limit phase).
[0079]
[0080] Current and Together, they serve as the three-phase current feedback signal input to the vector controller, and are adjusted according to the three-phase duty cycle. Six PWM drive signals are generated and output to the compressor permanent magnet synchronous motor to complete the sampling and driving of the current PWM cycle.
[0081] S3-4: Simultaneously trigger three-phase current sampling at the preset symmetrical sampling time to obtain the three-phase current sampling values. The three-phase current is then used as a current feedback signal and input to the vector controller; simultaneously, according to... Six PWM drive signals are generated and output to the compressor permanent magnet synchronous motor to complete the sampling and driving of the current PWM cycle.
[0082] In steps S3-4, it is preferable to perform three-phase direct current sampling at the center of the carrier or at symmetrical positions on both sides of the carrier to ensure the stability of the conditioning link signal and reduce sampling jitter.
[0083] Regarding the sampling strategy, this application intelligently classifies sampling conditions based on the real-time calculated three-phase PWM duty cycle. Direct sampling can be performed when all three phases meet the sampling conditions. When only one phase's duty cycle exceeds the limit, it automatically switches to a "two-phase sampling combined with Kirchhoff's current law reconstruction" method. Under conditions where two or more phases exceed the limit, synchronous correction is performed on the three-phase PWM duty cycle based on the aforementioned duty cycle bias, ensuring that the corrected PWM waveform maintains zero-vector time period symmetry and meets the minimum sampling window requirement. This adaptive sampling compensation mechanism can stably provide accurate three-phase current feedback under complex conditions such as different modulation depths, high back voltage, high bus voltage fluctuations, and high-speed operation, significantly reducing errors caused by sampling point offset and improving the reliability and continuity of current sampling.
[0084] Furthermore, in step S3, the duty cycle offset is calculated through the following steps. and maximum allowable duty cycle ;
[0085] Calculate the minimum sampling time based on the hardware parameters. ;
[0086] After determining the minimum sampleable time, this embodiment compares it with the PWM period. After normalization, the duty cycle offset is obtained. :
[0087] ;
[0088] ;
[0089] in This is the PWM cycle time; This is the upper limit of the phase voltage duty cycle (maximum allowable duty cycle). When the duty cycle of a certain phase does not exceed this upper limit, its corresponding sampling window time is greater than or equal to... ;Will and The parameters are stored in the controller as software parameters and used for subsequent PWM duty cycle determination and compensation calculation.
[0090] The above maximum allowable duty cycle As a unified threshold for judging whether the PWM duty cycle meets the sampling window requirements, it is the core basis for the classification and compensation of sampling conditions.
[0091] The aforementioned minimum sampling time Calculate using the following steps;
[0092] The fundamental technical feature of this embodiment is the construction of a mathematical model of the current sampling window based on the dynamic characteristics of the hardware, in order to determine the minimum sampleable time that must be satisfied within a single PWM control cycle.
[0093] The model takes five incompressible time parameters in the current conditioning link as input, including operational amplifier settling time. Feedback network establishment time Analog-to-digital converter sampling time Drive dead zone and safety margin time and power device delay time ;
[0094] .
[0095] The minimum sampleable time describes the minimum time required for the current conditioning link to stabilize before the signal stabilizes. It is the only physical basis for determining whether the PWM duty cycle has a valid sampling window. Without this mathematical model, it is impossible to calculate the duty cycle bias and the maximum allowable duty cycle, and it is also impossible to carry out subsequent operating condition classification and sampling compensation.
[0096] Among them, operational amplifier settling time The settling time is determined by the device bandwidth, output slew rate, and output amplitude. Specifically, it is the operational amplifier's settling time. Based on the gain-bandwidth product, input step change amplitude, and output slew rate of the operational amplifier, this method is used to characterize the time required for the output of the operational amplifier to reach a steady state after a change in the input.
[0097] The gain-bandwidth product (GBW) is the product of gain and bandwidth, and it determines the system's response speed. In operational amplifiers, the gain-bandwidth product GBW is related to the transconductance of each stage. and resistance Related to the product:
[0098]
[0099] For a two-stage amplifier design, the total gain-bandwidth product It is determined by the sum of the gain-bandwidth products of the first and second stages. Let's assume the gain-bandwidth product of the first stage... The second-stage gain-bandwidth product Then the total gain-bandwidth product is:
[0100]
[0101] Therefore, the total setup time It can be represented as:
[0102]
[0103] By adopting a common source, common gate (CSG) structure, the balance between gain and bandwidth is optimized, thereby effectively reducing the system setup time. .
[0104] The gain-bandwidth product (GBW) determines the system's response speed. This is achieved through proper design of the transconductance of each stage. , Source resistance and load resistance It can significantly improve the system's response speed and shorten the setup time while maintaining a high gain.
[0105] The setup time t2 of the feedback network is determined by the RC time constant. , The feedback resistor of the feedback network. This is the feedback capacitor of the feedback network.
[0106] Among them, the analog-to-digital converter sampling time It is determined by the sample-and-hold capacitance and the input impedance. ,in The sample-and-hold capacitor for the analog-to-digital converter. This is the input impedance of the analog-to-digital converter.
[0107] Among them, the drive dead time and safety margin time This is achieved through the configuration of the upper and lower bridge arms. The sum of the dead time configuration time for the upper and lower bridge arms of the driver and the additional safety margin is used to ensure that the switching devices do not shoot through.
[0108] Among them, the delay time of power devices It consists of turn-on delay and turn-off delay. ,in This refers to the turn-on delay time of the power device. This is the turn-off delay time of the power device.
[0109] This embodiment also provides a compressor motor current sampling system based on hardware compensation.
[0110] Combination Figure 4 The diagram shows the overall system structure. The current sampling signal conditioning module sends the three-phase current signal from the motor to the sampling system (a hardware-compensated compressor motor current sampling system). This sampling system corrects the three-phase PWM duty cycle and outputs it to the control and drive module. The control and drive module generates six PWM drive signals and outputs them to the compressor permanent magnet synchronous motor, completing the sampling and driving of the current PWM cycle. In addition, the motor is also connected to the control and drive module via an encoder module for convenient speed regulation.
[0111] Combination Figure 5 As shown, the sampling system described above in this embodiment includes:
[0112] The hardware parameter acquisition module is used to collect various hardware parameters of the circuit, such as the operational amplifier response speed (e.g., the operational amplifier's output slew rate, gain-bandwidth product, and input step change amplitude), feedback network bandwidth (e.g., the feedback resistor and feedback capacitor parameters of the feedback network), analog-to-digital converter sample-and-hold parameters (e.g., the analog-to-digital converter's sample-and-hold capacitor and input impedance), driver dead time (e.g., the dead time configuration time of the upper and lower bridge arms and the safety margin time), and power switch delay (e.g., the turn-on delay time and turn-off delay time of the power switch device).
[0113] The calculation module is connected to the hardware parameter acquisition module and receives the hardware parameters collected by the hardware parameter acquisition module. The calculation module is used to determine the maximum allowable duty cycle of the phase voltage based on the hardware parameters. and duty cycle offset The calculation module can construct a mathematical model of the current sampling window based on hardware parameters and dynamic hardware characteristics, and calculate the maximum allowable duty cycle based on this mathematical model. and duty cycle offset The specific calculation method is detailed in the above sampling method and will not be repeated here.
[0114] The sampling module is connected to the calculation module and receives the maximum allowable duty cycle calculated by the calculation module. and duty cycle offset The sampling module is used to acquire data for each PWM control cycle and calculate the three-phase PWM duty cycle. Specifically, it acquires data for each PWM control cycle, and within each PWM control cycle, it calculates the three-phase PWM duty cycle based on the d-axis and q-axis voltage commands or space voltage vectors obtained from vector control calculations. These three phases are denoted as the first phase duty cycle. Second phase duty cycle and the third duty cycle .
[0115] The compensation module is connected to the sampling module and receives the three-phase PWM duty cycle calculated by the sampling module. The compensation module synchronously corrects the three-phase PWM duty cycle based on the duty cycle bias, ensuring that the corrected three-phase PWM duty cycle meets the sampling window requirements, and generates a drive signal based on the corrected three-phase PWM duty cycle. Specifically, the sampling conditions can be intelligently classified based on the real-time calculated three-phase PWM duty cycle. Direct sampling can be performed when all three phases meet the sampling conditions. When only one phase's duty cycle exceeds the limit, it automatically switches to a "two-phase sampling combined with Kirchhoff's current law reconstruction" method. In cases where two or more phases exceed the limit, synchronous correction is performed on the three-phase PWM duty cycle based on the aforementioned duty cycle bias, ensuring that the corrected PWM waveform maintains zero-vector time period symmetry and meets the minimum sampling window requirements. The specific compensation strategy of the compensation module is detailed in step S3 above and will not be repeated here. The aforementioned adaptive sampling compensation mechanism can stably provide accurate three-phase current feedback under complex operating conditions such as different modulation depths, high back voltage, high bus voltage fluctuations, and high-speed operation, significantly reducing errors caused by sampling point offset and improving the reliability and continuity of current sampling.
[0116] In addition, the sampling system also includes a sampling execution and adaptive adjustment module and an environmental adaptive correction module. The sampling execution and adaptive adjustment module is connected to the compensation module, and the environmental adaptive correction module is connected to the sampling execution and adaptive adjustment module.
[0117] The sampling execution and adaptive adjustment module is used to perform feature calculations on the sampling results after correction and compare them with reference values. Then, it continues to adaptively update the compensation bias based on the deviation. The environmental adaptive adjustment module is used to implement continuous compensation under dynamic hardware conditions.
[0118] In summary, this invention provides a hardware-compensated method for sampling the current of a compressor permanent magnet synchronous motor, comprising the following steps: S1: acquiring various hardware parameters of the acquisition circuit; S2: determining the maximum allowable duty cycle of the phase voltage based on the hardware parameters. and duty cycle offset S3: In each PWM control cycle, calculate the three-phase PWM duty cycle, and synchronously correct the three-phase PWM duty cycle based on the duty cycle offset to ensure that the corrected three-phase PWM duty cycle meets the sampling window requirements.
[0119] The aforementioned sampling method incorporates various dynamic hardware parameters of the circuit into the current sampling process, constructing a mathematical model of the current sampling window based on the actual dynamic capabilities of the hardware. Compared to existing methods that rely on manual experience to set fixed sampling thresholds or fixed sampling windows, this method automatically determines the minimum sampleable time, the maximum allowable duty cycle, and a uniform duty cycle bias for compensating the three-phase PWM duty cycle based on the actual hardware response characteristics of the circuit. This ensures that the sampling window always matches the setup time of the current conditioning link, fundamentally avoiding problems such as insufficient sampling window, current measurement deviation, and three-phase imbalance caused by inaccurate empirical settings. The compensation amount of this method has higher accuracy and applicability.
[0120] The above sampling method, by ensuring that the sampling window matches the dynamic hardware setup process and achieving periodic symmetrical sampling of the three-phase current, can effectively reduce harmonic components in the stator current, alleviate the torque ripple and electromagnetic noise they cause, and improve the stability, vibration, and acoustic performance of the compressor motor. During long-term operation or wide-range variable frequency operation of the permanent magnet synchronous motor, the compensation strategy of the above sampling method can maintain good current balance and current regulation quality, making the dynamic response of the drive system smoother and improving overall operating performance.
[0121] The aforementioned sampling method automatically derives the sampling window threshold and compensation amount based on hardware parameters, without relying on manual experience for debugging. This significantly reduces the parameter tuning complexity and development time of the control algorithm, improving product consistency and manufacturability. The sampling method can be implemented in software without altering existing hardware structures and modulation strategies, making it easy to port and apply. It is adaptable to different controller platforms, power levels, and permanent magnet synchronous motor compressor drive systems with different topologies, demonstrating good versatility and scalability.
[0122] Regarding the sampling strategy, this application intelligently classifies sampling conditions based on the real-time calculated three-phase PWM duty cycle. Direct sampling can be performed when all three phases meet the sampling conditions. When only one phase's duty cycle exceeds the limit, it automatically switches to a "two-phase sampling combined with Kirchhoff's current law reconstruction" method. Under conditions where two or more phases exceed the limit, synchronous correction is performed on the three-phase PWM duty cycle based on the aforementioned duty cycle bias, ensuring that the corrected PWM waveform maintains zero-vector time period symmetry and meets the minimum sampling window requirement. This adaptive sampling compensation mechanism can stably provide accurate three-phase current feedback under complex conditions such as different modulation depths, high back voltage, high bus voltage fluctuations, and high-speed operation, significantly reducing errors caused by sampling point offset and improving the reliability and continuity of current sampling.
[0123] In summary, the above sampling method offers significant advantages in terms of improved sampling accuracy, enhanced three-phase current balance, improved system stability, noise and vibration control, optimized energy efficiency, and reduced development costs. It helps address issues such as insufficient sampling window, current distortion, three-phase imbalance, large current reconstruction error, increased motor noise, and instability in certain operating ranges. Furthermore, it effectively improves the control performance and operational reliability of the compressor's permanent magnet synchronous motor drive system.
[0124] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other.
[0125] The above description is merely a description of preferred embodiments of the present invention and is not intended to limit the scope of the present invention in any way. Any changes or modifications made by those skilled in the art based on the above disclosure shall fall within the protection scope of the claims.
Claims
1. A method for sampling compressor motor current based on hardware compensation, characterized in that, Includes the following steps: S1: Various hardware parameters of the acquisition circuit; S2: Determine the maximum allowable duty cycle of the phase voltage based on the aforementioned hardware parameters. and duty cycle offset ; S3: In each PWM control cycle, calculate the three-phase PWM duty cycle, and synchronously correct the three-phase PWM duty cycle based on the duty cycle bias to ensure that the corrected three-phase PWM duty cycle meets the sampling window requirements.
2. The compressor motor current sampling method based on hardware compensation as described in claim 1, characterized in that, Step S3 includes the following steps: Step S3-1: Determine the duty cycle of the three-phase PWM Is it less than the maximum allowable duty cycle? And count the number of phases N that meet the condition; if N is less than or equal to 1, then execute step S3-2; S3-2: PWM duty cycle for each phase In the process, the PWM duty cycle is sorted by numerical value and the middle value is selected as the target duty cycle. The target duty cycle value is then assigned to the maximum allowable duty cycle. ; PWM duty cycle Corrected to and according to Generate drive signals, where 。 3. The compressor motor current sampling method based on hardware compensation as described in claim 2, characterized in that, In step S3-1, if N=2, then step S3-3 is executed; S3-3: Perform current sampling on the two phases that meet the above conditions to obtain the two-phase current sampling values. and Reconstruct the current of another phase ; Current and Together, they serve as the three-phase current feedback signal input to the vector controller, and are adjusted according to the three-phase duty cycle. Generate driving signals.
4. The compressor motor current sampling method based on hardware compensation as described in claim 2, characterized in that, In step S3-1, if N=3, then step S3-4 is executed; S3-4: Sample the three-phase currents to obtain the sampled three-phase current values. The three-phase current is then used as a current feedback signal and input to the vector controller, according to... Generate driving signals.
5. The compressor motor current sampling method based on hardware compensation as described in claim 1, characterized in that, The hardware parameters collected in step S1 include: operational amplifier response speed, feedback network bandwidth, analog-to-digital converter sample-and-hold parameters, driver dead time, and power switch delay.
6. The compressor motor current sampling method based on hardware compensation as described in claim 1, characterized in that, In step S2, the duty cycle offset is calculated through the following steps. ; Calculate the minimum sampling time based on the hardware parameters. ; By small sampling time Calculate duty cycle offset , ; in This represents the PWM cycle time.
7. The compressor motor current sampling method based on hardware compensation as described in claim 6, characterized in that, The minimum sampling time Calculate using the following steps; Calculate the operational amplifier settling time based on the hardware parameters. Feedback network establishment time Analog-to-digital converter setup time Drive dead time and safety margin time Power switching delay time ; 。 8. The compressor motor current sampling method based on hardware compensation as described in claim 7, characterized in that, operational amplifier settling time Based on the gain-bandwidth product, input step change amplitude, and output slew rate of the operational amplifier, this method is used to characterize the time required for the output of the operational amplifier to reach a steady state after the input changes. And / or, ,in The feedback resistor of the feedback network. The feedback capacitor is used for the feedback network. And / or, ,in The sample-and-hold capacitor for the analog-to-digital converter. This is the input impedance of the analog-to-digital converter; And / or, the The sum of the dead time configuration for the upper and lower bridge arms of the driver and the additional safety margin; And / or, ,in This refers to the turn-on delay time of the power device. This is the turn-off delay time of the power device.
9. The compressor motor current sampling method based on hardware compensation as described in claim 6, characterized in that, In step S2 .
10. A compressor motor current sampling system based on hardware compensation, characterized in that, include: The hardware parameter acquisition module is used to collect various hardware parameters of the circuit. The calculation module is used to determine the maximum allowable duty cycle of the phase voltage based on the hardware parameters. and duty cycle offset ; The sampling module is used to collect data for each PWM control cycle and calculate the three-phase PWM duty cycle. The compensation module synchronously corrects the duty cycle of the three-phase PWM based on the duty cycle offset, so that the corrected three-phase PWM duty cycle meets the sampling window requirements.