Motor control method and device, motor, compressor and storage medium

By predicting and correcting the d-axis and q-axis currents of the motor and predicting and correcting the voltage, the problems of current sampling errors and harmonics in high-speed multi-pole motor controllers are solved, improving control performance and reducing the risk of failure.

CN118554818APending Publication Date: 2024-08-27GUANGDONG MEIZHI COMPRESSOR
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410613717.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-16
Publication Date
2024-08-27

AI Technical Summary

Technical Problem

Due to hardware limitations of high-speed multi-pole motor controllers, the control frequency is difficult to change, resulting in large current sampling harmonics and sampling errors, reducing control performance and increasing the risk of failure.

Method used

By predicting and correcting the d-axis current and q-axis current, the accurate current value at the preset control moment is obtained, and predicting and correcting the d-axis voltage and q-axis voltage to reduce the current sampling error and voltage command deviation, thereby improving control performance. .

Benefits of technology

It effectively reduces the current sampling error and current sampling harmonics, improves the control performance of the motor controller, and reduces the risk of failure.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118554818A
    Figure CN118554818A
Patent Text Reader

Abstract

The invention discloses a motor control method and device, a motor, a compressor and a storage medium, and the motor control method comprises the steps: obtaining d-axis current and q-axis current of the motor at a preset sampling moment; predicting a d-axis predicted current and a q-axis predicted current of the motor at a preset control moment according to the d-axis current and the q-axis current, the preset control moment being later than the preset sampling moment; determining a d-axis voltage and a q-axis voltage according to the d-axis predicted current, the q-axis predicted current, the d-axis current given value and the q-axis current given value; predicting a d-axis predicted voltage and a q-axis predicted voltage of the motor at a preset control moment according to the d-axis voltage and the q-axis voltage; and controlling the motor at a preset control moment based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage. According to the method, the problem of poor control performance caused by sampling errors and current sampling harmonic waves is solved, so that the control performance of the motor controller is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of motor technology, and in particular to a motor control method, device, motor, compressor and storage medium. Background Art

[0002] In the related art, the control frequency of the controller of the high-speed multi-pole motor is usually limited by hardware conditions and cannot change significantly with the change of the motor topology, especially in medium and large power drive products. When designing the controller of the high-speed multi-pole motor, a complete motor cycle includes fewer control and sampling cycles, and there are current sampling harmonics and large sampling errors, which reduce the control performance of the controller and increase the risk of operation failure. Summary of the invention

[0003] The present invention aims to solve one of the technical problems in the related art to at least a certain extent. To this end, the first purpose of the present invention is to propose a motor control method, which predicts and corrects the d-axis current and the q-axis current to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and predicts and corrects the d-axis voltage and the q-axis voltage to reduce the deviation of the voltage command, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and thus improving the control performance of the motor controller.

[0004] A second object of the present invention is to provide a computer-readable storage medium.

[0005] The third objective of the present invention is to provide a motor controller.

[0006] A fourth objective of the present invention is to provide a motor control device.

[0007] A fifth object of the present invention is to provide a motor.

[0008] A sixth object of the present invention is to provide a compressor.

[0009] To achieve the above-mentioned purpose, a motor control method is proposed according to an embodiment of the first aspect of the present invention, including: obtaining the d-axis current and q-axis current of the motor at a preset sampling moment; predicting the d-axis predicted current and q-axis predicted current of the motor at a preset control moment based on the d-axis current and the q-axis current, wherein the preset control moment is later than the preset sampling moment; determining the d-axis voltage and the q-axis voltage based on the d-axis predicted current, the q-axis predicted current, the d-axis current given value and the q-axis current given value; predicting the d-axis predicted voltage and the q-axis predicted voltage of the motor at a preset control moment based on the d-axis voltage and the q-axis voltage; and controlling the motor at the preset control moment based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage.

[0010] According to the motor control method of an embodiment of the present invention, the d-axis current and q-axis current of the motor at a preset sampling moment are obtained, and the d-axis predicted current and q-axis predicted current of the motor at a preset control moment are predicted based on the d-axis current and q-axis current, and the d-axis voltage and q-axis voltage are determined based on the d-axis predicted current, the q-axis predicted current, the d-axis current given value and the q-axis current given value, and the d-axis predicted voltage and q-axis predicted voltage of the motor at a preset control moment are predicted based on the d-axis voltage and q-axis voltage, and the motor is controlled at a preset control moment based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage, wherein the preset control moment is later than the preset sampling moment. Therefore, because the preset control time is later than the preset sampling time, there is a large sampling error in the d-axis current and the q-axis current. Therefore, by predicting the d-axis current and the q-axis current, the accurate d-axis current and the q-axis current at the preset control time can be obtained. When the motor is controlled according to the voltage vector, the actual voltage vector also has deviations. Therefore, it is necessary to predict and correct the d-axis voltage and the q-axis voltage to obtain the d-axis predicted voltage and the q-axis predicted voltage, and then based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage at the preset control time, the motor is accurately controlled, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, thereby improving the control performance of the motor controller and reducing the risk of failure.

[0011] According to one embodiment of the present invention, the preset sampling moment includes a first preset sampling moment and a second preset sampling moment, wherein the first preset sampling moment and the second preset sampling moment are in the same control cycle, and the second preset sampling moment is later than the first preset sampling moment.

