Motor control method and device, motor and storage medium

By sending pulse width modulation signals and detecting working current in the drag state of the motor, the problem of the rotor of a single-phase brushless motor is solved, which improves detection accuracy and extends the service life of the motor.

CN119210269APending Publication Date: 2024-12-27GUANGDONG MIDEA CONSUMER ELECTRICS MFG CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310775229.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-06-27
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

If the rotor turns the rotor over the center line of the stator magnetic field, if the phase exchange is not timely or the phase exchange is not carried out, it will cause the rotor to lose steps, affecting the normal operation of the motor, and it will be difficult for the existing technology to detect and solve this problem in a timely manner.

Method used

By sending the first pulse width modulation signal when the motor is in the drag state, adjusting its duty cycle, and obtaining the motor's working current, detecting whether the motor is in an abnormal state based on the working current and the specified current value, and determining whether the rotor is out of step.

Benefits of technology

Accurately detecting whether the motor's working current is too large, improves the accuracy of detection of rotor loss, avoids the motor's speed slowing or stuck due to loss of steps, and extends the service life of the motor.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119210269A_ABST
    Figure CN119210269A_ABST
Patent Text Reader

Abstract

The invention discloses a motor control method and device, a motor and a storage medium. The method comprises the following steps: when a motor is in a dragging state, sending a first pulse width modulation signal; the duty ratio of the first pulse width adjustment signal is a first duty ratio; obtaining the working current of the motor; and detecting whether the motor is in an abnormal state based on the working current and a specified current value corresponding to the first duty ratio. As the specified current value corresponding to the first duty ratio is the current critical value of normal working of the motor under the first pulse width modulation signal of the first duty ratio, whether the current working current of the motor is too large or not can be accurately detected by judging the size relation between the working current and the specified current value corresponding to the first duty ratio, and the working efficiency of the motor is improved. And the accuracy of detecting whether the rotor is out of step 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 drive technology, and more specifically, to a motor control method, device, motor and storage medium. Background Art

[0002] A single-phase brushless motor is an electric motor that uses semiconductor switching devices to achieve electronic commutation. It uses semiconductor switching devices (such as transistors) instead of traditional contact commutators and brushes, and thus has the advantages of high reliability, no commutation sparks, and low mechanical noise.

[0003] Specifically, when the rotor in a single-phase brushless motor rotates across the center line of the stator magnetic field (i.e., the coil magnetic field), the motor current needs to be commutated by turning on the corresponding semiconductor switching devices. If the commutation is not timely or not performed, the stator magnetic field will drag the rotation of the rotor, causing the rotor to lose step, thereby affecting the normal operation of the motor.

[0004] Therefore, it is necessary to detect whether the rotor is out of step in time during the driving process of the motor. Summary of the invention

[0005] Embodiments of the present application provide a method and device for controlling a motor, a motor, and a storage medium.

[0006] In a first aspect, some embodiments of the present application provide a method for controlling a motor, the method comprising sending a first pulse width modulation signal when the motor is in a drag state; the duty cycle of the first pulse width adjustment signal is a first duty cycle; obtaining the operating current of the motor; and detecting whether the motor is in an abnormal state based on the operating current and a specified current value corresponding to the first duty cycle.

[0007] In a second aspect, some embodiments of the present application further provide a control device for a motor, the control device comprising a sending module, an acquisition module and a detection module. The sending module is used to send a first pulse width modulation signal when the motor is in a dragging state; the duty cycle of the first pulse width modulation signal is a first duty cycle. The acquisition module is used to obtain the working current of the motor. The detection module is used to detect whether the motor is in an abnormal state based on the working current and a specified current value corresponding to the first duty cycle.

[0008] In a third aspect, some embodiments of the present application further provide a motor, the motor comprising one or more processors, a memory, and one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, and the one or more applications are configured to execute the above control method.

[0009] In a fourth aspect, some embodiments of the present application further provide an electrical device, which comprises the above-mentioned motor.

[0010] In a fifth aspect, some embodiments of the present application further provide a computer-readable storage medium, in which computer program instructions are stored, and the computer program instructions can be called by a processor to execute the above-mentioned control method.

[0011] In a sixth aspect, some embodiments of the present application also provide a computer program product, which implements the above-mentioned control method when executed.

[0012] The present application provides a control method, device, motor and storage medium of a motor. The control method sends a first pulse width modulation signal when the motor is in a dragging state, and the duty cycle of the first pulse width modulation signal is a first duty cycle, thereby obtaining the working current of the motor. Finally, based on the working current and the specified current value corresponding to the first duty cycle, it is detected whether the motor is in an abnormal state. When the motor loses step with the rotor, the rotor will slow down or even get stuck. At this time, the internal temperature of the motor increases, which reduces the equivalent resistance of the motor and increases the working current of the motor. Therefore, the present application determines whether the rotor loses step by judging the size relationship between the working current and the specified current value corresponding to the first duty cycle. Since the specified current value corresponding to the first duty cycle is the current critical value for the motor to work normally under the first pulse width modulation signal of the first duty cycle, by judging the size relationship between the working current and the specified current value corresponding to the first duty cycle, it is possible to accurately detect whether the current working current of the motor is too large, thereby improving the accuracy of detecting whether the rotor loses step. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0014] Figure 1 It is a schematic diagram of the structure of the motor provided in the embodiment of the present application.

[0015] Figure 2 yes Figure 1 Schematic diagram of the cross-sectional structure of the motor body.

[0016] Figure 3 It is a flow chart of a motor control method provided in the first embodiment of the present application.

[0017] Figure 4It is a flow chart of a motor control method provided in the second embodiment of the present application.

[0018] Figure 5 It is a flow chart of a motor control method provided in the third embodiment of the present application.

