Motor control method and device, motor, electronic water pump and vehicle

By setting fixed sampling windows at the rising and falling edges of the motor control signal and compensating for the other edge, the sampling error problem in the single-resistor current sampling method is solved, and the accuracy and stability of motor control are improved.

CN121055833APending Publication Date: 2025-12-02ANQING WELLING AUTO PARTS CO LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410693526.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-30
Publication Date
2025-12-02

AI Technical Summary

Technical Problem

In the existing technology, the single-resistor current sampling method has problems such as an unstable sampling window, large sampling error, difficulty in accurate current sampling, and impact on the accuracy and stability of motor control.

Method used

A fixed sampling window is set at one of the rising and falling edges of the motor control signal, and compensation is performed on the other edge to determine the sampling window of the single-resistance current detection circuit, thereby extending the effective voltage vector action time and improving sampling accuracy.

Benefits of technology

By using a fixed sampling window and edge compensation, current sampling errors are reduced, thereby improving the accuracy and stability of motor control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121055833A_ABST
    Figure CN121055833A_ABST
Patent Text Reader

Abstract

The invention discloses a motor control method and device, a motor, an electronic water pump and a vehicle, the motor control method is applied to a motor controller with a single-resistor current detection circuit, and the method comprises the following steps: determining a sampling window of the single-resistor current detection circuit, the sampling window is located at one of a rising edge of a motor control signal and a falling edge of the motor control signal; compensating the other one of the rising edge and the falling edge according to the sampling window to obtain a target edge; and controlling the motor according to one edge and the target edge. According to the method, the fixed current sampling window is arranged on one of the rising edge and the falling edge of the motor control signal, the current sampling error is reduced, the current sampling precision is improved, the other one of the rising edge and the falling edge of the motor control signal is correspondingly compensated, and the precision and the stability of the motor controller are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of motor technology, and in particular to a motor control method, device, motor, electronic water pump, and vehicle. Background Technology

[0002] In related technologies, current sampling methods mainly employ multi-resistor current sampling technology, which uses multiple resistors in the motor circuit to measure the current and then calculates the current value based on the relationship between voltage and resistance. Although this method is simple and easy to implement, it is prone to errors due to potential differences and temperature drift between resistors, affecting the accuracy and stability of current sampling.

[0003] To address the aforementioned issues and reduce hardware costs, a single-resistor current sampling technique has been employed. This technique involves using a single resistor in the inverter circuit to measure the current, and then calculating the current value based on the relationship between voltage and resistance. However, this technique has several drawbacks. For instance, the sampling window is not fixed, leading to significant sampling errors. Furthermore, the effective voltage vector in the low-modulation region and near switching areas has a short duration, making current sampling difficult. Summary of the Invention

[0004] This invention aims to at least partially solve one of the technical problems in related technologies. To this end, the first objective of this invention is to propose a motor control method that sets a fixed current sampling window at one edge of the rising and falling edges of the motor control signal, reducing current sampling errors and thus improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, improving the accuracy and stability of the motor controller.

[0005] A second objective of this invention is to provide a computer-readable storage medium.

[0006] The third objective of this invention is to provide a motor controller.

[0007] The fourth objective of this invention is to provide a motor control device.

[0008] The fifth objective of this invention is to provide an electric motor.

[0009] The sixth objective of this invention is to provide an electronic water pump.

[0010] The seventh objective of this invention is to provide a vehicle.

[0011] To achieve the above objectives, a motor control method is proposed according to a first aspect of the present invention, applied in a motor controller having a single-resistance current detection circuit. The method includes: determining a sampling window of the single-resistance current detection circuit, wherein the sampling window is located at one edge of the rising edge and the falling edge of the motor control signal; compensating the other edge of the rising edge and the falling edge according to the sampling window to obtain a target edge; and controlling the motor according to one edge and the target edge.

[0012] According to the motor control method of this invention, a sampling window for a single-resistor current detection circuit is determined. The sampling window is located at one of the rising and falling edges of the motor control signal. The other edge of the rising and falling edges is compensated based on the sampling window to obtain a target edge. The motor is then controlled based on one edge and the target edge. Thus, a fixed sampling window is set at one of the rising and falling edges of the motor control signal. The single-resistor current detection circuit samples the current within this sampling window, solving the problems of an unfixed sampling window and the difficulty in current sampling due to the short effective voltage vector duration. This reduces current sampling errors and improves current sampling accuracy. Because the sampling window is set at one of the rising and falling edges, the voltage vector duration at that edge is extended, requiring corresponding compensation for the other edge, thereby improving the accuracy and stability of the motor controller.

[0013] According to one embodiment of the present invention, the sampling window includes a first sampling window and a second sampling window, wherein determining the sampling window of the single-resistance current detection circuit includes: determining a first time interval between a first edge and a second edge of the motor control signal as the first sampling window; determining a second time interval between a second edge and a third edge of the motor control signal as the second sampling window, wherein the first time interval and the second time interval are respectively greater than or equal to the minimum sampling time, the times corresponding to the first edge, the second edge and the third edge increase sequentially, and the types of the first edge, the second edge and the third edge are the same.

[0014] According to one embodiment of the present invention, compensation for another edge among the rising and falling edges based on the sampling window includes: shifting the fourth edge of the motor control signal to the right by a first preset time, shifting the fifth edge of the motor control signal to the right by a second preset time, and keeping the sixth edge of the motor control signal unchanged, wherein the first preset time is greater than the second preset time, wherein the times corresponding to the fourth, fifth, and sixth edges increase sequentially, and the fourth, fifth, and sixth edges are of the same type and are different from the types of the first, second, and third edges.