[0012] According to an embodiment of the present invention, the first preset sampling time is at a rising edge of the carrier, and the second preset sampling time is at a falling edge of the carrier, and they are symmetrical.

[0013] According to one embodiment of the present invention, the preset control moment includes a first preset control moment and a second preset control moment, wherein the first preset control moment is later than the first preset sampling moment and earlier than the second preset control moment, the second preset control moment is later than the second preset sampling moment, the motor at the first preset control moment is controlled based on the d-axis current and the q-axis current at the first preset sampling moment, and the motor at the second preset control moment is controlled based on the d-axis current and the q-axis current at the second preset sampling moment.

[0014] According to one embodiment of the present invention, the d-axis predicted current and the q-axis predicted current are calculated according to the following formula: in, Id_tp is the predicted d-axis current, Iq_tp is the predicted q-axis current, Rs is the stator resistance, Ld and Lq are the direct-axis component and quadrature-axis component of the stator inductance, Id_tsa is the d-axis current, Iq_tsa is the q-axis current, Ts is the control period of the motor, ud_mean is the predicted voltage of the d-axis, uq_mean is the predicted voltage of the q-axis, ψ f is the permanent magnet flux, ω e is the electrical angular velocity.

[0015] According to one embodiment of the present invention, the d-axis predicted voltage and the q-axis predicted voltage are calculated according to the following formula: Among them, Vd_mean is the predicted voltage of the d-axis, Vq_mean is the predicted voltage of the q-axis, Vd is the d-axis voltage, Vq is the q-axis voltage, Ts is the control period of the motor, ψ f is the permanent magnet flux, ω e is the electrical angular velocity, and β is a preset parameter.

[0016] According to an embodiment of the present invention, the value range of the preset parameter is 0-1.

[0017] According to one embodiment of the present invention, vector control of a motor is performed at a preset control time based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage, including: performing position observation on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage to obtain the actual speed of the motor at the preset control time; and controlling the motor at the preset control time based on the actual speed and the given speed.

[0018] To achieve the above objective, according to a second aspect of the present invention, a computer-readable storage medium is provided, on which a motor control program is stored. When the program is executed by a processor, the motor control method of any of the above embodiments is implemented.

[0019] According to the computer-readable storage medium of an embodiment of the present invention, by executing the computer program of the above-mentioned motor control method, the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and by predicting and correcting the d-axis voltage and the q-axis voltage, the deviation of the voltage command is reduced, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0020] To achieve the above-mentioned purpose, according to an embodiment of the third aspect of the present invention, a motor controller is proposed, comprising: a memory, a processor, and a motor control program stored in the memory and executable on the processor. When the processor executes the program, the motor control method of any of the above-mentioned embodiments is implemented.

[0021] According to the motor controller of the embodiment of the present invention, a computer program of the motor control method is executed by a processor, and the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and the deviation of the voltage command is reduced by predicting and correcting the d-axis voltage and the q-axis voltage, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0022] To achieve the above-mentioned purpose, a motor control device is proposed according to an embodiment of the fourth aspect of the present invention, including: an acquisition module, used to acquire the d-axis current and q-axis current of the motor at a preset sampling time; a first prediction module, used to predict the d-axis predicted current and q-axis predicted current of the motor at a preset control time based on the d-axis current and the q-axis current, wherein the preset control time is later than the preset sampling time; a determination module, used to determine the d-axis voltage and the q-axis voltage based on the d-axis predicted current, the q-axis predicted current, the d-axis current given value and the q-axis current given value; a second prediction module, used to predict the d-axis predicted voltage and the q-axis predicted voltage of the motor at a preset control time based on the d-axis voltage and the q-axis voltage; and a control module, used to control the motor at a preset control time based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage.

[0023] According to the motor control device of the embodiment of the present invention, the d-axis current and q-axis current of the motor at a preset sampling moment are acquired through an acquisition module, and the d-axis predicted current and q-axis predicted current of the motor at a preset control moment are predicted according to the d-axis current and q-axis current through a first prediction module, and the d-axis voltage and q-axis voltage are determined according to the d-axis predicted current, the q-axis predicted current, the d-axis current given value and the q-axis current given value through a determination module, and the d-axis predicted voltage and q-axis predicted voltage of the motor at a preset control moment are predicted according to the d-axis voltage and q-axis voltage through a second prediction module, and the motor is controlled at a preset control moment based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage through a control module, wherein the preset control moment is later than the preset sampling moment. Therefore, because the preset control time is later than the preset sampling time, there is a large sampling error in the d-axis current and the q-axis current. Therefore, by predicting the d-axis current and the q-axis current, the accurate d-axis current and the q-axis current at the preset control time can be obtained. When the motor is controlled according to the voltage vector, the actual voltage vector also has deviations. Therefore, it is necessary to predict and correct the d-axis voltage and the q-axis voltage to obtain the d-axis predicted voltage and the q-axis predicted voltage, and then based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage at the preset control time, the motor is accurately controlled, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, thereby improving the control performance of the motor controller and reducing the risk of failure.

[0024] To achieve the above-mentioned objective, a motor is proposed according to a fifth aspect of the present invention, comprising: the aforementioned motor controller or the aforementioned motor control device.