[0019] Figure 6 It is a flow chart of a motor control method provided in the fourth embodiment of the present application.

[0020] Figure 7 It is a module block diagram of the motor control device provided in an embodiment of the present application.

[0021] Figure 8 This is a module block diagram of the motor provided in an embodiment of the present application.

[0022] Fig. 9 It is a module block diagram of the computer-readable storage medium provided in an embodiment of the present application. DETAILED DESCRIPTION

[0023] The embodiments of the present application are described in detail below, and examples of the embodiments 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 only used to explain the present application, and cannot be understood as limiting the present application.

[0024] In order to enable those skilled in the art to better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without making creative work are within the scope of protection of the present application.

[0025] The present application provides a control method, device, motor and storage medium of a motor. The control method sends a first pulse width modulation signal when the motor is in a dragging state, and the duty cycle of the first pulse width modulation signal is a first duty cycle, thereby obtaining the working current of the motor. Finally, based on the working current and the specified current value corresponding to the first duty cycle, it is detected whether the motor is in an abnormal state. When the motor loses step with the rotor, the rotor will slow down or even get stuck. At this time, the internal temperature of the motor increases, which reduces the equivalent resistance of the motor and increases the working current of the motor. Therefore, the present application determines whether the rotor loses step by judging the size relationship between the working current and the specified current value corresponding to the first duty cycle. Since the specified current value corresponding to the first duty cycle is the current critical value for the motor to work normally under the first pulse width modulation signal of the first duty cycle, by judging the size relationship between the working current and the specified current value corresponding to the first duty cycle, it is possible to accurately detect whether the current working current of the motor is too large, thereby improving the accuracy of detecting whether the rotor loses step.

[0026] In order to facilitate the detailed description of the present application, the application environment of the present application embodiment is first introduced in conjunction with the accompanying drawings. Figure 1 , an embodiment of the present application provides a motor 100. The motor 100 is a device that converts electrical energy into mechanical energy. It uses an energized coil (for example, a stator winding) to generate a rotating magnetic field and acts on the rotor to form a magneto-electrical power rotation torque, thereby driving the rotor to rotate. The motor 100 can be applied to electrical equipment (for example, a washing machine, an air conditioner, a refrigerator, an electric car, an electric motorcycle, etc.). Specifically, the motor 100 may include a single-phase brushless motor, a three-phase brushless motor, etc. This embodiment is introduced by taking the motor 100 as a single-phase brushless motor as an example.

[0027] In this embodiment, the motor 100 may include a control module 10, a motor body 20 and a current detection module 30, wherein the control module 10 is electrically connected to the motor body 20, and is used to control the rotation of the motor body 20. The current detection module 30 is connected in series with the motor body 20, and is used to detect the current of the branch where the motor body 20 is located. Among them, the control module 10 may include a control unit 120, a drive unit 140 and a switch unit 160, wherein the drive unit 140 is electrically connected between the control unit 120 and the switch unit 160, and the switch unit 160 is electrically connected to the motor body 20. The control unit 120 is used to send a specified control signal to the switch unit 160, thereby controlling the switch unit 160 to enter different working states to control the rotation of the motor body 20. The drive unit 140 is used to amplify the control signal output by the control unit 120, so that the amplified control signal can smoothly control the switch unit 160, thereby ensuring the normal operation of the control module 10.