[0015] According to one embodiment of the present invention, when the first time interval and the second time interval are respectively the minimum sampling time, the second preset time is the minimum sampling time, and the first preset time is twice the minimum sampling time.

[0016] According to one embodiment of the present invention, controlling a motor based on an edge and a target edge includes: determining a first comparison value based on the edge and determining a second comparison value based on the target edge; comparing a carrier wave with the first comparison value and the second comparison value respectively to generate a target motor control signal; and controlling the motor based on the target motor control signal.

[0017] According to one embodiment of the present invention, the motor control signal includes a three-phase motor control signal, wherein each phase motor control signal is a PWM signal.

[0018] According to one embodiment of the present invention, before determining the sampling window of the single-resistor current detection circuit, the method further includes: acquiring the target voltage vector of the motor; and determining the motor control signal based on the target voltage vector using a voltage modulation algorithm.

[0019] To achieve the above objectives, a computer-readable storage medium is provided according to a second aspect of the present invention, having stored thereon a motor control program that, when executed by a processor, implements the motor control method of any of the foregoing embodiments.

[0020] According to the computer-readable storage medium of the present invention, by executing the computer program of the above-described motor control method, a fixed current sampling window is set at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling error and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0021] To achieve the above objectives, a motor controller is provided according to a third aspect of the present invention, 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, it implements the motor control method of any of the foregoing embodiments.

[0022] According to the embodiment of the present invention, the motor controller executes the computer program of the above-described motor control method through a processor, and sets a fixed current sampling window at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling error and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0023] To achieve the above objectives, a motor control device is provided according to a fourth aspect of the present invention, applied in a motor controller having a single-resistance current detection circuit. The device includes: a determining module for determining a sampling window of the single-resistance current detection circuit, wherein the sampling window is located at one edge of the rising edge and the falling edge of the motor control signal; a compensation module for compensating the other edge of the rising edge and the falling edge according to the sampling window to obtain a target edge; and a control module for controlling the motor according to one edge and the target edge.

[0024] According to an embodiment of the present invention, the motor control device determines the sampling window of the single-resistor current detection circuit through a determining module. The sampling window is located at one of the rising and falling edges of the motor control signal. A compensation module compensates for the other edge of the rising and falling edges based on the sampling window to obtain a target edge. A control module controls the motor based on one edge and the target edge. Thus, a fixed sampling window is set at one of the rising and falling edges of the motor control signal. The single-resistor current detection circuit samples the current within this sampling window, solving the problems of an unfixed sampling window and the difficulty in current sampling due to the short effective voltage vector duration. This reduces current sampling errors and improves current sampling accuracy. Because the sampling window is set at one of the rising and falling edges, the voltage vector duration at that edge is prolonged, requiring corresponding compensation for the other edge, thereby improving the accuracy and stability of the motor controller.

[0025] To achieve the above objectives, a motor is provided according to a fifth aspect embodiment of the present invention, comprising: the aforementioned motor controller or the aforementioned motor control device.

[0026] According to the embodiments of the present invention, by employing the above-described motor controller or motor control device, a fixed current sampling window is set at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling errors and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0027] To achieve the above objectives, an electronic water pump is provided according to a sixth aspect embodiment of the present invention, including the aforementioned motor.

[0028] According to an embodiment of the present invention, the electronic water pump employs the aforementioned motor and sets a fixed current sampling window at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling errors and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, improving the accuracy and stability of the motor controller.

[0029] To achieve the above objectives, a vehicle comprising the aforementioned electronic water pump is provided according to a seventh aspect embodiment of the present invention.

[0030] According to the vehicle of the present invention, by employing the above-mentioned electronic water pump, a fixed current sampling window is set at one edge of the rising and falling edges of the motor control signal, which reduces the current sampling error and improves the current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0031] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description

[0032] Figure 1 This is a schematic diagram of the structure of a motor control system according to an embodiment of the present invention;

[0033] Figure 2 This is a schematic flowchart of a motor control method according to an embodiment of the present invention;

[0034] Figure 3 This is a schematic diagram of a sampling window according to an embodiment of the present invention;

[0035] Figure 4 This is a schematic diagram of compensation for falling edges according to an embodiment of the present invention;

[0036] Figure 5 This is a system schematic diagram of a motor controller according to an embodiment of the present invention;

[0037] Figure 6 This is a schematic diagram of the structure of a motor control device according to an embodiment of the present invention;

[0038] Figure 7 This is a schematic diagram of a motor system according to an embodiment of the present invention;

[0039] Figure 8 This is a schematic diagram of a motor system according to another embodiment of the present invention;

[0040] Figure 9 This is a schematic diagram of an electronic water pump system according to an embodiment of the present invention;

[0041] Figure 10 This is a schematic diagram of a vehicle system according to an embodiment of the present invention. Detailed Implementation

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

[0043] The following description, with reference to the accompanying drawings, describes an embodiment of the present invention, including a motor control method, apparatus, motor controller, motor, electronic water pump, vehicle, and storage medium.

[0044] It should be noted that the motor control method of this invention can be applied to... Figure 1 In the motor controller 30 shown, reference Figure 1 As shown, the motor control system includes an inverter 10, a motor 20, and a motor controller 30. The inverter 10 includes three-phase bridge arms, namely a U-phase bridge arm, a W-phase bridge arm, and a V-phase bridge arm, which are connected to the U-phase, W-phase, and V-phase of the motor M. The upper bridge arms of each of the three phase bridge arms are connected to the positive terminal of the DC power supply Vdc. The motor controller 30 includes a single-resistor current detection circuit 31 and a control chip 32. The single-resistor current detection circuit 31 includes a current-sensing resistor Rs, one end of which is connected to the negative terminal of the DC power supply Vdc, and the other end of which is connected to the lower bridge arm of each of the three phase bridge arms.