[0025] According to the motor of the embodiment of the present invention, by adopting the above-mentioned motor controller or motor control device, the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and by predicting and correcting the d-axis voltage and the q-axis voltage, the deviation of the voltage command is reduced, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0026] To achieve the above-mentioned purpose, a compressor is proposed according to a sixth aspect of the present invention, comprising: the aforementioned motor controller, or the aforementioned motor control device, or the aforementioned motor.

[0027] According to the compressor of the embodiment of the present invention, by adopting the above-mentioned motor controller or motor control device or motor, the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and by predicting and correcting the d-axis voltage and the q-axis voltage, the deviation of the voltage command is reduced, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0028] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] Figure 1 is a timing diagram of the control moment of the current sampling moment in the related art;

[0030] Figure 2 is a schematic diagram of the error between the a-phase current at the sampling moment and the actual a-phase current at the control moment in the related art;

[0031] Figure 3 is a schematic diagram of the error between the c-phase current at the sampling moment and the actual c-phase current at the control moment in the related art;

[0032] Figure 4 is a flow chart of a motor control method according to an embodiment of the present invention;

[0033] Figure 5 is a schematic diagram of current correction according to an embodiment of the present invention;

[0034] Figure 6 is a schematic diagram of a current controller according to an embodiment of the present invention;

[0035] Figure 7 is a schematic diagram of a current controller according to another embodiment of the present invention;

[0036] Figure 8 is a schematic diagram of the speed of a motor control method using an embodiment of the present invention;

[0037] Fig. 9 is a timing diagram of two sampling moments and two control moments according to an embodiment of the present invention;

[0038] Fig.10 is a schematic diagram of two current corrections according to an embodiment of the present invention;

[0039] Fig.11 is a system schematic diagram of a motor controller according to an embodiment of the present invention;

[0040] Fig.12 is a system schematic diagram of a motor control device according to an embodiment of the present invention;

[0041] Fig.13 and Fig.14 is a system schematic diagram of a motor according to an embodiment of the present invention;

[0042] Figure 15-17 is a system schematic diagram of a compressor according to an embodiment of the present invention. DETAILED DESCRIPTION

[0043] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.

[0044] In the related art, taking the motor current sampling method through a single resistor as an example, the motor current sampling time and control time in each control cycle are as follows: Figure 1 As shown, the duration of each control cycle is Ts, and Sa, Sb and Sc are driving signals of the a-phase upper bridge arm, the b-phase upper bridge arm and the c-phase upper bridge arm respectively. Figure 1 As shown, the a-phase current Ia_s is sampled at time T0, the c-phase current Ic_s is sampled at time T1, and the b-phase current Ib_s is calculated based on the a-phase current Ia_s and the c-phase current Ic_s to obtain the three-phase current. The motor controller controls the motor based on the sampled three-phase current at the control time (i.e., time Tp).

[0045] However, there is an obvious delay between the Tp moment and the sampling moment, so there is an obvious sampling error between the three-phase current at the Tp moment and the three-phase current obtained by sampling. Figure 2 The a-phase current error Ia_error between the a-phase current Ia_s sampled at time T0 and the actual a-phase current Ia_control at time Tp is shown. Figure 3 The c-phase current error Ic_error between the c-phase current Ic_s sampled at time T1 and the actual c-phase current Ic_control at time Tp is shown. Therefore, the motor controller performs control based on the three-phase current with a large error, resulting in poor control performance and a risk of operating failure. In addition, there are harmonic problems in the sampled three-phase current.

[0046] Based on this, an embodiment of the present invention provides a motor control method, device, motor, compressor and storage medium, which obtains the correct d-axis predicted current and q-axis predicted current at a preset control moment by predicting and correcting the d-axis current and the q-axis current, thereby reducing the current sampling error and current sampling harmonics, and reduces the deviation of the voltage command by predicting and correcting the d-axis voltage and the q-axis voltage, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0047] The motor control method, device, motor, compressor and storage medium according to the embodiments of the present invention are described below with reference to the accompanying drawings.

[0048] Figure 4 FIG. 1 is a flow chart of a motor control method according to an embodiment of the present invention. Figure 4 As shown, the motor control method includes the following steps:

[0049] S101, obtaining the d-axis current and q-axis current of the motor at a preset sampling time.

[0050] Specifically, the three-phase current of the motor at a preset sampling time is sampled, and then the three-phase sampled current is transformed by Clarke to obtain the α-axis current and the β-axis current, and then the α-axis current and the β-axis current are transformed by Park to obtain the d-axis current and the q-axis current.

[0051] It should be noted that the three-phase current of the motor can be sampled by a single-resistance sampling method in the relevant technology, or by a dual-resistance sampling method or a three-resistance sampling method, and there is no specific limitation here.

[0052] S102, predicting a d-axis predicted current and a q-axis predicted current of the motor at a preset control time according to the d-axis current and the q-axis current, wherein the preset control time is later than the preset sampling time.

[0053] Specifically, Figure 5 As shown, because the preset control moment is later than the preset sampling moment, there is an error between the d-axis current Id_tsa and the q-axis current Iq_tsa corresponding to the preset control moment and the d-axis current Id_tp and the q-axis current Iq_tp corresponding to the preset sampling moment. Therefore, it is necessary to perform prediction and correction on the d-axis current Id_tsa and the q-axis current Iq_tsa sampled at the preset sampling moment to obtain accurate d-axis predicted current Id_tp and q-axis predicted current Iq_tp at the preset control moment.

