Motor control device, motor control method, motor control device and electronic equipment
By using voltage sampling and current sampling techniques to determine the rotor position of the motor in electronic equipment, the problem of dead-point of single-phase motors is solved, and the reliability and accuracy of motor control is improved.
Patent Information
- Application Number
- CN202310757228.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-25
- Publication Date
- 2024-12-27
AI Technical Summary
Due to the dead point of zero torque, single-phase motors have low reliability in motor control by electronic devices, making it difficult to accurately identify the initial rotor position, affecting the normal start-up and operation of the motor.
The bus voltage and response current of the motor are obtained through the voltage sampling circuit and the current sampling circuit, and the rotor position of the motor is determined by using the main control chip, and the motor rotation is controlled according to this position to ensure that the motor operates while accurately identifying the rotor position.
It improves the reliability of motor control, avoids the problem of motor start dead points, and ensures the normal operation and control accuracy of the motor.
Smart Images

Figure CN119210224A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of electronic technology, and in particular to a motor control device, a motor control method, a device and an electronic device. Background Art
[0002] With the development of science and technology, electronic devices are used more and more widely and have more and more functions. They have become one of the necessities in people's daily life. At present, electronic devices including motors are becoming more and more common. In the related technology, since the single-phase motor has only one set of stator windings, there is a dead point where the torque is zero. Therefore, the control of the motor by the electronic device has the problem of low reliability. Summary of the invention
[0003] In view of the above problems, the present application proposes a motor control device, a motor control method, a device and an electronic device, which can determine the initial rotor position of the motor by driving the bus voltage of the motor and the response current of the motor, and control the rotation of the motor based on the rotor position. While accurately identifying the rotor position of the motor, the motor operation can be controlled, thereby improving the reliability of motor control.
[0004] In the first aspect, the embodiment of the present application provides a motor control device, which includes a voltage sampling circuit, a current sampling circuit and a main control chip. The voltage sampling circuit is used to connect to the motor and collect the bus voltage that drives the motor to work during the operation of the motor; the current sampling circuit is used to connect to the motor and collect the response current of the motor during the operation of the motor; the main control chip is connected to the voltage sampling circuit and the current sampling circuit respectively, and is used to determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position.
[0005] In a second aspect, an embodiment of the present application provides a motor control method, which is applied to the motor control device provided in the first aspect. The method includes: during the operation of the motor, obtaining the bus voltage that drives the motor to work and acquired by the voltage sampling circuit, and obtaining the response current of the motor to work and acquired by the current sampling circuit; determining the rotor position of the motor according to the bus voltage and the response current, and controlling the rotation of the motor according to the rotor position.
[0006] In a third aspect, an embodiment of the present application provides a motor control device, which is applied to the motor control device provided in the first aspect above. The motor control device includes: a bus voltage and response current acquisition module and a motor rotation control module. Among them, the bus voltage and response current acquisition module is used to obtain the bus voltage that drives the motor to work and acquired by the voltage sampling circuit during the operation of the motor, and to obtain the response current of the motor to work acquired by the current sampling circuit; the motor rotation control module is used to determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position.
[0007] In a fourth aspect, an embodiment of the present application provides an electronic device, comprising: a motor; 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 method of the second aspect described above.
[0008] In a fifth aspect, an embodiment of the present application provides a computer-readable storage medium, in which a program code is stored, and the program code is called by a processor to execute the method of the second aspect as described above.
[0009] The motor control device, motor control method, device and electronic device provided in the embodiments of the present application obtain the bus voltage of the driving motor collected by the voltage sampling circuit and the response current of the motor collected by the current sampling circuit during the operation of the motor; determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position, and then determine the initial rotor position of the motor by the bus voltage of the driving motor and the response current of the motor, and control the rotation of the motor based on the rotor position, control the operation of the motor while accurately identifying the rotor position of the motor, and improve the reliability of motor control. BRIEF DESCRIPTION OF THE DRAWINGS
[0010] 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.
[0011] Figure 1 A schematic diagram showing the rotor position of a motor provided by an embodiment of the present application is shown.
[0012] Figure 2 A structural block diagram of a motor control device provided by an embodiment of the present application is shown.
[0013] Figure 3 A structural block diagram of a motor control device provided by an embodiment of the present application is shown.
[0014] Figure 4 A circuit structure schematic diagram of a pre-driving circuit provided in one embodiment of the present application is shown.
[0015] Figure 5 A circuit structure schematic diagram of an inverter circuit provided in one embodiment of the present application is shown.
[0016] Figure 6 A circuit structure diagram of a voltage sampling circuit provided in one embodiment of the present application is shown.
[0017] Figure 7 A circuit structure schematic diagram of a first current sampling circuit provided in an embodiment of the present application is shown.
[0018] Figure 8 A circuit structure schematic diagram of a second current sampling circuit provided in an embodiment of the present application is shown.
[0019] Fig. 9 A flow chart of a motor control method provided by an embodiment of the present application is shown.
[0020] Fig.10 A flow chart of a motor control method provided by an embodiment of the present application is shown.
[0021] Fig.11 A flow chart of a motor control method provided by an embodiment of the present application is shown.
[0022] Fig.12 A structural block diagram of a motor control device provided by an embodiment of the present application is shown.
[0023] Fig.13 A structural block diagram of an electronic device provided by an embodiment of the present application is shown.
[0024] Fig.14 A structural block diagram of a computer-readable storage medium provided by an embodiment of the present application is shown. DETAILED DESCRIPTION
[0025] 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.
[0026] 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.
[0027] With the development of science and technology, electronic devices are becoming more and more diverse. At present, electronic devices including motors are becoming more and more common, such as vacuum cleaners, washing machines, exhaust fans, etc. Correspondingly, the reliability requirements for motor control in related technologies are getting higher and higher. In the related technology, a solution of unequal air gap design is proposed to solve the problem of dead point of single-phase motors, so that the position of the rotor when the motor starts avoids the dead point. Among them, the normal n-pole motor rotor in a single-phase motor has 2n initial positions in a static state. In the process of controlling a single-phase motor, each time the motor is started, the initial position of the rotor needs to be determined, and then the motor current commutation is controlled in the required direction.
[0028] For example, see Figure 1 , which shows a schematic diagram of the rotor position of a motor provided by an embodiment of the present application. In order to avoid the problem of a dead point at the start of a single-phase motor, the stator core of the motor is designed with unequal air gaps, wherein the motor includes a pair of pole motor rotors, and the rotor is affected by the cogging torque in a stationary state. The initial position of the rotor of the motor has and only has two initial positions, such as Figure 1 Position 1 as shown, where the N pole of the rotor is at an oblique upper position and the S pole is at an oblique lower position; Figure 1 Position 2 is shown, in which the N pole of the rotor is diagonally downward and the S pole is diagonally upward.
[0029] Therefore, in the related art, since the single-phase motor has only one set of stator windings, there is a dead point where the torque is zero, and therefore, the control of the motor by the electronic equipment has a problem of low reliability.
[0030] In view of the above problems, the inventors have discovered after long-term research and proposed a motor control device, motor control method, device and electronic equipment provided in the embodiments of the present application, which determines the initial rotor position of the motor by driving the bus voltage of the motor and the response current of the motor, and controls the rotation of the motor based on the rotor position. When the rotor position of the motor is accurately identified, the motor is controlled to work, thereby improving the reliability of controlling the motor. Among them, the specific motor control method is described in detail in the subsequent embodiments.
[0031] See also Figure 2, which shows a schematic diagram of a motor control device provided by an embodiment of the present application. In the embodiment of the present application, the motor control device 10 may include a voltage sampling circuit 101, a current sampling circuit 102 and a main control chip 103.
[0032] Among them, the voltage sampling circuit 101 can be used to connect with the motor and collect the bus voltage that drives the motor to work during the operation of the motor; the current sampling circuit 102 can be used to connect with the motor and collect the response current of the motor during the operation of the motor; the main control chip 103 can be connected to the voltage sampling circuit 101 and the current sampling circuit 102 respectively, and can be used to determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position.
[0033] The input end of the voltage sampling circuit 101 may be connected to the input end of the driving circuit of the motor, and the output end of the voltage sampling circuit 101 may be connected to the main control chip 103 .
[0034] For example, see Figure 3 , which shows a schematic diagram of the port connection of the voltage sampling circuit provided in an embodiment of the present application. Among them, the input end of the voltage sampling circuit 101 can be connected to the input end of the motor drive circuit, and the output end of the voltage sampling circuit 101 can be connected to the main control chip 103. Among them, the input end of the motor drive circuit may include a power supply unit; wherein the voltage sampling circuit 101 can be connected to the power supply unit of the motor drive circuit, and is used to sample the bus voltage of the drive motor, which can also be understood as being used to sample the energy of the drive motor.
[0035] In some embodiments, the motor drive circuit can be connected to the main control chip 103, or to an associated electronic device, for receiving a drive signal sent by the main control chip 103 or an associated electronic device, and driving the motor to work in response to the drive signal. Optionally, the motor drive circuit can include a pre-drive circuit and an inverter circuit.
[0036] Exemplarily, the input end of the pre-driving circuit can be connected to the main control chip 103 to receive the driving signal sent by the main control chip 103; the output end of the pre-driving circuit can be connected to the inverter circuit to control the conduction of the inverter circuit in response to the driving signal, and control the flow direction of the current in the inverter circuit. The inverter circuit can be connected to the motor to drive the motor to work.
[0037] Wherein, the pre-drive circuit may be composed of one or more circuit elements such as resistors, capacitors, and diodes. Wherein, the inverter circuit may be composed of one or more circuit elements such as resistors, capacitors, diodes, and electronic switches. Wherein, the electronic switch included in the inverter circuit may include a field effect transistor MOS tube. Exemplarily, the inverter circuit may include an "H bridge" composed of four MOS tubes; accordingly, the inverter circuit is connected to the motor, and different current directions can be provided for the motor drive through different MOS tube conduction modes.
[0038] Among them, considering that the driving current of the MOS tube is generally greater than 100mA, the chip IO output capacity of the main control chip 103 is generally less than or equal to 10mA. Optionally, the pre-drive circuit may include a pre-drive chip, which can receive the drive signal sent by the main control chip 103, and turn on the corresponding MOS tube in response to the drive signal to drive the motor to work. Among them, the drive signal may include the current flow direction of the motor. Further, the pre-drive circuit can turn on the electronic switch included in the inverter circuit based on the drive signal, control the inverter circuit to turn on the current flow corresponding to the drive signal to control the motor to work. Among them, the pre-drive chip can include a driver chip such as an LN8362 chip and a SOT23-6 chip, which is not limited here.
[0039] For example, see Figure 4 , which shows a schematic diagram of the circuit structure of the pre-drive circuit provided in an embodiment of the application. The pre-drive circuit is composed of resistors R1, R2, R3, R4, R5, R6, capacitors C1, C2, C3, C4, diodes D1, D2, pre-drive chips U1, U2, as shown in FIG. Figure 4 The connection method shown is composed of the following. The pre-drive circuit can receive the drive signal PWM_UH high-level signal and PWM_UL low-level signal sent by the main control chip 103 or the associated electronic device; the pre-drive chip U1 included in the pre-drive circuit can output the U signal, HOU signal and LOU signal to the inverter circuit based on the drive signal, and the pre-drive chip U2 included in the pre-drive circuit can output the V signal, HOU signal and LOU signal to the inverter circuit based on the drive signal. The U signal, V signal, HOU signal and LOU signal output by the pre-drive circuit can control the conduction mode of the inverter circuit, and thus control the flow direction of the motor current.
[0040] In some embodiments, the input end of the motor driving circuit may be connected to a power supply unit, wherein the power supply unit may provide a voltage to drive the motor to work to the driving circuit. The power supply unit may provide a 265V voltage, a 220V voltage, a 175V voltage, etc., which are not limited here.
[0041] Optionally, the power supply unit may include a unit for rectifying the 310V mains power to obtain an output voltage. Exemplarily, the power supply unit may filter the mains power with an electrolytic capacitor and then input the mains power into the motor drive circuit to provide the drive circuit with a bus voltage for driving the motor to work.
[0042] For example, see Figure 5 , which shows a schematic diagram of the circuit structure of an inverter circuit provided by an embodiment of the present application. The inverter circuit comprises resistors R7, R8, R9, R10, R11, R12, R13, R14, R15, R16, capacitors C5, C6, MOS1, MOS2, MOS3, MOS4, as shown in FIG. Figure 5 The connection method shown in the figure is as follows. Among them, capacitors C5 and C6 can rectify and filter the 310V mains power to obtain the bus voltage for driving the motor. Among them, MOS1, MOS2, MOS3, and MOS4 can form an "H bridge", MOS1 and MOS3 are turned on as one group, and MOS2 and MOS4 are turned on as another group.
[0043] Please refer to Figure 4 and Figure 5 , wherein the U signal, V signal, HOU signal and LOU signal output by the pre-drive circuit can control the conduction of MOS1 and MOS4, and the U signal, V signal, HOU signal and LOU signal output by the pre-drive circuit can also control the conduction of MOS2 and MOS3. The motor can be connected to the inverter circuit. After the MOS tube is turned on, the current can flow through the motor based on the direction of U—>V, and can also flow through the motor based on the direction of V—>U, thereby driving the motor to work.
[0044] For example, please refer to Figure 5 and Figure 6 , Figure 6 FIG. 1 is a schematic diagram showing the circuit structure of a voltage sampling circuit provided by an embodiment of the present application. The voltage sampling circuit 101 is composed of a resistor R17, a resistor R18, a resistor R19, a resistor R20, a resistor R21, a resistor R22, a capacitor C7, a diode D3, and a Figure 6 The input end of the voltage sampling circuit 101 can be connected to the input end of the motor drive circuit, which can be understood as the input end of the voltage sampling circuit 101 is connected to the power supply unit of the motor drive circuit. Figure 6 The 310V voltage shown is understood as the input end of the voltage sampling circuit 101; Figure 5The 310V of the inverter circuit shown is understood as the input voltage of the voltage sampling circuit 101. The output end of the voltage sampling circuit 101 can be connected to the main control chip 103, and the output end of the voltage sampling circuit 101 can output the collected bus voltage U_AD of the driving motor.
[0045] In some embodiments, the current sampling circuit 102 may include a first current sampling circuit, a first end of the first current sampling circuit may be used to connect to an input end of a first resistor included in a drive circuit of the motor, a second end of the first current sampling circuit may be used to be grounded, a third end of the first current sampling circuit may be used to connect to a main control chip, and the first current sampling circuit may be used to collect a first current corresponding to the first resistor.
[0046] The first current sampling circuit may be composed of one or more circuit elements such as resistors, capacitors, and comparators. Figure 5 and Figure 7 ,in, Figure 7 FIG. 1 is a schematic diagram showing the circuit structure of a first current sampling circuit provided by an embodiment of the present application. The first current sampling circuit comprises a resistor R23, a resistor R24, a capacitor C8, a comparator 1, and a Figure 7 The first end of the first current sampling circuit can be understood as follows: Figure 7 The I_shunt1 input terminal can be used to connect to the first resistor (such as Figure 5 The first current sampling circuit is connected to the input end of the resistor R16 shown in the figure, the second end of the first current sampling circuit can be used for grounding, and the third end of the first current sampling circuit can be used for connecting to the main control chip 103, wherein the third end of the first current sampling circuit can send the voltage I_AD of the first resistor to the ground to the main control chip 103. Further, the main control chip 103 can obtain the first current corresponding to the first resistor according to the voltage I_AD and the resistance of the first resistor using the Ohm's law formula. Accordingly, it can be understood that the first current sampling circuit can be used to collect the first current corresponding to the first resistor.
[0047] Among them, the current sampling circuit 101 can also include a second current sampling circuit, the first end of the second current sampling circuit can be used to connect to the first end of the second resistor included in the driving circuit, the second end of the second current sampling circuit can be used to connect to the input end of the first resistor included in the driving circuit, the third end of the second current sampling circuit can be used to connect to the main control chip 103, and the second current sampling circuit can be used to collect a second current corresponding to the first resistor and the second resistor, wherein the first resistor can be connected in series with the second resistor.
[0048] The second current sampling circuit may be composed of one or more circuit elements such as resistors, capacitors, and comparators. Figure 5 and Figure 8 ,in, Figure 8 FIG. 1 shows a schematic diagram of the circuit structure of a second current sampling circuit provided by an embodiment of the present application. The second current sampling circuit comprises a resistor R25, a resistor R26, a capacitor C9, a comparator 2, and a Figure 8 The connection method shown is composed
[0049] The first end of the second current sampling circuit can be understood as follows: Figure 8 The iv+ input terminal can be used to connect to the second resistor (such as Figure 5 A first end of a resistor R15) is connected.
[0050] The second end of the second current sampling circuit can be understood as follows: Figure 8 The input end of I_shunt1 can be used to connect to the first resistor (such as Figure 5 The input terminal of the resistor R16 is connected as shown.
[0051] The third end of the second current sampling circuit can be used to connect to the main control chip 103, wherein the third end of the second current sampling circuit can send the voltage I_U of the first resistor and the second resistor to the ground to the main control chip 103. Further, the main control chip 103 can obtain the second current corresponding to the first resistor and the second resistor based on the Ohm's law formula according to the voltage I_U, the first resistor and the second resistor. Accordingly, it can be understood that the second current sampling circuit can be used to collect the second current corresponding to the first resistor and the second resistor.
[0052] It can be understood that, when MOS1 and MOS4 are turned on, the first resistor can be connected in series with the second resistor, and when MOS2 and MOS3 are turned on, the first resistor can be connected in parallel with the second resistor.
[0053] Wherein, in the case where the first resistor is connected in series with the second resistor, the current sampling circuit may include a first current sampling circuit and / or a second current sampling circuit. Wherein, the second current sampling circuit may sample the voltage of the first resistor and the second resistor to the ground, and send the collected voltage of the first resistor and the second resistor to the ground to the main control chip 103 based on the third terminal; accordingly, the main control chip 103 may obtain the second current based on the voltage of the first resistor and the second resistor to the ground, the resistance value of the first resistor, and the resistance value of the second resistor. Wherein, the first current sampling circuit may sample the voltage of the first resistor to the ground, and send the collected voltage of the first resistor to the ground to the main control chip 103 based on the third terminal; accordingly, the main control chip 103 may obtain the first current based on the voltage of the first resistor to the ground and the resistance value of the first resistor, wherein the first current is the same as the second current. Wherein, the main control chip 103 may obtain the first current as the response current, or may obtain the second current and use the second current as the response current.
[0054] Wherein, when the first resistor is connected in parallel with the second resistor, the current sampling circuit may include a first current sampling circuit and / or a second current sampling circuit. Wherein, the first current sampling circuit may sample the voltage of the first resistor to the ground, and send the collected voltage of the first resistor to the ground to the main control chip 103 based on the third terminal; accordingly, the main control chip 103 may obtain the first current based on the voltage of the first resistor to the ground and the resistance value of the first resistor. Wherein, the main control chip 103 may obtain the first current as the response current.
[0055] Optionally, the main control chip 103 may include a microcontroller unit (MCU). In this embodiment, the main control chip 103 may determine the rotor position of the motor according to the bus voltage obtained from the voltage sampling circuit and the response current obtained from the current sampling circuit, and control the motor to rotate according to the rotor position, and then determine the initial rotor position of the motor by driving the bus voltage of the motor and the response current of the motor, and control the motor to rotate based on the rotor position, and control the motor to start working when the rotor position of the motor is accurately identified, thereby improving the reliability of controlling the motor.
[0056] See also Fig. 9 , Fig. 9The flow chart of the motor control method provided by an embodiment of the present application is shown. The motor control method is applied to the motor control device provided by an embodiment of the present application, and the initial rotor position of the motor is determined by the bus voltage of the driving motor and the response current of the motor, and the motor rotation is controlled based on the rotor position. When the rotor position of the motor is accurately identified, the motor operation is controlled, and the reliability of controlling the motor is improved. In a specific embodiment, the motor control method can be applied to Fig.12 The motor control device 200 and the electronic device 100 ( Fig.13 ). The following will take an electronic device as an example to illustrate the specific process of this embodiment. Of course, it can be understood that the electronic device used in this embodiment may include a washing machine, a hair dryer, an exhaust fan, and other electronic devices including the motor control device provided in an embodiment of the present application, which are not limited here. Among them, the electronic device can be connected to the motor. Fig. 9 The process shown is described in detail, and the motor control method may specifically include the following steps:
[0057] Step S110: During the operation of the motor, the bus voltage for driving the motor to operate is acquired by the voltage sampling circuit, and the response current of the motor to operate is acquired by the current sampling circuit.
[0058] In this embodiment, the electronic device may include a motor, and the electronic device may also be connected to one or more motors. The motor may include a single-phase motor; the single-phase motor may adopt an uneven air gap design on the stator; the single-phase motor may generate a magnetic resistance torque based on the uneven air gap design, ensuring that the rotor of the motor does not stop at a dead point with zero torque when the power is cut off and the reliability of controlling the rotation of the motor is ensured.
[0059] The electronic device may further include a motor control device, wherein the motor control device may include a voltage sampling circuit, a current sampling circuit and a main control chip. The voltage sampling circuit may be used to connect to the motor, and collect the bus voltage that drives the motor to work during the operation of the motor. The current sampling circuit may be used to connect to the motor, and collect the response current of the motor during the operation of the motor. The main control chip may be connected to the voltage sampling circuit and the current sampling circuit respectively, and used to determine the initial rotor position of the motor when it is currently started according to the bus voltage and the response current, and perform subsequent control operations on the motor according to the rotor position, such as controlling the motor to rotate.
[0060] In some embodiments, in order to avoid the dead point when starting a single-phase motor, the electronic device can fix the current direction of the driving motor when starting the motor, and continue to drive the motor for a first preset time. Accordingly, the electronic device can obtain the bus voltage that drives the motor to work collected by the voltage sampling circuit during the operation of the motor, and obtain the response current of the motor collected by the current sampling circuit. Among them, the first preset time can be pre-set in the electronic device, or the electronic device can obtain it from an associated cloud or electronic device through wireless communication technology (such as Bluetooth, WiFi, Zigbee technology and other wireless technologies). Exemplarily, the first preset time can be a time length less than or equal to 10 milliseconds, which is not limited here.
[0061] As an implementable manner, the electronic device can fix the current direction of the motor when the motor is started, and continuously drive the motor to work for a second preset time under the drive of the current of the preset duty cycle during the process of determining the rotor position. Accordingly, the electronic device can obtain the bus voltage sampled by the voltage sampling circuit to drive the motor to work, and obtain the response current of the motor sampled by the current sampling circuit during the operation of the motor. Among them, the second preset time can be pre-set in the electronic device, or the electronic device can obtain it from the associated cloud or electronic device through wireless communication technology. Among them, the second preset time can be equal to or different from the first preset time, which is not limited here. As another implementable manner, the electronic device can include one or more motors, or be connected to one or more motors. Among them, the electronic device can receive a first drive instruction input by a user, wherein the first drive instruction can carry the identification of the target drive motor, the preset duty cycle of the current of the drive motor, and the preset time. Correspondingly, the electronic device can determine that the motor needs to be controlled to work after receiving the first drive instruction, and further, the electronic device can parse the first drive instruction to obtain the identification of the target drive motor, the preset duty cycle of the current of the drive motor, and the preset time. Among them, the electronic device can determine a motor corresponding to the identification of the target drive motor from one or more motors included in the electronic device as the target drive motor based on the identification of the target drive motor, and the electronic device can perform subsequent rotor position determination operations on the target drive motor based on a preset duty cycle and preset duration of the current of the drive motor.
[0062] As another practicable manner, the electronic device may include a motor, or the electronic device is connected to a motor, that is, the motor controlled by the electronic device is fixed. Wherein, the preset duration of the electronic device briefly driving the motor to work to determine the rotor position of the motor and the preset duty cycle of the current may also be fixed. Wherein, the electronic device may receive a second drive instruction input by a user, wherein the second drive instruction does not carry an identification of the target drive motor, a preset duty cycle of the current of the drive motor, and a preset duration. Accordingly, the electronic device may determine that the motor needs to be controlled upon receiving the second drive instruction, and further, the electronic device may perform subsequent rotor position determination operations on the motor based on the preset duty cycle and preset duration of the current of the drive motor that remain fixed.
[0063] Optionally, the preset duty cycle of the current can be set by the user or obtained through third-party experimental data. Exemplarily, the preset duty cycle of the current is 25%, which is determined by third-party experimental data (such as motor parameters). The preset duration can be set by the user or obtained through third-party experimental data. Exemplarily, the preset duration is 10 milliseconds, which is obtained through third-party experimental data.
[0064] In some embodiments, the electronic device obtains the voltage of the driving motor sampled by the voltage sampling circuit as the bus voltage, and can also determine the voltage of the driving circuit of the input motor, such as the mains, as the bus voltage by table lookup calculation, and can also determine the AC voltage of the input motor obtained by sampling as the bus voltage by directly sampling the AC voltage. Optionally, the electronic device obtains the response current by obtaining the current of the motor sampled by the current sampling circuit under the bus voltage drive as the response current. Among them, the electronic device can control the current sampling circuit to obtain the response current by means of the built-in operational amplifier of the MCU, and can also control the current sampling circuit to obtain the response current by means of an external current sampling operational amplifier, which is not limited here.
[0065] Step S120: determining the rotor position of the motor according to the bus voltage and the response current, and controlling the rotation of the motor according to the rotor position.
[0066] In some embodiments, after the electronic device obtains the bus voltage of the motor drive and the response current during the motor drive process, it can determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position.
[0067] In this embodiment, the stator in the motor is designed with unequal air gaps, wherein the motor may include a pair of or more pairs of pole motor rotors. Exemplarily, the motor includes a pair of pole motor rotors, and correspondingly, a pair of pole motors have two initial positions when the motor is stationary. At the two initial positions, the motor has different current responses due to the salient polarity of the motor. Among them, the electronic device can conduct a preset duty cycle current to any phase of the motor, and during the process of driving the motor to work for a preset time, the current rotor position of the motor is determined by combining the bus voltage of the driving motor collected by the voltage sampling circuit and the response current of the motor drive collected by the current sampling circuit under the current bus voltage. Among them, the electronic device can control the motor to perform subsequent rotation operations according to the rotor position.
[0068] Among them, the process of the electronic device determining the rotor position of the motor according to the bus voltage and the response current may include that the electronic device can determine the energy input by the current motor drive circuit power supply unit according to the bus voltage sampled by the voltage sampling circuit, such as the current mains input voltage of 175V to 264V. Among them, the electronic device can be pre-set with a voltage and current correspondence relationship, and the electronic device can also obtain the voltage and current correspondence relationship from an associated cloud or electronic device. Among them, the voltage and current correspondence relationship can be a voltage and current correspondence table, or it can be a calculation relationship formula of voltage and current.
[0069] Exemplarily, the electronic device may be pre-set with programming codes corresponding to the voltage and current correspondence table, such as:
[0070] / ****MotorPark TABLE**** /
[0071] #define Volume_175 1438
[0072] #define Volume_180 1473
[0073] #define Volume_185 1515
[0074] #define Volume_190 1561
[0075] #define Volume_195 1598
[0076] #define Volume_200 1635
[0077] #define Volume_205 1680
[0078] #define Volume_210 1716
[0079] #define Volume_215 1762
[0080] #define Volume_220 1796
[0081] #define Volume_225 1838
[0082] #define Volume_230 1879
[0083] #define Voltage_235 1918
[0084] #define Volume_240 1961
[0085] #define Volume_245 2001
[0086] #define Volume_250 2042
[0087] #define Volume_255 2080
[0088] #define Volume_260 2126
[0089] #define Volume_265 2167
[0090] The current corresponding to different voltages Voltage can be set based on macro definition. For example, in the voltage-current correspondence MotorPark TABLE, the current corresponding to the voltage 175V can be set to 1438, that is, #define Voltage_1751438.
[0091] Among them, the electronic device can determine the preset current threshold corresponding to the bus voltage from the corresponding relationship between voltage and current. For example, the bus voltage is 220V and the preset current threshold corresponding to the bus voltage can be determined as 1796 from the corresponding relationship between voltage and current.
[0092] Optionally, the electronic device can determine the rotor position of the motor according to the relationship between the preset current threshold and the response current. Figure 1 , wherein the motor includes a pair of poles of the motor rotor, and the rotor position of the motor in the stationary state can be position one or position two. Figure 5, the electronic device can supply any phase of the motor, such as passing the current U->V to the motor, that is, MOS1 and MOS4 are turned on, and then the circuit driving the motor is turned on. Among them, the electronic device can control the motor to drive a preset duration (such as less than or equal to 10 milliseconds) with a current of a preset duty cycle (such as 25%); wherein, in the process of the electronic device driving the motor to work, the electronic device can obtain the bus voltage collected by the voltage sampling circuit, such as 220V, and determine the preset current threshold value according to the bus voltage, such as 1796; the electronic device can also obtain the response current collected by the current sampling circuit, such as 1900. Among them, the electronic device can determine the rotor position of the motor based on the relationship between the preset current value and the response current. For example, if the response current is greater than the preset current threshold, the rotor position of the motor is determined to be position one; if the response current is less than or equal to the preset current threshold, the rotor position of the motor is determined to be position two. Among them, since 1900 (response current)>1796 (preset current threshold), the rotor position of the motor is determined to be position one.
[0093] It can be understood that in this embodiment, when the electronic device starts the motor, it compares the response current with the preset current threshold based on the response current fed back during the motor driving process and the preset current threshold determined according to the bus voltage during the motor driving process, determines the rotor position of the current motor when it starts, and performs subsequent control operations based on the rotor position. By accurately identifying the rotor position when the motor starts, the problem of the motor starting dead point is effectively avoided, thereby improving the reliability of the electronic device's control over the motor.
[0094] A motor control method provided in an embodiment of the present application obtains the bus voltage of the driving motor collected by the voltage sampling circuit and the response current of the motor collected by the current sampling circuit during the operation of the motor; determines the rotor position of the motor according to the bus voltage and the response current, and controls the rotation of the motor according to the rotor position, and then determines the initial rotor position of the motor by the bus voltage of the driving motor and the response current of the motor, and controls the rotation of the motor based on the rotor position, controls the operation of the motor while accurately identifying the rotor position of the motor, and improves the reliability of controlling the motor.
[0095] See also Fig.10 , Fig.10 The flow chart of the motor control method provided by an embodiment of the present application is shown in FIG. The method is applied to the electronic device including the motor control device. Fig.10 The process shown is described in detail, and the motor control method may specifically include the following steps:
[0096] Step S210: During the operation of the motor, the bus voltage for driving the motor to operate is acquired by the voltage sampling circuit, and the response current of the motor to operate is acquired by the current sampling circuit.
[0097] For the specific description of step S210, please refer to the specific description of step S110 above, which will not be repeated here.
[0098] Step S220: determining a target current corresponding to the bus voltage based on a preset corresponding relationship, wherein the preset corresponding relationship includes a corresponding relationship between a plurality of preset voltages and a plurality of preset currents.
[0099] In some embodiments, a preset correspondence may be pre-set in the electronic device, wherein the preset correspondence includes a correspondence between a plurality of preset voltages and a plurality of preset currents. Optionally, the correspondence between a plurality of preset voltages and a plurality of preset currents may include a mapping relationship table between a plurality of preset voltages and a plurality of preset currents, or may include a calculation formula for a plurality of preset voltages and a plurality of preset currents, etc., which is not limited here. Exemplarily, the correspondence between a plurality of preset voltages and a plurality of preset currents is a mapping relationship table between a plurality of preset voltages and a plurality of preset currents, wherein the correspondence between each preset voltage and each preset current in the mapping relationship table may be set with a voltage value of 5V as a step.
[0100] In some embodiments, after obtaining the bus voltage, the electronic device may determine the target current corresponding to the bus voltage based on a preset correspondence relationship, wherein the electronic device may obtain a preset current corresponding to a preset voltage equal to the bus voltage from the preset correspondence relationship as the target current.
[0101] Optionally, the electronic device may obtain, from a preset corresponding relationship, a preset current corresponding to a preset voltage having a minimum difference with the bus voltage as the target current.
[0102] Step S230: determining the rotor position of the motor based on the magnitude relationship between the target current and the response current.
[0103] In some implementations, after the electronic device obtains the target current and the response current of the motor, it can determine the rotor position of the motor based on the magnitude relationship between the target current and the response current.
[0104] Optionally, the electronic device determines the rotor position of the motor based on the magnitude relationship between the target current and the response current, which may include: if the difference between the target current and the response current is determined to be within a first range based on the magnitude relationship, then the rotor position of the motor can be determined to be a first position; or if the difference between the target current and the response current is determined to be within a second range based on the magnitude relationship, then the rotor position of the motor can be determined to be a second position, wherein the first range and the second range may be different, and the first position is different from the second position.
[0105] For example, see Figure 1 and Figure 5 The motor is a single-phase brushless motor including a pair of poles of the motor rotor, and the rotor position is position one or position two in the static state. Wherein, the electronic device determines the rotor position of the motor when it starts, which can be based on the different motor current responses, that is, the motor salient polarity, to conduct the current of the preset duty cycle to any phase of the motor, and combine the response current sampled by the current sampling circuit and the bus voltage sampled by the voltage sampling circuit to determine the rotor position of the motor at the current startup. Wherein, the electronic device can determine the energy of the current mains input motor based on the bus voltage sampled by the voltage sampling circuit; wherein, the electronic device can determine the current with a preset duty cycle of 25% and a current direction of the motor U—>V (MOS1 and MOS are turned on) based on the parameters of the motor. Wherein, the electronic device can determine the target current corresponding to the bus voltage according to the bus voltage and the preset corresponding relationship. Wherein, the electronic device can compare the target current with the response current, such as the response current is 1900, and the target current corresponding to the bus voltage 220V is 1796, where 1900>1796, and then determine that the rotor position of the motor is position one.
[0106] In some embodiments, the motor may include an n-pole motor rotor, and there are 2n possible initial rotor positions of the corresponding motor in a stationary state. Accordingly, the electronic device may obtain the bus voltage to determine the target current, and after obtaining the response current, calculate the difference between the target current and the response current; if the difference between the target current and the response current is within the first range, the rotor position of the motor may be determined to be the first position; or if the difference between the target current and the response current is determined to be within the second range based on the magnitude relationship, the rotor position of the motor may be determined to be the second position, wherein the first range and the second range may be different, and the first position and the second position may be different.
[0107] It can be understood that if the difference between the target current and the response current is within a third range, the rotor position of the motor can be determined to be a third position, wherein the third range may be different from the first range and the second range, and the third position is different from the first position and the second position.
[0108] Step S240: controlling the motor to rotate according to the rotor position.
[0109] For the specific description of step S240, please refer to the specific description of step S140 above, which will not be repeated here.
[0110] Compared with the motor control method provided in one embodiment of the present application, Fig. 9 The motor control method shown in this embodiment can also determine the target current corresponding to the bus voltage based on a preset corresponding relationship, wherein the preset corresponding relationship includes a correspondence between multiple preset voltages and multiple preset currents, and based on the magnitude relationship between the target current and the response current, determine the rotor of the motor, and then accurately determine the rotor position when the motor starts in combination with the magnitude relationship between the target current corresponding to the bus voltage and the response current, and control the motor to rotate under this rotor position, thereby improving the reliability of controlling the motor.
[0111] See also Fig.11 , Fig.11 The flow chart of the motor control method provided by an embodiment of the present application is shown in FIG. The method is applied to the electronic device including the motor control device. Fig.11 The process shown is described in detail, and the motor control method may specifically include the following steps:
[0112] Step S310: receiving a driving instruction, wherein the driving instruction carries a driving duration and a driving duty cycle.
[0113] In some embodiments, the electronic device may receive a driving instruction input by a user, wherein the driving instruction may carry a driving duration and a driving duty ratio of a current during operation of the driving motor. Optionally, after receiving the driving instruction input by the user, the electronic device may determine that the motor needs to be controlled to start and operate, and the electronic device may perform subsequent control of the motor based on the driving duration and the driving duty ratio of the current during operation of the driving motor.
[0114] Step S320: driving the motor to operate based on the driving duration and the driving duty cycle.
[0115] In some embodiments, after receiving the driving instruction, the electronic device can parse the driving instruction to obtain the driving duration and driving duty cycle carried by the driving instruction. The electronic device can drive the motor to work based on the driving duration and the driving duty cycle. Exemplarily, the driving duration carried by the driving instruction is 10 milliseconds and the driving duty cycle is 25%; the electronic device can control the motor to work briefly for 10 milliseconds when starting the motor, and output a pulse cycle of current to drive the motor to work based on the driving duty cycle of 25% to energize the motor and drive the motor to work.
[0116] Step S330: During the operation of the motor, the bus voltage collected by the voltage sampling circuit for driving the motor to operate is obtained.
[0117] For the specific description of step S330, please refer to the specific description of step S110 above, which will not be repeated here.
[0118] Step S340: during the operation of the motor, the current collected by the current sampling circuit is obtained in the high level interval of the driving duty cycle as the response current.
[0119] The electronic device can obtain the current collected by the current sampling circuit as the response current in the high level interval of the driving duty cycle of the corresponding current during the operation of the motor. Exemplarily, the electronic device can trigger the current sampling circuit to sample the response current in the high level interval corresponding to the driving duty cycle.
[0120] In some embodiments, the driving instruction may further include a current direction, wherein the current direction may include a first current direction flowing through a first resistor and a second resistor in series included in a driving circuit of the motor or a second current direction flowing through a first resistor and a second resistor in parallel included in the driving circuit of the motor. After receiving the driving instruction, the electronic device may parse the driving instruction to obtain the current direction, and control the conduction of the driving circuit of the motor based on the current direction.
[0121] For example, see Figure 5 , wherein the first resistor included in the motor drive circuit may include Figure 5 The resistor R16 shown, the second resistor may include Figure 5 The first current direction flowing through the first resistor and the second resistor connected in series in the motor driving circuit can be understood as Figure 5 After MOS1 and MOS4 are turned on, the current flows through the motor in the direction of U->V; the second current direction flowing through the first resistor and the second resistor in parallel in the motor drive circuit can be understood as Figure 5 After MOS2 and MOS3 are turned on, the current flows through the motor in the direction of V->U.
[0122] Among them, the current sampling circuit may include a first current sampling circuit and a second current sampling circuit. Accordingly, the electronic device may obtain the response current of the motor operation collected by the current sampling circuit, and if the electronic device determines that the current direction is the first current direction, it may obtain the first current corresponding to the first resistor collected by the first current sampling circuit or obtain the second current corresponding to the first resistor and the second resistor collected by the second current sampling circuit as the response current. It can be understood that under the first current direction, the first resistor is connected in series with the second resistor, and the current of the corresponding first resistor is equal to the current of the first resistor and the second resistor.
[0123] Correspondingly, the electronic device may obtain the response current of the motor operation collected by the current sampling circuit. If the electronic device determines that the current direction is the second current direction, the first current corresponding to the first resistor collected by the first current sampling circuit may be obtained as the response current.
[0124] Step S350: determining the rotor position of the motor according to the bus voltage and the response current, and controlling the rotation of the motor according to the rotor position.
[0125] For the specific description of step S350, please refer to the specific description of step S110 above, which will not be repeated here.
[0126] Compared with the motor control method provided in one embodiment of the present application, Fig. 9 The motor control method shown in this embodiment can also receive a drive instruction, which carries a drive duration and a drive duty cycle. The motor is driven based on the drive duration and the drive duty cycle. During the operation of the motor, the current collected by the current sampling circuit is obtained in the high level interval of the drive duty cycle as the response current, thereby improving the accuracy of determining the rotor position when the motor starts and improving the reliability of motor control.
[0127] See also Fig.12 , Fig.12 The module block diagram of the motor control device provided by an embodiment of the present application is shown. The motor control device 200 is applied to the electronic device provided by an embodiment of the present application. Fig.12 The process shown in the figure is described in detail, the motor control device 200 includes: a bus voltage and response current acquisition module 210 and a motor rotation control module 220, wherein:
[0128] The bus voltage and response current acquisition module 210 is used to acquire the bus voltage for driving the motor to work acquired by the voltage sampling circuit and acquire the response current of the motor to work acquired by the current sampling circuit during the operation of the motor.
[0129] The motor rotation control module 220 is used to determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position.
[0130] Further, the motor rotation control module 220 may include: a target current determination unit, a rotor position determination unit and a motor rotation control subunit, wherein:
[0131] The target current determination unit is used to determine the target current corresponding to the bus voltage based on a preset corresponding relationship, wherein the preset corresponding relationship includes a corresponding relationship between multiple preset voltages and multiple preset currents.
[0132] The rotor position determination unit is used to determine the rotor position of the motor based on the magnitude relationship between the target current and the response current.
[0133] The motor rotation control subunit is used to control the rotation of the motor according to the rotor position.
[0134] Further, the motor control device 210 may include: a first position determination unit or a second position determination unit, wherein:
[0135] The first position determining unit is configured to determine that the rotor position of the motor is a first position if it is determined based on the magnitude relationship that the difference between the target current and the response current is within a first range.
[0136] A second position determination unit is used to determine that the rotor position of the motor is a second position if the difference between the target current and the response current is determined to be within a second range based on the magnitude relationship, wherein the first range is different from the second range, and the first position is different from the second position.
[0137] Furthermore, during the operation of the motor, before obtaining the bus voltage collected by the voltage sampling circuit to drive the motor to operate and obtaining the response current of the motor to operate collected by the current sampling circuit, the motor control device 200 may further include: a drive instruction receiving module and a pre-drive module, wherein:
[0138] The driving instruction receiving module is used to receive the driving instruction, wherein the driving instruction carries the driving duration and the driving duty cycle.
[0139] A pre-driving module is used to drive the motor to work based on the driving duration and the driving duty cycle.
[0140] Furthermore, the bus voltage and response current acquisition module 210 may include: a response current acquisition subunit, wherein:
[0141] The response current acquisition subunit is used to acquire the current collected by the current sampling circuit in the high level interval of the driving duty cycle as the response current.
[0142] Further, the driving instruction also includes a current direction, wherein the current direction includes a first current direction flowing through a first resistor and a second resistor in series included in the driving circuit of the motor or a second current direction flowing through a first resistor and a second resistor in parallel included in the driving circuit of the motor, the current sampling circuit includes a first current sampling circuit and a second current sampling circuit, and the bus voltage and response current acquisition module 210 may also include: a first response current acquisition unit or a second response current acquisition unit, wherein:
[0143] A first response current acquisition unit is used to acquire the first current corresponding to the first resistor acquired by the first current sampling circuit or to acquire the second current corresponding to the first resistor and the second resistor acquired by the second current sampling circuit as the response current if the current direction is the first current direction.
[0144] A second response current acquisition unit is configured to acquire, if the current direction is the second current direction, a first current corresponding to the first resistor collected by the first current sampling circuit as the response current.
[0145] 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.
[0146] In several embodiments provided in the present application, the coupling between modules may be electrical, mechanical or other forms of coupling.
[0147] In addition, each functional module in each embodiment of the present application can be integrated into a processing 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.
[0148] See also Fig.13 , which shows a structural block diagram of an electronic device provided in an embodiment of the present application. The electronic device 100 may be an electronic device such as an exhaust fan, a washing machine, a hair dryer, etc. that can run an application. The electronic device 100 in the present application may include: a motor 110, a processor 120, a memory 130, and one or more applications. Among them, one or more applications may be stored in the memory 130 and configured to be executed by one or more processors 120, and one or more programs are configured to execute the method described in the aforementioned method embodiment.
[0149] The processor 120 may include one or more processing cores. The processor 120 uses various interfaces and lines to connect various parts of the entire electronic device 100, and executes various functions and processes data of the electronic device 100 by running or executing instructions, programs, code sets or instruction sets stored in the memory 130, and calling data stored in the memory 130. Optionally, the processor 120 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 120 can integrate one or a combination of a central processing unit (CPU), a graphics processing unit (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 the content to be displayed; 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 120, but may be implemented separately through a communication chip.
[0150] In some embodiments, the processor 120 may include a main control chip 103, which can obtain the bus voltage of the driving motor 110 collected by the voltage sampling circuit and the response current of the motor 110 collected by the current sampling circuit during the operation of the motor 110; determine the rotor position of the motor 110 based on the bus voltage and the response current, and control the rotation of the motor 110 based on the rotor position.
[0151] The memory 130 may include a random access memory (RAM) or a read-only memory (ROM). The memory 130 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 130 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 following various method embodiments, etc. The data storage area may also store data (such as audio data, temperature data, time data) created by the electronic device 100 during use.
[0152] See also Fig.14, which shows a structural block diagram of a computer-readable storage medium provided in an embodiment of the present application. The computer-readable medium 300 stores program codes, which can be called by a processor to execute the method described in the above method embodiment.
[0153] The computer readable storage medium 300 can be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read-only memory), an EPROM, a hard disk, or a ROM. Optionally, the computer readable storage medium 300 includes a non-transitory computer-readable storage medium. The computer readable storage medium 300 has storage space for program codes 310 that perform any method steps in the above method. These program codes can be read from or written to one or more computer program products. The program code 310 can be compressed, for example, in an appropriate form.
[0154] In summary, the motor control device, motor control method, device and electronic device provided in the embodiments of the present application obtain the bus voltage of the driving motor collected by the voltage sampling circuit and the response current of the motor collected by the current sampling circuit during the operation of the motor; determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position, and then determine the initial rotor position of the motor by the bus voltage of the driving motor and the response current of the motor, and control the rotation of the motor based on the rotor position, control the operation of the motor while accurately identifying the rotor position of the motor, and improve the reliability of controlling the motor.
[0155] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A motor control device, characterized in that: The motor control device comprises: A voltage sampling circuit, wherein the voltage sampling circuit is used to be connected to the motor and to collect a bus voltage that drives the motor to work during the operation of the motor; A current sampling circuit, the current sampling circuit is used to be connected to the motor and collect the response current of the motor when the motor is working; A main control chip, wherein the main control chip is connected to the voltage sampling circuit and the current sampling circuit respectively, and is used to determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position.
2. The motor control device according to claim 1, characterized in that: The input end of the voltage sampling circuit is connected to the input end of the driving circuit of the motor, and the output end of the voltage sampling circuit is connected to the main control chip.
3. The motor control device according to claim 1, characterized in that: The current sampling circuit comprises a first current sampling circuit: The first end of the first current sampling circuit is used to be connected to the input end of the first resistor included in the driving circuit of the motor, the second end of the first current sampling circuit is used to be grounded, the third end of the first current sampling circuit is used to be connected to the main control chip, and the first current sampling circuit is used to collect a first current corresponding to the first resistor.
4. The motor control device according to claim 3, characterized in that: The current sampling circuit also includes a second current sampling circuit: The first end of the second current sampling circuit is used to connect to the first end of the second resistor included in the driving circuit, the second end of the second current sampling circuit is used to connect to the input end of the first resistor included in the driving circuit, the third end of the second current sampling circuit is used to connect to the main control chip, and the second current sampling circuit is used to collect a second current corresponding to the first resistor and the second resistor, wherein the first resistor is connected in series with the second resistor.
5. A motor control method, characterized in that: Applied to the motor control device according to any one of claims 1 to 4, the method comprises: During the operation of the motor, the bus voltage for driving the motor to operate is acquired by the voltage sampling circuit, and the response current of the motor to operate is acquired by the current sampling circuit; The rotor position of the motor is determined according to the bus voltage and the response current, and the rotation of the motor is controlled according to the rotor position.
6. The method according to claim 5, characterized in that Determining the rotor position of the motor according to the bus voltage and the response current, and controlling the rotation of the motor according to the rotor position, comprises: Determining a target current corresponding to the bus voltage based on a preset corresponding relationship, wherein the preset corresponding relationship includes a corresponding relationship between a plurality of preset voltages and a plurality of preset currents; Determining a rotor position of the motor based on a magnitude relationship between the target current and the response current; The motor is controlled to rotate according to the rotor position.
7. The method according to claim 6, characterized in that The determining the rotor position of the motor based on the magnitude relationship between the target current and the response current includes: If it is determined based on the magnitude relationship that the difference between the target current and the response current is within a first range, then the rotor position of the motor is determined to be a first position; or If it is determined based on the magnitude relationship that the difference between the target current and the response current is within a second range, the rotor position of the motor is determined to be a second position, wherein the first range is different from the second range, and the first position is different from the second position.
8. The method according to claim 5, characterized in that In the process of the motor working, before obtaining the bus voltage collected by the voltage sampling circuit to drive the motor working and obtaining the response current of the motor working collected by the current sampling circuit, the method further includes: Receive a driving instruction, wherein the driving instruction carries a driving duration and a driving duty cycle; The motor is driven to operate based on the driving duration and the driving duty cycle.
9. The method according to claim 8, characterized in that The step of obtaining the response current of the motor collected by the current sampling circuit includes: The current collected by the current sampling circuit is obtained in the high level interval of the driving duty cycle as the response current.
10. The method according to claim 8, characterized in that The driving instruction also includes a current direction, wherein the current direction includes a first current direction flowing through a first resistor and a second resistor connected in series included in a driving circuit of the motor or a second current direction flowing through a first resistor and a second resistor connected in parallel included in the driving circuit of the motor, the current sampling circuit includes a first current sampling circuit and a second current sampling circuit, and obtaining a response current of the motor collected by the current sampling circuit includes: If the current direction is the first current direction, obtaining a first current corresponding to the first resistor collected by the first current sampling circuit or obtaining a second current corresponding to the first resistor and the second resistor collected by the second current sampling circuit as the response current; or If the current direction is the second current direction, the first current corresponding to the first resistor collected by the first current sampling circuit is obtained as the response current.
11. A motor control device, characterized in that: Applicable to the motor control device according to any one of claims 1 to 4, the device comprising: A bus voltage and response current acquisition module, used to acquire the bus voltage for driving the motor to work acquired by the voltage sampling circuit, and acquire the response current of the motor to work acquired by the current sampling circuit during the operation of the motor; The motor rotation control module is used to determine the rotor position of the motor according to the bus voltage and the response current, and control the rotation of the motor according to the rotor position.
12. An electronic device, characterized in that: include: Motor; one or more processors; Memory; One or more application programs, wherein the one or more application programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the method according to any one of claims 5 to 10.
13. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores program codes, which can be called by a processor to execute the method according to any one of claims 5 to 10.