[0045] The control chip 32 is used to generate motor control signals based on the current speed, current, and desired speed of the motor 20, in order to drive and control the switching transistors in the inverter 10. The inverter 10 can convert the DC power supplied by the DC power supply Vdc into three-phase AC power, thereby controlling the rotation of the motor 20. The control logic can be various, such as two-to-two conduction or three-to-three conduction, etc. The specific control logic will not be elaborated here.

[0046] Figure 2 This is a schematic flowchart of a motor control method according to an embodiment of the present invention, as shown below. Figure 2 As shown, the motor control method includes:

[0047] S101, Determine the sampling window of the single-resistor current detection circuit, wherein the sampling window is located at one of the rising edge and falling edge of the motor control signal.

[0048] Specifically, a fixed sampling window is set at one of the rising and falling edges of the motor control signal. A first sampling point and a second sampling point are set in the sampling window. The single-resistance current detection circuit samples the current of one phase at the first sampling point to obtain the first current sampling value. The single-resistance current detection circuit samples the current of one phase at the second sampling point to obtain the second current sampling value. The phase of the current sampled at the first sampling point is different from the phase of the current sampled at the second sampling point. Since the sum of the three-phase currents of the motor is 0, the third phase current can be obtained from the first and second current sampling values, thus obtaining the three-phase current.

[0049] Furthermore, in some embodiments, the motor control signal includes a three-phase motor control signal, wherein each phase motor control signal is a PWM (Pulse-Width Modulation) signal.

[0050] It is understandable that when adopting such... Figure 1 In the motor control system shown, the inverter 10 includes three-phase bridge arms, so the motor control signal includes the motor control signal for each phase bridge arm, and each phase motor control signal is a PWM signal. The rising edge of the motor control signal is the transition edge of each phase motor control signal from low level to high level, and the falling edge of the motor control signal is the transition edge of each phase motor control signal from high level to low level.

[0051] In some embodiments, the sampling window includes a first sampling window and a second sampling window, wherein determining the sampling window of the single-resistance current detection circuit includes: determining a first time interval between a first edge and a second edge of the motor control signal as the first sampling window; and determining a second time interval between a second edge and a third edge of the motor control signal as the second sampling window, wherein the first time interval and the second time interval are respectively greater than or equal to the minimum sampling time, the times corresponding to the first edge, the second edge and the third edge increase sequentially, and the types of the first edge, the second edge and the third edge are the same.

[0052] Specifically, the first sampling point is within the first sampling window, and the second sampling point is within the second sampling window. The first, second, and third edges are of the same type, indicating that the first, second, and third edges are either rising edges or falling edges, respectively. Sufficient time intervals need to be reserved between the first and second edges and between the second and third edges to ensure that the single-resistor current detection circuit can complete current sampling. Therefore, the first time interval and the second time interval are both greater than or equal to the minimum sampling time.

[0053] For example, when the sampling window is set at the rising edge of the motor control signal:

[0054] by Figure 3 Taking the rising edge sequence as an example, when the rising edge sequence of the motor control signal is set to U phase, V phase, W phase, the first rising edge is the U phase rising edge, the second rising edge is the V phase rising edge, and the third rising edge is the W phase rising edge. The area between the U phase rising edge and the V phase rising edge is the first sampling window, and the first sampling point is set within the first sampling window. The voltage vector corresponding to the first sampling point is 100. At this time, the single-resistor current detection circuit samples the negative U phase current -Iu. The area between the V phase rising edge and the W phase rising edge is the second sampling window, and the second sampling point is set within the second sampling window. The voltage vector corresponding to the second sampling point is 110. At this time, the single-resistor current detection circuit samples the positive W phase current Iw. The V phase current Iv can be calculated based on the U phase current Iu and the W phase current Iw.

[0055] When the rising edge sequence of the motor control signal is set to V phase, U phase, W phase, the first rising edge is the V phase rising edge, the second rising edge is the U phase rising edge, and the third rising edge is the W phase rising edge. The first sampling window is between the V phase rising edge and the U phase rising edge, and the second sampling window is between the U phase rising edge and the W phase rising edge.

[0056] When the rising edge sequence of the motor control signal is set to V phase, W phase, U phase, the first rising edge is the V phase rising edge, the second rising edge is the W phase rising edge, and the third rising edge is the U phase rising edge. The first sampling window is between the V phase rising edge and the W phase rising edge, and the second sampling window is between the W phase rising edge and the U phase rising edge.

[0057] When the rising edge sequence of the motor control signal is set to W phase, V phase, U phase, the first rising edge is the W phase rising edge, the second rising edge is the V phase rising edge, and the third rising edge is the U phase rising edge. The first sampling window is between the W phase rising edge and the V phase rising edge, and the second sampling window is between the V phase rising edge and the U phase rising edge.

[0058] When the rising edge sequence of the motor control signal is set to W phase, U phase, V phase, the first rising edge is the W phase rising edge, the second rising edge is the U phase rising edge, and the third rising edge is the V phase rising edge. The first sampling window is between the W phase rising edge and the U phase rising edge, and the second sampling window is between the U phase rising edge and the V phase rising edge.