[0054] In some embodiments, the d-axis predicted current Id_tp and the q-axis predicted current Iq_tp are calculated according to the following formula (1):

[0055]

[0056] in, Id_tp is the predicted d-axis current, Iq_tp is the predicted q-axis current, Rs is the stator resistance, Ld and Lq are the direct-axis component and quadrature-axis component of the stator inductance, Id_tsa is the d-axis current, Iq_tsa is the q-axis current, Ts is the control period of the motor, ud_mean is the predicted voltage of the d-axis, uq_mean is the predicted voltage of the q-axis, ψ f is the permanent magnet flux, ω e is the electrical angular velocity.

[0057] Specifically, formula (1) is constructed based on the relationship between the motor voltage and the motor current. The predicted voltage ud_mean of the d-axis is the d-axis voltage corresponding to the predicted current Id_tp, and the predicted voltage uq_mean of the q-axis is the q-axis voltage corresponding to the predicted current Iq_tp. Therefore, substituting the d-axis current Id_tsa and the q-axis current Iq_tsa into formula (1) can obtain the predicted current Id_tp and the q-axis current Iq_tp.

[0058] S103, determining a d-axis voltage and a q-axis voltage according to the d-axis predicted current, the q-axis predicted current, the d-axis current given value, and the q-axis current given value.

[0059] Specifically, closed-loop feedback control is performed according to the d-axis predicted current, the q-axis predicted current, the d-axis current set value and the q-axis current set value, and the d-axis predicted current and the d-axis current set value as well as the q-axis predicted current and the q-axis current set value are respectively input into the current controller to obtain the d-axis voltage and the q-axis voltage.

[0060] It should be noted that the current controller can be a plurality of feedback controllers, or a combination of a plurality of feedback controllers, and there is no specific limitation here.

[0061] For example, suppose the current controller is Figure 6 and Figure 7 The PI (Proportional Integral) controller shown in FIG. The generation process of the d-axis voltage Vd and the q-axis voltage Vq is as follows: Figure 6 As shown, the first difference between the d-axis given current Id_REF and the d-axis predicted current Id_tp is determined, and the first difference is input to the PI controller to obtain the d-axis voltage Vd; as shown Figure 7 As shown, a second difference between the q-axis given current Iq_REF and the q-axis predicted current Iq_tp is determined, and the second difference is input into the PI controller to obtain the q-axis voltage Vq.

[0062] S104, predicting a d-axis predicted voltage and a q-axis predicted voltage of the motor at a preset control time according to the d-axis voltage and the q-axis voltage.

[0063] Specifically, the motor controller inputs the d-axis voltage and the q-axis voltage to the pulse width modulation module at the preset control time, and the pulse width modulation module generates a drive signal according to the d-axis voltage and the q-axis voltage, and drives the inverter of the motor through the drive signal, thereby driving the motor to run. There is a delay between the preset control time and the motor responding to the d-axis voltage and the q-axis voltage, resulting in a deviation in the actual voltage vector command. Therefore, the d-axis voltage and the q-axis voltage are predicted to obtain accurate d-axis predicted voltage and q-axis predicted voltage.

[0064] In some embodiments, the d-axis predicted voltage and the q-axis predicted voltage are calculated according to the following formula (2):

[0065]

[0066] Among them, Vd_mean is the predicted voltage of the d-axis, Vq_mean is the predicted voltage of the q-axis, Vd is the d-axis voltage, Vq is the q-axis voltage, Ts is the control period of the motor, ψ f is the permanent magnet flux, ω e is the electrical angular velocity, and β is a preset parameter.

[0067] That is, the d-axis voltage and the q-axis voltage are substituted into formula (2) to correct the d-axis voltage and the q-axis voltage to obtain the d-axis predicted voltage and the q-axis predicted voltage.

[0068] Furthermore, in some embodiments, the value range of the preset parameter is 0-1.

[0069] It should be noted that the preset parameters can be used to simulate the delay characteristics of the motor responding to the voltage vector in actual applications. The preferred value of the preset parameters is 0.5, at which time the d-axis predicted voltage and q-axis predicted voltage obtained by formula (2) are closest to the voltage vector of the motor in actual applications.

[0070] S105 , controlling the motor at a preset control time based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage, and the q-axis predicted voltage.

[0071] Specifically, because the d-axis predicted current, q-axis predicted current, d-axis predicted voltage and q-axis predicted voltage are accurate vector signals of the motor at a preset control moment, precise control of the motor can be achieved based on the d-axis predicted current, q-axis predicted current, d-axis predicted voltage and q-axis predicted voltage.

[0072] In the above embodiment, the sampled d-axis current and q-axis current are predicted to obtain accurate d-axis predicted current and q-axis predicted current at a preset control moment, thereby reducing the current sampling error and the amplitude of the current sampling fundamental wave; further, the d-axis voltage and q-axis voltage are obtained based on the d-axis predicted current and the q-axis predicted current. Since there is a delay in the control of the motor in actual applications, the d-axis voltage and the q-axis voltage are predicted to obtain the d-axis predicted voltage and the q-axis predicted voltage, thereby eliminating the influence of the motor delay characteristics. Therefore, based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage, the motor can be accurately controlled, thereby improving the control performance of the motor controller and reducing the risk of operating failures.