[0028] The switch unit 160 may include a first transistor 1610, a second transistor 1630, a third transistor 1650, and a fourth transistor 1670. The first transistor 1610 and the second transistor 1630 are connected in series between the power supply terminal and the ground terminal, and the third transistor 1650 and the fourth transistor 1670 are connected in series between the power supply terminal and the ground terminal. One end of the motor body 20 is connected to the common end (i.e., Figure 1 The other end of the motor body 20 is connected to the common end between the third transistor 1650 and the fourth transistor 1670 (ie, Figure 1 Therefore, the main body of the switch unit 160 in this embodiment is an "H-bridge" switch circuit composed of four transistors.

[0029] Here, the working process of the switch unit 160 is introduced. When the first transistor 1610 and the fourth transistor 1670 are in a closed state, and the second transistor 1630 and the third transistor 1650 are in an open state, the current at the motor body 20 flows in from the U end and flows out from the V end. When the second transistor 1630 and the third transistor 1650 are in a closed state, and the first transistor 1610 and the fourth transistor 1670 are in an open state, the current at the motor body 20 flows in from the V end and flows out from the U end. Therefore, the control unit 120 can turn on different transistors to change the direction of the current at the motor body 20, and then change the direction of the magnetic field of the coil inside the motor body 20, so that the motor body 20 works smoothly. Specifically, the relevant introduction of the motor body 20 is described below.

[0030] In this embodiment, the transistor included in the switch unit 160 can be a bipolar junction transistor (Bipolar Junction Transistor, BJT tube) or a metal oxide semiconductor field effect transistor (Metal-Oxide-Semiconductor Field-Effect Transistor, MOSFET tube). Here, the transistors included in the switch unit 160 are all MOSFET tubes for explanation.

[0031] exist Figure 1In the illustrated embodiment, the first transistor 1610 may be a first MOSFET tube, the second transistor 1630 may be a second MOSFET tube, the third transistor 1650 may be a third MOSFET tube, and the fourth transistor 1670 may be a fourth MOSFET tube. Wherein, the source electrodes of the first MOSFET tube and the third MOSFET tube are both connected to the power supply terminal, the power supply terminal can provide a power supply voltage of a specified amplitude (for example, 310V), the drain electrode of the first MOSFET tube is connected to the source electrode of the second transistor 1630 to form a common terminal (that is, the U terminal), the drain electrode of the third MOSFET tube is connected to the source electrode of the fourth MOSFET tube to form a common terminal (that is, the V terminal), and the drain electrodes of the second transistor 1630 and the fourth MOSFET tube are both connected to the ground terminal. In addition, the gate electrodes of the first MOSFET tube, the second MOSFET tube, the third MOSFET tube, and the fourth MOSFET tube are respectively connected to the control unit 120 to enter different open and closed states under the control of the control unit 120.

[0032] The control unit 120 may be a control chip, which is used to send corresponding control signals to the first transistor 1610, the second transistor 1630, the third transistor 1650 and the fourth transistor 1670 in the switch unit 160 respectively so that the corresponding transistors enter the corresponding open and close states. Specifically, the control signal may be a pulse width modulation signal (PWM signal), and the control unit 120 may adjust the duty cycle corresponding to the PWM signal, thereby adjusting the voltage across the motor body 20 to adjust the speed of the motor body 20. Specifically, the larger the duty cycle of the PWM signal, the faster the speed of the motor body 20.

[0033] The driving unit 140 is electrically connected between the control unit 120 and the switch unit 160, and is used to amplify the control signal output by the control unit 120 so that the amplified control signal can smoothly control the switch unit 160. Specifically, the driving unit 140 includes a first driving subunit 1410 and a second driving subunit 1430, wherein the input end of the first driving subunit 1410 is connected to the control unit 120, and the output end of the first driving subunit 1410 is connected to the first transistor 1610 and the second transistor 1630 respectively. Since the first transistor 1610 and the second transistor 1630 are complementary and turned on when the switch unit 160 is working, that is, only one of the first transistor 1610 and the second transistor 1630 is in the on state, therefore, the first driving subunit 1410 can also convert the first PWM signal output by the control unit 120 into a pair of PWM signals with complementary amplitudes and output them to the first transistor 1610 and the second transistor 1630 respectively. Similarly, the input end of the second driver unit 1430 is connected to the control unit 120, and the output end of the second driver unit 1430 is respectively connected to the third transistor 1650 and the fourth transistor 1670. Since the third transistor 1650 and the fourth transistor 1670 are complementary and turned on when the switch unit 160 is working, the second driver unit 1430 can also convert the second PWM signal output by the control unit 120 into a pair of PWM signals with complementary amplitudes and output them to the third transistor 1650 and the fourth transistor 1670 respectively. Specifically, the first driver unit 1410 and the second driver unit 1430 can be respectively implemented by a driving circuit, or can be a dedicated driving chip, which is not specifically limited in this embodiment.

[0034] See also Figure 2 The motor body 20 may include a stator 210 and a rotor 230, wherein the stator 210 may be wound by a coil and surround the outer circumference of the rotor 230. In this embodiment, the stator 210 is connected between the U end and the V end, so when the circuit flow direction at the U end and the V end changes, the flow direction of the current in the coil also changes, so that the direction of the magnetic field generated by the stator 210 (that is, the direction of the coil magnetic field) also changes. Exemplarily, when the current direction flows from the U end to the V end, the direction of the coil magnetic field may be the X direction; when the current direction flows from the V end to the U end, the direction of the coil magnetic field may be the opposite direction of the X direction.

[0035] The rotor 230 may be an iron core provided with a permanent magnet, and therefore, the rotor 230 itself has a magnetic field. When a current flows through the stator 210 and generates a coil magnetic field, the coil magnetic field attracts the rotor 230 to rotate until the rotor magnetic field direction of the rotor 230 coincides with the coil magnetic field direction. At this time, the control unit 120 changes the coil magnetic field direction, and the rotor 230 continues to rotate under the action of inertia, so that the motor body 20 is in a working state.

[0036] The current detection module 30 is connected in series with the motor body 20, and is used to detect the current of the branch where the motor body 20 is located, and the current can be regarded as the working current of the motor 100. In this embodiment, the current detection module 30 can also be electrically connected to the control unit 120, and the control unit 120 is also used to determine whether the motor 100 is in an abnormal state based on the above current value. Specifically, the current detection module 30 can be a current detection circuit, or it can also be a dedicated current sensor (for example, a Hall current sensor, etc.), and this embodiment does not limit the specific implementation method of the current detection module 30.

[0037] See also Figure 3 , which shows a control method for a motor provided by the first embodiment of the present application. Specifically, the method may include the following steps.

[0038] Step S310: When the motor is in a dragging state, a first pulse width modulation signal is sent.

[0039] Before the motor enters the running state, it is necessary to drag the motor first to ensure that the motor can be in a normal working state later, that is, the dragging state can be understood as the trial operation state of the motor. If the working parameters of the motor are normal in the dragging state, the motor can be controlled to continue running. If the working parameters of the motor are abnormal in the dragging state, the motor can be turned off in time to ensure the service life of the motor. Specifically, the control unit can determine whether the motor is in the dragging state by querying the working state flag of the motor. If the value of the working state flag is a specified value corresponding to the dragging state, it is determined that the motor is in the dragging state. Exemplarily, the working state flag can be a binary character. If the value of the binary character is 1, the control unit determines that the motor is in the dragging state.

[0040] As an implementation method, the motor can be Figure 1 According to the circuit structure shown, when the control unit determines that the motor is in the dragging state, it can send the first pulse width modulation signal to the four transistors in the switch unit respectively, that is, the control unit sends four first pulse width modulation signals to the switch unit, wherein the duty cycle of each first pulse width modulation signal is the first duty cycle.

[0041] The first pulse width modulation signal refers to a PWM signal, and the first duty cycle of the PWM signal refers to the proportion of the power-on time to the total time in a pulse cycle. Therefore, the larger the first duty cycle, the longer the power-on time of the motor is, and the faster the speed of the motor is.

[0042] In some possible embodiments, the first duty cycle may be a default value in the control unit, wherein the first duty cycle may be greater than or equal to 10% and less than or equal to 90%, for example, the first duty cycle may be 20%, 30%, and so on.

[0043] In some other possible embodiments, the first duty cycle can be determined based on historical driving data of the motor. For example, the control unit can obtain the duty cycle of the PWM signal of the motor when it was in the driving state last time, and determine the duty cycle as the first duty cycle.

[0044] In some other possible embodiments, the first duty cycle may also correspond to the model of the motor one-to-one. For example, a mapping table representing the correspondence between different motor models and different first duty cycles may be pre-stored in the control unit, and the control unit may first obtain the hardware parameters of the motor and determine the model of the motor therefrom, and then determine the corresponding first duty cycle by querying the above mapping table, so that the first duty cycle determined in this embodiment is more accurate and reasonable.

[0045] Step S320, obtaining the working current of the motor.

[0046] As an implementation mode, the control unit may obtain the working current of the motor at preset time intervals. The preset time may be a default value in the control unit, wherein the preset time may be greater than or equal to 10 ms and less than or equal to 100 ms, for example, the preset time may be 30 ms, 50 ms, etc. The preset time may also be adjusted by the R&D personnel based on the actual working conditions of the motor, and this embodiment does not specifically limit this.

[0047] Step S330, detecting whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle.

[0048] In this embodiment, if the motor is in a normal state, under the action of the first pulse width modulation signal, the motor current will smoothly change phase, and the motor will rotate normally. If the motor is in an abnormal state, for example, due to untimely or no commutation, the rotor inside the motor loses step during rotation. At this time, the rotor will slow down or even get stuck, causing the internal temperature of the motor to rise, which reduces the equivalent resistance of the motor and increases the working current of the motor. Therefore, this embodiment can compare the magnitude relationship between the working current and the specified current value corresponding to the first duty cycle, and then determine whether the motor is in an abnormal state. Among them, the specified current value corresponding to the first duty cycle can be understood as the current critical value of the motor working normally under the first pulse width modulation signal of the first duty cycle. Therefore, the control unit can accurately detect whether the current working current of the motor is too large by judging the magnitude relationship between the working current and the specified current value corresponding to the first duty cycle, thereby improving the accuracy of detecting whether the rotor has lost step.

[0049] See also Figure 4 , which shows a control method for a motor provided by the second embodiment of the present application. Specifically, the method may include the following steps.

[0050] Step S410, positioning the rotor of the motor.

[0051] In this embodiment, when the control unit starts to control the motor to rotate, it needs to determine the initial position of the rotor in the motor to achieve accurate commutation of the current. If the phase is not commutated in time when the rotor reaches the stator magnetic field centerline, the rotor may lose step. Therefore, before sending the first pulse width modulation signal, the control unit needs to position the rotor of the motor to ensure that the motor can work smoothly.

[0052] As an implementation method, according to the salient polarity principle of the motor, the magnitude of the motor current is different when the rotor is in different initial positions. Therefore, the control unit may first conduct a current in a fixed direction to the motor, and then determine the initial position of the motor based on the sampled motor current. Specifically, step S410 may include step S4110 and step S4130.

[0053] Step S4110, obtaining the positioning current of the motor.

[0054] In this embodiment, the control unit first conducts a current in a fixed direction to the motor. For example, the motor can be turned on. Figure 1The first transistor and the fourth transistor in the motor make the current direction of the motor flow in from the U terminal and out from the V terminal. Then, after the current continues for a specified period of time, the control unit samples the motor current at this time, and determines the sampled current value as the positioning current of the motor. Among them, the specified time length can be a default value in the control unit, wherein the specified time length can be greater than or equal to 5ms and less than or equal to 20ms. For example, the preset time length can be 10ms, etc. The specified time length can also be adjusted by the R&D personnel based on the actual working conditions of the motor, and this embodiment does not specifically limit this.

[0055] Step S4130: determining an initial position of the rotor corresponding to the positioning current based on the positioning current and a preset second mapping relationship.

[0056] In this embodiment, the second mapping relationship represents the correspondence between different positioning currents and different initial positions of the rotor. Exemplarily, the second mapping relationship can be a second mapping table, which stores the correspondence between different current intervals and different initial positions. When the control unit obtains the positioning current of the motor, the current interval in which the positioning current is located is determined, and then the initial position of the rotor can be determined by querying the above-mentioned second mapping table. Specifically, the second mapping relationship can be summarized by R&D personnel based on a large amount of test data, and this embodiment does not specifically limit this.

[0057] This embodiment provides a rotor positioning method, which can determine the initial position of the rotor by obtaining the positioning current, so that the subsequent motor can work smoothly. In addition, the method does not need to set up an additional position sensor, saving the hardware cost of the motor.

[0058] Step S420, when the initial position of the rotor is determined, the motor is controlled to enter a dragging state.

[0059] In this embodiment, the control unit controls the motor to enter the dragging state when the initial position of the rotor is determined. Specifically, the control unit can determine the commutation moment of the motor based on the initial position of the rotor, and then drag the motor based on the commutation moment.

[0060] Step S430: When the motor is in a dragging state, a first pulse width modulation signal is sent.

[0061] Step S440, obtaining the working current of the motor.

[0062] In this embodiment, the specific implementation of step S430 and step S440 can refer to the relevant introduction in step S310 and step S320, which will not be repeated here.

[0063] Step S450: determining a specified current value corresponding to the first duty cycle based on the first duty cycle and a preset first mapping relationship.

[0064] In this embodiment, the first mapping relationship represents the correspondence between different duty cycles and different specified current values. Exemplarily, the first mapping relationship may be a first mapping table, which stores the correspondence between different duty cycles and different specified current values. Please refer to Table 1, which schematically provides a first mapping table.

[0065] Table-1

[0066] Duty Cycle 20% 25% 30% 35% 40% 45% Specify the current value 1.0A 1.1A 1.2A 1.3A 1.4A 1.5A

[0067] The control unit can determine the first duty cycle by acquiring the signal parameters of the first pulse width modulation signal, and then query the first mapping table to determine the specified current value corresponding to the first duty cycle. For example, if the first duty cycle is 20%, the specified current value can be determined to be 1A based on the above Table-1.

[0068] In some other possible embodiments, the first mapping relationship can also be reflected by a mapping function, and the control unit calculates the corresponding specified current value by the mapping function when the first duty cycle is determined. Specifically, the first mapping relationship can be summarized by R&D personnel based on a large amount of test data, and this embodiment does not specifically limit this.

[0069] It should be noted that this embodiment does not specifically limit the execution order of step S440 and step S450. Step S440 may be executed before step S450, or after step S450, or simultaneously with step S450.

[0070] Step S460: When the operating current is greater than the specified current value corresponding to the first duty cycle, it is determined that the motor is in an abnormal state.

[0071] In this embodiment, when the operating current is greater than a specified current value corresponding to the first duty cycle, the control unit determines that the motor is in an abnormal state.

[0072] In other embodiments, when the operating current is less than or equal to a specified current value corresponding to the first duty cycle, the control unit determines that the motor is in a normal state.

[0073] This embodiment provides a method for controlling a motor. The method determines the initial position of the rotor before the motor enters the dragging state, which can ensure that the motor can accurately commutate the current in subsequent work, thereby ensuring that the motor can work smoothly.

[0074] See also Figure 5, which shows a motor control method provided by the third embodiment of the present application. Specifically, the method may include the following steps.

[0075] Step S510: When the motor is in a dragging state, a first pulse width modulation signal is sent.

[0076] Step S520, obtaining the working current of the motor.

[0077] Step S530, detecting whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle.

[0078] In this embodiment, the specific implementation of steps S510 to S530 can refer to the relevant introduction in steps S310 to S530, which will not be repeated here.

[0079] Step S540: restart the motor when it is detected that the motor is in an abnormal state.

[0080] In this embodiment, when the control unit detects that the motor is in an abnormal state, it means that the motor rotor is likely to lose step. In this case, the control unit restarts the motor. Specifically, the control unit first stops sending the first pulse width modulation signal, so that the motor enters the off state, and then restarts the motor. It should be noted here that the control unit still needs to position the rotor before restarting the motor, and then restart the motor when the initial position of the rotor is known. Specifically, the implementation method of positioning the rotor can refer to the relevant introduction in step S410 and step S420, which will not be repeated here.

[0081] As an implementation, step S540 may include step S5410 and step S5430.

[0082] Step S5410, when it is detected that the motor is in an abnormal state, the number of restarts of the motor is updated.

[0083] In this embodiment, the control unit updates the number of restarts of the motor when the motor is detected to be in an abnormal state. When the motor is started for the first time, the control unit may initialize the value of the number of restarts to 0, and each time the motor is detected to be in an abnormal state, the control unit increases the number of restarts by one to update the number of restarts.

[0084] Step S5430: restart the motor when the updated restart times are less than the specified times.

[0085] In this embodiment, the control unit restarts the motor when the updated restart number is less than the specified number. The specified number may be a default value in the control unit, wherein the specified number may be greater than or equal to 1 and less than or equal to 10, for example, the specified number may be 3, 5, 7, etc. The specified number may also be adjusted by the R&D personnel based on the actual working condition of the motor, and this embodiment does not specifically limit this.

[0086] The control unit in this embodiment is set with a specified number of times, so as to avoid restarting the motor even when it is determined that the motor is in an abnormal state for multiple times, thereby ensuring the service life of the motor.

[0087] In some other embodiments, the control unit determines that the motor is in a fault state when the number of restarts after the update is greater than or equal to the specified number of times. In this case, the control unit no longer performs the step of restarting the motor, and the control unit can send a fault code to the host computer to remind the user or maintenance personnel to repair the motor in time.

[0088] In some possible embodiments, when the control unit determines that the motor is in an abnormal state, it can increase the duty cycle of the PWM signal to drag the motor again to improve the success rate of the motor operation. It should be noted here that when the motor loses step, the moment when the rotor passes through the stator magnetic field centerline and the moment when the motor current changes phases will be inconsistent. For example, the motor current has completed the phase change before the rotor has rotated through the stator magnetic field centerline. Therefore, the control unit can increase the speed of the rotor by increasing the duty cycle so that the moment when the rotor passes through the stator magnetic field centerline and the moment when the motor current changes phases are consistent, thereby avoiding the problem of the rotor losing step and ensuring that the motor can run smoothly in the future. Specifically, step S550 can be included after step S540.

[0089] Step S550: When the motor is in the dragging state, a second pulse width modulation signal is sent.

[0090] In this embodiment, the duty cycle of the second pulse width modulation signal is a second duty cycle, the second duty cycle is greater than the first duty cycle, and the operating current of the motor under the second pulse width modulation signal is less than or equal to the specified current value corresponding to the second duty cycle. Specifically, the second duty cycle can be a default value in the control unit, or can be determined based on the historical drag data of the motor.

[0091] As an implementation mode, the control unit can read the first duty cycle adopted by the motor driving this time, and determine the sum of the first duty cycle and the first preset increment as the second duty cycle, wherein the first preset increment can be a default value in the control unit, or can be determined by the R&D personnel according to the actual working conditions of the motor. Specifically, the first preset increment can be greater than or equal to 1% and less than or equal to 20%. For example, the first preset increment can be 5%. Exemplarily, when the first duty cycle is 20% and the first preset increment is 5%, the control unit determines that the second duty cycle is 25%, and then sends a second pulse width modulation signal with a duty cycle of 25%.

[0092] As another implementation, the control unit can read the first duty cycle used in this motor drive, and determine the product of the first duty cycle and the first preset ratio as the second duty cycle, wherein the first preset ratio is a real number greater than 1, which can be a default value in the control unit, or can be determined by the R&D personnel according to the actual working conditions of the motor. Specifically, the first preset ratio can be greater than or equal to 1.1, and less than or equal to 2. For example, the first preset ratio can be 1.5. Exemplarily, when the first duty cycle is 20% and the first preset ratio is 1.5, the control unit determines that the second duty cycle is 30%, and then sends a second pulse width modulation signal with a duty cycle of 30%.

[0093] As another embodiment, the control unit can read the first duty cycle used for this motor dragging, can increase the value of the duty cycle in sequence, and determine whether the working current under the duty cycle is less than or equal to the specified current value corresponding to the duty cycle. If so, the current duty cycle is determined as the second duty cycle. If not, the value of the duty cycle is further increased. Exemplarily, when the first duty cycle is 20%, the duty cycle is first increased to 22%, the working current of the motor when the duty cycle is 22% is obtained, and it is determined whether the working current is less than or equal to the specified current value corresponding to the duty cycle of 22%. If so, the second duty cycle is determined to be 22%. If not, the duty cycle is increased to 24%, and the above-mentioned working current judgment step is performed. The control unit can avoid the situation where the second duty cycle is too large by determining the second duty cycle in the above-mentioned manner, thereby ensuring the smooth operation of the subsequent motor.

[0094] This embodiment provides a method in which, when a motor abnormality is determined, the control unit increases the rotation speed of the rotor by increasing the duty cycle to ensure that the motor can subsequently run smoothly.

[0095] In some other possible implementations, when the control unit determines that the motor is in an abnormal state, the motor can be dragged again by increasing the cycle duration of the in-phase cycle to improve the success rate of the motor operation. Among them, the direction of the coil magnetic field of the motor remains unchanged in the in-phase cycle. Exemplarily, at 01:00, the control unit switches the direction of the motor current to flow in from the U end and out from the V end, and at 01:02, the control unit switches the direction of the motor current to flow in from the V end and out from the U end, then 01:00 to 01:02 is a in-phase cycle, and the cycle duration of the in-phase cycle is 2 seconds. Due to the increase in the cycle duration of the in-phase cycle, the moment of motor current commutation is delayed, so that the moment when the rotor passes through the stator magnetic field center line is consistent with the moment of motor current commutation, thereby avoiding the problem of rotor loss of step, so as to ensure that the motor can run smoothly later. Specifically, step S560 can be included after step S540.

[0096] Step S560: When the motor is in the dragging state, a third pulse width modulation signal is sent.

[0097] In this embodiment, the period duration of the in-phase period of the first pulse width modulation signal is the first period duration, and the period duration of the in-phase period of the third pulse width modulation signal is the second period duration, and the second period duration is greater than the first period duration. The duty cycle of the third pulse width modulation signal is the same as the duty cycle of the first pulse width modulation signal, and the operating current of the motor under the third pulse width modulation signal is less than or equal to the specified current value corresponding to the first duty cycle. Specifically, the second period duration can be a default value in the control unit, or it can be determined based on the historical drag data of the motor.

[0098] As an implementation mode, the control unit can read the first duration used for this motor dragging, and determine the sum of the first duration and the second preset increment as the second duration, wherein the second preset increment can be a default value in the control unit, or can be determined by the R&D personnel according to the actual working conditions of the motor. Specifically, the second preset increment can be greater than or equal to 5ms and less than or equal to 20ms. For example, the second preset increment can be 10ms. Exemplarily, when the first duration is 50ms and the second preset increment is 10ms, the control unit determines that the second duration is 60ms, and then sends a third pulse width modulation signal with a period duration of 60ms in the same phase period.

[0099] As another embodiment, the control unit can read the first duration used for this motor dragging, and determine the product of the first duration and the second preset ratio as the second duration, wherein the second preset ratio is a real number greater than 1, which can be a default value in the control unit, or can be determined by the R&D personnel according to the actual working conditions of the motor. Specifically, the second preset ratio can be greater than or equal to 1.1, and less than or equal to 2, for example, the second preset ratio can be 1.2. Exemplarily, when the first duration is 50ms and the second preset ratio is 1.2, the control unit determines that the second duration is 60ms, and then sends a third pulse width modulation signal with a period duration of 60ms in the same phase period.

[0100] As another embodiment, the control unit can read the first duration used for this motor dragging, can increase the value of the cycle duration in sequence, and determine whether the working current under the cycle duration is less than or equal to the specified current value corresponding to the first duty cycle, if so, the current cycle duration is determined as the second duration. If not, then the value of the cycle duration is further increased. Exemplarily, when the first duration is 50ms, the cycle duration is first increased to 55ms, the working current of the motor when the cycle duration is 55ms is obtained, and it is determined whether the working current is less than or equal to the specified current value corresponding to the first duty cycle, if so, the cycle duration of the same phase cycle is determined to be 55ms. If not, the cycle duration is increased to 60ms, and the above-mentioned working current judgment step is performed. The control unit can avoid the situation where the cycle duration is too large by determining the cycle duration in the above-mentioned manner, thereby ensuring the smooth operation of the subsequent motor.

[0101] This embodiment provides a method in which, when it is determined that the motor is abnormal, the control unit drives the motor again by increasing the period length of the same-phase period to ensure that the motor can run smoothly subsequently.

[0102] See also Figure 6 , which shows a motor control method provided by the fourth embodiment of the present application. Specifically, the method may include the following steps.

[0103] Step S600: initializing the motor.

[0104] As an implementation mode, the control unit reads the preset initialization parameters and initializes the relevant parameters of the motor. In this embodiment, the control unit initializes the number of restarts of the motor, StallCount, to 0.

[0105] Step S605, entering the rotor positioning state.

[0106] Step S610, determining whether the rotor has completed positioning.

[0107] If yes, execute step S615; if no, execute step S605.

[0108] Specifically, the positioning process of the rotor by the control unit can refer to the relevant introduction in step S410, which will not be repeated here.

[0109] Step S615, entering the motor dragging state.

[0110] Step S620, calculate the duty cycle, send a PWM signal corresponding to the duty cycle, and detect the working current of the motor.

[0111] In this embodiment, the control unit calculates the duty cycle by the following formula.

[0112] P=[20+StallCount*5]%

[0113] Where P is the duty cycle and StallCount is the number of times the motor is restarted.

[0114] Step S625, determining whether the operating current is greater than a specified current value corresponding to the duty cycle.

[0115] If not, execute step S630; if so, execute step S635.

[0116] Specifically, the process of determining the designated current value may refer to the relevant introduction in step S450, which will not be repeated here.

[0117] Step S630, entering the motor running state.

[0118] Step S635, stop sending the PWM signal and increase the restart count by 1.

[0119] Step S640, determining whether the restart times are less than a specified times.

[0120] If yes, execute step S605; if no, execute step S645.

[0121] Step S645, determining the current state of the motor as a fault state.

[0122] Step S650, sending the fault code to the host computer.

[0123] Step S655, the system reports a fault.

[0124] See also Figure 7, which shows a control device 700 for a motor provided in an embodiment of the present application. The control device 700 includes a sending module 710, an acquisition module 720 and a detection module 730. Among them, the sending module 710 is used to send a first pulse width modulation signal when the motor is in a dragging state; the duty cycle of the first pulse width modulation signal is a first duty cycle. The acquisition module 720 is used to obtain the working current of the motor. The detection module 730 is used to detect whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle.

[0125] In some embodiments, the detection module 730 is specifically used to determine the specified current value corresponding to the first duty cycle based on the first duty cycle and a preset first mapping relationship; the first mapping relationship represents the correspondence between different duty cycles and different specified current values. When the working current is greater than the specified current value corresponding to the first duty cycle, it is determined that the motor is in an abnormal state.

[0126] In some embodiments, the control device 700 further includes a restart module (not shown in the figure), wherein after the detection module 730 is used to detect whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle, the restart module is used to restart the motor when it is detected that the motor is in an abnormal state. The sending module 710 is also used to send a second pulse width modulation signal when the motor is in a dragging state; the duty cycle of the second pulse width modulation signal is a second duty cycle, the second duty cycle is greater than the first duty cycle, and the working current of the motor under the second pulse width modulation signal is less than or equal to the specified current value corresponding to the second duty cycle.

[0127] In some embodiments, the period duration of the in-phase period of the first pulse width modulation signal is the first period duration. The control device 700 also includes a restart module (not shown in the figure), wherein, after the detection module 730 is used to detect whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle, the restart module is used to restart the motor when it is detected that the motor is in an abnormal state. The sending module 710 is also used to send a third pulse width modulation signal when the motor is in a dragging state; the period duration of the in-phase period of the third pulse width modulation signal is the second period duration; the second period duration is greater than the first period duration, and the duty cycle of the third pulse width modulation signal is the same as the duty cycle of the first pulse width modulation signal; the working current of the motor under the third pulse width modulation signal is less than or equal to the specified current value corresponding to the first duty cycle.

[0128] In some embodiments, the restart module is specifically used to update the restart times of the motor when it is detected that the motor is in an abnormal state; and restart the motor when the updated restart times are less than the specified times.

[0129] In some embodiments, the control device 700 further includes a positioning module (not shown in the figure) and a control module (not shown in the figure). The positioning module is used to position the rotor of the motor before the sending module 710 sends the first pulse width modulation signal when the motor is in the dragging state. The control module is used to control the motor to enter the dragging state when the initial position of the rotor is determined.

[0130] In some embodiments, the positioning module is specifically used to obtain the positioning current of the motor; based on the positioning current and a preset second mapping relationship, determine the initial position of the rotor corresponding to the positioning current; the second mapping relationship represents the correspondence between different positioning currents and different initial positions of the rotor.

[0131] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and modules can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here.

[0132] In several embodiments provided in the present application, the coupling between modules may be electrical, mechanical or other forms of coupling.

[0133] In addition, each functional module in each embodiment of the present application can be integrated into a control module, or each module can exist physically separately, or two or more modules can be integrated into one module. The above integrated modules can be implemented in the form of hardware or software functional modules.

[0134] The present application provides a control device for a motor, which can determine whether the motor is in an abnormal state by comparing the magnitude relationship between the working current and the specified current value corresponding to the first duty cycle. Furthermore, since the working current in the present application is measured under a first pulse width modulation signal with a duty cycle of the first duty cycle, and the specified current value used to determine whether the motor is abnormal corresponds to the first duty cycle. Therefore, based on the specified current value set in the present application, it is possible to more accurately determine whether the working current is too large, thereby improving the accuracy of detecting whether the rotor is out of step.

[0135] See also Figure 8 , which shows that the embodiment of the present application further provides a motor 800, which includes: one or more processors 810, a memory 820, and one or more applications. Among them, the one or more applications are stored in the memory and are configured to be executed by one or more processors, and the one or more applications are configured to execute the above method.

[0136] The processor 810 may include one or more processing cores. The processor 810 uses various interfaces and lines to connect various parts of the entire battery management system, and executes various functions and processes data of the battery management system by running or executing instructions, programs, code sets or instruction sets stored in the memory 820, and calling data stored in the memory 820. Optionally, the processor 810 can be implemented in at least one hardware form of digital signal processing (DSP), field programmable gate array (FPGA), and programmable logic array (PLA). The processor 810 can integrate one or more combinations of a central processing unit 810 (CPU), a graphics processing unit 810 (GPU), and a modem. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing display content; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 810, but may be implemented separately through a communication chip.

[0137] The memory 820 may include a random access memory 820 (Random Access Memory, RAM), and may also include a read-only memory 820 (Read-Only Memory, ROM). The memory 820 may be used to store instructions, programs, codes, code sets, or instruction sets. The memory 820 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the various method embodiments described below, etc. The data storage area may also store data created by the electronic device during use (such as a phone book, audio and video data, chat record data), etc.

[0138] See also Fig. 9 , Fig. 9 It is schematically shown that an embodiment of the present application further provides a computer-readable storage medium 900, in which computer program instructions 910 are stored. The computer program instructions 910 can be called by a processor to execute the method described in the above embodiment.

[0139] The computer-readable storage medium 900 may be, for example, a flash memory, an electrically erasable programmable read-only memory (EEPROM), an electrically programmable read-only memory (EPROM), a hard disk, or a read-only memory (ROM). Optionally, the computer-readable storage medium includes a non-transitory computer-readable storage medium. The computer-readable storage medium 900 has storage space for computer program instructions 910 for executing any method steps of the above method. These computer program instructions 910 may be read from one or more computer program products or may be written into one or more computer program products.

[0140] The above are only preferred embodiments of the present application, and are not intended to limit the present application in any form. Although the present application has been disclosed as above with preferred embodiments, it is not intended to limit the present application. Any technical personnel in the field can make some changes or modify the technical contents disclosed above into equivalent embodiments without departing from the scope of the technical solution of the present application. However, any brief modifications, equivalent changes and modifications made to the above embodiments based on the technical essence of the present application without departing from the content of the technical solution of the present application are still within the scope of the technical solution of the present application.

Claims

1. A method for controlling a motor, characterized in that: include: When the motor is in a dragging state, sending a first pulse width modulation signal; The duty cycle of the first pulse width adjustment signal is a first duty cycle; Obtaining a working current of the motor; Based on the working current and a specified current value corresponding to the first duty cycle, it is detected whether the motor is in an abnormal state.

2. The control method according to claim 1, characterized in that: The detecting whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle includes: Based on the first duty cycle and a preset first mapping relationship, determining a specified current value corresponding to the first duty cycle; the first mapping relationship represents a correspondence between different duty cycles and different specified current values; When the operating current is greater than a specified current value corresponding to the first duty cycle, it is determined that the motor is in an abnormal state.

3. The control method according to claim 1, characterized in that: After detecting whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle, the method further includes: When detecting that the motor is in an abnormal state, restarting the motor; When the motor is in the drag state, a second pulse width modulation signal is sent; the duty cycle of the second pulse width modulation signal is a second duty cycle, the second duty cycle is greater than the first duty cycle, and the operating current of the motor under the second pulse width modulation signal is less than or equal to the specified current value corresponding to the second duty cycle.

4. The control method according to claim 1, characterized in that: The period duration of the in-phase period of the first pulse width modulation signal is a first duration; After detecting whether the motor is in an abnormal state based on the working current and the specified current value corresponding to the first duty cycle, the method further includes: When detecting that the motor is in an abnormal state, restarting the motor; When the motor is in the drag state, a third pulse width modulation signal is sent; the period length of the in-phase period of the third pulse width modulation signal is a second period length; the second period length is greater than the first period length, and the duty cycle of the third pulse width modulation signal is the same as the duty cycle of the first pulse width modulation signal; the operating current of the motor under the third pulse width modulation signal is less than or equal to the specified current value corresponding to the first duty cycle.

5. The control method according to claim 3 or 4, characterized in that: When detecting that the motor is in an abnormal state, restarting the motor comprises: When it is detected that the motor is in an abnormal state, updating the restart times of the motor; When the updated restart number is less than a specified number, the motor is restarted.

6. The control method according to claim 1, characterized in that: Before sending the first pulse width modulation signal when the motor is in the driving state, the method further includes: Positioning the rotor of the motor; When the initial position of the rotor is determined, the motor is controlled to enter a drag state.

7. The control method according to claim 6, characterized in that: Positioning the rotor of the motor includes: Obtaining a positioning current of the motor; Based on the positioning current and a preset second mapping relationship, an initial position of the rotor corresponding to the positioning current is determined; the second mapping relationship represents a correspondence between different positioning currents and different initial positions of the rotor.

8. A control device for a motor, characterized in that: include: A sending module, used for sending a first pulse width modulation signal when the motor is in a dragging state; The duty cycle of the first pulse width adjustment signal is a first duty cycle; An acquisition module, used for acquiring the working current of the motor; A detection module is used to detect whether the motor is in an abnormal state based on the working current and a specified current value corresponding to the first duty cycle.

9. A motor, characterized in that: The motor comprises: one or more processors; Memory; One or more applications, wherein one or more of the applications are stored in the memory and configured to be executed by one or more of the processors, and one or more of the applications are configured to execute the method according to any one of claims 1-7.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer program instructions, and the computer program instructions can be called by a processor to execute the method according to any one of claims 1 to 7.