[0059] When the rising edge sequence of the motor control signal is set to U phase, W phase, V phase, the first rising edge is the U phase rising edge, the second rising edge is the W phase rising edge, and the third rising edge is the V phase rising edge. The area between the U phase rising edge and the W phase rising edge is the first sampling window, and the area between the W phase rising edge and the V phase rising edge is the second sampling window.

[0060] When the sampling window is set at the falling edge of the motor control signal:

[0061] When the falling edge sequence of the motor control signal is set to U phase, V phase, W phase, the first falling edge is the U phase falling edge, the second falling edge is the V phase falling edge, and the third falling edge is the W phase falling edge. The first sampling window is between the U phase falling edge and the V phase falling edge, and the second sampling window is between the V phase falling edge and the W phase falling edge.

[0062] The falling edges of the motor control signal are sequentially set as V phase, U phase, and W phase. The first falling edge is the V phase falling edge, the second falling edge is the U phase falling edge, and the third falling edge is the W phase falling edge. The first sampling window is between the V phase falling edge and the U phase falling edge, and the second sampling window is between the U phase falling edge and the W phase falling edge.

[0063] When the falling edge sequence of the motor control signal is set to V phase, W phase, U phase, the first falling edge is the V phase falling edge, the second falling edge is the W phase falling edge, and the third falling edge is the U phase falling edge. The first sampling window is between the V phase falling edge and the W phase falling edge, and the second sampling window is between the W phase falling edge and the U phase falling edge.

[0064] When the falling edge sequence of the motor control signal is set to W phase, V phase, U phase, the first falling edge is the W phase falling edge, the second falling edge is the V phase falling edge, and the third falling edge is the U phase falling edge. The first sampling window is between the W phase falling edge and the V phase falling edge, and the second sampling window is between the V phase falling edge and the U phase falling edge.

[0065] When the falling edge sequence of the motor control signal is set to W phase, U phase, V phase, the first falling edge is the W phase falling edge, the second falling edge is the U phase falling edge, and the third falling edge is the V phase falling edge. The first sampling window is between the W phase falling edge and the U phase falling edge, and the second sampling window is between the U phase falling edge and the V phase falling edge.

[0066] When the falling edge sequence of the motor control signal is set to U phase, W phase, V phase, the first falling edge is the U phase falling edge, the second falling edge is the W phase falling edge, and the third falling edge is the V phase falling edge. The period between the U phase falling edge and the W phase falling edge is the first sampling window, and the period between the W phase falling edge and the V phase falling edge is the second sampling window.

[0067] S102, compensate for the other edge between the rising edge and the falling edge according to the sampling window to obtain the target edge.

[0068] Specifically, because sufficient time intervals need to be reserved at the edge where the sampling window is located, the delay of the rising edge corresponding to the sampling window causes changes in the turn-on time of each phase arm in the inverter, resulting in a decrease in the accuracy of the motor controller and the motor failing to run to the desired speed. Therefore, it is necessary to compensate for the other edge of the rising and falling edges according to the sampling window.

[0069] by Figure 3 Taking the example shown, if a fixed sampling window is set at the rising edge of the motor control signal, the rising edge of phase V may occur at time t0. When a fixed sampling window is set at the rising edge of the motor control signal, the first time interval between the rising edges of phase U and phase V needs to be greater than or equal to the minimum sampling time. Therefore, the rising edge of phase V is delayed to time t1. If the falling edge of phase V is not compensated, the conduction time of the upper arm of phase V becomes shorter, causing errors in the motor controller's control and affecting its accuracy and stability. Therefore, compensation for the falling edge of phase V is necessary to ensure that the change in the conduction time of the upper arm of phase V is small and does not affect the motor control.

[0070] In some embodiments, compensation is performed on the other edge of the rising edge and the falling edge according to the sampling window, including: shifting the fourth edge of the motor control signal to the right by a first preset time, shifting the fifth edge of the motor control signal to the right by a second preset time, and keeping the sixth edge of the motor control signal unchanged, wherein the first preset time is greater than the second preset time, wherein the times corresponding to the fourth edge, the fifth edge and the sixth edge increase sequentially, and the fourth edge, the fifth edge and the sixth edge are of the same type and are different from the types of the first edge, the second edge and the third edge.

[0071] Specifically, when the sampling window is set to the rising edge, the first, second, and third edges are rising edges, and the fourth, fifth, and sixth edges are falling edges. The rising edge corresponding to the third falling edge (i.e., the sixth edge) of the motor control signal is the first rising edge. Because the time of the first rising edge does not change, no compensation is needed for the third falling edge. The rising edge corresponding to the second falling edge (i.e., the fifth edge) of the motor control signal is the second rising edge. Because the first time interval between the second and first rising edges needs to be greater than or equal to the minimum sampling time, the second rising edge is delayed, and the second falling edge also needs to be delayed. Therefore, the second falling edge is shifted to the right by a second preset time. The rising edge corresponding to the first falling edge (i.e., the sixth edge) of the motor control signal is the third rising edge. Because the second time interval between the third and second rising edges needs to be greater than or equal to the minimum sampling time, the third rising edge is delayed, and the first falling edge also needs to be delayed. Furthermore, because the time the third rising edge is delayed is greater than the time the second rising edge is delayed, the first falling edge is shifted to the right by a first preset time.