[0073] In some embodiments, vector control of the motor is performed at a preset control time based on the d-axis predicted current, q-axis predicted current, d-axis predicted voltage and q-axis predicted voltage, including: performing position observation on the d-axis predicted current, q-axis predicted current, d-axis predicted voltage and q-axis predicted voltage to obtain the actual speed of the motor at the preset control time; and controlling the motor at the preset control time based on the actual speed and the given speed.

[0074] Specifically, a position observer can be pre-built, and then the d-axis predicted current, q-axis predicted current, d-axis predicted voltage, and q-axis predicted voltage are input into the position observer. The position observer outputs the actual speed and actual rotor position of the motor at the preset control time, and then the motor is controlled at the preset control time according to the actual speed and the given speed. The position observer can use a full-order Romberg observer, and the general form of the Romberg observer is shown in formula (3):

[0075]

[0076] Based on formula (3), the error coordinate model (4) in the rotating synchronous coordinate system is constructed:

[0077]

[0078] in, is the d-axis voltage in the error coordinate system, is the q-axis voltage in the error coordinate system, is the mechanical angular velocity, Ls is the stator inductance, is the d-axis current in the error coordinate system, is the q-axis current in the error coordinate system, p is the differential operator, is the d-axis back EMF error, is the q-axis back EMF error, is the total flux linkage of the motor, is the rotor position error.

[0079] In order to meet the requirements of high-frequency speed harmonic observation and consider the stability of the observer, the bandwidth ω0 is set to 300 Hz and the damping ξ is equal to 1.0. Therefore, the feedback gain matrix L of the full-order Romberg observer is determined.

[0080] Then, by observing the rotor position error, the actual rotor position and actual speed can be obtained, and then the motor can be controlled according to the actual speed and the given speed. Figure 8 FIG. 1 shows a schematic diagram of the speed of a motor control method according to an embodiment of the present invention. Figure 8 It can be seen that the error between the actual speed and the given speed is small.

[0081] In the above embodiment, because the actual speed is obtained based on accurate d-axis predicted current, q-axis predicted current, d-axis predicted voltage and q-axis predicted voltage, the error of the actual speed is small and a better control effect can be achieved.

[0082] In some embodiments, the preset sampling moment includes a first preset sampling moment and a second preset sampling moment, wherein the first preset sampling moment and the second preset sampling moment are in the same control cycle, and the second preset sampling moment is later than the first preset sampling moment.

[0083] It is understandable that current sampling can be performed twice within one control cycle, thereby increasing the sampling frequency and obtaining a more accurate current.

[0084] Taking the current sampling method of the dual-resistance sampling method or the three-resistance sampling method as an example, because the dual-resistance sampling method or the three-resistance sampling method performs a current sampling once to obtain the three-phase current of the motor, therefore, the three-phase current sampling is performed at the first preset sampling time to obtain the first three-phase current at the first preset sampling time, and the first three-phase current is coordinate-transformed to obtain the first d-axis current and the first q-axis current, and then the second preset sampling time is performed to obtain the second three-phase current at the second preset sampling time, and the second three-phase current is coordinate-transformed to obtain the second d-axis current and the second q-axis current.

[0085] Taking the current sampling method as a single resistor sampling method as an example, the single resistor sampling method needs to perform current sampling twice to obtain two-phase currents, and then reconstruct the third-phase current based on the two-phase currents. Fig. 9As shown, the a-phase current is sampled at time T0 to obtain the first a-phase current Ia_s0, and the c-phase current is sampled at time T1 to obtain the first c-phase current Ic_s0. Because time T0 and time T1 are relatively close, they can be considered as two-phase currents at the same time. Then, the first b-phase current is reconstructed to obtain the first three-phase current at the first preset sampling time. Then, the a-phase current is sampled at time T2 to obtain the second a-phase current Ia_s1. At time T3, the c-phase current is sampled to obtain the second c-phase current Ic_s1. Because time T2 and time T3 are relatively close, they can be considered as two-phase currents at the same time. Then, the second b-phase current is reconstructed to obtain the second three-phase current at the first preset sampling time.

[0086] Further, in some embodiments, Fig. 9 As shown, the first preset sampling time is at the rising edge of the carrier, and the second preset sampling time is at the falling edge of the carrier, and they maintain symmetry.

[0087] Specifically, Fig. 9 As shown, the time from the first preset sampling moment to the midpoint of the control cycle (i.e., the moment corresponding to the carrier vertex) is the same as the time from the second preset sampling moment to the midpoint of the control cycle. This can effectively improve the problem of current sampling harmonics and obtain a more accurate sampling current.

[0088] In some embodiments, Fig. 9 and Fig.10 As shown, the preset control moment includes a first preset control moment and a second preset control moment, wherein the first preset control moment is later than the first preset sampling moment and earlier than the second preset control moment, the second preset control moment is later than the second preset sampling moment, the motor at the first preset control moment is controlled based on the d-axis current and the q-axis current at the first preset sampling moment, and the motor at the second preset control moment is controlled based on the d-axis current and the q-axis current at the second preset sampling moment.

[0089] Specifically, because a sampling moment is added in the same control cycle, a control moment can be added in the same control cycle. Because the first preset control moment is after the first preset sampling moment and before the second preset sampling moment, the motor is controlled based on the first d-axis current and the first q-axis current at the first preset sampling moment at the first preset control moment. Because the first preset control moment is after the second preset sampling moment, the motor is controlled based on the second d-axis current and the second q-axis current at the second preset sampling moment at the second preset control moment.