[0072] When the sampling window is set to the falling edge, the first, second, and third edges are falling edges, and the fourth, fifth, and sixth edges are rising edges. The falling edge corresponding to the third rising edge (i.e., the sixth edge) of the motor control signal is the first falling edge. Because the time of the first falling edge does not change, no compensation is needed for the third rising edge. The falling edge corresponding to the second rising edge (i.e., the fifth edge) of the motor control signal is the second falling edge. Because the first time interval between the second and first falling edges needs to be greater than or equal to the minimum sampling time, the second falling edge is delayed, and the second rising edge also needs to be delayed. Therefore, the second rising edge is shifted to the right by a second preset time. The falling edge corresponding to the first rising edge (i.e., the fourth edge) of the motor control signal is the third falling edge. Because the second time interval between the third and second falling edges needs to be greater than or equal to the minimum sampling time, the third falling edge is delayed, and the first rising edge also needs to be delayed. Furthermore, because the time the third falling edge is delayed is greater than the time the second falling edge is delayed, the first rising edge is shifted to the right by a first preset time.

[0073] In some embodiments, where the first time interval and the second time interval are respectively the minimum sampling time, the second preset time is the minimum sampling time, and the first preset time is twice the minimum sampling time.

[0074] Understandably, because the first time interval is the minimum sampling time, in order to ensure the accuracy of motor control, the fifth edge of the motor control signal is shifted to the right by a second preset time. Since the second time interval is also the minimum sampling time, the delay time of the fourth edge is twice the delay time of the fifth edge, so the first preset time is twice the minimum sampling time.

[0075] by Figure 4 As shown in the example, when the sampling window is set at the rising edge, compensation for the falling edge is required. When the rising edge sequence is U phase, V phase, W phase, the falling edge sequence is W phase, V phase, U phase. Because the first sampling window is set between the rising edge of U phase and the rising edge of V phase, and the second sampling window is set between the rising edge of V phase and the rising edge of W phase, compensation is required for the falling edges of V phase and W phase, as follows: Figure 4 As shown in the shaded area, the falling edge of phase V is moved to the right by a second preset time, and the falling edge of phase W is moved to the right by a first preset time.

[0076] When the sampling window is set at the rising edge, the falling edge is delayed, and the duty cycle corresponding to the falling edge of the three-phase motor control signal increases. Therefore, the duty cycle corresponding to the falling edge of the three-phase motor control signal is as shown in formula (1):

[0077]

[0078] Where Duty_uc, Duty_vc, and Duty_wc are the compensated duty cycles of phase U, V, and W, respectively; Duty_u, Duty_v, and Duty_w are the initial duty cycles of phase U, V, and W, respectively; and t is the initial duty cycle of phase W. sample For the minimum sampling time, T PWM This is the PWM control cycle.

[0079] When the sampling window is set at the rising edge, if the rising edge sequence is V phase, U phase, W phase, then the falling edge sequence is W phase, U phase, V phase. Therefore, it is necessary to compensate for the falling edge of U phase and the falling edge of W phase by shifting the falling edge of W phase to the right by a first preset time and shifting the falling edge of U phase to the right by a second preset time. Therefore, the duty cycle corresponding to the falling edge of the three-phase motor control signal is as shown in formula (2):

[0080]

[0081] When the sampling window is set at the rising edge, if the rising edge sequence is V phase, W phase, U phase, then the falling edge sequence is U phase, W phase, V phase. Therefore, it is necessary to compensate for the falling edge of U phase and the falling edge of W phase by shifting the falling edge of U phase to the right by a first preset time and shifting the falling edge of W phase to the right by a second preset time. Therefore, the duty cycle corresponding to the falling edge of the three-phase motor control signal is as shown in formula (3):

[0082]

[0083] When the sampling window is set at the rising edge, if the rising edge sequence is W phase, V phase, U phase, then the falling edge sequence is U phase, V phase, W phase. Therefore, it is necessary to compensate for the falling edge of U phase and the falling edge of V phase by shifting the falling edge of U phase to the right by a first preset time and shifting the falling edge of V phase to the right by a second preset time. Therefore, the duty cycle corresponding to the falling edge of the three-phase motor control signal is as shown in formula (4):

[0084]

[0085] When the sampling window is set at the rising edge, if the rising edge sequence is W phase, U phase, V phase, then the falling edge sequence is V phase, U phase, W phase. Therefore, it is necessary to compensate for the falling edge of U phase and the falling edge of V phase. The falling edge of V phase is shifted to the right by a first preset time, and the falling edge of U phase is shifted to the right by a second preset time. Therefore, the duty cycle corresponding to the falling edge of the three-phase motor control signal is as shown in formula (5):

[0086]

[0087] When the sampling window is set at the rising edge, if the rising edge sequence is U phase, W phase, V phase, then the falling edge sequence is V phase, W phase, U phase. Therefore, it is necessary to compensate for the falling edge of V phase and the falling edge of W phase by shifting the falling edge of V phase to the right by a first preset time and shifting the falling edge of W phase to the right by a second preset time. Therefore, the duty cycle corresponding to the falling edge of the three-phase motor control signal is as shown in formula (6):

[0088]

[0089] When the sampling window is set at the falling edge, if the falling edge sequence is U phase, V phase, W phase, then the rising edge sequence is W phase, V phase, U phase. Therefore, compensation is needed for the rising edges of V phase and W phase. The rising edge of W phase is shifted to the right by a first preset time, and the rising edge of V phase is shifted to the right by a second preset time. When the sampling window is set at the falling edge, the rising edge is delayed, and the duty cycle corresponding to the rising edge of the three-phase motor control signal decreases. Therefore, the duty cycle corresponding to the rising edge of the three-phase motor control signal is as shown in formula (7):

[0090]

[0091] When the sampling window is set at the falling edge, if the falling edge sequence is V phase, U phase, W phase, then the rising edge sequence is W phase, U phase, V phase. Therefore, it is necessary to compensate for the rising edges of U phase and W phase, shifting the rising edge of W phase to the right by a first preset time and shifting the rising edge of U phase to the right by a second preset time. Thus, the duty cycle corresponding to the rising edge of the three-phase motor control signal is as shown in formula (8):

[0092]

[0093] When the sampling window is set at the falling edge, if the falling edge sequence is V phase, W phase, U phase, then the rising edge sequence is U phase, W phase, V phase. Therefore, it is necessary to compensate for the rising edges of U phase and W phase, shifting the rising edge of U phase to the right by a first preset time and shifting the rising edge of W phase to the right by a second preset time. Therefore, the duty cycle corresponding to the rising edge of the three-phase motor control signal is as shown in formula (9):

[0094]

[0095] When the sampling window is set at the falling edge, if the falling edge sequence is W phase, V phase, U phase, then the rising edge sequence is U phase, V phase, W phase. Therefore, it is necessary to compensate for the rising edges of U phase and V phase, shifting the rising edge of U phase to the right by a first preset time and shifting the rising edge of V phase to the right by a second preset time. Therefore, the duty cycle corresponding to the rising edge of the three-phase motor control signal is as shown in formula (10):

[0096]

[0097] When the sampling window is set at the falling edge, if the falling edge sequence is W phase, U phase, V phase, then the rising edge sequence is V phase, U phase, W phase. Therefore, it is necessary to compensate for the rising edges of U phase and V phase, shifting the rising edge of V phase to the right by a first preset time and shifting the rising edge of U phase to the right by a second preset time. Thus, the duty cycle corresponding to the rising edge of the three-phase motor control signal is as shown in formula (11):

[0098]

[0099] When the sampling window is set at the falling edge, if the falling edge sequence is U phase, W phase, V phase, then the rising edge sequence is V phase, W phase, U phase. Therefore, it is necessary to compensate for the rising edges of V phase and W phase, shifting the rising edge of V phase to the right by a first preset time and shifting the rising edge of W phase to the right by a second preset time. Thus, the duty cycle corresponding to the rising edge of the three-phase motor control signal is as shown in formula (12):

[0100]

[0101] S103 controls the motor based on an edge and a target edge.

[0102] Specifically, the rising and falling times of the motor control signal can be determined based on an edge and a target edge, and then the motor control signal is updated to control the motor.

[0103] In some embodiments, controlling a motor based on an edge and a target edge includes: determining a first comparison value based on an edge and determining a second comparison value based on a target edge; comparing a carrier wave with the first comparison value and the second comparison value respectively to generate a target motor control signal; and controlling the motor based on the target motor control signal.

[0104] Specifically, when the inverter is a three-phase bridge arm, the motor control signal includes the three-phase motor control signal. Therefore, the first comparison value includes the first U-phase comparison value, the first V-phase comparison value, and the first W-phase comparison value, and the second comparison value includes the second U-phase comparison value, the second V-phase comparison value, and the second W-phase comparison value. Figure 4 Taking the example shown, when the carrier wave is greater than the first U-phase comparison value, the U-phase motor control signal changes from low to high. When the carrier wave is greater than the second U-phase comparison value, the U-phase motor control signal changes from high to low. The generation methods of the V-phase motor control signal and the W-phase motor control signal are the same as those of the U-phase motor control signal, and will not be repeated here. Then, the U-phase bridge arm, V-phase bridge arm, and W-phase bridge arm are controlled according to the U-phase motor control signal, V-phase motor control signal, and W-phase motor control signal, respectively.

[0105] In the above embodiments, a fixed current sampling window is set at one of the rising and falling edges of the motor control signal, which realizes single-resistor current sampling at a fixed time. This solves the problems of the sampling window not being fixed and the short effective voltage vector action time making current sampling difficult, reduces current sampling error, and thus improves current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges, thereby improving the accuracy and stability of the motor controller.

[0106] In some embodiments, before determining the sampling window of the single-resistor current detection circuit, the method further includes: acquiring the target voltage vector of the motor; and determining the motor control signal based on the target voltage vector using a voltage modulation algorithm.

[0107] In other words, by performing coordinate transformation on the three-phase current sampled by the single-resistor current detection circuit, the d-axis current and q-axis current can be obtained. Based on the d-axis current and q-axis current, as well as the given d-axis current and q-axis current, the target voltage vector can be obtained. Then, the SVPWM (Space Vector Pulse Width Modulation) algorithm or SPWM (Sine Pulse Width Modulation) algorithm is used to generate motor control signals to drive and control the switching transistors in the inverter.

[0108] In summary, the motor control method according to embodiments of the present invention determines the sampling window of the single-resistor current detection circuit. The sampling window is located at one of the rising and falling edges of the motor control signal. The other edge of the rising and falling edges is compensated based on the sampling window to obtain a target edge. The motor is then controlled based on one edge and the target edge. Thus, a fixed sampling window is set at one of the rising and falling edges of the motor control signal. The single-resistor current detection circuit samples the current within this sampling window, solving the problems of an unfixed sampling window and the difficulty in current sampling due to the short effective voltage vector duration. This reduces current sampling errors and improves current sampling accuracy. Because the sampling window is set at one of the rising and falling edges, the voltage vector duration at that edge is extended, requiring corresponding compensation for the other edge, thereby improving the accuracy and stability of the motor controller.