[0090] For example, if Fig.10As shown, formula (1) is used to predict the first d-axis current Id_tsa1 and the first q-axis current Iq_tsa1 at the first preset sampling moment, and the first d-axis predicted current Id_tp1 and the first q-axis predicted current Iq_tp1 of the motor at the first preset control moment are obtained. Then, the first d-axis voltage and the first q-axis voltage are obtained according to the first d-axis predicted current Id_tp1, the first q-axis predicted current Iq_tp1, the first d-axis current given value, and the first q-axis current given value. Then, formula (2) is used to predict the first d-axis voltage and the first q-axis voltage to obtain the first d-axis predicted voltage and the first q-axis predicted voltage. Then, based on the first d-axis predicted current Id_tp1, the first q-axis predicted current Iq_tp1, the first d-axis predicted voltage and the first q-axis predicted voltage, the motor is controlled at the first preset control moment.

[0091] Formula (1) is used to predict the second d-axis current Id_tsa2 and the second q-axis current Iq_tsa2 at the second preset sampling moment, and the second d-axis predicted current Id_tp2 and the second q-axis predicted current Iq_tp2 of the motor at the second preset control moment are obtained. Then, the second d-axis voltage and the second q-axis voltage are obtained according to the second d-axis predicted current Id_tp2, the second q-axis predicted current Iq_tp2, the second d-axis current given value, and the second q-axis current given value. Then, formula (2) is used to predict the second d-axis voltage and the second q-axis voltage to obtain the second d-axis predicted voltage and the second q-axis predicted voltage. Then, based on the second d-axis predicted current Id_tp2, the second q-axis predicted current Iq_tp2, the second d-axis predicted voltage and the second q-axis predicted voltage, the motor is controlled at the second preset control moment.

[0092] In an optional embodiment, if Fig. 9 and Fig.10 As shown, the first preset control moment is the midpoint moment of the control cycle, and the second preset control moment is the zero point moment of the control cycle.

[0093] In the above embodiment, because there are two sampling moments in the same control cycle, there are two control moments in the same control cycle, which increases the control frequency. This not only improves the delay problem of the motor controller, but also solves the problem of larger harmonics caused by fewer control cycles, thereby further improving the control performance of the motor controller.

[0094] In summary, according to the motor control method of the embodiment of the present invention, because the preset control moment is later than the preset sampling moment, there is a large sampling error in the d-axis current and the q-axis current. Therefore, by predicting the d-axis current and the q-axis current, the accurate d-axis current and the q-axis current at the preset control moment can be obtained. When the motor is controlled according to the voltage vector, the actual voltage vector also has deviations. Therefore, it is necessary to predict and correct the d-axis voltage and the q-axis voltage to obtain the d-axis predicted voltage and the q-axis predicted voltage, and then accurately control the motor at the preset control moment based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, thereby improving the control performance of the motor controller and reducing the risk of failure. Furthermore, since one sampling moment is added in the same control cycle, there are two control moments in the same control cycle, which increases the control frequency, not only improving the delay problem of the motor controller, but also solving the problem of large harmonics caused by fewer control cycles, thereby further improving the control performance of the motor controller.

[0095] Corresponding to the above embodiments, an embodiment of the present invention further provides a computer-readable storage medium on which a motor control program is stored. When the program is executed by a processor, the motor control method of any of the above embodiments is implemented.

[0096] According to the computer-readable storage medium of an embodiment of the present invention, by executing the computer program of the above-mentioned motor control method, the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and by predicting and correcting the d-axis voltage and the q-axis voltage, the deviation of the voltage command is reduced, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0097] Corresponding to the above embodiment, the embodiment of the present invention further provides a motor controller. Fig.11 As shown, the motor controller 100 includes: a memory 110, a processor 120, and a motor control program stored in the memory 110 and executable on the processor 120. When the processor 120 executes the program, the motor control method of any of the above embodiments is implemented.

[0098] According to the motor controller of the embodiment of the present invention, a computer program of the motor control method is executed by a processor, and the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and the deviation of the voltage command is reduced by predicting and correcting the d-axis voltage and the q-axis voltage, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0099] Corresponding to the above embodiment, an embodiment of the present invention further provides a motor control device. Fig.12 As shown, the motor control device includes: an acquisition module 10 , a first prediction module 20 , a determination module 30 , a second prediction module 40 and a control module 50 .

[0100] Among them, the acquisition module 10 is used to obtain the d-axis current and q-axis current of the motor at a preset sampling time; the first prediction module 20 is used to predict the d-axis predicted current and q-axis predicted current of the motor at a preset control time based on the d-axis current and the q-axis current, wherein the preset control time is later than the preset sampling time; the determination module 30 is used to determine the d-axis voltage and q-axis voltage based on the d-axis predicted current, the q-axis predicted current, the d-axis current given value and the q-axis current given value; the second prediction module 40 is used to predict the d-axis predicted voltage and q-axis predicted voltage of the motor at a preset control time based on the d-axis voltage and the q-axis voltage; the control module 50 is used to control the motor at a preset control time based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage.