[0109] Corresponding to the above embodiments, embodiments of the present invention also provide a computer-readable storage medium storing a motor control program thereon, which, when executed by a processor, implements the motor control method of any of the foregoing embodiments.

[0110] According to the computer-readable storage medium of the present invention, by executing the computer program of the above-described motor control method, a fixed current sampling window is set at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling error and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0111] Corresponding to the above embodiments, embodiments of the present invention also provide a motor controller. For example... Figure 5 As shown, the motor controller 30 includes: a memory 321, a processor 322, and a motor control program stored in the memory 321 and executable on the processor 322. When the processor 322 executes the program, it implements the motor control method of any of the aforementioned embodiments.

[0112] According to the embodiment of the present invention, the motor controller executes the computer program of the above-described motor control method through a processor, and sets a fixed current sampling window at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling error and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0113] Corresponding to the above embodiments, embodiments of the present invention also provide a motor control device. The motor control device is applied in a motor controller having a single-resistance current detection circuit, such as... Figure 6 As shown, the device includes: a determination module 40, a compensation module 50, and a control module 60.

[0114] The determination module 40 is used to determine the sampling window of the single-resistor current detection circuit, wherein the sampling window is located at one of the rising edge and the falling edge of the motor control signal; the compensation module 50 is used to compensate the other edge of the rising edge and the falling edge according to the sampling window to obtain the target edge; and the control module 60 is used to control the motor according to one edge and the target edge.

[0115] In some embodiments, the sampling window includes a first sampling window and a second sampling window. The determining module is configured to: determine a first time interval between the first edge and the second edge of the motor control signal as the first sampling window; and determine a second time interval between the second edge and the third edge of the motor control signal as the second sampling window, wherein the first time interval and the second time interval are respectively greater than or equal to the minimum sampling time, the times corresponding to the first edge, the second edge and the third edge increase sequentially, and the types of the first edge, the second edge and the third edge are the same.

[0116] In some embodiments, the compensation module 50 is further configured to: move the fourth edge of the motor control signal to the right by a first preset time, move the fifth edge of the motor control signal to the right by a second preset time, and keep the sixth edge of the motor control signal unchanged, wherein the first preset time is greater than the second preset time, wherein the times corresponding to the fourth edge, the fifth edge and the sixth edge increase sequentially, and the fourth edge, the fifth edge and the sixth edge are of the same type and are different from the first edge, the second edge and the third edge.

[0117] In some embodiments, where the first time interval and the second time interval are respectively the minimum sampling time, the second preset time is the minimum sampling time, and the first preset time is twice the minimum sampling time.

[0118] In some embodiments, the control module 60 is further configured to: determine a first comparison value based on an edge, and determine a second comparison value based on a target edge; compare the carrier wave with the first comparison value and the second comparison value respectively to generate a target motor control signal; and control the motor according to the target motor control signal.

[0119] In some embodiments, the motor control signal includes a three-phase motor control signal, wherein each phase motor control signal is a PWM signal.

[0120] In some embodiments, the apparatus further includes an acquisition module and a calculation module, wherein the acquisition module is configured to acquire a target voltage vector of the motor before determining the sampling window of the single-resistance current detection circuit; and the calculation module is configured to determine a motor control signal based on the target voltage vector using a voltage modulation algorithm.

[0121] It should be noted that the specific implementation of the motor control device in this embodiment corresponds one-to-one with the specific implementation of the motor control method in the foregoing embodiments of this invention, and will not be repeated here.

[0122] According to an embodiment of the present invention, the motor control device determines the sampling window of the single-resistor current detection circuit through a determining module. The sampling window is located at one of the rising and falling edges of the motor control signal. A compensation module compensates for the other edge of the rising and falling edges based on the sampling window to obtain a target edge. A control module controls the motor based on one edge and the target edge. Thus, a fixed sampling window is set at one of the rising and falling edges of the motor control signal. The single-resistor current detection circuit samples the current within this sampling window, solving the problems of an unfixed sampling window and the difficulty in current sampling due to the short effective voltage vector duration. This reduces current sampling errors and improves current sampling accuracy. Because the sampling window is set at one of the rising and falling edges, the voltage vector duration at that edge is prolonged, requiring corresponding compensation for the other edge, thereby improving the accuracy and stability of the motor controller.

[0123] Corresponding to the above embodiments, embodiments of the present invention also provide a motor. For example... Figure 7 and Figure 8 As shown, the motor 200 includes: the aforementioned motor controller 30 or the aforementioned motor control device 100.

[0124] According to the embodiments of the present invention, by employing the above-described motor controller or motor control device, a fixed current sampling window is set at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling errors and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0125] Corresponding to the above embodiments, embodiments of the present invention also provide an electronic water pump. For example... Figure 9 As shown, the electronic water pump 300 includes the aforementioned motor 200.

[0126] According to an embodiment of the present invention, the electronic water pump employs the aforementioned motor and sets a fixed current sampling window at one edge of the rising and falling edges of the motor control signal, thereby reducing current sampling errors and improving current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, improving the accuracy and stability of the motor controller.

[0127] Corresponding to the above embodiments, embodiments of the present invention also provide a vehicle. For example... Figure 10 As shown, vehicle 1000 includes the aforementioned electronic water pump 300.