[0101] In some embodiments, the preset sampling moment includes a first preset sampling moment and a second preset sampling moment, wherein the first preset sampling moment and the second preset sampling moment are in the same control cycle, and the second preset sampling moment is later than the first preset sampling moment.

[0102] In some embodiments, the first preset sampling time is at a rising edge of the carrier, and the second preset sampling time is at a falling edge of the carrier, and they maintain symmetry.

[0103] In some embodiments, the preset control moment includes a first preset control moment and a second preset control moment, wherein the first preset control moment is later than the first preset sampling moment and earlier than the second preset control moment, the second preset control moment is later than the second preset sampling moment, the motor at the first preset control moment is controlled based on the d-axis current and q-axis current at the first preset sampling moment, and the motor at the second preset control moment is controlled based on the d-axis current and q-axis current at the second preset sampling moment.

[0104] In some embodiments, the d-axis predicted current and the q-axis predicted current are calculated according to the following formula: in, Id_tp is the predicted d-axis current, Iq_tp is the predicted q-axis current, Rs is the stator resistance, Ld and Lq are the direct-axis component and quadrature-axis component of the stator inductance, Id_tsa is the d-axis current, Iq_tsa is the q-axis current, Ts is the control period of the motor, ud_mean is the predicted voltage of the d-axis, uq_mean is the predicted voltage of the q-axis, ψ f is the permanent magnet flux, ω e is the electrical angular velocity.

[0105] In some embodiments, the d-axis predicted voltage and the q-axis predicted voltage are calculated according to the following formula: Among them, Vd_mean is the predicted voltage of the d-axis, Vq_mean is the predicted voltage of the q-axis, Vd is the d-axis voltage, Vq is the q-axis voltage, Ts is the control period of the motor, ψ f is the permanent magnet flux, ω e is the electrical angular velocity, and β is a preset parameter.

[0106] In some embodiments, the value range of the preset parameter is 0-1.

[0107] In some embodiments, the control module 50 is also used to: perform position observation on the d-axis predicted current, q-axis predicted current, d-axis predicted voltage and q-axis predicted voltage to obtain the actual speed of the motor at a preset control time; and control the motor at a preset control time based on the actual speed and the given speed.

[0108] It should be noted that the specific implementation of the motor control device of the embodiment of the present invention corresponds one to one with the specific implementation of the motor control method of the aforementioned embodiment of the present invention, and will not be described in detail herein.

[0109] According to the motor control device of the embodiment of the present invention, the d-axis current and q-axis current of the motor at a preset sampling moment are acquired through an acquisition module, and the d-axis predicted current and q-axis predicted current of the motor at a preset control moment are predicted according to the d-axis current and q-axis current through a first prediction module, and the d-axis voltage and q-axis voltage are determined according to the d-axis predicted current, the q-axis predicted current, the d-axis current given value and the q-axis current given value through a determination module, and the d-axis predicted voltage and q-axis predicted voltage of the motor at a preset control moment are predicted according to the d-axis voltage and q-axis voltage through a second prediction module, and the motor is controlled at a preset control moment based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage through a control module, wherein the preset control moment is later than the preset sampling moment. Therefore, because the preset control time is later than the preset sampling time, there is a large sampling error in the d-axis current and the q-axis current. Therefore, by predicting the d-axis current and the q-axis current, the accurate d-axis current and the q-axis current at the preset control time can be obtained. When the motor is controlled according to the voltage vector, the actual voltage vector also has deviations. Therefore, it is necessary to predict and correct the d-axis voltage and the q-axis voltage to obtain the d-axis predicted voltage and the q-axis predicted voltage, and then based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage at the preset control time, the motor is accurately controlled, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, thereby improving the control performance of the motor controller and reducing the risk of failure.

[0110] Corresponding to the above embodiment, an embodiment of the present invention further provides a motor. Fig.13 and Fig.14 As shown, the motor 300 includes: the aforementioned motor controller 100 or the aforementioned motor control device 200 .

[0111] According to the motor of the embodiment of the present invention, by adopting the above-mentioned motor controller or motor control device, the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and by predicting and correcting the d-axis voltage and the q-axis voltage, the deviation of the voltage command is reduced, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0112] Corresponding to the above embodiment, the embodiment of the present invention further provides a compressor. Figures 15 to 17 As shown, the compressor 400 includes: the aforementioned motor controller 100 , or the aforementioned motor control device 200 , or the aforementioned motor 300 .

[0113] According to the compressor of the embodiment of the present invention, by adopting the above-mentioned motor controller or motor control device or motor, the d-axis current and the q-axis current are predicted and corrected to obtain the correct d-axis predicted current and q-axis predicted current at the preset control moment, thereby reducing the current sampling error and current sampling harmonics, and by predicting and correcting the d-axis voltage and the q-axis voltage, the deviation of the voltage command is reduced, thereby solving the problem of poor control performance caused by sampling errors and current sampling harmonics, and further improving the control performance of the motor controller.

[0114] It should be noted that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in combination with these instruction execution systems, devices or apparatuses. For the purposes of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in combination with these instruction execution systems, devices or apparatuses. More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection portion with one or more wirings (electronic device), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways if necessary, and then stored in a computer memory.

[0115] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0116] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.

[0117] In addition, the terms "first", "second", etc. used in the embodiments of the present invention are only used for descriptive purposes and should not be understood as indicating or implying relative importance, or implicitly indicating the number of technical features indicated in the present embodiment. Therefore, the features defined by the terms "first", "second", etc. in the embodiments of the present invention can explicitly or implicitly indicate that the embodiment includes at least one of the features. In the description of the present invention, the word "multiple" means at least two or two or more, such as two, three, four, etc., unless otherwise clearly and specifically defined in the embodiments.

[0118] In the present invention, unless otherwise clearly specified or limited in the embodiments, the terms "installed", "connected", "connected" and "fixed" etc. in the embodiments should be understood in a broad sense. For example, the connection can be a fixed connection, a detachable connection, or an integrated connection. It can be understood that it can also be a mechanical connection, an electrical connection, etc.; of course, it can also be a direct connection, or an indirect connection through an intermediate medium, or it can be the internal connection of two elements, or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to the specific implementation situation.

[0119] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.

Claims

1. A motor control method, characterized in that: include: Obtain the d-axis current and q-axis current of the motor at a preset sampling time; Predicting a d-axis predicted current and a q-axis predicted current of the motor at a preset control time according to the d-axis current and the q-axis current, wherein the preset control time is later than the preset sampling time; Determine the d-axis voltage and the q-axis voltage according to the d-axis predicted current, the q-axis predicted current, the d-axis current given value, and the q-axis current given value; Predicting a predicted d-axis voltage and a predicted q-axis voltage of the motor at the preset control time according to the d-axis voltage and the q-axis voltage; The motor is controlled at the preset control time based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage, and the q-axis predicted voltage.

2. The method according to claim 1, characterized in that The preset sampling time includes a first preset sampling time and a second preset sampling time, wherein the first preset sampling time and the second preset sampling time are in the same control cycle, and the second preset sampling time is later than the first preset sampling time.

3. The method according to claim 2, characterized in that The first preset sampling time is at a rising edge of the carrier, and the second preset sampling time is at a falling edge of the carrier, and they are kept symmetrical.

4. The method according to claim 3, characterized in that The preset control moment includes a first preset control moment and a second preset control moment, wherein the first preset control moment is later than the first preset sampling moment and earlier than the second preset control moment, the second preset control moment is later than the second preset sampling moment, the motor is controlled based on the d-axis current and the q-axis current at the first preset sampling moment at the first preset control moment, and the motor is controlled based on the d-axis current and the q-axis current at the second preset sampling moment at the second preset control moment.

5. The method according to any one of claims 1 to 4, characterized in that The d-axis predicted current and the q-axis predicted current are calculated according to the following formula: in, Id_tp is the predicted d-axis current, Iq_tp is the predicted q-axis current, Rs is the stator resistance, Ld and Lq are the direct-axis component and quadrature-axis component of the stator inductance, Id_tsa is the d-axis current, Iq_tsa is the q-axis current, Ts is the control period of the motor, ud_mean is the predicted voltage of the d-axis, uq_mean is the predicted voltage of the q-axis, ψ f is the permanent magnet flux, ω e is the electrical angular velocity.

6. The method according to any one of claims 1 to 4, characterized in that The d-axis predicted voltage and the q-axis predicted voltage are calculated according to the following formula: Wherein, Vd_mean is the predicted voltage of the d-axis, Vq_mean is the predicted voltage of the q-axis, Vd is the d-axis voltage, Vq is the q-axis voltage, Ts is the control period of the motor, ψ f is the permanent magnet flux, ω e is the electrical angular velocity, and β is a preset parameter.

7. The method according to claim 6, characterized in that The value range of the preset parameter is 0 to 1.

8. The method according to claim 1, characterized in that Performing vector control on the motor at the preset control time based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage, and the q-axis predicted voltage includes: Performing position observation on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage, and the q-axis predicted voltage to obtain an actual speed of the motor at the preset control time; The motor is controlled at the preset control time based on the actual rotation speed and the given rotation speed.

9. A computer-readable storage medium, characterized in that: A motor control program is stored thereon, and when the motor control program is executed by a processor, a motor control method according to any one of claims 1 to 8 is implemented.

10. A motor controller, characterized in that: include: A memory, a processor, and a motor control program stored in the memory and executable on the processor, wherein when the processor executes the motor control program, the motor control method according to any one of claims 1 to 8 is implemented.

11. A motor control device, characterized in that: include: An acquisition module is used to acquire the d-axis current and q-axis current of the motor at a preset sampling time; A first prediction module, configured to predict a d-axis predicted current and a q-axis predicted current of the motor at a preset control time according to the d-axis current and the q-axis current, wherein the preset control time is later than the preset sampling time; a determination module, configured to determine a d-axis voltage and a q-axis voltage according to the d-axis predicted current, the q-axis predicted current, a d-axis current given value, and a q-axis current given value; A second prediction module, used for predicting a d-axis predicted voltage and a q-axis predicted voltage of the motor at the preset control moment according to the d-axis voltage and the q-axis voltage; A control module is used to control the motor at the preset control time based on the d-axis predicted current, the q-axis predicted current, the d-axis predicted voltage and the q-axis predicted voltage.

12. A motor, characterized in that: include: The motor controller according to claim 10 or the motor control device according to claim 11.

13. A compressor, characterized in that: include: The motor controller according to claim 10, or the motor control device according to claim 11, or the motor according to claim 12.