[0128] The vehicle 1000 according to an embodiment of the present invention includes the electronic water pump 300 described in any of the above embodiments. Here, the vehicle can be a new energy vehicle. In some embodiments, the new energy vehicle can be a pure electric vehicle with an electric motor as the main driving force. In other embodiments, the new energy vehicle can also be a hybrid vehicle with both an internal combustion engine and an electric motor as the main driving force. Regarding the internal combustion engine and electric motor mentioned in the above embodiments that provide driving power for the new energy vehicle, the internal combustion engine can use gasoline, diesel, hydrogen, etc. as fuel, and the method of providing electrical energy to the electric motor can be a power battery, hydrogen fuel cell, etc., without special limitation. It should be noted that this is merely an exemplary description of the structure of new energy vehicles, etc., and is not intended to limit the scope of protection of the present invention.

[0129] According to the vehicle of the present invention, by employing the above-described motor, a fixed current sampling window is set at one edge of the rising and falling edges of the motor control signal, which reduces the current sampling error and improves the current sampling accuracy. Furthermore, corresponding compensation is performed on the other edge of the rising and falling edges of the motor control signal, thereby improving the accuracy and stability of the motor controller.

[0130] 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 embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (such as a computer-based system, a processor-included system, or other system that can fetch and execute instructions from, an instruction execution system, apparatus, or device). For the purposes of this specification, "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transmit programs for use by, or in conjunction with, an instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of computer-readable media include: an electrical connection having one or more wires (electronic device), a portable computer disk drive (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Alternatively, the computer-readable medium may be paper or other suitable media on which the program can be printed, since the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in a computer memory.

[0131] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.

[0132] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0133] Furthermore, the terms "first," "second," etc., used in the embodiments of this invention are for descriptive purposes only and should not be construed as indicating or implying relative importance, or implicitly specifying the number of technical features indicated in this embodiment. Therefore, features defined with terms such as "first" and "second" in the embodiments of this invention can explicitly or implicitly indicate that the embodiment includes at least one of those features. In the description of this invention, the word "multiple" means at least two or more, such as two, three, four, etc., unless otherwise explicitly specified in the embodiments.

[0134] In this invention, unless otherwise explicitly specified or limited in the embodiments, the terms "installation," "connection," "joining," and "fixing" appearing in the embodiments should be interpreted broadly. For example, a connection can be a fixed connection, a detachable connection, or an integral part; 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 communication of two components, or the interaction between two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific implementation.

[0135] Although embodiments of the present invention have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present invention. Those skilled in the art can make changes, modifications, substitutions and variations to the above embodiments within the scope of the present invention.

Claims

1. A motor control method, characterized in that, The method, applied in a motor controller with a single-resistance current detection circuit, includes: The sampling window of the single-resistor current detection circuit is determined, wherein the sampling window is located at one of the rising edge and the falling edge of the motor control signal; The target edge is obtained by compensating for the other edge between the rising edge and the falling edge according to the sampling window; The motor is controlled based on the one edge and the target edge.

2. The method according to claim 1, characterized in that, The sampling window includes a first sampling window and a second sampling window, wherein determining the sampling window of the single-resistor current detection circuit includes: The first time interval between the first edge and the second edge of the motor control signal is defined as the first sampling window; The second time interval between the second edge and the third edge of the motor control signal is determined as the second sampling window, wherein the first time interval and the second time interval are respectively greater than or equal to the minimum sampling time, the time corresponding to the first edge, the second edge and the third edge increases sequentially, and the first edge, the second edge and the third edge are of the same type.

3. The method according to claim 2, characterized in that, Compensation is performed on the other edge of the rising edge and the falling edge according to the sampling window, including: The fourth edge of the motor control signal is moved to the right by a first preset time, and the fifth edge of the motor control signal is moved to the right by a second preset time, while the sixth edge of the motor control signal remains unchanged. The first preset time is greater than the second preset time. The times corresponding to the fourth, fifth, and sixth edges increase sequentially. The fourth, fifth, and sixth edges are of the same type and are different from the types of the first, second, and third edges.

4. The method according to claim 3, characterized in that, When the first time interval and the second time interval are respectively the minimum sampling time, the second preset time is the minimum sampling time, and the first preset time is twice the minimum sampling time.

5. The method according to any one of claims 1-4, characterized in that, Controlling the motor based on the one edge and the target edge includes: A first comparison value is determined based on the edge, and a second comparison value is determined based on the target edge; The carrier wave is compared with the first comparison value and the second comparison value respectively to generate the target motor control signal; The motor is controlled according to the target motor control signal.

6. The method according to any one of claims 1-4, characterized in that, The motor control signals include three-phase motor control signals, wherein each phase motor control signal is a PWM signal.

7. The method according to any one of claims 1-4, characterized in that, Before determining the sampling window of the single-resistor current detection circuit, the method further includes: Obtain the target voltage vector of the motor; The motor control signal is determined based on the target voltage vector using a voltage modulation algorithm.

8. A computer-readable storage medium, characterized in that, It stores a motor control program, which, when executed by a processor, implements the motor control method according to any one of claims 1-7.

9. A motor controller, characterized in that, include: The system includes 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, it implements the motor control method according to any one of claims 1-7.

10. A motor control device, characterized in that, The device, used in a motor controller with a single-resistance current detection circuit, comprises: A determining module is used to determine the sampling window of the single-resistor current detection circuit, wherein the sampling window is located at one of the rising edge and the falling edge of the motor control signal; The compensation module is used to compensate for the other edge between the rising edge and the falling edge according to the sampling window to obtain the target edge; The control module is used to control the motor based on the one edge and the target edge.

11. An electric motor, characterized in that, include: The motor controller according to claim 9 or the motor control device according to claim 10.

12. An electronic water pump, characterized in that, include: The motor according to claim 11.

13. A vehicle, characterized in that, Including the electronic water pump according to claim 12.